Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] CANopen is Master / Slave protocol ?

Status
Not open for further replies.

dhruv_electro

Advanced Member level 4
Full Member level 1
Joined
Dec 17, 2010
Messages
118
Helped
9
Reputation
18
Reaction score
8
Trophy points
1,298
Location
India
Visit site
Activity points
2,378
Hi,

We are familiar with MODBUS a lot. Now we have just started learning about CAN. System we wanted to implement is as follows:

test.jpg

We have multiple node wanted shared data. So we decided to give a try to CANOpen / J1939. Till date we have transfer various bytes over raw CAN peripheral Module in MCUs. As a learning we have gone through here:

https://www.esd-electronics-usa.com/online-seminars.html


Our Queries:
1. Pardon if we misunderstood here CANopen, Is it like CANopen is a Master / Slave protocol?
2. If yes, Is it necessary that one master should be there in CANopen network? Because we wanted to avoid Master / Slave (Query / Response)
3. Can you suggest which we should use CANopen or J1939?
4. No matter how hard we find, there is not useful material available about J1939 !!! (Do we need to pay to SAE lump-sum amount of $500 just to learn and check if J1939 is suitable for us?)
 

Hi,

Answers to your questions:
1- In CANopen, the main role of the master is to manage communication states (reset, start/stop) of each node in the network. Exchange of data is carried out using PDOs for realtime data and can be done without a master if startup conditions of nodes are set properly. Each node can produce PDOs and is capable of consuming PDOs from any other node.
2- No. Each node can send data at any time. See bus arbitration in CAN.
3- It depends on your application. But I can say that J1939 is less complex. To share data you can use any.
4- You can get specs if you do a web search. Also see the other thread for my suggestion.
https://www.edaboard.com/threads/319511/#post1366040
You can also request CANopen specs from CiA, provided at no cost.

From the SW side, you will need a few thousand lines of code to implement full featured J1939 or CANopen stack. Or you can buy from vendors such as Vector, IXXAT, ESD. There are free alternatives to have a try but may not be reliable as commercial ones.
 
Thanks for to the point reply.

Meanwhile we have gone through CANopen spects available over various sources.

2- No. Each node can send data at any time. See bus arbitration in CAN.

So how states can be changed in slave devices in slave only network? Is is possible if we use only slaves in CANopen network? Even HMI or Diagnostic Software over PC be used as slave?

Meanwhile we also gone through J1939 link you provided and found a book on amazon.

CANopen is lot more function oriented while J1939 is bit data oriented. We mean J1939 plays with CAN IDs more. Is it true?

But I can say that J1939 is less complex.

We also thought to give a try first to J1939 rather.

Or you can buy from vendors such as Vector, IXXAT, ESD.

Yes we just asked for the quotes but the prices are out of our extreme capacity.

If you are experienced person with both stacks can you suggest which stack is faster to implement? We are designing a T-ECU of an old engine. Our other threads about it is here:

https://www.edaboard.com/threads/306575/#post1355133

https://www.edaboard.com/threads/316194/#post1355132
 

If it is an automotive application, you should use J1939. Even if you are an experienced programmer, it will take at least several months to implement it. Also you must verify the operation of it for a while. If you are using Microchip products, Microchip provides a J1939 stack with limited functionality for their 8 bit MCUs. If not, you can use it as a reference. But I don't recommend you to select a 8 bit MCU for this purpose.
 
Ok we will go for J1939 for this application. We are using 32bit MCUs in this application. Yes we know that it will take too much of our resources to build it on our own. But yet we need to try. We are using microchip stack as start point.

Thank you very much for very valuable advices.
 
Last edited:

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top