From aa4ebfeb70d73bc2790a92701197ceed5b47633d Mon Sep 17 00:00:00 2001 From: penglei <1624952103@qq.com> Date: Tue, 13 Jan 2026 09:58:20 +0800 Subject: [PATCH] =?utf8?q?=E4=BC=98=E5=8C=96UI=E7=9D=A1=E7=9C=A0=E6=95=B0?= =?utf8?q?=E6=8D=AE=E6=B8=85=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- code/sdk/zhihui/drivers/cywee/dml/cywee_dml.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/code/sdk/zhihui/drivers/cywee/dml/cywee_dml.c b/code/sdk/zhihui/drivers/cywee/dml/cywee_dml.c index 115a91fde..ef36bd7cc 100644 --- a/code/sdk/zhihui/drivers/cywee/dml/cywee_dml.c +++ b/code/sdk/zhihui/drivers/cywee/dml/cywee_dml.c @@ -343,12 +343,16 @@ static void clean_sleep_data(void) memset(status_file_path, 0, sizeof(status_file_path)); memset(dir_path, 0, sizeof(dir_path)); memset(nap_file_path, 0, sizeof(nap_file_path)); - memset(&ui_nap_data, 0, sizeof(ui_nap_data)); - memset(&ui_sleep_data, 0, sizeof(ui_nap_data)); wake_up_flag = 0; } +static void cywee_clean_ui_sleep_data(void) +{ + memset(&ui_nap_data, 0, sizeof(ui_nap_data)); + memset(&ui_sleep_data, 0, sizeof(ui_nap_data)); +} + void cywee_read_nap_data(void) { char day[12] = {0}; @@ -1215,7 +1219,7 @@ void cywee_inactivity_mode_change(int mode) //睡眠 case INACTIVITY_MODE_SLEEPING: // CWM_OS_dbgPrintf("INACTIVITY_MODE_SLEEPING\r\n"); - + cywee_clean_ui_sleep_data(); //设置睡眠 memset(&scl, 0, sizeof(scl)); scl.iData[0] = 1; -- 2.17.1