Transmit Process; Receive Process - Motorola ColdFire MCF5281 User Manual

Motorola microcontroller user's manual
Table of Contents

Advertisement

25.4.1 Transmit Process

The CPU prepares or changes an MB for transmission by executing the following steps:
• Writing the Control/Status word to hold Tx MB inactive (code = 1000).
• Writing the ID_HIGH and ID_LOW words.
• Writing the Data bytes
• Writing the Control/Status word (active Code, Length)
The first and last steps are mandatory!
Starting from the last step, this MB will participate in the internal arbitration process, which
takes place every time the CAN bus is sensed as free by the receiver or at the inter-frame
space, and there is at least one MB ready for transmission. This internal arbitration process
is intended to select the MB from which the next frame is transmitted.
When this process is over, and there is a 'winner' MB for transmission, the frame is
transferred to the serial message buffer (SMB) for transmission (Move Out).
While transmitting, the FlexCAN transmits up to eight data bytes, even if the DLC is bigger
in value.
At the end of the successful transmission, the value of the free-running timer (which was
captured at the beginning of the Identifier field on the CAN bus), is written into the "Time
Stamp" field in the MB, the Code field in the Control/Status word of the MB is updated and
a status flag is set in the IFLAG register.

25.4.2 Receive Process

The CPU prepares or changes an MB for frame reception by executing the following steps:
• Writing the control/status word to hold Rx MB inactive (code = 0000).
• Writing the ID_HIGH and ID_LOW words.
• Writing the control/status word to mark the Rx MB as active and empty.
The first and last steps are mandatory!
Starting from the last step, this MB is an active receive buffer and will participate in the
internal matching process, which takes place every time the receiver receives an error-free
frame. In this process, all active receive buffers compare their ID value to the newly
received one, and if a match occurs, the frame is transferred (Move In) to the first (that is,
lowest entry) matching MB. The value of the free-running timer (which was captured at the
beginning of the Identifier field on the CAN bus) is written into the "Time Stamp" field in
MOTOROLA
NOTE
NOTE
Chapter 25. FlexCAN
Functional Overview
25-9

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfire mcf5282

Table of Contents