ikalogic

Open full view…

CAN&CANFD CRC

khalm
Thu, 23 Jan 2020 12:48:03 GMT

Hi Ibrahem, I got a logic analyzer SP 209i, which is a great device and help me a lot. most of my tasks is to analyze a CAN & CANFD protocol, which is work fine except one point, the CRC. for example while I analyzing a CAN messages, I received the whole frames correctly except CRC field, it shown that CRC should be another value! Also in CANFD, when I select "ISO CRC (11898- 1:2015)" on the ScanStudio tool, it show me the same, CRC should be another value. and if I remove the select of "ISO CRC (11898- 1:2015)", I could not receive any message, it show me a stuffing error for every frame ! So this problem is happen whatever CAN or CANFD and also with different networks ! Could you tell me if I doing something wrong or I miss something ! Best regards, Khaled

Ibrahim KAMAL
Thu, 06 Feb 2020 13:00:57 GMT

Hello Khaled and sorry for the late reply. I don't think you're doing anything wrong, however, CAN CRC - especially CAN FD - can be quite tricky. As far as i know, I have validated the protocol decoder myself with several test fixtures. I would be however very interested to get a *.scana capture file of your system so that I can further analyze this and give you more feedback. Thanks!

Zappo
Mon, 10 Aug 2020 13:37:33 GMT

Hi Ibrahim, I just checked a really simple CAN communication but I get also a CRC-Error. What can I do? [2020-08-10_153641](//muut.com/u/ikalogic/s3/:ikalogic:Tp7o:20200810_153641.jpg.jpg)

Zappo
Mon, 10 Aug 2020 13:48:24 GMT

...addendum: I use a SP209i. Thanks a lot, Zappo.

Zappo
Tue, 11 Aug 2020 14:30:07 GMT

Hello Ibrahim, maybe I found an issue in your script "can.js". After inserting/modifiing the following lines in the function crc_calc(bits,crc_len) the calculated CRC is now correct in the "Normal CAN-Mode" (not FD-Mode): // crc = (1 << (crc_len -1)); //NOTE: For CAN FD ISO only! MZ 11.08.2020 if (is_fd_mode) // MZ 11.08.2020 { crc = (1 << (crc_len -1)); //NOTE: For CAN FD ISO only! } Can you please validate this? Thanks for a short feedback... Best regards, Zappo.

mabernotas
Wed, 16 Sep 2020 12:20:32 GMT

Hi, Ibrahim, I have SQ100 and want to connect it to the car with CAN BUS working on 500kbps. I used 5MHz and higher sampe rates and set 500kBps speed in decoder's UI, but got no success. I get Stuffing errors for every packet, no hex view is displayed. Any suggestions on how to configure the software to decode cars CAN traffic? (I use Scanastudio 4.016.) Maybe older versions work ok? Thank you in advance. Best Regards, Mario

Ibrahim KAMAL
Thu, 17 Sep 2020 07:03:05 GMT

Hello Mario, Did you configure channels 1 & 2 as CAN inputs?

Zappo
Tue, 22 Sep 2020 12:15:54 GMT

Hello Ibrahim, I refer to my mail from 2020-08-10. Can you confirm my findings, please? Best Regards, Zappo.