1.26.6.10 1.27.9.10 1.28.10.10 1.34.7.10 1.41.8.10 1.42.6.10 MCANx_MessageReceive Function
C
bool MCANx_MessageReceive(uint8_t bufferNumber, MCAN_RX_BUFFER *rxBuffer) // x - Instance of the MCAN peripheral
Summary
Read a message from the specific Rx Buffer.
Description
This routine reads a message from the specific Rx Buffer.
Precondition
MCANx_Initialize has been called.
Parameters
Param | Description |
---|---|
bufferNumber | Rx buffer number |
rxBuffer | Pointer to Rx buffer |
Returns
true - When a message has been received
false - When a message has not been received
Example
uint8_t rxBuffer[MCAN0_RX_BUFFER_SIZE]; memset(rxBuffer, 0x00, MCAN0_RX_BUFFER_ELEMENT_SIZE); // Read message from Rx Buffer 0 MCAN0_MessageReceive(0, (MCAN_RX_BUFFER *)rxBuffer);
Remarks
None.