cancel
Showing results for 
Search instead for 
Did you mean: 

It's not possible to reset the FDCAN instance individually

Lyu.1
Senior

Hi,Master
MCU:   STM32H743II
Question:
Both FDCAN channels in the MCU are currently in use. I now intend to reset each FDCAN instance (i.e., reset all its registers) during its respective bus-off event, and then reinitialize the instance. Resetting all registers of an instance is typically done through the corresponding FDCAN RST bit in the RCC. However, since both instances share the same RCC, triggering the reset would affect both instances simultaneously. Therefore, I've made modifications for resetting a single instance as follows:

HAL_FDCAN_DeInit(hfdcan);
hfdcan->Instance->CREL = 0x32141218;
hfdcan->Instance->ENDN = 0x87654321;
hfdcan->Instance->DBTP = 0x00000A33;
...

However, the aforementioned method can only reset some of the registers. Are there any better ways to achieve a reset of a single FDCAN instance? Thank you very much.

1 ACCEPTED SOLUTION

Accepted Solutions
mƎALLEm
ST Employee

Hello,

Unfortunately there is no way to reset the FDCAN instances separately.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

View solution in original post

4 REPLIES 4
mƎALLEm
ST Employee

Hello,

Unfortunately there is no way to reset the FDCAN instances separately.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

ok, Thank you for your guidance

MHoll.2
Senior III

Normally You don't need the reset a FDCAN controller when he is in Bus_off state, it should be sufficent to reset the INIT Flag in the CCCR register. This will make the Controller recover from Bus_off once the cause is removed.

From the reference manual capter 56.5.13:

MHoll2_0-1755867872272.png

 

Thank you for the good guidance.