mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-09-14 15:16:40 +00:00
refactor(solo): move solo build configs into their own solo/ folder; one build per board; document all build flags
Solo's `_solo_dual` env for each board lived inside variants/<board>/, mixed in with the shared upstream board configs (repeater, room server, plain companion) that every MeshCore fork carries. Split them out into their own top-level solo/<board>/ folder -- each still `extends` the board base defined in its original variants/<board>/platformio.ini, just no longer interleaved with it file-wise. - platformio.ini: extra_configs picks up solo/*/platformio.ini alongside variants/*/platformio.ini. - build-solo-firmwares.yml: env-discovery grep now scans solo/ instead of variants/ (the release matrix is unchanged -- same 8 envs, same names). - pr-build-check.yml: solo/** added to the trigger paths. - GAT562 30S Mesh Kit: dropped the separate solo_ble env -- solo_dual is a strict superset (BLE still works, plus USB), and every other board only ever had one solo build to begin with. - GAT562 Mesh Watch13: renamed solo_ble -> solo_dual (added DUAL_SERIAL=1) to match. No comment anywhere recorded whether this board's USB data lines are actually broken out to a connector -- DUAL_SERIAL compiles and works over BLE regardless, so worst case the USB half goes unused. - Removed a dead AUTO_SHUTDOWN_MILLIVOLTS from the three solo envs that set it (Heltec V3/V4, T-Echo Lite+KeyShield): that macro is only ever read in the old ui-tiny UITask, never ui-new, which every solo build (these included) uses -- it did nothing on any of them. Left alone everywhere else it's set (non-solo companion envs elsewhere use ui-tiny/ui-orig, or the flag is legitimately read); out of scope here. - Added docs/solo_features/build_flags.md: every optional -D flag a solo build understands (GPIO, CardKB/joystick, Hall-sensor cover lock, buzzer/ vibration, GPS switch, display/battery tuning), verified against the code rather than the existing per-board comments, with what's already baked into every solo build kept separate from what's opt-in. - README: doc index + Building from source section link to the new page; path references to the moved solo files updated to solo/<board>/. All 8 solo_dual envs rebuilt clean after the move; native test suite (40 cases) unaffected. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
; Solo build for GAT562 30S Mesh Kit -- extends the board base defined in
|
||||
; variants/gat562_30s_mesh_kit/platformio.ini. Solo configs live in their own
|
||||
; top-level solo/ folder, separate from the shared upstream board variants in
|
||||
; variants/, so this repo's Solo-specific additions don't get mixed in with
|
||||
; configs other MeshCore forks/upstream also carry.
|
||||
;
|
||||
; Dual (BLE+USB) only -- the previous BLE-only solo_ble env was dropped since
|
||||
; dual is a strict superset (BLE still works, plus USB) and Solo standardises
|
||||
; on one build per board.
|
||||
[env:GAT562_30S_Mesh_Kit_solo_dual]
|
||||
extends = GAT562_30S_Mesh_Kit
|
||||
board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
|
||||
board_upload.maximum_size = 712704
|
||||
; Optimise for size, not speed: the nRF52 Arduino core defaults to -Ofast
|
||||
; (≈ -O3 + -ffast-math), which bloats flash by ~200 KB on this feature-rich
|
||||
; solo build. -Os keeps every feature, fits comfortably, and is actually safer
|
||||
; for float (no fast-math reassociation). Speed is irrelevant for the UI/mesh.
|
||||
build_unflags = -Ofast
|
||||
build_flags =
|
||||
${GAT562_30S_Mesh_Kit.build_flags}
|
||||
-I examples/companion_radio/ui-new
|
||||
-D DISPLAY_CLASS=SSD1306Display
|
||||
-D MAX_CONTACTS=350
|
||||
-D MAX_GROUP_CHANNELS=40
|
||||
-D BLE_PIN_CODE=123456
|
||||
-D OFFLINE_QUEUE_SIZE=256
|
||||
-D FIRMWARE_SOLO_BUILD=1
|
||||
-D MESHCORE_VERSION='"1.17"'
|
||||
-D UI_SENSORS_PAGE=1
|
||||
-D UI_HAS_JOYSTICK_UPDOWN=1
|
||||
-D ADVERT_NAME='"@@MAC"'
|
||||
-D ENV_INCLUDE_GPS=1
|
||||
; misc-fixed 6x9 OLED font (full Latin/Greek/Cyrillic), same as the Wio L1
|
||||
; builds. Solo only: it costs ~14 KB of flash and the repeater/companion
|
||||
; builds have no keyboard to type those alphabets on.
|
||||
-D OLED_MISC_FIXED_FONT=1
|
||||
-D DUAL_SERIAL=1
|
||||
-D ENABLE_SCREENSHOT
|
||||
-Os
|
||||
; QSPIFLASH disabled: QSPI IO0/IO2 pins (P0.30/P0.28) conflict with joystick LEFT/UP
|
||||
; -D MESH_PACKET_LOGGING=1
|
||||
; -D MESH_DEBUG=1
|
||||
build_src_filter = ${GAT562_30S_Mesh_Kit.build_src_filter}
|
||||
+<helpers/nrf52/SerialBLEInterface.cpp>
|
||||
+<helpers/ui/buzzer.cpp>
|
||||
+<../examples/companion_radio/*.cpp>
|
||||
+<../examples/companion_radio/ui-new/*.cpp>
|
||||
lib_deps =
|
||||
${GAT562_30S_Mesh_Kit.lib_deps}
|
||||
adafruit/RTClib @ ^2.1.3
|
||||
densaugeo/base64 @ ~1.4.0
|
||||
end2endzone/NonBlockingRTTTL@^1.3.0
|
||||
Reference in New Issue
Block a user