FlexCAN through DMA for S32K322

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

FlexCAN through DMA for S32K322

71 Views
vignesh3
Contributor II

Can I use message buffers for receiving and transmitting through DMA instead of using legacy RX FIFO.

and Is the message buffer address is present in the SRAM area because I have studied that we can use non configured message buffers as SRAM in the application notes ?

0 Kudos
Reply
3 Replies

34 Views
vignesh3
Contributor II

vignesh3_1-1743499422119.png

In the above image only MB0 is accessible by DMA if I have configured legacy RX fifo but "The Legacy RX FIFO occupies the memory space originally reserved for MB5–MB0" this line is telling that legacy fifo using these (MB5–MB0) message buffers from Refrence Manual.

Then I no need to initialize message buffers "FlexCAN_Ip_ConfigRxMb (INST_BOARD_INITPERIPHERALS_FLEXCAN_3, 10, &rxInfo, 0x12345678);"  If I am using legacy fifo right?

And can you tell me if I no need to initialize the message buffers, how to initialize legacy fifo for DMA? 

0 Kudos
Reply

17 Views
PetrS
NXP TechSupport
NXP TechSupport

Hi

you can use both a legacy RXFIFO and dedicated RX MB simultaneously. So configuration of another RX MB is upon a user.
For possible implementation you can refer to https://community.nxp.com/t5/S32K-Knowledge-Base/Example-S32K312-CAN-Transmit-amp-Receive-Using-MB-a...

BR, Petr

0 Kudos
Reply

56 Views
PetrS
NXP TechSupport
NXP TechSupport

Hi,

DMA is supported only over RXFIFOs (legacy or enhanced) no over MBs.
And yes, the unused memory space (of MBs and RXIMR) can be used as general-purpose RAM space. Rules are described in chapter 73.3.14 Bus interface of the device RM.

BR, Petr

0 Kudos
Reply