Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > General Computer Discussion > General Computer Support > CRC in CAN Controller.

Reply
Thread Tools

CRC in CAN Controller.

 
 
renvilakathu renvilakathu is offline
Junior Member
Join Date: Sep 2008
Posts: 1
 
      09-25-2008
Dear all,

While reading the CAN controller Bosch spec, I noticed the CRC logic mentioned in it.

I know that the CRC is the reminder after the division of the input sequence by the generator polynomial.

I am familiar with the concept/logic of,

MSB of zero --> Shift left bring in next bit.

MSB one --> Xor with generator polynomial and shift left.

But this logic cannot be used directly if the input is serial.

On the other hand, we cannot waste clocks waiting for enough bits to come to start CRC calculation.

Logic in Bosch spec is tackling this situation. But i couln't get the real mathematics behind this logic.

This is the pseudo code. Generator polynomial is x15+x14+x10+x8+x7+x4+x3+1 equivalent to 4599 H.

****************************************

CRC_RG = 0; // initialize 15-bit shift register
REPEAT
CRCNXT = NXTBIT EXOR CRC_RG(14);
CRC_RG(14:1) = CRC_RG(13:0); // shift left by 1
CRC_RG(0) = 0;
IF CRCNXT THEN
CRC_RG(14:0) = CRC_RG(14:0) EXOR (4599hex);
ENDIF
UNTIL (CRC SEQUENCE starts or there is an ERROR condition)

*****************************************

Please help.

Looking forward to hear from you.

Thanks in advance.


Regards,
Renju
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How to use easics crc generator? Jan Decaluwe VHDL 11 11-26-2010 07:29 PM
String::CRC crc function returns incorrect result, why? `Zidane Tribal Perl 1 07-28-2007 08:01 PM
String::CRC crc function returns incorrect result, why? `Zidane Tribal Perl Misc 3 07-27-2007 11:41 AM
crc-8 and crc-16 code... Mamut C++ 5 02-22-2007 02:22 PM
How can i unpack a EXE file that contains a CRC error Jackal Computer Support 1 10-08-2003 06:59 PM



Advertisments