Two Concepts

There are two checksum concepts: the classic checksum and the enhanced checksum. With the classic checksum, only the useful data is protected. With the enhanced checksum, the useful data and the PID are protected. The enhanced checksum is used for identifiers 0 to 59, effective with Version 2.0 of the protocol. To retain downward compatibility, diagnostic frames are always protected with the classic checksum.

Computation

The checksums are computed according to the following formula:

  • Checksum = INV (data byte 1 ⊕ data byte 2 ⊕ ... ⊕ data byte 8)

To form the checksum, the individual data bytes are added by modulo-256 arithmetic. This involves adding overrun bits to the specific intermediate result. Finally, the overall result is inverted, and the Slave Task transmits it as the checksum. The receiver computes the checksum for the received data bytes by the same algorithm, except for the inversion. The receiver detects a transmission error if the sum of the data bytes and the arriving checksum is not 0xFF.

Data Protection

This protection method is not particularly powerful. However, it achieves the data integrity required for use in the subbus area. This applies especially to operation with Unconditional Frames that contain few data bytes. The residual error probability rises with a growing number of data bytes.



Last modified: Tuesday, 19 May 2020, 4:14 PM