mirror of
https://github.com/gityf/crc.git
synced 2026-08-12 20:32:20 +08:00
add crc8
This commit is contained in:
+19
@@ -0,0 +1,19 @@
|
|||||||
|
#ifndef _CRC_CRC8_H
|
||||||
|
#define _CRC_CRC8_H
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
|
// LSB-first
|
||||||
|
uint8_t crc8_lsb(const char *buf, int len);
|
||||||
|
|
||||||
|
// MSB-first
|
||||||
|
uint8_t crc8_msb(const char *buf, int len);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif /* __cplusplus */
|
||||||
|
#endif
|
||||||
Reference in New Issue
Block a user