
CHAPTER 19 CAN CONTROLLER
Preliminary User’s Manual U16541EJ1V0UM
673
<3> Mask setting for CAN module 1 (mask 1) (example)
(Using CAN1 address mask 1 registers L and H (C1MASKL1 and C1MASKH1))
CMID28
CMID27
CMID26
CMID25
CMID24
CMID23
CMID22
CMID21
CMID20
CMID19
CMID18
1
0
0101
11
1
CMID17
CMID16
CMID15
CMID14
CMID13
CMID12
CMID11
CMID10
CMID9
CMID8
CMID7
1
1111
11
1
CMID6
CMID5
CMID4
CMID3
CMID2
CMID1
CMID0
11
1
1: Do not compare (mask)
0: Compare
Values are written to mask 1, bits CMID27 to CMID24 and CMID22 = 0 and bits CMID28, CMID23, and
CMID21 to CMID0 = 1.
19.9.4
Multi buffer receive block function
Two or more receive message buffers can be grouped as a multi buffer receive block (MBRB) by setting the same
ID to two or more message buffers.
The MBRB can store two or more data frames from the CAN bus without
overwriting previously received messages. Support by the CPU is not necessary for this operation.
The user can determine which data block reception completion the CPU has to be informed of by setting the IE bit
in the C0MCTRLm register of the message buffer. If a data block consists of message k, the user could initialize the
message k buffer for the reception of the data block. In message buffers 0 to (k-1) the IE bits are cleared (0) (i.e.
interrupts disabled) and in message buffer k the IE bit is set (1) (interrupts enabled).
This kind of configuration
establishes a ring buffer that provides received messages to the CPU in a FIFO manner when the CPU reads the
messages before the MBRB overflows.
19.9.5
Remote frame reception
In the operational modes “normal operating mode”, “normal operating mode with ABT”, “receive-only mode”,
“single-shot mode” and “self-test mode” the receive message acceptance filtering machine evaluates all message
buffers that satisfy the following conditions as to whether the received remote frame should be accepted.
The message buffer has to be assigned to the CAN I/F channel (MA0 bit in C0MCONFm register is set to 1B or
larger).
The message buffer has to be configured as a transmit message buffer (MT2 to MT0 bits in C0MCONFm register
are set to 000B).
The message buffer has to be marked ready for CAN protocol processing (RDY bit set (1) in C0MCTRLm
register)
The RTR bit in the transmit message buffer has to be cleared (0).
The TRQ bit in the transmit message buffer has to be cleared (0).
Upon acceptance of a remote frame, the following actions are executed if the identifier of the received remote
frame matches the identifier of a message buffer that satisfies the above conditions.
The MDLC[3:0] bit string in the C0MDLCm register is overwritten by the DLC value of the received remote frame.
The DN flag is set (1)
The interrupt status bit CINTS1 in the C0INTS register is set (1)