From: luozheng <1732036298@qq.com> Date: Wed, 29 Oct 2025 11:53:15 +0000 (+0800) Subject: ln:debug调试界面添加显示ppp波特率 X-Git-Tag: V1.0.9_20251128_194606_LN~56^2~31^2~3 X-Git-Url: http://git.snicker.com.cn/?a=commitdiff_plain;h=6cc38dc3488119e09b7637d0ff5e0d952f3afab3;p=mirrors%2FFD230.git ln:debug调试界面添加显示ppp波特率 --- diff --git a/code/sdk/application/wearable/ln/service/msg_center/src/notify/debug_output_notification/debug_output_notification.cpp b/code/sdk/application/wearable/ln/service/msg_center/src/notify/debug_output_notification/debug_output_notification.cpp index f15750653..177fbfa44 100644 --- a/code/sdk/application/wearable/ln/service/msg_center/src/notify/debug_output_notification/debug_output_notification.cpp +++ b/code/sdk/application/wearable/ln/service/msg_center/src/notify/debug_output_notification/debug_output_notification.cpp @@ -19,6 +19,7 @@ extern "C" { #endif #include "ln_api.h" +#include char *uapi_ln_get_device_id(void); char *uapi_ln_get_device_iccid(void); char *uapi_ln_get_device_model(void); @@ -156,7 +157,12 @@ namespace OHOS { std::string deviceInfo = "设备号:" + std::string(uapi_ln_get_device_id()) + "\n"; deviceInfo += "设备iccid:" + std::string(uapi_ln_get_device_iccid()) + "\n"; - deviceInfo += "设备version:" + std::string(uapi_ln_get_device_version()) + "\n"; + + char version_buf[128] = {0}; + uint32_t version_len = sizeof(version_buf) - 1; // 预留1字节给字符串结束符 + uapi_get_buildversion((uint8_t *)version_buf, version_len); + deviceInfo += "设备version:" + std::string(version_buf) + "\n"; + deviceInfo += "设备model:" + std::string(uapi_ln_get_device_model()) + "\n"; WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "设备连接状态:%d", ln_ws_get_connection_state()); @@ -180,6 +186,10 @@ namespace OHOS deviceInfo += "设备连接状态:未知状态 " +std::to_string(ln_ws_get_connection_state()); break; } + + //ppp波特率 + uint32_t ppp_baudrate = get_ppp_baudrate_from_config_model(); + deviceInfo += "ppp波特率:" + std::to_string(ppp_baudrate) + "\n"; return deviceInfo; }