fix(bootloader): remove recovery key hook

This commit is contained in:
cjiio committed 2026-09-04 11:02:00 +08:00
1 parent f913af29a3
commit 6e482f887d
28 files changed
+181 -236

No files matched your search

+5 -4
View File
@@ -9,9 +9,10 @@ This file is the only mandatory entry point for AI-assisted work in this reposit
## Project and safety baseline
- Target: ESP32-C3, 8 MB Flash, no PSRAM, ESP-IDF 5.5.3.
- Preserve mini-program BLE install compatibility: the 3 MB application limit,
`cardid` at `0x356000`, permanent Recovery at `0x700000`, and the five-second
UP-key bootloader hook are mandatory template contracts.
- Preserve the protected Flash layout: the 3 MB application limit, `cardid` at
`0x356000`, and factory-owned Recovery at `0x700000` are mandatory template
contracts. The template intentionally provides no function-key bootloader
hook for entering Recovery.
- Preserve existing user changes. Start with `git status --short --branch`; never overwrite or clean unrelated files.
- Hardware facts follow this priority: product specifications and measured results → `components/bsp/include/bsp_pins.h` → BSP headers and implementation → hardware guide → README/demo code. If a task requires a hardware detail not defined by these sources, ask the user instead of guessing.
- Reusable board logic belongs in `components/bsp`; pages, state machines, animations, and application tasks belong in `main`.
@@ -30,7 +31,7 @@ This file is the only mandatory entry point for AI-assisted work in this reposit
| Environment bootstrap or missing toolchain | `docs/development/engineering/environment-setup.md` |
| BSP, pins, buses, display, audio, battery | `docs/hardware-design/AI_HARDWARE_DEVELOPMENT_GUIDE.md`, `components/bsp/include/bsp_pins.h` |
| Demo or menu | `main/demo.h`, `main/main.c`, the nearest `main/demo_*.c` implementation |
| Build, test, dependencies, partitions | `docs/development/engineering/build-and-test.md`, `docs/development/engineering/ble-recovery-compatibility.md`, `sdkconfig.defaults`, `partitions.csv` |
| Build, test, dependencies, partitions | `docs/development/engineering/build-and-test.md`, `docs/development/engineering/protected-flash-layout.md`, `sdkconfig.defaults`, `partitions.csv` |
| CI or release | the matching file in `docs/development/ci/CI-*.md` and `.github/workflows/` |
| Project completion | `docs/development/release/project-completion.md` (then the `issue-suggestions` or `experience-pr` skill) |
| Documentation | `docs/contribution/doc-conventions.md`, `docs/README.md` |
+4 -4
View File
@@ -9,9 +9,9 @@
## 项目与安全基线
- 目标平台:ESP32-C3、8 MB Flash、无 PSRAM、ESP-IDF 5.5.3。
- 必须保持小程序 BLE 安装兼容:3 MB 应用上限、`cardid@0x356000`、
永久 `recovery@0x700000` 以及上键持续 5 秒进入 Recovery 的 bootloader hook
均为模板强制契约。
- 必须保持受保护的 Flash 布局:3 MB 应用上限、`cardid@0x356000`
与工厂所有的 `recovery@0x700000` 均为模板强制契约。模板不提供
任何功能键进入 Recovery 的 bootloader hook。
- 保留用户已有修改。先执行 `git status --short --branch`,不得覆盖或清理无关文件。
- 硬件事实优先级:产品规格与实测结果 → `components/bsp/include/bsp_pins.h` → BSP 头文件与实现 → 硬件指南 → README/demo。任务所需硬件细节未在这些来源中定义时,直接询问用户,不得猜测。
- 可复用板级逻辑放入 `components/bsp`;页面、状态机、动画和应用任务放入 `main`。
@@ -30,7 +30,7 @@
| 环境引导或缺少工具链 | `docs/development/engineering/environment-setup.zh_CN.md` |
| BSP、引脚、总线、显示、音频、电池 | `docs/hardware-design/AI_HARDWARE_DEVELOPMENT_GUIDE.zh_CN.md`、`components/bsp/include/bsp_pins.h` |
| Demo 或菜单 | `main/demo.h`、`main/main.c`、最近的 `main/demo_*.c` 实现 |
| 构建、测试、依赖、分区 | `docs/development/engineering/build-and-test.zh_CN.md`、`docs/development/engineering/ble-recovery-compatibility.zh_CN.md`、`sdkconfig.defaults`、`partitions.csv` |
| 构建、测试、依赖、分区 | `docs/development/engineering/build-and-test.zh_CN.md`、`docs/development/engineering/protected-flash-layout.zh_CN.md`、`sdkconfig.defaults`、`partitions.csv` |
| CI 或发布 | `docs/development/ci/CI-*.zh_CN.md` 中的对应文件与 `.github/workflows/` |
| 项目开发完成 | `docs/development/release/project-completion.zh_CN.md`(再进入 `issue-suggestions` 或 `experience-pr` skill) |
| 文档 | `docs/contribution/doc-conventions.zh_CN.md`、`docs/README.zh_CN.md` |
-8
View File
@@ -1,12 +1,4 @@
cmake_minimum_required(VERSION 3.16)
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
# Community firmware replaces the bootloader when installed over USB. Keep the
# factory Recovery entry gesture in every derivative build so USB development
# does not strand the device outside the mini-program BLE install path.
idf_build_set_property(
BOOTLOADER_EXTRA_COMPONENT_DIRS
"${CMAKE_CURRENT_LIST_DIR}/bootloader_components/"
APPEND)
project(FoloToy-AI-Passport)
Loaded 3 of 28 files, more files were not shown because too many files have changed in this diff. Show more