Page 1 of 1

CRC library?

Posted: Tue Mar 12, 2013 3:56 pm
by sblair
Is there a CRC library already in the Netburner somewhere? Specifically I'm on the 5270 here.

I looked in the docs and didn't see anything but I know there are other parts of the system that use CRC I believe....

Thanks.
Scott

Re: CRC library?

Posted: Thu Mar 14, 2013 12:15 am
by roland.ames
Looking at my installation (rel24_rc2), I can see three different CRC calculators.

in MOD5270\system\emulticast.cpp there is code for a FCS-32, table lookup
in system\ahdlc.cpp there is code for a FCS-16 (as defined in RFC 1662), table lookup
in system SDIO.cpp there is code for a CRC7, polynomial

I also have some code that generates the 16bit CRC used in the MODBUS-RTU protocol, table lookup,
I have some code that generates CCITT-16, using the polynomial