496
CHAPTER 21 CAN CONTROLLER
21.9 Procedure for Transmission by Message Buffer (x)
After setting the bit timing, frame format, ID, and acceptance filter, set BVALx to 1 to
activate the message buffer (x).
■ Procedure for Transmission by Message Buffer (x)
●
Setting transmit data length code
Set the transmit data length code (byte count) to DLC3 to DLC0 of the DLC register (DLCRx).
For data frame transmission (when TRTRx of the transmission RTR register (TRTRR) is 0), set the data
length of the transmitted message.
For remote frame transmission (when TRTRx = 1), set the data length (byte count) of the requested
message.
Note:
Setting other than 0000
B
to 1000
B
(0 to 8 bytes) is prohibited.
●
Setting transmit data (only for transmission of data frame)
For data frame transmission (when TRTRx of the transmission register (TRTRR) is 0), set data as the count
of byte transmitted in the data register (DTRx).
Note:
Transmit data should be rewritten while the TREQx bit of the transmission request register (TREQR)
set to 0. There is no need for setting the BVALx bit of the message buffer valid register (BVALR) to 0.
Setting the BVALx bit to 0 may cause incoming remote frame to be lost.
●
Setting transmission RTR register
For data frame transmission, set TRTRx of the transmission RTR register (TRTRR) to 0.
For remote frame transmission, set TRTRx to 1.