Hi @pdnr7,
The FlexCAN receives frames transmitted by itself if another device on the CAN bus acknowledges the data. If no other node acknowledges the frame, an ACK error is generated and, the module does not receive the frame sent by itself.
One solution could be to set up the Self Reception Disable register (SRXDIS) to 1b, which disables the reception of frames transmitted by itself.
Best regards, Julian
Hi,
Setting SRXDIS is not helping, behavior is same echo is still happening only case of all pass filter(mask 0x0, filter 0x0)
Hi @pdnr7,
This could also be caused by your device sending data back, could you please confirm if all your nodes are different devices? Or are you testing this project with various KW36Z?
Also, please confirm if Loop Back Mode (LPB) is enabled, as this could be another cause.
As an alternative, you could set up a filter that ignores the frame when the ID of the frame matches the ID of the FlexCAN MB. You may filter out self-received frames on hardware level by configuring ID masking (Rx Mask Registers RXGMASK, RX14MASK and RX15MASK).
Best regards, Julian
Thanks for detailed explanation.
1, Yes the other nodes are CAN emulator(PCAN-USB). Sent data from NXP(FlexCan) is being successfully received at other nodes(PCAN-USB).
2,
3, My application(a well known industrial protocol) requires a all pass filter, and it will have to send can messages with different IDs at run time based on the traffic.
Also if i set all pass filter with format = kFLEXCAN_FrameFormatExtend or kFLEXCAN_FrameFormatStandard .I am getting rx data for both extended and standard.
Hello,
It seems Peak's System device (PCAN-USB) has a feature for confirmation of frames, regarding its manual on chapter 7.1, which echoes frames to confirm physical transmission. Could you please revise this feature on your devices to see if that's the cause of the problem?
Best regards, Julian
PCAN-USB is tested with other devices with the same settings, this is not happening with other devices.
Hi,
I would like to review your code since none of the solutions are working. Would it be possible for you to share your project?
Best regards, Julian.
Hello,
I reviewed your code and it appears the register activation for SRXDIS is not present, or at least I couldn't find it, have you removed it once you confirmed it didn't work? Or is it present somewhere else?
Best regards, Julian
Hi,
Yes, I removed SRXDIS after setting and testing it.
Hi,
I've been testing this issue with the FlexCAN SDK, and this issue is not present on our example. Could you please confirm to us which mailbox are you using to receive messages? And if it is possible, a screenshot of the CAN bus line in the reception and of the board's registers to see if it is present on the line or the board.
Best regards, Julián
Hi,
There are 2 more nodes present other than NXP(Flexcan). This is observed only when the ID is 0x0 and Mask is 0x0 and I am getting callback function called twice with "status_t" "kStatus_FLEXCAN_RxIdle" followed by "kStatus_FLEXCAN_TxIdle".