MOTOROLA
Chapter 16. CAN 2.0B Controller Module
16-11
TouCAN Architecture
16.3.4
Error Counters
The TouCAN has two error counters, the transmit (Tx) error counter and the receive (Rx)
counters. The rules for increasing and decreasing these counters are described in the CAN
protocol, and are fully implemented in the TouCAN. Each counter has the following
features:
Eight-bit up/down-counter
Increment by eight (Rx error counter also increments by one)
Decrement by one
Avoid decrement when equal to zero
Rx error counter reset to a value between 119 and 127 inclusive, when the TouCAN
transitions from error passive to error active
Following reset, both counters reset to zero
Detect values for error passive, bus off and error active transitions
Cascade usage of Tx error counter with an additional internal counter to detect the
128 occurrences of 11 consecutive recessive bits necessary to transition from bus off
into error active.
Both counters are read-only (except in test/freeze/halt modes).
The TouCAN responds to any bus state as described in the CAN protocol, transmitting an
error active or error passive flag, delaying its transmission start time (error passive) and
avoiding any influence on the bus when in the bus off state. The following are the basic
rules for TouCAN bus state transitions:
If the value of the Tx error counter or Rx error counter increments to a value greater
than or equal to 128, the fault confinement state (FCS[1:0]) field in the error status
register is updated to reflect an error passive state.
If the TouCAN is in an error passive state, and either the Tx error counter or Rx error
counter decrements to a value less than or equal to 127 while the other error counter
already satisfies this condition, the FCS[1:0] field in the error status register is
updated to reflect an error active state.
If the value of the Tx error counter increases to a value greater than 255, the
FCS[1:0] field in the error status register is updated to reflect a bus off state, and an
interrupt may be issued. The value of the Tx error counter is reset to zero.
If the TouCAN is in the bus off state, the Tx error counter and an additional internal
counter are cascaded to count 128 occurrences of 11 consecutive recessive bits on
the bus. To do this, the Tx error counter is first reset to zero, and then the internal
counter begins counting consecutive recessive bits. Each time the internal counter
counts 11 consecutive recessive bits, the Tx error counter is incremented by one and
the internal counter is reset to zero. When the Tx error counter reaches the value of