38.8.1.1 Reading a Receive Message Object

Before reading a receive message object, the application must ensure that the RX FIFO is not empty by reading the CxFIFOSTAy register. The RX FIFO is not empty if TFNRFNIF is set.

The RX FIFO user address (CxFIFOUAy) points to the RAM of the next receive message object to read. R0 of the receive message object is read first, followed by R1, R2 and so on.

After the receive message object is read from RAM, the RX FIFO needs to be incremented by setting the UINC bit (CxFIFOCONy[8]). This will make the CAN Protocol module increment to the tail of the FIFO and update CxFIFOUAy.

Now the application can read the next message from the RX FIFO.

Table 38-8. Receive Message Object
ByteBit 7Bit 6Bit 5Bit 4Bit 3Bit 2Bit 1Bit 0
0SID[7:0]
1EID[4:0]SID[10:8]
2EID[12:5]
3---EID[17:13]
4FILHIT[4:0]--ESI
5--RTRIDEDLC[3:0]
6--------
7--------
8Receive Data Byte 0
9Receive Data Byte 1
10Receive Data Byte 2
11Receive Data Byte 3
12Receive Data Byte 4
13Receive Data Byte 5
14Receive Data Byte 6
15Receive Data Byte 7
…………………………………………………………………………………………………………………………………………………
m-3Receive Data Byte n-3
m-2Receive Data Byte n-2
m-1Receive Data Byte n-1
mReceive Data Byte n

SID[10:0]: Standard Identifier bits

EID[17:0]: Extended Identifier bits

RTR: Remote Transmission Request bit

IDE: Identifier Extension bit - distinguishes between base and extended format.

DLC[3:0]: Data Length Code bits

RXMSGTS[31:0]: Receive Message Timestamp bits

Note:
  1. Receive Message Object: Data Bytes 0-n; payload size is configured individually with the PLSIZE[2:0] bits.
  2. RXMSGTSx only exists in objects where RXTSEN is set.