1 #pragma once 2 #include <common/sys/types.h> 3 4 /** 5 * @brief 计算crc7 6 * 7 * @param crc crc初始值 8 * @param buffer 输入缓冲区 9 * @param len buffer大小(bytes) 10 * @return uint8_t crc 11 */ 12 uint8_t crc7(uint8_t crc, const uint8_t *buffer, size_t len);