collector: RSSI of connected sensors via kernel mgmt API

BlueZ fills Device1.RSSI only while scanning; sensors connect to us, so
the field stayed empty. MGMT_OP_GET_CONN_INFO (like btmgmt conn-info)
returns the link RSSI; polled per connected sensor and after each write.
Needs CAP_NET_ADMIN (AmbientCapabilities in the collector unit).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-10 10:58:05 +00:00
co-authored by Claude Opus 5.5
parent 56d635f051
commit 392095d549
5 changed files with 172 additions and 8 deletions
+2
View File
@@ -7,6 +7,8 @@ N = 4
DEFAULT_REPORT_INTERVAL_MIN = 30
STALE_PERIODS = 3 # k: silence for k*period → stale; another k → lost
TICK_INTERVAL_S = 0.5 # connect poll + flush cadence
RSSI_PERIOD_S = 2.0 # link RSSI refresh while a sensor is connected
RSSI_TIMEOUT_S = 3.0 # one mgmt get-conn-info call
ADV_DEBOUNCE_S = 1.0
UI_LOG_LIMIT = 200