![background image](http://html1.mh-extra.com/html/nec/v850e-dx3/v850e-dx3_preliminary-users-manual_4115960721.webp)
721
CAN Controller (CAN)
Chapter 19
Preliminary User’s Manual U17566EE1V2UM00
19.11 Message Transmission
19.11.1
Message transmission
In all the operation modes, if the CnMCTRLm.TRQ bit is set to 1 in a message
buffer that satisfies the following conditions, the message buffer that is to
transmit a message is searched.
• Used as a message buffer
(CnMCONFm.MA0 bit set to 1.)
• Set as a transmit message buffer
(CnMCONFm.MT2 to CnMCONFm.MT0 bits set to 000B.)
• Ready for transmission
(CnMCTRLm.RDY bit is set to 1.)
The CAN system is a multi-master communication system. In a system like
this, the priority of message transmission is determined based on message
identifiers (IDs). To facilitate transmission processing by software when there
are several messages awaiting transmission, the CAN module uses hardware
to check the ID of the message with the highest priority and automatically
identifies that message. This eliminates the need for software-based priority
control.
Transmission priority is controlled by the identifier (ID).
Figure 19-29
Message processing example
After the transmit message search, the transmit message with the highest
priority of the transmit message buffers that have a pending transmission
request (message buffers with the TRQ bit set to 1 in advance) is transmitted.
If a new transmission request is set, the transmit message buffer with the new
transmission request is compared with the transmit message buffer with a
pending transmission request. If the new transmission request has a higher
priority, it is transmitted, unless transmission of a message with a low priority
has already started. If transmission of a message with a low priority has
already started, however, the new transmission request is transmitted later.
The highest priority is determined according to the following rules.
Message No.
The CAN module transmits messages in the following sequence.
Message waiting to be transmitted
ID = 120H
ID = 229H
ID = 223H
ID = 023H
ID = 123H
0
1
2
3
4
5
6
7
8
9
1. Message 6
2. Message 1
3. Message 8
4. Message 5
5. Message 2
electronic components distributor