How to config mcal canfd?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to config mcal canfd?

Jump to solution
1,690 Views
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 Solution
1,552 Views
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.

View solution in original post

3 Replies
1,553 Views
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.

1,545 Views
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 Kudos
1,552 Views
15359283122
Contributor II

It works.Thank you very much.

0 Kudos