The generic `pio test -e native` selected test_packet_filter and test_battery_gate, which need their own include paths, source selection and filesystem shim; both errored out and failed the whole command. List them in test_ignore so each runs in the environment that can actually build it. Also correct the safety net the review found unsound: - makePacket() left payload, path and transport codes uninitialized while mesh::Packet's constructor only sets header/path_len/payload_len, so tests hashed whatever the stack held. Initialize them, and clamp payload_len, hsz and hops to the real buffer bounds. LenInterval's 200-byte packet became the 184-byte boundary that actually exists; the hsize=4 case is now labelled artificial, since Packet::setPath rejects hash size 4 as reserved. - filterCLI() was called through a null RegionMap*, and the CLI does call members on it. Provide the real constructor in the stub and pass an instance. - NativeFile::read() formed a data pointer for zero-length and past-EOF reads, so reading an empty file passed nullptr to memcpy. Return 0 first. write() validates its backing store and tracks position; the two-argument open now honours "r"/"w", and flush/rename exist for the persistence work to come. - The CLI helper now replies into the real 160-byte CLI_REPLY_MAX with a canary after it, asserting both no overrun and NUL termination in the window. Add ASan+UBSan environments for both feature suites so "assertions passed" is not mistaken for "no undefined behaviour". The three problems the review found this way — the oversized fixture, the null member call and the empty read — had all been passing their assertions. 54 native + native_kiss_modem cases green; the sanitizer envs report zero diagnostics.
MeshCore — Repeater Firmware with a Remote-Configurable Packet Filter
This is a feature fork of MeshCore. It tracks upstream automatically (synced weekly) and adds two repeater-focused capabilities on top of stock firmware. Everything else — supported boards, clients, protocols, build system — is identical to upstream; see the upstream README for the general project, hardware support, and getting-started guide.
What this fork adds
📡 Packet filter
A remote-configurable drop-rule engine for the simple_repeater firmware.
Rules match on packet type, route type, region, hop count, channel, and —
on decrypted payloads — channel identity and sender/text patterns. Rules are
managed over the repeater CLI, locally via serial or remotely over the mesh
by an authenticated admin. No rebuild, no physical access.
Independently of the rules, flood-route adverts can be rate-limited per originating node: each node's advert is forwarded at most once per window (up to 30 days), taming advert storms on busy channels while every node stays discoverable.
→ Full guide, including the complete predicate reference and CLI commands: FILTER.md
🔋 Battery gate
A configurable low-battery cut-off: below a set voltage the repeater stops forwarding (but stays reachable and keeps advertising); when the battery recovers it resumes automatically. Debounce + hysteresis keep it from flapping, and the admin can check voltage and tune thresholds over the mesh.
→ Full guide: BATTERY.md
Why run this instead of stock repeater firmware?
Stock repeaters forward everything they hear, until the battery dies. This fork is for operators who want policy and resilience at the node:
- Shared / community nodes — mute noisy senders or channels that eat your airtime, without asking anyone to change their setup.
- OpenHop-style policy, nothing extra to run — the rule engine is modelled after the policy filters in OpenHop and lives entirely in the repeater firmware, so you get about the same functionality with just the node itself — no computer, companion app, or other hardware needed.
- Solar / off-grid sites — the node goes quiet while it can still answer you, instead of disappearing dark, and wakes itself when there's sun again.
Getting the firmware
Prebuilt binaries for all supported boards are on the Releases page. Two channels:
| Channel | Branch | Based on | Tags |
|---|---|---|---|
| dev | repeater-filter |
upstream dev (merged weekly by CI) |
filter-v*-dev.N |
| stable | repeater-filter-stable |
upstream main releases |
filter-v* |
Flash as you would stock firmware, then follow FILTER.md to set your first rules over the CLI.