Skip to main content
daithi62
Associate II
October 17, 2018
Question

Does CAN Masking truly mask all unwanted CAN IDs?

  • October 17, 2018
  • 0 replies
  • 565 views

I'm working on the STM32F1 device and have been reading the CAN filtering and masking process. I now understand how the ID mask and filter works. I do have one question though as in certain cases I'm unsure if the filter would work 100% correctly.

If I want to get the message from CAN ID 0x100 thru 0x12F, using a 29 bit identifier I would use the following mask and filter;

Filter: 0000 0000 0000 0000 0000 0001 0000 0000

Mask: 0001 1111 1111 1111 1111 1111 1100 0000

I can see how this filters for CAN IDs 0x100 thru 0x12F. But am I correct in thinking that this would also allow CAN IDs 0x130 thru 0x13F through also, as bits 5:4 are "Don't care" ?

Thanks,

Cod

    This topic has been closed for replies.