
50.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 abort of the transmission.
3. 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.
4. Read back the CODE field to check if the transmission was aborted or transmitted
5. Clear the corresponding interrupt flag.
6. Write the ID register (containing the local priority if enabled via MCR[LPRIO_EN]).
7. Write payload data bytes.
8. Configure the Control and Status word with the desired configuration.
a. Set ID type via MB_CS[IDE].
b. Set Remote Transmission Request (if needed) via MB_CS[RTR].
c. Set Data Length Code in bytes via MB_CS[DLC]. See
information.
d. Activate the message buffer to transmit the CAN frame by setting
MB_CS[CODE] to 0xC.
NOTE
It is strongly recommended that all the fields in MB_CS word
be configured in only one 32-bit write operation to maximize
software performance. If the fields are configured in separate
writes, the MB_CS[CODE] must be the last write in the C/S
word.
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.
• A status flag is set in the Interrupt Flag register.
• 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
Kinetis KE1xF Sub-Family Reference Manual, Rev. 4, 06/2019
1434
NXP Semiconductors
Summary of Contents for KE1xF Series
Page 2: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 2 NXP Semiconductors...
Page 138: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 138 NXP Semiconductors...
Page 360: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 360 NXP Semiconductors...
Page 490: ...Interrupts Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 490 NXP Semiconductors...
Page 562: ...Boot Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 562 NXP Semiconductors...
Page 706: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 706 NXP Semiconductors...
Page 736: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 736 NXP Semiconductors...
Page 866: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 866 NXP Semiconductors...
Page 1164: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1164 NXP Semiconductors...
Page 1178: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1178 NXP Semiconductors...
Page 1380: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1380 NXP Semiconductors...
Page 1472: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1472 NXP Semiconductors...
Page 1482: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1482 NXP Semiconductors...