Hi,
I'm working on S32K144 CAN peripheral in which I'm using RX FIFO filter to receive data from multiple ID's.
-> 0x404 is masked with 0x7FC thus lower 2 bits are don't care, so messages with ID 0x404-0x407 are received
-> 0x420 is masked with 0x7F0 thus lower 4 bits are don't care, so messages with ID 0x420-0x42F are received
已解决! 转到解答。
I checked and reproduced your problem, what i want to say is that this is not a software problem but that you overestimated the communication rate.
you can see that the bus load rate is close to 100%
here is my test code without using FreeRTOS and it works find on myside
So could you please test this case without using FreeRTOS, if the result is same with mine, then I think this might be an issue with your freertos.
Hi @Senlent ,
I'm attaching my project which uses Free RTOS.
I'm sending 10 frames with 10 different ID's in 10mS (from Flexcan0 to CAN tool) and simultaneously receiving other frames using flexcan callback. (i.e. Sending frames from CAN tool to S32K144 Flexcan0 in 10mS)
If I'm Sending 16 or 17 frames from CAN tool in 10mS then this code works fine, Flexcan0 is able to send 10 frames to CAN tool.
But if I'm Sending more than 16 or 17 frames from CAN tool in 10mS then flexcan0 stops sending frames to CAN tool. I'm getting MB transfer state = STATUS_BUSY.
If Flexcan0 is receiving more than 16 frames then it is not able to send any frames till I reduce no of frames sending from CAN tool.
Is different TX MB required to send standard and extended frames?
Can we use same MB to transmit large no of frames?
Help me with this.
Hi,
Thanks for the response. I'm able to receive expected ID's.
I've one more query about CAN transmission.
I'm using Flexcan0 with below settings.
I'm receiving data in RX FIFO (8 MB's are occupied) and I'm using TX MB's 9 to 16 to send data. But after receiving multiple frames (16 no. frames) continuously, TX MB is not able to send data. I'm getting MB Transfer status = STATUS_BUSY.
If there are 15 no. frames to be received then I'm getting Transfer status = STATUS_SUCCESS and able to send data.
There can be N no of frames to be received but I'm not able to send data after receiving 16 frames.
Please help me with this.
I see no problem with this setting, and I made a sample test
Sending more than 16 frames at the same time, no problems were found.
please provide more info about your issue, demo code, test process.
please refer to this post.
https://community.nxp.com/t5/S32K-Knowledge-Base/S32K1xx-FlexCAN-Mask-Setting-Demo/ta-p/1519753
for example:
format A, individual mask ,extended frame,mask value set to 0xFFFFFF00