feat(repeater): passive mesh analyzer -- nodes + rxlog over the console

Two RAM-only, opt-in tables fed from the normal RX path and pulled out
over the text console (serial / BLE) for a BLE bridge + map to consume.
Both are compiled out unless the build sets a non-zero size; enabled on
SenseCap_Solar_repeater_ble (-D MAX_HEARD_NODES=48 -D RXLOG_SIZE=96,
~6 KB RAM).

  nodes [offset]  -- registry of heard REPEATERS and ROOM SERVERS (chat
    clients are deliberately skipped: personal/mobile devices, privacy).
    Per node: pubkey prefix, name, type, lat/lon, last SNR/RSSI, seconds
    since heard, and the path the advert arrived by. Fed from onAdvertRecv
    (adverts are signature-verified upstream). -> map dots + topology
    edges + link quality.

  rxlog [cursor]  -- circular firehose of EVERY parsed frame heard, fed
    from logRx() (synchronous, so SNR/RSSI belong to that frame). Per
    record: monotonic seq (paging cursor), time, packet hash, header
    (route|type), SNR/RSSI, hop path. -> live traffic / analyzer view.

Both replies are paged to stay within the ~160 B console reply cap and
carry a trailer (next cursor + totals) so the bridge can drain and detect
if it fell behind the ring. Reachable over serial, the PIN-paired BLE
console and the admin mesh CLI, same as `neighbors`.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
tthandClaude Opus 4.8 committed 2026-07-12 00:19:32 +02:00
1 parent 5c092498ff
commit 44aa778e97
3 files changed
+261 -1

No files matched your search

+6
View File
@@ -80,6 +80,12 @@ build_flags =
; GPS on/off itself persists via the `gps on|off` CLI command (NodePrefs).
; Note: the L76K draws ~25-35 mA — plan for the extra power on a solar node.
-D ENV_SKIP_GPS_DETECT=1
; Passive mesh analyzer (TeTeHacko): expose heard repeaters/room servers and a
; frame firehose over the text console for a BLE bridge/map. RAM-only, ~10 KB.
; nodes [offset] -> heard repeater/room registry (identity, geo, SNR, path)
; rxlog [cursor] -> circular log of every frame heard (type, path, SNR/RSSI)
-D MAX_HEARD_NODES=48
-D RXLOG_SIZE=96
; -D MESH_PACKET_LOGGING=1
build_src_filter = ${SenseCap_Solar.build_src_filter}
+<../examples/simple_repeater/*.cpp>