
GR716-DS-UM, May 2019, Version 1.29
217
www.cobham.com/gaisler
GR716
Priority inversion is handled by disabling the transmitting channel, i.e. setting CanTxC-
TRL.ENABLE=0b as described above, and observing the progress, i.e. reading via the CanTxC-
TRL.ONGOING bit as described above. When the transmit channel is disabled, it can be re-
configured and a higher priority message can be transmitted. Note that the single shot mode does not
require the channel to be disabled, but the progress should still be observed as above.
No message transmission is started while the channel is not enabled.
25.5.8 Interrupts
During transmission several interrupts can be generated:
•
TxLoss:
Message arbitration lost for transmit (could be caused by
communications error, as indicated by other interrupts as well)
•
TxErrCntr: Error counter incremented for transmit
•
TxSync:
Synchronization message transmitted
•
Tx:
Successful transmission of one message
•
TxEmpty:
Successful transmission of all messages in buffer
•
TxIrq:
Successful transmission of a predefined number of messages
•
TxAHBErr: AHB access error during transmission
•
Off:
Bus-off condition
•
Pass:
Error-passive condition
The Tx, TxEmpty and TxIrq interrupts are only generated as the result of a successful message trans-
mission, after the CanTxRD.READ pointer has been incremented.
25.6
Reception
The receive channel is defined by the following parameters:
•
base address
•
buffer size
•
write pointer
•
read pointer
The receive channel can be enabled or disabled.
25.6.1 Circular buffer
The receive channel operates on a circular buffer located in memory external to the CAN controller.
The circular buffer can also be used as a straight buffer. The buffer memory is accessed via the
AMBA AHB master interface.
Each CAN message occupies 4 consecutive 32-bit words in memory. Each CAN message is aligned to
4 words address boundaries (i.e. the 4 least significant byte address bits are zero for the first word in a
CAN message).
The size of the buffer is defined by the CanRxSIZE.SIZE field, specifying the number of CAN mes-
sages * 4 that fit in the buffer.
E.g. CanRxSIZE.SIZE=2 means 8 CAN messages fit in the buffer.
Note however that it is not possible to fill the buffer completely, leaving at least one message position
in the buffer empty. This is to simplify wrap-around condition checking.
E.g. CanRxSIZE.SIZE=2 means that 7 CAN messages fit in the buffer at any given time.