14#ifndef ZEPHYR_INCLUDE_SYS_CRC_H_
15#define ZEPHYR_INCLUDE_SYS_CRC_H_
28#define CRC8_CCITT_INITIAL_VALUE 0xFF
138 return crc16(src, len, 0x8005, 0xffff,
true);
177 size_t len,
bool first_pkt,
bool last_pkt);
uint8_t crc7_be(uint8_t seed, const uint8_t *src, size_t len)
Compute the CRC-7 checksum of a buffer.
uint32_t crc32_ieee_update(uint32_t crc, const uint8_t *data, size_t len)
Update an IEEE conforming CRC32 checksum.
uint16_t crc16_itu_t(uint16_t seed, const uint8_t *src, size_t len)
Compute the CRC-16/XMODEM checksum of a buffer.
uint16_t crc16_ccitt(uint16_t seed, const uint8_t *src, size_t len)
Compute the CRC-16/CCITT checksum of a buffer.
uint32_t crc32_c(uint32_t crc, const uint8_t *data, size_t len, bool first_pkt, bool last_pkt)
Calculate CRC32C (Castagnoli) checksum.
uint8_t crc8_ccitt(uint8_t initial_value, const void *buf, size_t len)
Compute CCITT variant of CRC 8.
uint8_t crc8(const uint8_t *src, size_t len, uint8_t polynomial, uint8_t initial_value, bool reversed)
Generic function for computing CRC 8.
uint16_t crc16(const uint8_t *src, size_t len, uint16_t polynomial, uint16_t initial_value, bool pad)
Generic function for computing CRC 16.
static uint16_t crc16_ansi(const uint8_t *src, size_t len)
Compute ANSI variant of CRC 16.
Definition: crc.h:136
uint32_t crc32_ieee(const uint8_t *data, size_t len)
Generate IEEE conform CRC32 checksum.
__UINT32_TYPE__ uint32_t
Definition: stdint.h:60
__UINT8_TYPE__ uint8_t
Definition: stdint.h:58
__UINT16_TYPE__ uint16_t
Definition: stdint.h:59
static fdata_t data[2]
Definition: test_fifo_contexts.c:15