From: Caisking Date: Thu, 11 Sep 2025 06:58:54 +0000 (+0800) Subject: 关闭语音助手的宏 X-Git-Tag: leiniao_debug_1.0.0_20250922_020716~99^2~1 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=82d4df6d97f67485b3b46420d36d116ac58b0afa;p=mirrors%2FFD230.git 关闭语音助手的宏 --- diff --git a/code/sdk/application/wearable/fd230/nativeapp/nativeui/assistant/src/AssistantModel.cpp b/code/sdk/application/wearable/fd230/nativeapp/nativeui/assistant/src/AssistantModel.cpp index 3b5135c97..8cb99088d 100644 --- a/code/sdk/application/wearable/fd230/nativeapp/nativeui/assistant/src/AssistantModel.cpp +++ b/code/sdk/application/wearable/fd230/nativeapp/nativeui/assistant/src/AssistantModel.cpp @@ -19,10 +19,9 @@ #include "lwip/err.h" #endif -#ifdef SUPPORT_PHONE_SERVICE #include "phoneservice/include/PhoneService.h" #include "phoneservice/include/PhoneServiceC.h" -#endif + #include "vibrator_service.h" @@ -153,32 +152,27 @@ void AssistantModel::Init() { //获取状态[hfp] bool AssistantModel::GetHFPStatus(void) { -#ifdef SUPPORT_PHONE_SERVICE if (uapi_hfp_connect_state()) { WEARABLE_LOGI(WEARABLE_LOG_MODULE_APP, "uapi_hfp_connect_state is ok"); return true; } -#endif WEARABLE_LOGI(WEARABLE_LOG_MODULE_APP, "uapi_hfp_connect_state is failed"); return false; } //开启语音助手[soc] bool AssistantModel::StartAssistant(void) { -#ifdef SUPPORT_PHONE_SERVICE if (uapi_open_voice_recognition() == 0) { WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "uapi_open_voice_recognition is ok"); //成功开启语音助手 uapi_dev_runtime_set_voice_status(1); return true; } -#endif WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "uapi_open_voice_recognition is failed"); return false; } //关闭语音助手 void AssistantModel::StopAssistant(void) { -#ifdef SUPPORT_PHONE_SERVICE if (uapi_close_voice_recognition() == 0) { WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "uapi_close_voice_recognition is ok"); @@ -186,7 +180,6 @@ void AssistantModel::StopAssistant(void) { WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "uapi_close_voice_recognition is failed"); } -#endif } //语音回答界面->主界面