feat(firmware): Mini firmware as mini/ variant on the root stewart-core - #30
Merged
Conversation
…root stewart-core Fold the standalone Mini-6DOF firmware into this repo as a second build-time firmware variant alongside `Controller/`, both sharing the single root `stewart-core` submodule. Source files copied in (not a subtree/submodule of Mini-6DOF). Part of the firmware-unification effort (6dof/FIRMWARE_UNIFICATION.md, DECISIONS 2026-07-18). Variant map - `Controller/` = normal (full system): MCPWM step/dir -> AASD-15A; PCBv1 ESP32 / PCBv2 ESP32-S3; W5500 Ethernet. - `mini/` = mini (desktop): LEDC PWM -> hobby servos; analog 50 Hz, runtime-switchable to digital 250 Hz via SERVO:RATE. - Both point at ../stewart-core (single source of truth = atan2f). Changes - Copy Mini-6DOF `Controller/` tree into `mini/` (main/, include/, CMakeLists.txt, partitions.csv, sdkconfig.defaults, embedded demo .m6p). Excludes .git, build/, generated sdkconfig, and the mini's own components/stewart-core submodule. - Rewire `mini/CMakeLists.txt` to the root submodule via `set(EXTRA_COMPONENT_DIRS ".../stewart-core")`, mirroring Controller/. The mini's `main/CMakeLists.txt` already PRIV_REQUIRES stewart-core; it now resolves to the root component. No `components/stewart-core` reference remains. - Advance the root `stewart-core` submodule e5ef989 -> a820e74 (origin/main head: "feat(mca): add output-stage intensity + per-axis gain/invert, schema v6"). Required: the mini Phase-3 firmware calls mcaGetIntensity / mcaSetAxisGain / mcaApplyOutputStage and MotionCueingConfig.axis_gain/axis_invert, which the old pin predates. Per the locked decision these cue params live in the SHARED core. - Copy mini 3D parts into `cad/mini/` (servo mount, seat rails, pcb mount). - Add `firmware/README.md` (variant map + build) and rewrite `mini/README.md` (variant framing, hardware/pinout/geometry, servo-rate profile, commands). Both document the config-follows-flashed-features direction (FINGERPRINT advertises caps; app/bridge derive config) and the deferred Controller/->normal/ + firmware/common/ refactor. Build-verified on ESP-IDF v5.5 (both reach "Project build complete" with fresh bins): - mini -> esp32 -> mini_6dof.bin - Controller -> esp32s3 -> stewart_platform.bin (unchanged by the submodule bump) Not done here (deliberately): Mini-6DOF not archived; no hardware flashed; no handshake re-architecture; no Controller/->normal/ + firmware/common/ move. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
… job + close trigger gaps
Address coordinator review on the firmware-unification PR:
- Move firmware/README.md -> repo-root FIRMWARE.md (variant map lives next to
mini/ and Controller/); remove the lonely firmware/ directory. Fix all
relative links (../ prefixes) now that it sits at the root.
- Drop mini/build-esp-idf.ps1 (redundant with the 6dof-esp-build skill);
mini/README.md now points at the skill for headless builds.
- CI (.github/workflows/ci.yml): add a "Build Mini Firmware (ESP-IDF)" job that
builds mini/ for esp32 (mirrors the ESP32-S3 Controller job: recursive
submodules, esp-idf-ci-action v5.5.2, uploads mini_6dof.* artifacts).
- Broaden path triggers so a shared-core bump can't slip past CI:
* ci.yml (firmware + SIL): add mini/**, stewart-core (submodule gitlink),
and the workflow file itself.
* unit_tests.yml (C math tests): add stewart-core — the math under test now
lives in the submodule, so a bump must retrigger the tests. This is the
exact gap that let the e5ef989->a820e74 bump go unverified.
Re-verified: mini esp32 build still reaches "Project build complete" with a fresh
mini_6dof.bin. App/SIL tests confirmed 47/47 against a820e74 by the coordinator.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Firmware unification — step 1
Folds the standalone Mini-6DOF firmware into this repo as a second build-time variant alongside
Controller/, both sharing the single rootstewart-coresubmodule. Source files were copied in (not a subtree/submodule of Mini-6DOF). Per6dof/FIRMWARE_UNIFICATION.md+ DECISIONS 2026-07-18.Variant map
Controller/mini/SERVO:RATE)Both point at
../stewart-coreviaEXTRA_COMPONENT_DIRS+PRIV_REQUIRES stewart-core.Changes
Controller/→mini/(excludes.git,build/, generatedsdkconfig, its owncomponents/stewart-core).mini/CMakeLists.txtto the root submodule (mirrorsController/). Nocomponents/stewart-corereference remains.stewart-coree5ef989 → a820e74 (origin/main head: "add output-stage intensity + per-axis gain/invert, schema v6"). Required — the mini Phase-3 firmware usesmcaGetIntensity/mcaSetAxisGain/mcaApplyOutputStage+axis_gain/axis_invert, which live in the shared core per the locked decision.cad/mini/.firmware/README.md(variant map) + rewrittenmini/README.md(hardware/pinout/geometry/commands). Both note the config-follows-flashed-features direction and the deferredController/→normal/+firmware/common/refactor.Build-verified (ESP-IDF v5.5, both "Project build complete" + fresh bin)
mini→ esp32 →mini_6dof.binController→ esp32s3 →stewart_platform.bin(unaffected by the submodule bump)Deliberately NOT done
Mini-6DOF not archived · no hardware flashed · no handshake re-architecture · no
Controller/→normal/move · draft, not merged.🤖 Generated with Claude Code