![NXP Semiconductors freescale KV4 Series Reference Manual Download Page 1130](http://html1.mh-extra.com/html/nxp-semiconductors/freescale-kv4-series/freescale-kv4-series_reference-manual_17217891130.webp)
Before proceeding with the functional description, an important concept must be
explained. A Message Buffer is said to be "active" at a given time if it can participate in
both the Matching and Arbitration processes. An Rx MB with a 0b0000 code is inactive
(refer to
). Similarly, a Tx MB with a 0b1000 or 0b1001 code is also
43.5.1 Transmit process
To transmit a CAN frame, the CPU must prepare a Message Buffer for transmission by
executing the following procedure:
1. Check whether the respective interrupt bit is set and clear it.
2. If the MB is active (transmission pending), write the ABORT code (0b1001) to the
CODE field of the Control and Status word to request an abortion of the
transmission. Wait for the corresponding IFLAG bit to be asserted by polling the
CAN_IFLAG register or by the interrupt request if enabled by the respective IMASK
bit. Then read back the CODE field to check if the transmission was aborted or
transmitted (see
). If backwards compatibility is
desired (CAN_MCR[AEN] bit is negated), just write the INACTIVE code (0b1000)
to the CODE field to inactivate the MB but then the pending frame may be
transmitted without notification (see
3. Write the ID word.
4. Write the data bytes.
5. Write the DLC, Control, and CODE fields of the Control and Status word to activate
the MB.
When the MB is activated, it participates in the arbitration process and is eventually
transmitted according to its priority.
At the end of the successful transmission, the value of the Free Running Timer is written
into the Time Stamp field, the CODE field in the Control and Status word is updated, the
CRC Register is updated, a status flag is set in the Interrupt Flag Register and an interrupt
is generated if allowed by the corresponding Interrupt Mask Register bit. The new CODE
field after transmission depends on the code that was used to activate the MB (see
).
Functional description
KV4x Reference Manual, Rev. 2, 02/2015
1130
Preliminary
Freescale Semiconductor, Inc.
Summary of Contents for freescale KV4 Series
Page 2: ...KV4x Reference Manual Rev 2 02 2015 2 Preliminary Freescale Semiconductor Inc...
Page 60: ...KV4x Reference Manual Rev 2 02 2015 60 Preliminary Freescale Semiconductor Inc...
Page 128: ...Debug Security KV4x Reference Manual Rev 2 02 2015 128 Preliminary Freescale Semiconductor Inc...
Page 138: ...Boot KV4x Reference Manual Rev 2 02 2015 138 Preliminary Freescale Semiconductor Inc...
Page 1358: ...KV4x Reference Manual Rev 2 02 2015 1358 Preliminary Freescale Semiconductor Inc...