VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

CAN FD Automatic Frame Processing Issue

Hello everybody,

I am working on an automotive component that communicate through CAN FD protocol.

In these period I am facing some problems in calculate the CRC value through Automatic Frame Processing functionality that is included in Veristand. What I've observed is that I am not able to include any byte higher than the seventh and this is probably due to the fact the AFP is compatible just on the classic CAN that is characterized by 8 bytes frames (if I am not wrong).

There is any solution to overcome this problem in Veristand?

 

Thank you in advance for your support.

 

Lorenzo.

0 Kudos
Message 1 of 4
(2,056 Views)

Hello Lorenzo,

 I think this might help: https://github.com/NIVeriStandAdd-Ons/CAN-Frame-Protection-Custom-Device

 

 It's a Custom Device, so it won't be as performant as Automatic Frame Processing, but for our ECUs it works OK (for now at least 🙂 )

Piotr F.
Hardware Engineer @ ZF
0 Kudos
Message 2 of 4
(2,023 Views)

Hello Piotr,

Thank you for your answer. I've already tried with the Custom Device "CAN Frame Protection" but it was not successful since I don't understand where I can put the polynomial and the XOR in order to execute the calculation of the CRC.

The polynomial is the CRC calculation key that allows to the devices involved in the communication to check the integrity of a message. This is possibile only making calculation on the same polynomial otherwise the CRC sent with the message and the CRC calculated by the device that receive the message will never match.

 

Lorenzo M.

Test Engineer @Eldor Corporation S.p.A.

 

 

0 Kudos
Message 3 of 4
(1,979 Views)

Hello Lorenzo,

 In case of this Custom Device, you have to modify the source code to include CRC options other than defined. From my notes you have to modify 3 files in "Frame Protection Support" component:

  • Calculate Counter and Protection Main.vi - new case for new protection method. You add the calculation of the CRC here.
  • Initialize Protection Frames.vi - new case if XNET conversion session is needed
  • Cleanup Protection Frames.vi  - new case if XNET conversion session was added in Initalize

Also there is an enum *.ctl (control) defining all possible protection schemes, so it's also to be modified to include an additional option.

 

Piotr F.
Hardware Engineer @ ZF
0 Kudos
Message 4 of 4
(1,970 Views)