ota: admin OTA statistics — ota stats reply

Add an admin-only `ota stats` reply: one dense line with the running firmware's merkle content-id (mid) AND its EndF body_hash (only body_hash was surfaced before), version, served-set count + digest, live fetch state/progress, and policy — snprintf-bounded to the 160-byte reply. The remote CLI path is already admin-gated, so it's admin-only over the mesh (send it from the app's repeater command screen, or the WiFi/serial OTA console). A new servedDigest() accessor exposes the beacon set-digest.

HW-verified on RAK4631: reports the fw identity + live fetch state (incl. during a warm-start capture).
This commit is contained in:
Valentin Kivachuk Burda committed 2026-07-03 08:02:37 +02:00
1 parent 8953214761
commit b159737ede
3 files changed
+63 -2

No files matched your search

+11
View File
@@ -47,6 +47,16 @@ ota status
Shows your current firmware version, your node's update "target" (its hardware/role id), and whether a
download is in progress.
For a denser admin view — your firmware's content id (`mid`) **and** its body hash, the fingerprint of the
set you're serving, live download progress, and the current policy — use:
```
ota stats
```
On a remote node this is **admin-only** (the remote command console requires the admin password) — send it
from the app's repeater command screen, or the WiFi/serial OTA console.
### 2. Find updates available near me
```
@@ -229,6 +239,7 @@ that only contains what changed). You get them by:
|---|---|
| List all commands | `ota help` |
| See my firmware + any download | `ota status` (or just `ota`) |
| Admin: ids/hashes + serving + policy | `ota stats` (admin-only remotely) |
| Find updates nearby | `ota ls` |
| Download update #1 | `ota get 1` |
| Cancel a download | `ota cancel` |