Skip to main content
YLin.2
Associate II
Nov 12, 2020 4:18 PM UTC
Question

Filter and Mask configuration of FlexCAN for SPC560

Hi,

I can't find any document that defines the Filter and Mask for FlexCAN, so I post a question about it.

I think the filter only passes frames that contain exact ID as the ID in ID mask field. Am I right?

0693W000005BDKVQA4.jpgBest regards

Yuechuan Lin

    This topic has been closed for replies.

    3 replies

    DCARR
    Visitor II
    Mar 21, 2022 11:18 AM UTC

    Hi,

    YES you are right.

    The CAN controller is configured to use the RX global mask that is set to 0x0FFFFFFF

    Best regards

    Domenico

    PChia.2237
    Senior
    Dec 7, 2022 8:54 AM UTC

    Is possible to change or just check this RX global mask?

    Because i have a problem in standard RX that seams that filter mask is not 0x7FF , but 0x3FF.

    I have tested in this way:

    RX ID= 0x1

    up to message id 0x201 -> 0b 0010 0000 0001 filter works

    if i send message id 0x401 ->0b 0100 0000 0001 filter not works, because i i receive the message.

    Best Regards,

    Patrick

    PChia.2237
    Senior
    Dec 7, 2022 9:40 AM UTC

    I have solved replacing in can_lld.h

    canp->flexcan->RXGMASK.R = 0x0FFFFFFFU;

    with

    canp->flexcan->RXGMASK.R = 0xFFFFFFFFU;