Committed on the Free edition of March Hare Software CVSNT Server. Upgrade to CVS Suite for more features and support: http://march-hare.com/cvsnt/ git-svn-id: http://moon:8086/svn/vhdl/trunk@790 cc03376c-175c-47c8-b038-4cd826a8556b
14 lines
482 B
C
14 lines
482 B
C
// CRC32 function
|
|
// To create a CRC from a new buffer, use this:
|
|
// crc = MakeCRC32(mydata, data_len, 0);
|
|
// If you need to continue the CRC (e.g. your data is in multiple buffers),
|
|
// continue like this:
|
|
// crc = MakeCRC32(moredata, more_len, crc);
|
|
//
|
|
// Your desired CRC should be the complement of the CRC generated by
|
|
// MakeCRC32:
|
|
// desired = crc
|
|
// desired - crc = 0
|
|
|
|
unsigned long MakeCRC32(char *data, unsigned int len, unsigned long CRC);
|