
CHAPTER 19 CAN CONTROLLER
User’s Manual U16541EJ4V0UD
714
(4) Error state
(a) Types of error states
The following three types of error states are defined by the CAN specification.
Error active
Error passive
Bus-off
These types of error states are classified by the values of the C0ERC.TEC7 to C0ERC.TEC0 bits
(transmission error counter bits) and the C0ERC.REC6 to C0ERC.REC0 bits (reception error counter bits)
as shown in Table 19-13.
The present error state is indicated by the C0INFO register.
When each error counter value becomes equal to or greater than the error warning level (96), the
C0INFO.TECS0 or C0INFO.RECS0 bit is set to 1. In this case, the bus state must be tested because it is
considered that the bus has a serious fault. An error counter value of 128 or more indicates an error
passive state and the TECS1 or RECS1 bit is set to 1.
If the value of the transmission error counter is greater than or equal to 256 (actually, the transmission
error counter does not indicate a value greater than or equal to 256), the bus-off state is reached and
the C0INFO.BOFF bit is set to 1.
If only one node is active on the bus at startup (i.e., when the bus is connected only to the local station),
ACK is not returned even if data is transmitted. Consequently, re-transmission of the error frame and
data is repeated. In the error passive state, however, the transmission error counter is not incremented
and the bus-off state is not reached.
Table 19-13. Types of Error States
Type
Operation
Value of Error
Counter
Indication of C0INFO
Register
Operation Specific to Error State
Transmission
0 to 95
TECS1, TECS0 = 00
Reception
0 to 95
RECS1, RECS0 = 00
Transmission
96 to 127
TECS1, TECS0 = 01
Error active
Reception
96 to 127
RECS1, RECS0 = 01
Outputs an active error flag (6 consecutive dominant-
level bits) on detection of the error.
Transmission
128 to 255
TECS1, TECS0 = 11
Error passive
Reception
128 or more
RECS1, RECS0 = 11
Outputs a passive error flag (6 consecutive
recessive-level bits) on detection of the error.
Transmits 8 recessive-level bits, in between
transmissions, following an intermission (suspend
transmission).
Bus-off
Transmission
256 or more
(not indicated)
Note
BOFF = 1,
TECS1, TECS0 = 11
Communication is not possible.
When the frame is received, no messages are stored
and the following operations are performed.
<1> TSOUT toggles.
<2> REC is incremented/decremented.
<3> VALID bit is set.
If the initialization mode is set and then 11 recessive-
level bits are generated 128 times in a row in an
operation mode other than the initialization mode,
the error counter is reset to 0 and the error active
state can be restored.
Note
The value of the transmit error counter (TEC) does not carry any meaning if BOFF has been set. If an error
that increments the value of the transmission error counter by 8 while the counter value is in a range of 248 to
255 occurs, the counter is not incremented and the bus-off state is assumed.