0

It is known fact that short circuiting CAN_High and CAN_Low on a CAN bus leads to a bus off condition.

With respect to the physical layer, how does this condition lead to bus off condition?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Jagdish
  • 45
  • 2
  • 4

1 Answers1

3

CAN is a differential protocol. That means 0 or 1 (to be specific, dominant and recessive) is decided on the basis of the difference between voltages on the CANH and CANL lines.

When you short these two lines, there will not be any voltage difference and that falls under the voltage range of recessive bits. In other words, shorting two lines will be considered as a continuous transmission of recessive bits.

When you transmit 6 or more consecutive recessive bits, it is considered as an error!

And when this error count goes more than 255, the CAN controller goes into the BUS_OFF state.

As lines are shorted, there will be way more recessive bits and the error count will reach 255 in no time which will lead to BUS_OFF.

The CAN protocol does have a "bus recovery mechanism" in which it will wait for 11 consecutive recessive bits for 128 times (which it will as the bus is shorted), but again, the same error frame thing will happen, and it will be back in BUS_OFF.

This cycle will continue!

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Swanand
  • 4,027
  • 10
  • 41
  • 69
  • Hi Swanand thanks for your reply. Very good explanation. Can you please explain what happens when CANH is shorted to VBAT, CANH shorted to GND, CANL shorted to VBAT and CANL shorted to GND? – Jagdish Apr 20 '14 at 12:06
  • @user3530634 What do you think what must be happening? Give it a try! – Swanand Apr 21 '14 at 02:59
  • 1
    "When you transmit 6 or more consecutive recessive bits, it is considered as Error":: IMO this is some kind of misleading since a bus is also recessive if every node is mute. From the perspective of a sender its more like a sender is listenig to what he is saying, and if he does not hear what he wanted to say, its either a case of loosing arbitration, or one of more possible errror conditions defined by the CAN standard. – grenix Oct 22 '18 at 13:55