SetRxFifoGlobalMask behavior


SetRxFifoGlobalMask behavior

376 次查看
Contributor I


I used imxrt1050 and SDK is 2.6.1

below is my settings

uint32_t rxFifoFilter[] = {FLEXCAN_RX_FIFO_STD_FILTER_TYPE_A(0x3c0, 0, 0)};

rxFifoConfig.idFilterNum = sizeof(rxFifoFilter) / sizeof(rxFifoFilter[0]);
rxFifoConfig.idFilterTable = rxFifoFilter;
rxFifoConfig.idFilterType = kFLEXCAN_RxFifoFilterTypeA;
rxFifoConfig.priority = kFLEXCAN_RxFifoPrioHigh;
FLEXCAN_SetRxFifoConfig(EXAMPLE_CAN, &rxFifoConfig, true);


txFrame.format = kFLEXCAN_FrameFormatStandard;
txFrame.type   = kFLEXCAN_FrameTypeData;     = FLEXCAN_ID_STD(0x7ff);
txFrame.length = DLC;‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

txFrame2.format = kFLEXCAN_FrameFormatStandard;
txFrame2.type   = kFLEXCAN_FrameTypeData;     = FLEXCAN_ID_STD(0x7c0);
txFrame2.length = DLC;

In this condition, why I still receive the txFrame ? 

the txFrame ID didn't match.

Filter         =  0x  1  1110 0000 00000000000000000000
Mask        =  0x      1100 1100 00000000000000000000

txFrame   =  0x 11  1111 1111 1000000000000000000- 
txFrame2 =  0x 11  1110 0000 0000000000000000000- 

and what's the difference between RxFifoGlobalMask and RxIndividualMask ?


Best Regareds,

Andy Dong

标签 (1)
标记 (2)
0 项奖励
2 回复数

268 次查看
Contributor I

Hi, Kerry Zhou

I used SDK_2.5.0_MIMXRT1052xxxxB\boards\evkbimxrt1050\driver_examples\flexcan\loopback_transfer

I modified this example to test the Rx FIFO.

 I used MB 13&14 to transmit the txFrame&txFrame2.

the result of above settings is not what I imagine.

the txFrame and txFrame2 masked by RxFifoGlobalMask should be below

txFrame   =  0x xx  11xx 11xx xxxxxxxxxxxxxxxxxxx
txFrame2 =  0x xx  11xx 00xx xxxxxxxxxxxxxxxxxxx- 

so txFrame will not be received.


Best Regards,

Andy Dong

0 项奖励

268 次查看
NXP TechSupport
NXP TechSupport

Hello Andy Dong ,

  What's the SDK project you are using? Could you please tell me the path?

  This one?


  Please also update your SDK to the newest version.

  It seems your code not the directly SDK original code, do you modify the code, please also tell me which file, then I can help you to check more details.

RXMGMASK is used to mask the filter fields of all Rx MBs, excluding MBs 14-15, which have individual mask registers.

RXIMR are used as acceptance masks for ID filtering in Rx MBs and the Rx FIFO


Wish it helps you!



- If this post answers your question, please click the "Mark Correct" button. Thank you!


- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.

0 项奖励