crc16-ccitt.h
Go to the documentation of this file.
#ifndef CRC16_CCITT_H
#define CRC16_CCITT_H
#include "301/CO_driver.h"
/* default configuration, see CO_config.h */
#ifndef CO_CONFIG_CRC16
#define CO_CONFIG_CRC16 (0)
#endif
#if ((CO_CONFIG_CRC16) & CO_CONFIG_CRC16_ENABLE) || defined CO_DOXYGEN
#ifdef __cplusplus
extern "C" {
#endif
void crc16_ccitt_single(uint16_t *crc, const uint8_t chr);
uint16_t crc16_ccitt(const uint8_t block[],
size_t blockLength,
uint16_t crc);
/* CO_crc16_ccitt */
#ifdef __cplusplus
}
#endif /*__cplusplus*/
#endif /* (CO_CONFIG_CRC16) & CO_CONFIG_CRC16_ENABLE */
#endif /* CRC16_CCITT_H */
CO_driver.h
Interface between CAN hardware and CANopenNode.
crc16_ccitt
uint16_t crc16_ccitt(const uint8_t block[], size_t blockLength, uint16_t crc)
Calculate CRC sum on block of data.
uint16_t
unsigned int uint16_t
UNSIGNED16 in CANopen (0006h), 16-bit unsigned integer.
Definition: CO_driver.h:153
crc16_ccitt_single
void crc16_ccitt_single(uint16_t *crc, const uint8_t chr)
Update crc16_ccitt variable with one data byte.
uint8_t
unsigned char uint8_t
UNSIGNED8 in CANopen (0005h), 8-bit unsigned integer.
Definition: CO_driver.h:151