From: luozheng <1732036298@qq.com> Date: Fri, 8 May 2026 06:46:55 +0000 (+0800) Subject: 解决oat不自动开机问题 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=f09c88b0f18dfe1df38d089fb304c6cbac685a67;p=mirrors%2FFD230.git 解决oat不自动开机问题 --- diff --git a/code/sdk/application/brandy/brandy_standard/board_init.c b/code/sdk/application/brandy/brandy_standard/board_init.c index 1be94b4f7..1f167b598 100644 --- a/code/sdk/application/brandy/brandy_standard/board_init.c +++ b/code/sdk/application/brandy/brandy_standard/board_init.c @@ -208,6 +208,11 @@ void check_pwrkey_3s(void) PRINT("CPU reset Case is REBOOT , no need check PowerKey"NEWLINE); return ; } + /* OTA/升级流程结束后常用 REBOOT_CAUSE_UPG_COMPLETION(0x2040),若仍做电源键长按 gate 会立刻关机,后续升级无法执行 */ + if (cpu_reset_case == REBOOT_CAUSE_UPG_COMPLETION) { + PRINT("【开机按键】检测到升级完成重启(UPG_COMPLETION),跳过长按校验"NEWLINE); + return; + } if (startup_reason == STARTUP_VBUS_EN) { PRINT("【开机按键】检测到充电/VBUS启动,跳过长按校验,直接继续启动"NEWLINE);