Commit Graph
3768 Commits
Author SHA1 Message Date
Jason Huebert 3c4bb6b277 feat: support two MQTT observer broker slots
Rework the observer configuration to numbered mqtt1.*/mqtt2.* broker
slots with shared mqtt.* settings, expand the observer target catalog,
and update the user guide and tests.
2026-10-19 08:36:57 -05:00
Jason Huebert d7987cf653 feat: expand MQTT observer configuration 2026-10-19 08:36:57 -05:00
Jason Huebert f904b6b755 feat: add optional MQTT observer firmware 2026-10-19 08:36:57 -05:00
github-actions[bot] 02ff9675c8 Merge remote-tracking branch 'origin/main' into repeater-filter-stable
# Conflicts:
#	README.md
v1.18.0 filter-v1.18.0
2026-10-15 13:45:19 +00:00
Scott Powell 81dbae592f Merge branch 'dev' 2026-10-15 19:42:40 +11:00
Scott Powell 07a833bbbe * version 1.18.0 2026-10-15 19:42:01 +11:00
ripplebiz 9043a2bbf8 Merge pull request #3596 from recrof/wifi-companion-boards
added dynamic wifi to: heltec wsl3, v4r8, wireless paper; rak 3112; seeed xiao s3 (wio)
2026-10-15 19:35:32 +11:00
Rastislav Vysoky 97c0aec8d6 added dynamic wifi to: heltec wsl3, v4r8, wireless paper; rak 3112; xiao s3 (wio) 2026-10-15 09:57:31 +02:00
ripplebiz f1b608a777 Merge pull request #2377 from fschrempf/dev
Disable NRF52 undervoltage bootlock feature
2026-10-15 15:02:12 +11:00
Jason Huebert 8ff51b81dd ci: split upstream sync from stable promotion v1.17.1-r7 filter-v1.17.1-r7 2026-10-14 15:09:36 +00:00
Jason Huebert 704616f65f fix: widen per-rule airtime counter 2026-10-14 15:09:36 +00:00
Jason Huebert e0754a74ba fix: display filter airtime in seconds 2026-10-14 15:09:36 +00:00
Jason Huebert 39f0f88fd6 feat: lower fleet !ack reply window default to 15 s
The 60 s default made every !ack test cycle a long wait, and most fleets
are a handful of nodes. Drop the default to 15 s and document a sizing
rule of thumb (~5 s per repeater, never below ~15 s) so operators widen it
deliberately as the fleet grows.

- FLEET_REPLY_WINDOW_MS 60000 -> 15000 (FleetConfig.h)
- FLEET.md: storm-control sizing guidance, command/limits tables, default
- test_fleet: default reply-window assertion
2026-10-14 15:09:36 +00:00
Jason Huebert 878d883710 docs: clarify that a fleet job is one message, not several
Clarify in FLEET.md that a job's commands are the lines of a single group
text and cannot be split across messages: only a message's first line is
checked for the !id marker, so a lone command is ordinary chat. Spotted in
field use, where the 'send the commands one at a time' reading was natural.

