Skip to main content
LJere
Associate
July 17, 2019
Solved

How to config with CAN bus filter in SPCstudio?

  • July 17, 2019
  • 1 reply
  • 1434 views

Hi all,

I'm using SPC570S0DISP DEMO Board(SPC570S50E1) to lean how to config CAN's filter.

And the attachment is my config and source code.

In my config,i just want CAN ID 0x112 to interrupt fifo callback function.And then i get the data in callback function. But unfortunatelly,ID 0x112/0x200/0x312/0x400/0x512/0x600/0x712 can interrupt fifo callback also.

So,can anyone help me correct my configuration and explain it?

thanks.

Jer.

    This topic has been closed for replies.
    Best answer by Erwan YVIN

    Hi ,

    Maybe you should add a filter in your configuration

    Cf Screenshot

    0690X000009YqHLQA0.png

    Best regards

    Erwan

    1 reply

    Erwan YVIN
    Erwan YVINBest answer
    ST Employee
    July 17, 2019

    Hi ,

    Maybe you should add a filter in your configuration

    Cf Screenshot

    0690X000009YqHLQA0.png

    Best regards

    Erwan

    LJere
    LJereAuthor
    Associate
    July 18, 2019

    Hi Erwan,

    The attachment file"filterConfig" was my configuration.And it doesn't work.The fifo callback function still able to be interruptted by 0x200/0x400/0x600.

    And i find some information from "RM0349 SPC570Sx 32-bit MCU reference manual rev6, Dec 2015",please check attachment--"CAN mask".That means 3-13bits avaliable to standard frame.So,i used filter mask--0x1fff to check also.But without any improvement.0690X000009Yr86QAC.png

    0690X000009Yr7wQAC.png

    Can you help me set-up the configuration of filter items?

    Thanks.

    Jer.