2024-02-22 05:10 AM
Hello,
I am trying to implement the FDCAN in classic mode on the STM32G491 without the HAL. But I am havin trouble understanding how to configure and then use the CAN SRAM. I am not using the HAL nor CMSIS nor anyting else. Just the basic register definitions in a single h file. The bxCAN was way more simple and works great on a F103 (also bare metal). But the FDCAN on the G491 is somwhat more complex.
I have setup a sample in STMCubeIDE and tryed to extract the information from there. But I just dont get how the configuration of the CAN SRAM section works and how I can then send or receive any messages through this SRAM.
Does anyone have a working example of this in bare metal C?
2024-06-16 03:01 AM
Hey.
Did you ever end up finding an example implementation for the FDCan on bare metal?
2024-06-16 03:46 AM
Hi,
no but I implemented it on my own. All works now. Once I understood how the FDCAN ram worked it was pretty simple. You can set up the ram with a struct just like all the other registers and treat it as registers. That way it becomes very simple to understand and use.