优化产测读取心率id,优化读取老化测试标志 1600/1
authorpenglei <1624952103@qq.com>
Mon, 6 Jan 2025 09:59:02 +0000 (17:59 +0800)
committerpenglei <1624952103@qq.com>
Mon, 6 Jan 2025 09:59:02 +0000 (17:59 +0800)
code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c
code/sdk/drivers/peripheral/ppg/hx3695/hx3695.c

index 41cdfd4..2bffc86 100644 (file)
@@ -2,7 +2,7 @@
  * @Author: penglei 1624952103@qq.com\r
  * @Date: 2024-06-17 14:31:08\r
  * @LastEditors: penglei 1624952103@qq.com\r
- * @LastEditTime: 2024-11-23 16:04:42\r
+ * @LastEditTime: 2025-01-06 16:20:03\r
  * @FilePath: /FD230/code/sdk/application/wearable/service/factorytest_service/factorytest_protocol.c\r
  * @Description: \r
  * \r
@@ -982,10 +982,12 @@ void factorytest_protocol_soft_test_decode(uint8_t submode,uint8_t testitem,uint
             {\r
                 //查询老化标志\r
                 uint8_t send_data[3] = {0};\r
+                do_custom_fileoperate_service_check_msg(CUSTOM_FILEOPERATE_MSG_TYPE_AGING_DATA_READ, NULL, 0);\r
+                LOS_Msleep(500);\r
 \r
-                send_data[1] = aging_t.flag;\r
+                send_data[1] = aging_result_t.flag;\r
 \r
-                if(aging_t.fail_num != 0)\r
+                if(aging_result_t.fail_num != 0)\r
                 {\r
                     send_data[2] = 0x01;\r
                 }\r
@@ -1358,6 +1360,11 @@ void factorytest_protocol_soft_test_decode(uint8_t submode,uint8_t testitem,uint
                 //获取 ppg_id\r
                 uint8_t ppg_id;\r
                 uapi_ppg_get_id(&ppg_id);\r
+                if(ppg_id != 0x65)\r
+                {\r
+                    hx3695_chip_check();\r
+                    uapi_ppg_get_id(&ppg_id);\r
+                }\r
                 factorytest_protocol_replymsg(BLE_TEST_CMD_MODE_SOFT_TEST,\r
                         BLE_TEST_CMD_SOFT_TEST_SUB_MODE_HRS,\r
                         0x01,\r
index 8917677..8feed29 100644 (file)
@@ -369,7 +369,7 @@ bool hx3695_chip_check(void)
     uint8_t i = 0;\r
     uint8_t chip_id = 0;\r
     hx3695_chip_id = 0;\r
-    for(i=0; i<5; i++)\r
+    for(i=0; i<10; i++)\r
     {\r
         hx3695_ppg_on();\r
         hx3695_delay_ms(5);\r