cancel
Showing results for 
Search instead for 
Did you mean: 

Extended CAN2.0B filtering in List mode problem

Linas L
Senior II

Hello, In my system I have extended canbus with 29b identifier. With mask filtering it looks to be working, but list filtering gives me problems;

( i have setup where on STM32 is sending data with with any ID I want, and second is capturing data as well as all lines are monitored by scope with CAN decoder)

  sFilterConfig.FilterBank = 0;
  sFilterConfig.FilterMode = CAN_FILTERMODE_IDLIST
  sFilterConfig.FilterScale = CAN_FILTERSCALE_32BIT;
  uint32_t Filter =0x1;
  uint32_t Mask  = 0x8;
 
  sFilterConfig.FilterIdHigh = ((Filter<<3)>>16)&0xFFFF;
  sFilterConfig.FilterIdLow =   (Filter<<3)&0xFFFF;
  sFilterConfig.FilterMaskIdHigh = ((Mask<<3)>>16)&0xFFFF;
  sFilterConfig.FilterMaskIdLow  = (Mask<<3)&0xFFFF;

So my understanding that in list mode, single bank can allow message to go to RxFIFO and generate IRQ.

So in this code I would expect it should trigger at 0x01 and 0x08 ID. But it does not. ( all it does it is generating ACK and CANBUS). and sweeping ID's up to 65535 does not trigger my CAN IRQ.

While again, all is working in mask mode.

So what I am doing wrong ? Registers are set based on RM by hall driver correctly by the looks of it.

0 REPLIES 0