精简 usr_app 架构:去掉关机/休眠死代码,按键复用 key.c 状态机,ISR 重活统一延后到任务上下文

Type-C 长供电、上电即工作、无软关机,删除 app_boot/app_power 及 DP0 开关相关逻辑,
去掉空占位 app_fan_run 和无效的 usr_timer_pick_mode/rearm(数码管 4ms 扫描已 priority=1,
系统本来就不会进低功耗)。按键 5s 配对 / 12s OTA 改走 key.c 长按分级,去掉自计时与 1~5s 死区。
新增 app_defer,NVM/配对/OTA 只在 ISR 置位、在 500ms 任务上下文落地,避免再在 usr_timer 里写 flash。
规格书与注释同步精简。
This commit is contained in:
2026-08-31 17:57:52 +08:00
parent 5cc7e9dbd6
commit e324ebd99b
51 changed files with 542 additions and 886 deletions
+1 -1
View File
@@ -326,7 +326,7 @@ void app_main()
usr_var.usr_power_charge_flag=2;
}
/* 配对只由 app_boot 长按 5s 置 usr_goto_pair;禁止上电清三元组(规格书 5.2 / 14 章) */
/* 配对只由运行态长按 5skey_manager 分级)置 usr_goto_pair;禁止上电清三元组(规格书 5.2 / 14 章) */
ui_manage_init();
ui_update_status(STATUS_POWERON);