Skip to main content
ATeso.1
Associate
May 30, 2023
Solved

CAN Receive Interruption not working on STM32F0-DISCOVERY

  • May 30, 2023
  • 3 replies
  • 1166 views

Hello,

I am trying to set up a CAN Data Frame receive interruption on a STM32F0-DISCOVERY board. The interruption seems to jump for all other IER register elements, but not for the RX. Stopping the processor execution on debug and checking the status of the RX registers, it seems not receive any kind of data, even though there is a source of data frames in the BUS.

I have tried also to set up the CAN interface in Loopback mode to test the system alone. The same result is obtained.

Has anybody had the same problem? Any idea why the RX registers are not being filled with the bus date?

Thanks in advance,

This topic has been closed for replies.
Best answer by mƎALLEm

Hello,

It could be filter config issue. If the filter is not well configured you will never receive the data.

You can inspire from any CAN example provided in STM32CubeF0.

Example from the path STM32072B_EVAL\Examples\CAN\CAN_Networking

3 replies

mƎALLEm
mƎALLEmBest answer
ST Technical Moderator
May 30, 2023

Hello,

It could be filter config issue. If the filter is not well configured you will never receive the data.

You can inspire from any CAN example provided in STM32CubeF0.

Example from the path STM32072B_EVAL\Examples\CAN\CAN_Networking

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
ATeso.1
ATeso.1Author
Associate
May 31, 2023

Hello again,

You were right, the problem came from not configuring the filters. I used the example you mentioned as base and now the CAN is able to receive data.

Thanks a lot.

mƎALLEm
ST Technical Moderator
May 31, 2023

Thank you for the confirmation.

I invite you to close this thread by clicking "Select as best" my answer to help others to find the answer later-on.

Thank you.

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