FlexCAN Module
MCF5253 Reference Manual, Rev. 1
Freescale Semiconductor
25-25
The purpose of deactivation is data coherency. The match/arbitration process scans the MBs to decide
which MB to transmit or receive. If the CPU updates the MB in the middle of a match or arbitration
process, the data of that MB may no longer be coherent; therefore, that MB is deactivated.
Even with the coherence mechanism described above, writing to the C/S word of active MBs when not in
freeze mode may produce undesirable results. Examples are:
•
Matching and arbitration are one-pass processes. If MBs are deactivated after they are scanned, no
re-evaluation is done to determine a new match/winner. If an Rx MB with a matching ID is
deactivated during the matching process after it was scanned, then this MB is marked as invalid to
receive the frame, and FlexCAN will keep looking for another matching MB within the ones it has
not scanned yet. If it can not find one, then the message will be lost. Suppose, for example, that two
MBs have a matching ID to a received frame, and the user deactivated the first matching MB after
FlexCAN has scanned the second. The received frame will be lost even if the second matching MB
was free to receive.
•
If a Tx MB containing the lowest ID is deactivated after the FlexCAN has scanned it, then the
FlexCAN will look for another winner within the MBs that it has not yet scanned. Therefore, it may
transmit an MB that may not have the lowest ID at the time because a lower ID might be present
that it had already scanned before the deactivation.
•
There is a point in time until which the deactivation of a Tx MB causes it not to be transmitted (end
of move-out). After this point, it is transmitted, but no interrupt is issued and the CODE field is not
updated.
25.6.5.3
Locking and Releasing Message Buffers
Besides message buffer deactivation, the lock/release/busy mechanism is designed to guarantee data
coherency during the receive process. The following examples demonstrate how the lock/release/busy
mechanism will affect FlexCAN operation:
1. Reading a control/status word of a message buffer triggers a lock for that message buffer. A new
received message frame that matches the message buffer cannot be written into this message buffer
while it is locked.
2. To release a locked message buffer, the CPU either locks another message buffer (by reading its
control/status word) or globally releases any locked message buffer (by reading the free-running
timer).
3. If a receive frame with a matching ID is received during the time the message buffer is locked, the
receive frame will not be immediately transferred into that message buffer, but will remain in the
SMB. There is no indication when this occurs.
4. When a locked message buffer is released, if a frame with a matching identifier exists within the
SMB, then this frame will be transferred to the matching message buffer.
5. If two or more receive frames with matching IDs are received while a message buffer with a
matching ID is locked, the last received frame with that ID is kept within the serial message buffer,
while all preceding ones are lost. There is no indication of lost messages when this occurs.
Summary of Contents for MCF5253
Page 1: ...Document Number MCF5253RM Rev 1 08 2008 MCF5253 Reference Manual...
Page 26: ...MCF5253 Reference Manual Rev 1 xxvi Freescale Semiconductor...
Page 32: ...MCF5253 Reference Manual Rev 1 xxxii Freescale Semiconductor...
Page 46: ...MCF5253 Introduction MCF5253 Reference Manual Rev 1 1 14 Freescale Semiconductor...
Page 62: ...Signal Description MCF5253 Reference Manual Rev 1 2 16 Freescale Semiconductor...
Page 98: ...Instruction Cache MCF5253 Reference Manual Rev 1 5 10 Freescale Semiconductor...
Page 104: ...Static RAM SRAM MCF5253 Reference Manual Rev 1 6 6 Freescale Semiconductor...
Page 128: ...Synchronous DRAM Controller Module MCF5253 Reference Manual Rev 1 7 24 Freescale Semiconductor...
Page 144: ...Bus Operation MCF5253 Reference Manual Rev 1 8 16 Freescale Semiconductor...
Page 176: ...System Integration Module SIM MCF5253 Reference Manual Rev 1 9 32 Freescale Semiconductor...
Page 198: ...Analog to Digital Converter ADC MCF5253 Reference Manual Rev 1 12 6 Freescale Semiconductor...
Page 246: ...DMA Controller MCF5253 Reference Manual Rev 1 14 18 Freescale Semiconductor...
Page 282: ...UART Modules MCF5253 Reference Manual Rev 1 15 36 Freescale Semiconductor...
Page 344: ...Audio Interface Module AIM MCF5253 Reference Manual Rev 1 17 46 Freescale Semiconductor...
Page 362: ...I2 C Modules MCF5253 Reference Manual Rev 1 18 18 Freescale Semiconductor...
Page 370: ...Boot ROM MCF5253 Reference Manual Rev 1 19 8 Freescale Semiconductor...