- Quick start gains a 'one job = one message' callout
- Script format states a job cannot be split across messages, with an example
- Troubleshooting gains a matching row (noid counter climbing)
2026-10-14 15:09:36 +00:00
Jason Huebert e7974760b5 fix: only include merged firmware when present 2026-10-14 15:09:36 +00:00
Jason Huebert feb0cbc872 fix: include ESP32 -merged.bin assets in local release uploads
The per-target upload file list was built with a glob that does not match
the '-merged.bin' suffix of the mergebin artifact, so ESP32 merged
firmware was built and staged in out/ but never uploaded (dev.17 shipped
208 assets instead of 299). Add it to the artifact list.
2026-10-14 15:09:36 +00:00
Liam Cottle 2586f7abe3 Merge pull request #3591 from liamcottle/feature/companion-ble-wifi
Add WiFi support to Heltec v3 and v4 BLE variants
2026-10-14 20:23:11 +13:00
liamcottle a0fc769660 rework companion ui for ip address so it fits in multi interface variants 2026-10-14 16:29:41 +13:00
liamcottle c0d00a060a enable wifi interface for heltec v4 ble variant 2026-10-14 15:16:55 +13:00
liamcottle 590bc23ab9 enable wifi interface for heltec v3 ble variant 2026-10-14 15:05:00 +13:00
Liam Cottle 8e48e01a4b Merge pull request #3589 from meshcore-dev/remove-room-repeater
Room: "set repeat" CLI now deprecated
2026-10-14 14:27:54 +13:00
Scott Powell 481f72cae7 * only 'repeat on' now intercepted 2026-10-14 12:21:38 +11:00
ripplebiz d86cad8a82 Merge pull request #3575 from agessaman/feat/lr1121-dual-band-power
LR1121: keep TX power valid across sub-GHz and 2.4 GHz
2026-10-14 12:04:47 +11:00
ripplebiz 97113a7050 Merge pull request #3574 from agessaman/feat/waveshare-esp32s3-lr1121
feat(variants): add Waveshare ESP32-S3-LR1121
2026-10-14 12:00:11 +11:00
Scott Powell 8579c66747 * Room: "set repeat" CLI now deprecated 2026-10-14 11:48:58 +11:00
ripplebiz b47fd54905 Merge pull request #3573 from meshcore-dev/ack-timing-fix
ACK forwarding timing fix
2026-10-13 15:48:29 +11:00
ripplebiz 52d7bf1551 Merge pull request #3568 from meshcore-dev/zero-scope
Treat transport code 0 the same as un-scoped.
2026-10-13 15:48:02 +11:00
agessaman eac6e66b1b fix(radiolib): keep LR1121 tx power valid across sub-GHz and 2.4 GHz
- Clip requested power to the active PA's range instead of failing. A
  stored 22 dBm was rejected at 2.4 GHz (HF PA max 13 dBm), and since
  setTxPower ignores errors the sub-GHz PA stayed configured.
- Re-apply the requested power after every successful retune: PA choice
  depends on the band, and set radio / tempradio only call setParams.
2026-10-11 21:07:05 -07:00
agessaman 3d1a5d4c64 feat(variants): add Waveshare ESP32-S3-LR1121
ESP32-S3FH4R2 (4MB flash, 2MB PSRAM, native USB-CDC) with an LR1121.
Pins, the DIO5/DIO6 RF switch table and the 1.8 V TCXO follow the HF
schematic and Waveshare's examples. Envs: repeater, room server,
companion USB/BLE and KISS modem, all on min_spiffs so roles share one
partition layout.

Only RFO_HP_LF is wired (R4 on RFO_LP_LF is not fitted), so the new
opt-in LR1121_FORCE_HP_PA flag keeps RadioLib on the HP PA at <= 14 dBm,
where it would otherwise select the unconnected LP PA.
2026-10-11 20:51:18 -07:00
Scott Powell 6df5aaed43 * ACK forwarding (in direct mode) had zero delay 2026-10-12 10:44:42 +11:00
Jason Huebert cf81dc6082 ci: include native_fleet in the stable promotion test gate
The gate ran the generic and filter/battery suites but not the fleet
suite, so stable could be promoted with fleet changes that were never
gate-tested. Align the gate with the full five-env run.
v1.17.1-r6 filter-v1.17.1-r6
2026-10-09 18:28:47 +00:00
Jason Huebert e908b649fd ci: fix stable promotion failing when main is already merged
The stable-promotion step staged the fork README before the cherry-pick
loop, relying on the main-merge commit to carry it. When main is already
contained in stable the merge is a no-op, the staged README change is
left uncommitted, and every cherry-pick is refused before it starts
(your local changes would be overwritten). With no pick state left, the
cherry-pick --abort cleanup fails too and the step dies unhandled.

Restore the README only when a merge commit is actually being created;
the post-loop README sync already covers the no-merge case.
2026-10-09 18:28:47 +00:00
Jason Huebert 00bd055990 ci: rename filter-build.yml to filter-release.yml
The workflow no longer builds anything; the file name was the last
stale artifact of the rename. Updates the two reusable-workflow calls
in sync-upstream.yml, the concurrency group id, and the references in
AGENTS.md and the local build script's comments.
2026-10-09 18:28:47 +00:00
Jason Huebert 4227229509 refactor: trim local-release-build.sh
- workers receive their platform from the map computed once up front
  (WORKER_PLATFORM) instead of re-running pio project config through a
  subprocess per target -- 155 subprocess invocations saved per full run
