crc_ccitt.h File Reference
CCITT Cyclic Redundancy Check (CRC-CCITT). More...
#include <cfg/compiler.h>#include <cpu/pgm.h>Go to the source code of this file.
Defines | |
| #define | CRC_CCITT_INIT_VAL ((uint16_t)0xFFFF) |
| CRC-CCITT init value. | |
Functions | |
| uint16_t | updcrc_ccitt (uint8_t c, uint16_t oldcrc) |
| Compute the updated CRC-CCITT value for one octet (inline version). | |
| uint16_t | crc_ccitt (uint16_t crc, const void *buf, size_t len) |
| This function implements the CRC-CCITT calculation on a buffer. | |
Detailed Description
CCITT Cyclic Redundancy Check (CRC-CCITT).
- Note:
- This algorithm is incompatible with the CRC16.
- Version:
- Id
- crc.h 2771 2009-08-06 07:01:06Z lottaviano
Definition in file crc_ccitt.h.
Function Documentation
| uint16_t crc_ccitt | ( | uint16_t | crc, | |
| const void * | buf, | |||
| size_t | len | |||
| ) |
This function implements the CRC-CCITT calculation on a buffer.
- Parameters:
-
crc Current CRC-CCITT value. buf The buffer to perform CRC calculation on. len The length of the Buffer.
- Returns:
- The updated CRC-CCITT value.
Definition at line 76 of file crc_ccitt.c.
