u8CCITT8()

Explanation

Calculate the CRC8.

Argument

Type
Name
Remark
uint8*
pu8Data
A string of bytes to calculate the CRC8.
unit8
size
Number of bytes to calculate.

Returns

Type
Remark
uint8
The calculated value of CRC8.

Sample code

1
#include "ccitt8.h"
2
3
...
4
char str[] = "abcABCDE";
5
uint8 u8crc = u8CCITT8(str, strlen(str));
Copied!
最終更新 8mo ago
リンクのコピー