All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
crc16.h File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


uint16_t fr_crc16_xmodem (uint8_t const *in, size_t in_len)
 CRC16 implementation according to CCITT standards. More...

Function Documentation

uint16_t fr_crc16_xmodem ( uint8_t const *  in,
size_t  in_len 

CRC16 implementation according to CCITT standards.

Note by antirez: this is actually the XMODEM CRC 16 algorithm, using the following parameters:

Name : "XMODEM", also known as "ZMODEM", "CRC-16/ACORN" Width : 16 bit Poly : 1021 (That is actually x^16 + x^12 + x^5 + 1) Initialization : 0000 Reflect Input byte : False Reflect Output CRC : False Xor constant to output CRC : 0000 Output for "123456789" : 31C3

[in]inData to perform CRC on.
[in]in_lenLength of data.
CRC16 of input data.

Definition at line 91 of file crc16.c.

+ Here is the caller graph for this function: