libosmocore
0.12.0
Osmocom core library
|
Go to the documentation of this file.
25 #include <sys/types.h>
29 extern uint16_t
osmo_crc16(uint16_t crc,
const uint8_t *buffer,
size_t len);
41 extern uint16_t
osmo_crc16_ccitt(uint16_t crc,
const uint8_t *buffer,
size_t len);
uint16_t osmo_crc16_ccitt(uint16_t crc, const uint8_t *buffer, size_t len)
Compute 16bit CCITT polynome 0x8408 (x^0 + x^5 + x^12) over given buffer.
Definition: crc16.c:108
uint16_t osmo_crc16(uint16_t crc, const uint8_t *buffer, size_t len)
Compute 16bit CCITT polynome 0x8408 (x^0 + x^5 + x^12) over given buffer.
Definition: crc16.c:59
uint16_t const osmo_crc16_ccitt_table[256]
CRC table for the CCITT CRC-6.
Definition: crc16.c:67
static uint16_t osmo_crc16_byte(uint16_t crc, const uint8_t data)
CRC-16 polynome 0x8005 (x^16 + x^15 + x^2 + 1)
Definition: crc16.h:32
static uint16_t osmo_crc16_ccitt_byte(uint16_t crc, const uint8_t data)
CCITT polynome 0x8408 (x^0 + x^5 + x^12)
Definition: crc16.h:44
uint16_t const osmo_crc16_table[256]
CRC table for the CRC-16.
Definition: crc16.c:18