- fail a worker that compiles but produces no artifacts, instead of
  surfacing later as a confusing empty gh upload
- (fix en route: the first platform-plumbing attempt looked the platform
  up under the wrong key inside run_one -- caught by the end-to-end
  test, not by syntax checking)
2026-10-09 18:28:47 +00:00
Jason Huebert 56ef4d5c31 ci: simplify release workflows
- filter-build.yml: drop the create_release input — the workflow's only
  purpose is cutting a release, and an input to make it a no-op was
  vestigial; the release job runs unconditionally
- filter-build.yml: replace the hand-rolled natCmp comparator (~16 lines
  of JS) with git's own version sort (--sort=-v:refname), which orders
  this tag scheme identically — verified against the fork's tags:
  dev prevTag filter-v1.17.1-dev.16, next counter 17, stable r5
- sync-upstream.yml: rename job ids build-dev/build-stable to
  release-dev/release-stable to match what they do now
2026-10-09 18:28:47 +00:00
Jason Huebert 33194ab4de fix: make local-release-build.sh machine-independent
- pin LC_ALL=C for the embedded build date: %b is locale-dependent, so a
  non-English system would bake a different FIRMWARE_BUILD_DATE string
  (and different artifact bytes) than CI or any other machine
- fail fast with a clear message on bash < 4 (mapfile/declare -A/wait -n;
  macOS ships bash 3.2)
- document the remote assumption: the bare-tag form needs a remote named
  "fork"; the release-URL form works from any clone

No other machine- or user-specific bits: paths are $HOME-based, the
PlatformIO home is the generic default, and gh targets are passed
explicitly.
2026-10-09 18:28:47 +00:00
Jason Huebert 74de6fe2bc ci: manual sync only; every non-fork workflow disabled
- sync-upstream.yml: drop the weekly cron; sync and stable promotion now
  run only when dispatched deliberately
- disabled at the fork level (Actions settings, no file changes):
  run-unit-tests, github-pages, stale-bot — leaving only the fork-owned
  sync-upstream and filter-build workflows active
2026-10-09 18:28:47 +00:00
Jason Huebert b553a04194 ci: cut releases in CI without building firmware
The 155-target build matrix cost 6-7 runner hours per release and got
Actions disabled on the fork. Firmware is now built and uploaded locally
(scripts/local-release-build.sh); CI keeps only the parts that are cheap
and need to be centralized.

- filter-build.yml: drop the validate-targets and build jobs and the
  targets input; keep the version job (tag scheme and change gate are
  unchanged) and create the release with no assets — the local script
  fills the assets in afterwards
- sync-upstream.yml: same two calls, retitled Create release; the
  force_build input now means create-the-release, not build
- AGENTS.md: describe the new split and where the stack-usage gate lives

Also disabled the upstream firmware-builder workflows at the fork level
(Actions settings, no file changes, so weekly upstream syncs cannot
conflict): build-{companion,repeater,room-server}-firmwares,
firmware-builder, and pr-build-check, which built firmware on every
push to main/dev — i.e. on every weekly sync.
2026-10-09 18:28:47 +00:00
Jason Huebert ad386360ce feat: add local release build script
Builds a filter release's firmware locally and uploads the assets to its
GitHub release, replacing the 155-target GitHub-hosted runner fan-out.
Given a release URL or tag, it checks out the exact commit the release
names into a persistent worktree (reruns are incremental via .pio),
builds every repeater target of the release tree N at a time, and streams
each target's artifacts to the release as it finishes.

- mirrors build.sh's per-target logic (build.sh itself cannot run in
  parallel: it wipes out/ on every invocation)
- version derivation and build flags match what filter-build.yml produced
- carries the stack-usage gate that used to run per target in CI
- uploads via gh from the host; build workers run in an isolated venv
  with PlatformIO's pinned toolchains, so nothing else on the machine
  participates in the build
