GR740-UM-DS, Nov 2017, Version 1.7
270
www.cobham.com/gaisler
GR740
The progress of the any ongoing access can be observed via the CanRxCTRL.ONGOING bit. The
CanRxCTRL.ONGOING must be 0b before the channel can be re-configured safely (i.e. changing
address, size or write pointer). It is also possible to wait for the Rx and RxMiss interrupts described
hereafter.
The channel can be re-enabled again without the need to re-configure the address, size and pointers.
No message reception is performed while the channel is not enabled
17.6.8 Interrupts
During reception several interrupts can be generated:
•
RxMiss:
Message filtered away for receive
•
RxErrCntr: Error counter incremented for receive
•
RxSync:
Synchronization message received
•
Rx:
Successful reception of one message
•
RxFull:
Successful reception of all messages possible to store in buffer
•
RxIrq:
Successful reception of a predefined number of messages
•
RxAHBErr: AHB access error during reception
•
OR:
Over-run during reception
•
OFF:
Bus-off condition
•
PASS:
Error-passive condition
The Rx, RxFull and RxIrq interrupts are only generated as the result of a successful message recep-
tion, after the CanRxWR.WRITE pointer has been incremented.
The OR interrupt is generated when a message is received while a previously received message is still
being stored. A full circular buffer will lead to OR interrupts for any subsequently received messages.
Note that the last message stored which fills the circular buffer will not generate an OR interrupt. The
overrun is also reported with the CanSTAT.OR bit, which is cleared when reading the register.
The error behavior of the CAN core is according to the CAN standard, which applies to the error
counter, buss-off condition and error-passive condition.
17.7
Global reset and enable
When the CanCTRL.RESET bit is set to 1b, a reset of the core is performed. The reset clears all the
register fields to their default values. Any ongoing CAN message transfer request will be aborted,
potentially violating the CAN protocol.
When the CanCTRL.ENABLE bit is cleared to 0b, the CAN core is reset and the configuration bits
CanCONF.SCALER, CanCONF.PS1, CanCONF.PS2, CanCONF.RSJ and CanCONF.BPR may be
modified. When disabled, the CAN controller will be in sleep mode not affecting the CAN bus by
only sending recessive bits. Note that the CAN core requires that 10 recessive bits are received before
any reception or transmission can be initiated. This can be caused either by no unit sending on the
CAN bus, or by random bits in message transfers.
17.8
Interrupt
Three interrupts are implemented by the CAN interface:
Index:Name:Description:
16
IRQ Common output from interrupt handler
17
TxSYNCSynchronization message transmitted (optional)