-
Notifications
You must be signed in to change notification settings - Fork 1
Flashing the Firmware
NaviCore targets the WCB v3.2 board (ESP32‑S3). There are three ways to get firmware onto a board: the in‑browser flasher (easiest), the Arduino IDE, or the build scripts / CI.
The config tool can flash a connected board directly over USB, pulling the latest compiled binaries from the repo's firmware/ folder.
- Open
config_tool/index.htmlin Chrome or Edge (Web Serial is required — Firefox/Safari won't work). - Plug the board in over USB.
- Go to Config → Firmware.
- Choose one of:
-
⬆ Update Firmware — routine update. Writes the bootloader, partition table, and app, but never touches the data partitions (the LittleFS
/config.jsonstore or NVS), so your saved configuration is preserved. -
⚠ Full Wipe & Flash — initial programming or recovery. Writes the same image and erases NVS (legacy/migration store) plus OTA data. Note: it does not erase the LittleFS partition, so the current
/config.jsonsurvives — to clear a bad config use Restore Defaults (RESET_DEFAULTS) instead. Use Full Wipe the first time you program a new board, or to clear stale OTA/NVS state.
-
⬆ Update Firmware — routine update. Writes the bootloader, partition table, and app, but never touches the data partitions (the LittleFS
Both modes write the same three regions (bootloader + partition table + app); the only difference is whether NVS + OTA data is also erased (neither mode touches the LittleFS config partition). The flasher reuses the port you're already connected on (no second port picker) and reconnects to the board automatically once it reboots — no need to re‑select the port afterward.
The page fetches binaries from main by default. (Developers can target another branch by setting localStorage.rc_fw_branch = '<branch>' in DevTools.)
The flasher uses esptool over Web Serial and needs a direct USB connection — you cannot flash through a "Via WCB" bridge. (The flash buttons are disabled while Via WCB is active.)
- Open
NaviCore.inoin the Arduino IDE. - Tools → Board → ESP32S3 Dev Module (or your usual WCB v3.2 board definition).
- Tools → Partition Scheme → Minimal SPIFFS (1.9 MB APP with OTA / 190 KB SPIFFS).
-
Tools → USB CDC On Boot → Enabled (so
Serialis native USB‑CDC; the firmware relies on this for the SBUS‑out UART allocation). - Tools → PSRAM → OPI PSRAM — required. The firmware allocates its ~210 KB runtime configuration in external PSRAM at boot; if PSRAM is disabled (or set to QSPI) the allocation fails and the board halts with a solid red status LED. The WCB v3.2's ESP32‑S3‑WROOM‑1 N16R8 module has 8 MB of octal PSRAM, hence "OPI".
-
Sketch → Upload, or Export Compiled Binary to produce the three
.binfiles.
Install via Library Manager (versions pinned to match CI — ArduinoJson must be v7; v6's DynamicJsonDocument allocation behavior breaks SET_CONFIG parsing):
- ArduinoJson (Benoit Blanchon) — 7.4.3
- EspSoftwareSerial — 8.1.0 (for S3/S4)
- Adafruit NeoPixel — 1.15.4
- PololuMaestro
Local library (drop into your sketchbook libraries/ folder):
-
WCB_Client + WCBStream (from the
greghulette/WCBClientrepo)
The exact library set + versions live in
.github/workflows/build-firmware.yml— that workflow is the source of truth, so check there if a build ever disagrees with this list.
-
CI (default): every push triggers
.github/workflows/build-firmware.yml, which compilesNaviCore.inofor ESP32‑S3, reads the version fromfw_version.h, and commits the three.binfiles back intofirmware/(tagged[skip ci]). Once that lands onmain, the in‑browser flasher can use it. -
Local: run
tools/build-firmware.ps1(Windows) ortools/build-firmware.sh(Linux/macOS/WSL). Both wraparduino-cliwith the correct FQBN + partition scheme and drop versioned bins intofirmware/. Prereqs:arduino-cli, theesp32core, and the library set from the CI workflow.
Three files per release, matched by suffix (the version prefix can change every build):
| File suffix | Flash address | Purpose |
|---|---|---|
_ESP32S3.bin |
0x10000 |
Application image (ota_0) |
_ESP32S3_boot.bin |
0x0 |
Second‑stage bootloader |
_ESP32S3_part.bin |
0x8000 |
Partition table |
NVS lives at 0x9000; OTA data at 0xE000; the saved config now lives in the LittleFS data (spiffs) partition. Update Firmware leaves all of them alone; Full Wipe & Flash erases NVS and OTA data only — the LittleFS config partition is untouched by either mode.
The version lives in fw_version.h at the repo root:
#define FW_VERSION_BASE "v0.2.0" // bump by hand for releases
#define FW_VERSION_DTG "011009QJUN26" // auto-stamped by the pre-commit hook
#define FW_VERSION FW_VERSION_BASE "_" FW_VERSION_DTG-
FW_VERSION_BASE— semver; edit by hand when cutting a release (v0.2.0 → v0.2.1 → v0.3.0 → v1.0.0). -
FW_VERSION_DTG— a Date‑Time‑Group stamped automatically bytools/git-hooks/pre-commiton every commit. Don't edit by hand.
The build embeds both into the .bin filename, and the firmware reports FW_VERSION in its boot banner and in the PONG reply — so the file on disk, the running version, and the source header always match. The config tool shows the connected board's version in its footer and on the Firmware tab.
Next: Transmitter Setup · Config Tool Guide
NaviCore — Astromech Animation Controller · Home · WCB v3.2 / ESP32‑S3
Setup
- Setup Guide — start here
- PCB Assembly and BOM
- Hardware and Wiring
- Flashing the Firmware
- Transmitter Setup
- Connecting
- Config Tool Guide
- Maestro Setup
Reference
- Action Editor and Command Library
- Actions Reference
- WLED and HCR Audio
- Record and Replay
- Cheat Sheet
- Configuration Schema
- WCB Network
- Remote Management over WCB
- Serial JSON Protocol
- CLI Commands
- Failsafe and Signal Loss
- Glossary
Help