UM10360 All information provided in this document is subject to legal disclaimers. © NXP B.V. 2013. All rights reserved.
User manual Rev. 3 — 19 December 2013  357 of 841
NXP Semiconductors
UM10360
Chapter 16: LPC176x/5x CAN1/2
[2] If there is not enough space to store the message within the Receive Buffer, that message is dropped and the Data Overrun condition is 
signalled to the CPU in the moment this message becomes valid. If this message is not completed successfully (e.g. because of an 
error), no overrun condition is signalled.
[3] The Transmission Complete Status bit is set '0' (incomplete) whenever the Transmission Request bit or the Self Reception Request bit 
is set '1' at least for one of the three Transmit Buffers. The Transmission Complete Status bit will remain '0' until all messages are 
transmitted successfully.
[4] If both the Receive Status and the Transmit Status bits are '0' (idle), the CAN-Bus is idle. If both bits are set, the controller is waiting to 
become idle again. After hardware reset 11 consecutive recessive bits have to be detected until idle status is reached. After Bus-off this 
will take 128 times of 11 consecutive recessive bits.
[5] Errors detected during reception or transmission will effect the error counters according to the CAN specification. The Error Status bit is 
set when at least one of the error counters has reached or exceeded the Error Warning Limit. An Error Warning Interrupt is generated, if 
enabled. The default value of the Error Warning Limit after hardware reset is 96 decimal, see also Section 16.7.7 “
CAN Error Warning 
Limit register (CAN1EWL - 0x4004 4018, CAN2EWL - 0x4004 8018)”.
[6] Mode bit '1' (present) and an Error Warning Interrupt is generated, if enabled. Afterwards the Transmit Error Counter is set to '127', and 
the Receive Error Counter is cleared. It will stay in this mode until the CPU clears the Reset Mode bit. Once this is completed the CAN 
Controller will wait the minimum protocol-defined time (128 occurrences of the Bus-Free signal) counting down the Transmit Error 
Counter. After that, the Bus Status bit is cleared (Bus-On), the Error Status bit is set '0' (ok), the Error Counters are reset, and an Error 
Warning Interrupt is generated, if enabled. Reading the TX Error Counter during this time gives information about the status of the 
Bus-Off recovery.
RX error counter
The RX Error Counter Register, which is part of the Status Register, reflects the current 
value of the Receive Error Counter. After hardware reset this register is initialized to 0. In 
Operating Mode this register appears to the CPU as a read-only memory. A write access 
to this register is possible only in Reset Mode. If a Bus Off event occurs, the RX Error 
Counter is initialized to 0. As long as Bus Off is valid, writing to this register has no 
effect.The Rx Error Counter is determined as follows:
RX Error Counter = (CANxGSR AND 0x00FF0000) / 0x00010000
Note that a CPU-forced content change of the RX Error Counter is possible only if the 
Reset Mode was entered previously. An Error Status change (Status Register), an Error 
Warning or an Error Passive Interrupt forced by the new register content will not occur 
until the Reset Mode is cancelled again. 
TX error counter
The TX Error Counter Register, which is part of the Status Register, reflects the current 
value of the Transmit Error Counter. In Operating Mode this register appears to the CPU 
as a read-only memory. After hardware reset this register is initialized to 0. A write access 
to this register is possible only in Reset Mode. If a bus-off event occurs, the TX Error 
Counter is initialized to 127 to count the minimum protocol-defined time (128 occurrences 
of the Bus-Free signal). Reading the TX Error Counter during this time gives information 
about the status of the Bus-Off recovery. If Bus Off is active, a write access to TXERR in 
the range of 0 to 254 clears the Bus Off Flag and the controller will wait for one occurrence 
of 11 consecutive recessive bits (bus free) after clearing of Reset Mode. The Tx error 
counter is determined as follows:
TX Error Counter = (CANxGSR AND 0xFF000000) / 0x01000000
Writing 255 to TXERR allows initiation of a CPU-driven Bus Off event. Note that a 
CPU-forced content change of the TX Error Counter is possible only if the Reset Mode 
was entered previously. An Error or Bus Status change (Status Register), an Error 
Warning, or an Error Passive Interrupt forced by the new register content will not occur