From: penglei <1624952103@qq.com> Date: Fri, 26 Jul 2024 08:48:20 +0000 (+0800) Subject: 修复编译问题 X-Git-Tag: release_V1.2.70_20241020_135402~741^2~4^2~8 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=refs%2Fchanges%2F590%2F2;p=mirrors%2FFD230.git 修复编译问题 --- diff --git a/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c b/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c index 81a20fa43..7b1c96197 100644 --- a/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c +++ b/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c @@ -2,7 +2,7 @@ * @Author: penglei 1624952103@qq.com * @Date: 2024-06-17 14:31:08 * @LastEditors: penglei 1624952103@qq.com - * @LastEditTime: 2024-07-24 09:39:01 + * @LastEditTime: 2024-07-26 16:46:54 * @FilePath: /FD230/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c * @Description: * @@ -85,22 +85,6 @@ static uint32_t aging_time = 0; static uint8_t pwr_button_result = 0; static uint8_t func_button_result = 1; - -static int CRC16_XMODEM(uint8_t *bytes,uint16_t length) { - int crc = 0x0000; // initial value - int polynomial = 0x1021; - for (int index = 0; index < length; index++) { - uint8_t b = bytes[index]; - for (int i = 0; i < 8; i++) { - uint8_t bit = ((b >> (7 - i) & 1) == 1); - uint8_t c15 = ((crc >> 15 & 1) == 1); - crc <<= 1; - if (c15 ^ bit) crc ^= polynomial; - } - } - crc &= 0xffff; - return crc; -} errcode_t factorytest_protocol_replymsg(uint8_t mode, uint8_t submode,uint8_t testitem, uint8_t *input_data,uint16_t input_len) {