S32K118 CAN RX MB MASK

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

S32K118 CAN RX MB MASK

ソリューションへジャンプ
446件の閲覧回数
Pohsuan
Contributor III

Hello NXP team,

I'm trying to configure the CAN RX message buffer global mask, based on the reference article in the link below.

https://community.nxp.com/t5/S32K-Knowledge-Base/S32K1xx-FlexCAN-Mask-Setting-Demo/ta-p/1519753

https://community.nxp.com/t5/S32K/S32K344-FlexCAN-How-to-setup-Rx-MB-mask-to-receive-the-CAN-FD/m-p/...

 

However, on my current CAN bus setup, I can only receive messages with IDs 0x300 and 0x400. I’m not able to receive IDs in the ranges 0x301 ~ 0x37F and 0x401 ~ 0x47F.

Am I missing any configuration?

Please check my project as attachment, and provide me some advice, Thank you!

 

タグ(1)
0 件の賞賛
返信
1 解決策
421件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

if receiving std ID you need to shift mask accordingly. The API does not do any shifting for mask register setup. So use

FlexCAN_Ip_SetRxMbGlobalMask(INST_FLEXCAN_0, 0x780<<18);

BR, Petr

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
422件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

if receiving std ID you need to shift mask accordingly. The API does not do any shifting for mask register setup. So use

FlexCAN_Ip_SetRxMbGlobalMask(INST_FLEXCAN_0, 0x780<<18);

BR, Petr

0 件の賞賛
返信
407件の閲覧回数
Pohsuan
Contributor III

Hello PetrS,

Thank you for your guidance. I was able to successfully receive the CAN messages.

When I using FlexCAN_Ip_SetRxMbGlobalMask, I needed to left-shift the mask value by 18 bits.
Is this behavior related to the version of the RTD library, or is it due to differences between the S32K118 and S32K344?

For reference, I’m currently using:
S32K1_RTD_2_0_0_P04_D2404_ASR_REL_4_7_REV_0000_20240417

Pohsuan_0-1746583811029.png

 

タグ(1)
0 件の賞賛
返信