The device list and detail page showed empty status columns/fields until
every request finished. They now render instantly from the last-known data
and refresh in the background, with a small "Syncing…" spinner in the page
header while fresh data is in flight.
- lib/deviceCache.js: last-known device list (per query), devices by id,
fleet status map, list metrics and Health-overview datasets. In memory
plus sessionStorage (except the large Health datasets); every storage
access is guarded.
- DeviceList: seeded from cache; status + metrics fetched in parallel with
the device list instead of after it; out-of-order search responses are
ignored; live heartbeats are written back to the cache.
- DeviceDetail: seeded from cache (DeviceList already holds the device),
reloads after modal saves refresh in place instead of unmounting the
tab, status comes from the new /mqtt/status/{serial}.
- HealthTab overview: same stale-while-revalidate per device + range.
Health tab firmware lag: the Firmware/OTA tile read the version from the
latest diagnostics report, which the firmware sends only every 5 minutes
(the first 5 minutes after boot), and the tab never re-fetched it while
open — so after an OTA it kept showing the old version. Firmware reports the
same compiled FW_VERSION in heartbeat and diagnostics, so the tile now uses
the heartbeat (30s, pushed live over WebSocket) and only shows the OTA
"update available" badge when the diagnostics report describes the
firmware that is running now. HealthTab also passes deviceId/canEdit down
to LogsTab for the log management actions in the next commit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- CrashDetail (components/shared): headline is abort_msg when present,
else the Xtensa exception name. For aborts, pc/exception/fault address are
shown muted with a note that they describe abort() and that the first
2-4 frames are abort internals. Shows task, uptime at crash, heap stats with
a "likely heap exhaustion / fragmentation" badge (largest_block < 12000 or
free_heap < 25000, F-055), PC + backtrace as 0x%08X in ESP serial format,
a copyable addr2line command (PC, backtrace, then the PC parsed from
"abort() was called at PC ..."), elf_sha256, and a backtrace-corrupted
flag. When the server has the build's ELF and addr2line, a Decode button
shows function + file:line per frame.
- Health tab boot history uses it, previews the headline in the row, and
gets a "Sync from device" button (telemetry.get_boot_history, merged
server-side).
- New /devices/crashes page (linked from the Fleet header): crashes grouped
across devices with per-device counts and the latest occurrence.
- Firmware release modal: optional firmware.elf attachment.
- API reference: boot_report payload documents the F-070 fields.
- lib/crashReport.js holds the parsing/formatting rules; lib/clipboard.js
a copy helper with a non-secure-context fallback.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Surfaces the new device-health telemetry (boot events, ping RTT,
diagnostics reports, alert events) across the console:
- HealthTab: boot/diagnostics timeline, CPU temp and RSSI charts
(LineChart), current alert status, and a Settings sub-tab for
DeviceHealthSettings thresholds
- LogsTab: dedicated log explorer embedded in the Health tab, with
level/source filtering and fmtLogTimestamp for dense timestamp rows
- OverviewTab: a "Latest Device Issue" card showing the most recent
alert event, colour-coded by severity and fading with age, plus a
modal to inspect the surrounding log lines
- DeviceList/DeviceListCardView/DeviceListMapView: fleet list gains a
SignalIndicator-based RSSI display in place of the plain online dot
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>