RM0046 FlexCAN
Doc ID 16912 Rev 5 537/936
Figure 263. Message buffer structure
012345678910111213141516171819202122232425262728293031
0x0 CODE
SRR
IDE
RTR
LENGTH TIME STAMP
0x4 PRIO ID (Standard/Extended) ID (Extended)
0x8 Data Byte 0 Data Byte 1 Data Byte 2 Data Byte 3
0xC Data Byte 4 Data Byte 5 Data Byte 6 Data Byte 7
= Unimplemented or Reserved
Table 267. Message Buffer structure field description
Field Description
CODE
Message Buffer Code
This 4-bit field can be accessed (read or write) by the CPU and by the Flexcan module itself, as
part of the message buffer matching and arbitration process. The encoding is shown in Table 268
and Table 269. See Section 22.4, “Functional description for additional information.
SRR
Substitute Remote Request
Fixed recessive bit, used only in extended format. It must be set to 1 by the user for transmission
(Tx Buffers) and will be stored with the value received on the CAN bus for Rx receiving buffers. It
can be received as either recessive or dominant. If FlexCAN receives this bit as dominant, then it is
interpreted as arbitration loss.
0 Dominant is not a valid value for transmission in Extended Format frames.
1 Recessive value is compulsory for transmission in Extended Format frames.
IDE
ID Extended Bit
This bit identifies whether the frame format is standard or extended.
0 Frame format is standard
1 Frame format is extended
RTR
Remote Transmission Request
This bit is used for requesting transmissions of a data frame. If FlexCAN transmits this bit as 1
(recessive) and receives it as 0 (dominant), it is interpreted as arbitration loss. If this bit is
transmitted as 0 (dominant), then if it is received as 1 (recessive), the FlexCAN module treats it as
bit error. If the value received matches the value transmitted, it is considered as a successful bit
transmission.
0 Indicates the current MB has a Data Frame to be transmitted
1 Indicates the current MB has a Remote Frame to be transmitted
LENGTH
Length of Data in Bytes
This 4-bit field is the length (in bytes) of the Rx or Tx data, which is located in offset 0x8 through
0xF of the MB space (see Ta bl e 2 63). In reception, this field is written by the FlexCAN module,
copied from the DLC (Data Length Code) field of the received frame. In transmission, this field is
written by the CPU and corresponds to the DLC field value of the frame to be transmitted. When
RTR=1, the Frame to be transmitted is a Remote Frame and does not include the data field,
regardless of the Length field.
TIME STAMP
Free-Running Counter Time Stamp
This 16-bit field is a copy of the Free-Running Timer, captured for Tx and Rx frames at the time
when the beginning of the Identifier field appears on the CAN bus.