- 1. Introduction
- 2. CAN Communication
- 3. CAN Framing
- 4. CAN Bus Access
- 5. CAN Data Protection
6. CAN FD
- Advantages and Consequences
- New Types of Frames
- Details of a CAN FD Frame
- Distinguishing CAN from CAN FD Frames
- Compatibility of CAN and CAN FD Controllers
- Accelerated Transmission
- Indicating too many Errors
- Length of the Data Field
- More Data with the same Security
- Changed Rules for Bit Stuffing and CRC Calculation
Logical Error Detection
Five mechanisms to detect an error
To detect corrupted messages, the CAN protocol defines five mechanisms:
bit monitoring, monitoring of the message format (Form Check),
monitoring of the bit coding (Stuff Check), evaluation of the
acknowledgement (ACK Check) and verifying the checksum (Cyclic
Tasks for sender and receiver
The bit monitoring and ACK check error detection mechanisms are performed by the sender. Independent of acceptance filtering, the receivers perform the form check, stuff check and cyclic redundancy check.
The figure “Error Detection” shows which fields of a data or remote
frame are affected by the individual error detection mechanisms.
The stuff check
serves to check the bit stream. The CAN protocol specifies that the
sender must transmit a complementary bit after five homogeneous bits —
for synchronization purposes. There is a stuffing error if more than
five homogeneous contiguous bits are received.
Within the framework of bit monitoring,
the sender compares the sent bit level with the actual bus level. A bit
error exists if the sender detects a discrepancy between the two
levels. Bit monitoring ensures that all global errors and all local
errors occurring at the sender are detected.
The form check
serves to check the format of a CAN message. Each CAN message always
exhibits the same bit sequences at certain positions. They are the CRC
delimiter, ACK delimiter and EOF. Senders always transmit these message
components recessively. A format error exists if a receiver detects a
dominant bus level within one of these message components in the Form
Cyclic Redundancy Check (CRC),
In the cyclic redundancy check (CRC) the
polynomial R(x) associated with the arriving data or remote frame should
equal a multiple of the generator polynomial G(x) specified by ISO
11898-1. If this is not the case (CRC error), then the data or remote
frame was corrupted during its transmission.
The acknowledgement mechanism defined in the CAN protocol specifies that all receivers must acknowledge every arriving CAN message right after the cyclic redundancy check. A single positive acknowledgement is sufficient to signal to the sender that at least one receiver received the CAN message it transmitted correctly. If not a single positive acknowledgement arrives at the sender, then an acknowledgement error has occurred (ACK error).