From: Caisking <3449750381@qq.com> Date: Wed, 23 Oct 2024 03:59:11 +0000 (+0800) Subject: 血氧:增加读写控制 X-Git-Tag: fd230_release_V1.3.102~199 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=2fd542fd3b6519d8df70feb6e67ae3db279d0026;p=mirrors%2FFD230.git 血氧:增加读写控制 --- diff --git a/code/sdk/application/wearable/fd230app/nativeui/bloodoxygen/src/BloodOxygenModel.cpp b/code/sdk/application/wearable/fd230app/nativeui/bloodoxygen/src/BloodOxygenModel.cpp index 3689e3645..1f3c2d484 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/bloodoxygen/src/BloodOxygenModel.cpp +++ b/code/sdk/application/wearable/fd230app/nativeui/bloodoxygen/src/BloodOxygenModel.cpp @@ -5,6 +5,7 @@ #include "wearable_log.h" #include "heart_blood/health_service/health_service.h" #include "custom_utils.h" + extern "C" errcode_t uapi_get_timestamp_ms(uint32_t *tm); #include "custom_utils.h" @@ -141,13 +142,13 @@ namespace OHOS // 保存检测数据 void BloodOxygenModel::Blood_Save() { - BloodOxygenData data; - data.SPO2 = currentspo2; - data.timestamp = BloodResultPresenter::GetInstance()->GetCurrentTime(); - SetCheckTime(data.timestamp); - HealthService::GetInstance()->UpdateHealthData(data); - WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "%d %ld", currentspo2, data.timestamp); + uint32_t timestamp = BloodResultPresenter::GetInstance()->GetCurrentTime(); + SetCheckTime(timestamp); + + //HealthService::GetInstance()->UpdateHealthData(data); + HealthService::GetInstance()->send_blood_save(); + } // 显示检测结果// 显示检测结果