2
\$\begingroup\$

I have two nodes A and B operating on a CAN bus. I have cut the bus off and Node A reached the error passive state due to the lack of ack from Node B (because I removed the bus).

What I noticed is that the Node A shall never reach the bus off state regardless of the fact that the TEC value is constantly increasing.


My question: Is that happening because there is no actually a real bus?

\$\endgroup\$
1
  • \$\begingroup\$ I would also like to mention for future viewers my understanding that a controller can't reach the BUS_OFF state only from ACK errors. \$\endgroup\$
    – zeus2
    Jun 12 '14 at 13:27
3
\$\begingroup\$

A CAN node enters the "BUS_OFF" state when the TEC value goes above 255. But if you look at the CAN specifications carefully, it has a special condition:

On Part A - page 26 OR Part B - page 63:

Start-up / Wake-up:

If during start-up only 1 node is online, and if this node transmits some message, it will get no acknowledgment, detect an error and repeat the message. It can become ’error passive’ but not ’bus off’ due to this reason.

In your condition, when you cut the bus, node A is the only node on the bus and hence it will remain in Error Passive, but it will never go to the BUS_OFF state... That's as per design.

I believe if you are the only one node on the bus, there is no point in being in the "BUS_OFF" state; rather the node should wait for other devices to start/get connected.

\$\endgroup\$
2
  • \$\begingroup\$ But how does a node know how many nodes are connected in the bus? \$\endgroup\$
    – user51576
    Aug 19 '14 at 6:20
  • 1
    \$\begingroup\$ @Satya It doesn't matter how many nodes are present, All it requires is at least ONE node to ACK the message. If there are multiple nodes, they all will assert ACK at the same time. So, No knowledge of "Node count" is required, it should be just >1 \$\endgroup\$
    – Swanand
    Aug 19 '14 at 13:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.