www.ti.com
eCAN Registers
807
SPRUI07–March 2020
Submit Documentation Feedback
Copyright © 2020, Texas Instruments Incorporated
Controller Area Network (CAN)
13.8.9.1 Handling of Remote Frames
If a remote frame is received (the incoming message has the RTR bit set), the CAN module compares the
identifier to all identifiers of the mailboxes using the appropriate masks starting at the highest mailbox
number in descending order.
In the case of a matching identifier (with the message object configured as send mailbox and AAM
(MSGID.29) in this message object set) this message object is marked as to be sent (TRS[n] is set).
In case of a matching identifier with the mailbox configured as a send mailbox and bit AAM in this mailbox
is not set, this message is not received in that mailbox.
After finding a matching identifier in a mailbox no further compare is done.
With a matching identifier and the message object configured as receive mailbox, this message is handled
like a data frame and the corresponding bit in the receive message pending (CANRMP) register is set.
The CPU then has to decide how to handle this situation. For information about the CANRMP register, see
Section 13.8.7.
For the CPU to change the data in a mailbox that is configured as a remote frame mailbox (AAM set) it
has to set the mailbox number and the change data request (CDR) bit [CANMC.8] first. The CPU can then
write the new data and clear the CDR bit to indicate to the eCAN that the access is finished. Until the CDR
bit is cleared, the transmission of this mailbox is not permitted. Therefore, the newest data is sent.
To change the identifier in that mailbox, the mailbox must be disabled first (CANMEn = 0).
For the CPU to request data from another node it configures the mailbox as a receive mailbox and sets
the TRS bit. In this case the module sends a remote frame request and receives the data frame in the
same mailbox that sent the request. Therefore, only one mailbox is necessary to do a remote request.
Note that the CPU must set RTR (MSGCTRL.4) to enable a remote frame transmission. Once the remote
frame is sent, the TRS bit of the mailbox is cleared by CAN. In this case, bit TAn will not be set for that
mailbox.
The behavior of the message object n is configured with CANMD[n] (CANMD.31-0), the AAM (MSGID.29),
and RTR (MSGCTRL.4). It shows how to configure a message object according to the desired behavior.
To summarize, a message object can be configured with four different behaviors:
1. A transmit message object is only able to transmit messages.
2. A receive message object is only able to receive messages.
3. A remote-request message object is able to transmit a remote request frame and to wait for the
corresponding data frame.
4. A auto-reply message object is able to transmit a data frame whenever a remote request frame is
received for the corresponding identifier.
NOTE: When a remote transmission request is successfully transmitted with a message object
configured in request mode, the CANTA register is not set and no interrupt is generated.
When the remote reply message is received, the behavior of the message object is the same
as a message object configured in receive mode.