在线时间0 小时
UID267210
注册时间2011-3-6
NXP金币0
该用户从未签到
新手上路

- 积分
- 40
- 最后登录
- 1970-1-1
|

楼主 |
发表于 2012-1-9 16:37:44
|
显示全部楼层
回复:can总线上为什么会收到自己发的帧?
回复第 2 楼 于2012-01-09 06:48:05发表:
不正常,你是不是把自我测试功能打开了?
没有啊,而且帧确实发出去了。
我在网上查了一下,看到也有人问,好像这是正常的现象?
http://forums.freescale.com/t5/Freescale-MQX-trade-Software/Flexcan-example/td-p/59317
I get contact with Freescale and they answer me:
The statement of the reference manual that you say is wrong. The statement should say the next:
"Note that FlexCAN only receive frames transmitted by itself if another device (node) on the CAN bus acknowledges the frame, which device has an ID that matches the FlexCAN Rx MB ID. If no other node acknowledges the frame, an ACK error is generated and, in this case, the module does not receive the frame sent by itself."
And unfortunately it's not possible to disable the Self-Received Frames.
The FlexCAN will receive frames transmitted by itself if another device on the CAN bus acknowledges the frame. If no other node acknowledges the frame, an ACK error is generated and, in this case, the module does not receive the frame sent by itself. That means the same FlexCAN module can't acknowledge its own message.
So all you can as an alternate to disabling this feature would be to 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).
So, you can reject your own messages unless you put a software mask
按照上面说法这是无法避免收到自己发出的帧数据的,除非在mask这边进行屏蔽,不知道理解的是否对。 |
|