SPRAD59 October 2023 TMS320F280039
From a CPU level (PIE, IFR and INTM), interrupt handling is identical between DCAN and MCAN. However, interrupt handling differs significantly at the module level. Table 6-1 summarizes the basic differences in interrupt handling between DCAN and MCAN modules:
Category | DCAN | MCAN |
---|---|---|
Interrupt sources | Error, Status and Transmission/Reception interrupts corresponding to each message object | 30 internal interrupt sources (specified in table below ) |
Global interrupt registers | Registers to enable, read and clear global interrupts present | Corresponding register is absent |
Configuring reception interrupt | Reception interrupt can be separately enabled by setting RxIE bit in each Message Object as required | Interrupt can be enabled or disabled for any new message being received in dedicated Rx Buffer. |
Determining source of receive interrupt | Value read from register CAN_INT corresponds to Message Object Number where message has been received in | Interrupt only denotes that a new message has been received in Rx Buffer. Value read from MCAN_NDATx registers corresponds to Rx Buffer element number where message has been received. |
Rx FIFO interrupts | No separate interrupt functionality supported | Additional interrupt sources available including New Message in FIFO, FIFO being full and FIFO Watermark Reached (Watermark can be configured during Message RAM configuration to generate an interrupt when FIFO is filled to a certain level to serve the application needs) |
Configuring transmission interrupts | Transmission interrupt can be separately enabled by setting TxIE bit in each Message Object as required | Transmission interrupt can be separately enabled by configuring the register MCAN_TXBTIE, where each bit corresponds to a separate Tx Buffer Element. |
Determining Source of transmission interrupt | Value read from register CAN_INT corresponds to Message Object Number where message has been transmitted from | Interrupt only denotes that a transmission has been completed. Value read from the MCAN_TXBTO register corresponds to the Tx Buffer element number from which the transmission has occurred. |