屏蔽部分打印 2017/1 2017/head 2022/target/1
authorCaisking <Casiking@zhihuishixun.com>
Tue, 29 Jul 2025 06:40:29 +0000 (14:40 +0800)
committerCaisking <Casiking@zhihuishixun.com>
Tue, 29 Jul 2025 06:40:29 +0000 (14:40 +0800)
code/sdk/application/wearable/fd230/nativeapp/nativeui/heartrate/src/HeartModel.cpp
code/sdk/application/wearable/fd230/nativeapp/nativeui/traing/src/TraingModel.cpp
code/sdk/zhihui/drivers/ppg/hx3695/hx3695.c

index fbc80a6..110b972 100644 (file)
@@ -1042,7 +1042,7 @@ static void heart_data_callbackProc(int data) {
   uint8_t wear = 1;\r
 #ifdef SUPPORT_PPG_SERVICE\r
   wear = ppg_get_wear_status();\r
-  printf("heart_data_callbackProc::wear = %d\n", wear);\r
+  WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP,"heart_data_callbackProc::hrs = %d\n", hrs);\r
   wear = 1; //暂时屏蔽\r
 #endif\r
   if (wear == 0) {\r
@@ -1052,7 +1052,7 @@ static void heart_data_callbackProc(int data) {
   uint8_t hrs = 0;\r
 #ifdef SUPPORT_PPG_SERVICE\r
   hrs = ppg_get_hrs();\r
-  printf("heart_data_callbackProc::hrs = %d\n", hrs);\r
+  WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP,"heart_data_callbackProc::hrs = %d\n", hrs);\r
 #endif\r
   OHOS::HeartModel::GetInstance()->UpHeartdata(hrs);\r
 }\r
index 742bed2..48eaa0a 100644 (file)
@@ -233,7 +233,7 @@ TraingModel ::TraingModel() {
 TraingModel ::~TraingModel() {
   WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "TraingModel::~TraingModel()");
   // TraingUnsubscribeTopic(TOPIC_EVENT_ACTIVITY_UPDATE); // 取消订阅
-  // TraingUnsubscribeTopic(TOPIC_EVENT_BLE_TRAINING);
+  TraingUnsubscribeTopic(TOPIC_EVENT_BLE_TRAINING);
   // TraingUnsubscribeTopic(TOPIC_EVENT_HEARTRATE_UPDATA);
   // TraingUnsubscribeTopic(TOPIC_EVENT_ACTIVITY_EXTRA_INFO_UPDATE);
 }
@@ -244,7 +244,7 @@ TraingModel *TraingModel::GetInstance(void) {
 
 void TraingModel ::Init() {
   // TraingSubscribeTopic(TOPIC_EVENT_ACTIVITY_UPDATE); // 进行消息订阅
-  // TraingSubscribeTopic(TOPIC_EVENT_BLE_TRAINING);
+  TraingSubscribeTopic(TOPIC_EVENT_BLE_TRAINING);
   // TraingSubscribeTopic(TOPIC_EVENT_HEARTRATE_UPDATA);
   // TraingSubscribeTopic(TOPIC_EVENT_ACTIVITY_EXTRA_INFO_UPDATE);
 }
@@ -2394,7 +2394,7 @@ static void sport_data_callbackProc(int data) {
   uint8_t hrs = 0;
 #ifdef SUPPORT_PPG_SERVICE
   hrs = ppg_get_hrs();
-  printf("heart_data_callbackProc::hrs = %d\n", hrs);
+  WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP,"heart_data_callbackProc::hrs = %d\n", hrs);
 #endif
   TraingModel::GetInstance()->AnalysisHeartData(hrs);
 }
@@ -2550,4 +2550,4 @@ void ble_training_init(void) {
 
 #endif
 
-} // namespace OHOS
+} // namespace OHOS
\ No newline at end of file
index ef7619f..94b0de8 100644 (file)
@@ -3058,8 +3058,7 @@ void hx3695_hrs_ppg_Int_handle(void)
 \r
     // PRINT("hrsresult.wearstatus: %d,  hr_living: %d, hr_result:%d \r\n",hrsresult.wearstatus,hrsresult.hr_living,hrsresult.lastesthrs);\r
 \r
-    PRINT("hx3695 data_cnt: %d,  hr_living: %d, hr_living_qu: %d, hr_living_std: %d, hr_result:%d \r\n",\r
-               alg_results.data_cnt,  hrsresult.hr_living, hrsresult.hr_living_qu, hrsresult.hr_living_std, hrsresult.lastesthrs);\r
+    // PRINT("hx3695 data_cnt: %d,  hr_living: %d, hr_living_qu: %d, hr_living_std: %d, hr_result:%d \r\n",alg_results.data_cnt,  hrsresult.hr_living, hrsresult.hr_living_qu, hrsresult.hr_living_std, hrsresult.lastesthrs);\r
 \r
        if(hrs_wear_status == MSG_HRS_WEAR && hrsresult.hr_living == MSG_LIVING_TRUE)\r
     {\r