2026-10-09 18:28:47 +00:00
Jason Huebert 00f163c6aa ci: simplify workflows; default to all repeater targets
- filter-build.yml: with no explicit targets input, build every repeater
  target this branch defines (build.sh list, case-insensitive 'repeater'
  match) instead of falling back to the FIRMWARE_TARGETS repo variable,
  so the variable is no longer needed and stable publishes the full
  repeater set like dev. Explicit input still validates with the
  unknown-name warning.
- filter-build.yml: drop the dead 'Clear stale artifacts' step (fresh
  runner, no out/ can exist) and trim release needs/if: validate-targets
  is required transitively through build, and a skipped build skips the
  release anyway, so the skip re-check is redundant.
- sync-upstream.yml: the two near-identical conflict-issue scripts
  (~50 lines each) become calls to a new composite action
  .github/actions/open-conflict-issue; one authoritative copy of the
  marker/search/update-or-create/setFailed logic.
- sync-upstream.yml: 'Configure Git' is two git config lines, not a
  github-script step spawning git in a loop.

Verified: all YAML parses; simulated target selection against
build.sh list resolves 155 repeater targets with no non-repeater
leakage and a working explicit-input path.
2026-10-09 18:28:47 +00:00
Jason Huebert 32068f4c73 ci: replace every shell step with github-script actions
All 'run:' steps in sync-upstream.yml and filter-build.yml become
actions/github-script scripts driving git/build via spawnSync, so no
step interprets input text as shell syntax and the actions carry no
shell scripting at all.

- Derive Version: JS port of the tag-scheme derivation; verified
  byte-equivalent to the shell version against this repo's state and a
  synthetic tag zoo (dev counter, -rN suffix, date-tag filtering,
  sort -V ordering). Dead SHORT_SHA dropped.
- Sync/promotion: git orchestration via spawnSync; conflict paths set
  their outputs and exit cleanly, and the conflict-issue steps raise
  core.setFailed. The two 'Fail on conflict' steps (run: exit 1) are
  gone; the stable issue step previously never ran because the stable
  step's exit 1 skipped it via the implicit success() gate — the
  failure now always comes from the issue step that reports it.
- Build Firmware / Clear stale artifacts: build.sh is invoked through
  spawnSync instead of a shell line.

