![](http://datasheet.mmic.net.cn/140000/ML9620GAZ210_datasheet_5009281/ML9620GAZ210_20.png)
ML9620 User’s Manual
Chapter 2
Register Descriptions
2 – 3
2.2.2 CAN Status register (CANSTAT)
7
6
5
4
3
2
1
0
CANSTAT
BOff
EWarn
EPass
RxOK
TxOK
LEC
reset value
0
Address
: CAN Base + 0x02
Access
: R/W
BOff, EWarn, EPass is ‘R’
Access Size : 8 bits
Bit Descriptions
LEC
Last Error Code (Type of the lase error to occur on the CAN bus)
The LEC field holds a code which indicates the type of the last error to occur on the CAN bus.
This field will be cleared to ‘0’ when a message has been transferred (reception or transmission)
without error.
The unused code ‘7’ may be written by the MCU to check for updates.
0
No Error:
1
Stuff Error:
More than 5 equal bits in a sequence have occurred in a part of a received
message where this is not allowed.
2
Form Error:
A fixed format part of a received frame has the wrong format.
3
Ack Error:
The message this CAN Controller transmitted was not acknowledged by another
node.
4
Bits 1 Error:
During the transmission of a message (with the exception of the arbitration field),
the device wanted to send a
recessive level (bit of logical value ‘1’), but the
monitored bus value was
dominant.
5
Bits 0 Error:
During the transmission of a message (or acknowledge bit, or active error flag,
or overload flag), the device wanted to send a dominant level (data or identifier
bit logical value ‘0’), but the monitored Bus value was recessive.
During Busoff
recovery, this status is set each time a sequence of 11 recessive bits has been
monitored.
This enables the MCU to monitor the proceeding of the Busoff
recovery sequence (indicating the bus is not stuck at dominant or continuously
disturbed).
6
CRC Error:
The CRC check sum was incorrect in the message received, the CRC received
for an incoming message does not match with the calculated CRC for the
received data.
7
Not used:
When the LEC shows the value ‘7’, no CAN bus event was detected since the
MCU wrote this value to the LEC.