How to config mcal canfd?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

How to config mcal canfd?

跳至解决方案
4,490 次查看
15359283122
Contributor II

Hi all,

   I use EB tresos to config Can module to support canfd,but it doesn't work,it just sends the can frame(using Can_Write function to send can data).The attachment is my Can.xdm. I don't have any idea on how to config the can module to send canfd frame.Expect you answer.Thanks a lot.

1 解答
4,352 次查看
hungnguyenphi
NXP Employee
NXP Employee

Hi  进铭 卢,

For sending a can FD with Can_Write() function, the ID of the PDU should Bit-OR with CAN_FD_ID_DESCRIPTOR (which is defined as 0x4000 for FD Standard and 0x40000000 for FD Extended.). E.g if you want to send canFD frame with ID 1, the ID of the PDU should be 0x4001 for FD Standard and 0x40000001. Could you please try it first. If it doesn't work, please provide the MCAL package name, can.epc and name of microprocessor you are using. So we can check it.

Best regards,

Hung.

在原帖中查看解决方案

3 回复数
4,353 次查看
hungnguyenphi
NXP Employee
NXP Employee

Hi  进铭 卢,

For sending a can FD with Can_Write() function, the ID of the PDU should Bit-OR with CAN_FD_ID_DESCRIPTOR (which is defined as 0x4000 for FD Standard and 0x40000000 for FD Extended.). E.g if you want to send canFD frame with ID 1, the ID of the PDU should be 0x4001 for FD Standard and 0x40000001. Could you please try it first. If it doesn't work, please provide the MCAL package name, can.epc and name of microprocessor you are using. So we can check it.

Best regards,

Hung.

4,345 次查看
jjaf_86
Contributor I

Hi,

 

I'm having the same issue, can you tell me where exactly have you changed the ID?

I'm trying to change in CAN IF module the parameter CanIfRxPduId to 0x4001 for ex,  but it complains that has to be 0-based and consecutive.

Maybe I'm changing in the wrong place.

Thanks.

0 项奖励
回复
4,352 次查看
15359283122
Contributor II

It works.Thank you very much.

0 项奖励
回复