Why Is My CAN in the Bus Off State?

Updated Jul 20, 2018

Reported In


  • PXI CAN Interface Module
  • C Series CAN Interface Module



Issue Details

Why does my CAN application regularly goes into the "Bus off State"?


Your CAN may be in the Bus Off State due to the number of errors you are seeing. If the "transmit error counter" is above 255, the CAN interface transitions into this state. Communication immediately stops under the assumption that the CAN interface must be isolated from other devices. When a CAN interface transitions to the bus off state, communication stops for the interface. All NI-XNET sessions for the interface no longer receive or transmit frame values. To restart the CAN interface and all its sessions, call XNET Start.vi. 

The transmit error counter begins at 0 when communication starts on the CAN interface. The counter increments when an error is detected for a transmitted frame and decrements when a frame transmits successfully. The counter increases more for an error than it is decreased for success. This ensures that the counter generally increases when a certain ratio of frames (roughly 1/8) encounter errors.

When communication state transitions to Bus Off, the transmit error counter no longer is valid.