CAN Data Bus Fault Recognition
Faults can result in errors during data transmission. Such transmission faults must be recognized and rectified. In the CAN protocol a distinction is made between two levels of fault recognition:
- Mechanisms at the data frame level
- Mechanisms at the bit level
Mechanisms at the data frame level
Cyclic-Redundancy-Check:
The transmitter calculates test bits from the message to be transmitted which are transmitted at the same time in the CRC field of the data telegram. The receiver recalculates these test bits from the data received and compares them with the test bits received.
Frame check:
This mechanism checks the structure of the frame transmitted, the bit fields being checked with the specified fixed format and the frame length also being checked. Faults recognized by frame checks are designated as format faults.
Bit level mechanisms
Monitoring:
Each station monitors the bus level during transmission and in the process recognizes differences between the transmitted and received bit. Bit faults which occur globally and locally at the transmitter can thus be recognized with certainty.
Bit stuffing:
A maximum of 5 sequential bits may have the same polarity between start of frame and the end of the CRC field in each data telegram. After 5 identical bits in sequence the transmitter inserts a bit of opposite polarity in the flow of bits. The receivers remove these bits again after the message is received.
Dealing with faults
If any station recognizes a fault on the CAN bus, it interrupts the running transmission by transmitting fault messages consisting of 6 dominants bits.
The fault message notifies all connected control modules of a local fault and they then ignore the transmitted message.
After a short pause all control units can transmit again the message with the highest priority again going first The control module whose message caused the fault also starts to transmit its message again (Automatic Repeat Request)