Verified the merge, promotion and conflict paths against a throwaway
fork/upstream fixture (clean merge, conflict abort with
conflicted-files.txt, cherry-pick, README-only skip, README sync,
gate-skip, push/idempotent rerun, bad source branch).
2026-10-09 18:28:47 +00:00
Jason Huebert 3195199579 feat: fleet ack reply uses repeater path-hash size and default flood scope
The ack reply was sent via sendFlood(): 1-byte path hashes and an
unscoped flood, regardless of the repeater's configuration. Route it
through a new sendFleetReply() hook on MyMesh that sends with the
repeater's configured path-hash size and, when a default flood scope is
set, scoped; with no default scope set it stays unscoped. The scoping
contract is documented in FLEET.md in the same commit.
2026-10-09 18:28:47 +00:00
Jason Huebert f56ff42425 feat: fleet ack reply body — newline after job key
Separate the job key from the response with a newline instead of a
space, so companions show the id and the response on distinct lines.
The body buffer is unchanged (the newline replaces the space byte), so
one packet still carries the same summary length. FLEET.md documents
the on-air body format, so that section is updated in the same commit.
2026-10-09 18:28:47 +00:00
Jason Huebert adef8a58bd ci: fix unmatched brace in stack usage check step
The OK-path echo used ${SU_FILES[@]" with no closing brace, so bash
consumed the rest of the script hunting for it and the step died with
'unexpected EOF while looking for matching }' before any .su file was
inspected. The firmware builds themselves compiled clean; every matrix
target failed only here (run 37724977530).
2026-10-09 18:28:47 +00:00
Jason Huebert 6b3f3fb5f1 fix: fleet script intake, kill switches and relay exemption
Found by on-air and on-device adversarial testing of the fleet CLI and the
script runner (Xiao repeater, driven through the aries companion).

- !at 0000000000 parsed to due_epoch 0, which the manager read as "run now":
  the script ran at once, bypassing the stale and clock-unset refusals.
  parse() now reports a `scheduled` flag, so 0 is a (stale) time.
- fleet off and fleet chan clear are the kill switches, but queued, sleeping
  and armed (!at) scripts kept running. They are now cancelled between passes
  (never inside run(), so a script switching the fleet off cannot pull its
  own slot away). Their keys stay consumed.
- A key forgotten while its job was still queued, sleeping or armed could be
  queued or armed a second time and run twice. A re-send of an in-flight job
  is now a duplicate.
- The relay exemption matched the one-byte channel hash, so every packet on
  any of the ~1-in-256 channels sharing it bypassed the battery gate.
  onGroupData() now records the packet the core just MAC-verified under the
  fleet key (MyMesh passes the packet, one-line hook change), and
  checkForward() exempts only that packet, by content hash.
- Scripts must be plain group text (txt_type 0). Other types were executed.
- The noid counter never moved, and malformed scripts were not counted as
  refused; both now match FLEET.md.
- The fleet status line shows badline, as documented.
- execCliLine logs `cli[key] line` before dispatch: the handlers tokenise the
  line in place, so the transcript showed a truncated command.

Tests: test_fleet covers each case (97 cases, ASan/UBSan clean). The five-env
native run is green (490 cases). FLEET.md and BATTERY.md updated to match.
2026-10-09 18:28:47 +00:00
Jason Huebert 78c79c1a95 fix: fleet acks must carry the group text header or every receiver drops them
fleetReplySend() composed the ack as a bare "<name>: <body>" string, but a
GRP_TXT payload on air is [ts(4)][txt_type(1)]"<name>: <body>" — receivers
parse the first five bytes as the text header (BaseChatMesh::onGroupDataRecv).
With the raw text, the byte at offset 4 was '-' (0x2d), an unsupported
txt_type, so every ack was dropped by every receiving device: scripts ran and
acked, but companions never saw the reply.

Compose the header like BaseChatMesh::sendGroupMessage does. FLEET.md already
documented replies as txt_type 0x00 plain group texts, so docs are unchanged.
2026-10-09 18:28:47 +00:00
Jason Huebert 631641787a docs: AGENTS.md — stack is a boot-breaking constraint the suites cannot see 2026-10-09 18:28:47 +00:00
Jason Huebert ea5ffa969a ci: fail targets whose repo code holds a stack frame >= 2 KB
The 2026-10 boot crash-loop shipped because a compiler-measurable hazard
(~8.5 KB of scratch in one boot-path frame vs a 4 KB nRF52 / 8 KB ESP32
loop-task stack) is invisible to the host-native test suites. Each release
target now builds with -fstack-usage (metadata-only, codegen unchanged) and
fails when any src/ or examples/ frame reaches 2 KB; the check errors out
loudly if the scan comes up empty instead of passing blind. Vendored
crypto and libdeps libraries are excluded: their larger frames ship today
and are not what this repo edits.
2026-10-09 18:28:47 +00:00
Jason Huebert 88ee19493a fix: parse filter config into the member stores — the stack scratch overflowed boot on ESP32
The v7 capacity bump (32 rules + 32 channels) made FilterRules::load()
stack-allocate ~8.5 KB of scratch copies on top of an already deep boot
chain. The Arduino loopTask stack is 8 KB, so every repeater that booted
this build ran off the bottom of the stack into the adjacent heap block;
the first fopen() after the overflow then died in malloc (Guru Meditation
LoadProhibited, crash-loop at boot, no config file required).

load() now parses straight into rules/channels, which resetToDefaults()
has already zeroed, and re-resets on a failed parse so a partial store
never survives. Behavior is unchanged; all 475 native tests pass as-is.
2026-10-09 18:28:47 +00:00
Jason Huebert 4c38c307aa fix: load() must not wipe the fleet's injected device services
resetToDefaults() NULLed time_fn/jitter_fn/send_fn, and load() calls it —
but MyMesh::begin() wires those services in just before fleet.begin(fs), so
after every boot the clock read as unset (!at jobs always refused) and
send_fn was NULL (!ack replies silently dropped). Wiring, not config
state: the three members now get in-class initializers and
resetToDefaults() never touches them.

Regression test drives a load after wiring the clock and asserts the !at
admission path still sees it; verified the test fails against the old
resetToDefaults() and passes with the fix. AGENTS.md fleet count 81 -> 82.
2026-10-09 18:28:47 +00:00