![]() |
![]() |
Common CAN functions for MCAN configuration.
Go to the source code of this file.
Macros | |
#define | MCAN_INTR_SRC_RX_MASK |
Functions | |
int_fast16_t | CANMCAN_setBitTimingRaw (const CAN_BitRateTimingRaw *rawTiming) |
Sets the MCAN raw bit timing. More... | |
int_fast16_t | CANMCAN_configMsgRAM (const CAN_MsgRAMConfig *config, uint32_t msgRAMSize, uint32_t enableCANFD) |
Configures the MCAN message RAM. More... | |
uint32_t | CANMCAN_getInterruptMask (uint32_t eventMask) |
Returns the MCAN IRQ mask based on the CAN event mask. More... | |
#define MCAN_INTR_SRC_RX_MASK |
Interrupt mask for all Rx sources (Rx FIFO 0, Rx FIFO 1, and dedicated Rx buffers).
int_fast16_t CANMCAN_setBitTimingRaw | ( | const CAN_BitRateTimingRaw * | rawTiming | ) |
Sets the MCAN raw bit timing.
rawTiming | A pointer to CAN_BitRateTimingRaw. |
CAN_STATUS_SUCCESS | if successful. |
CAN_STATUS_ERROR | if any timing values are invalid. |
int_fast16_t CANMCAN_configMsgRAM | ( | const CAN_MsgRAMConfig * | config, |
uint32_t | msgRAMSize, | ||
uint32_t | enableCANFD | ||
) |
Configures the MCAN message RAM.
config | A pointer to CAN_MsgRAMConfig. |
msgRAMSize | Size of the message RAM in bytes. |
enableCANFD | Set to 1U if CAN FD is enabled, 0U otherwise. |
CAN_STATUS_SUCCESS | if successful. |
CAN_STATUS_ERROR | if the message RAM config is invalid. |
uint32_t CANMCAN_getInterruptMask | ( | uint32_t | eventMask | ) |
Returns the MCAN IRQ mask based on the CAN event mask.
eventMask | CAN event mask. |