Can gateway controller detect all controllers present on CAN Network?

Our PC Application is connected to Embedded Gateway Controller over USB. Gatewary controller is connected to several embedded controllers over CAN bus.

PC Application needs to know what embedded controllers are present on the CAN Network because

PC Application needs to exchange information with these embedded controllers through the Gateway Controller.

How can Gateway Controller find out which embedded controllers are present on the CAN bus?

--------------------------------------- Posted through

formatting link

Reply to
janii
Loading thread data ...

It asks.

The gateway controller sends out a poll message asking all the embedded controllers to reply. Each of the embeded controllers then sends a reply to the gateway controller identifying itself.

--
Grant Edwards               grant.b.edwards        Yow! I own seven-eighths of 
                                  at               all the artists in downtown 
 Click to see the full signature
Reply to
Grant Edwards

seven-eighths of

downtown

Thank you for the reply! Could you please describe poll message and reply message in detail?

--------------------------------------- Posted through

formatting link

Reply to
janii

There is no general answer to this question other than "It depends." CAN mostly resides in the ISO model's transfer layer. What the higher level application layer does with the packets is not specified.

Reply to
Rich Webb

If you know nothing about the network except that it's 'CAN', you could just check every address. If there is a node listnening, it should assert the ACK bit. But this can be a bit time consuming for CAN 2.0.

If you you want a better answer, you will have to know more about the network.

Integrally quoting Rich Webb: "There is no general answer to this question other than "It depends." CAN mostly resides in the ISO model's transfer layer. What the higher level application layer does with the packets is not specified."

--
Stef    (remove caps, dashes and .invalid from e-mail address to reply by mail) 

What is a magician but a practising theorist? 
 Click to see the full signature
Reply to
Stef

You're designing the system, so it's up to you to define the messages.

--
Grant Edwards               grant.b.edwards        Yow! I am a traffic light, 
                                  at               and Alan Ginzberg kidnapped 
 Click to see the full signature
Reply to
Grant Edwards

The only thing that the gateway can reliably detect, if the gateway connected to a network with at least one other powered up device. When a CAN device sends a message, every other node will listen for the bus and if _any_ node receives a message with correct CRC, it will pull down the Ack bit (no matter if the message is addressed to this node). Thus, the sending node knows, that there is at least one active node (i.e. not in Listen Only mode e.g. autobauding).

If the Ack bit remains high after transmission, the transmitter knows that there are no other stations on the bus.

However, if something is known about the protocol, for example with CanOpen, look for Node Guard messages, which will also reveal the node ID.

Reply to
upsidedown

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.