Add a saved override to keep USB packet logging continuous
This commit is contained in:
1 parent
1f2fcfc449
commit
05679aa741
18 files changed
+382
-39
No files matched your search
@@ -56,6 +56,8 @@ current source. Where `usb.logging` is available, `get/set usb.debug on|off`
|
||||
selects debug intent without changing packet capture or adding a build variant.
|
||||
Debug defaults off for fresh and older preference images; effective output
|
||||
requires `usb.logging` and `usb.debug` on plus compiled diagnostic support.
|
||||
Shared USB consoles also provide saved `get/set usb.logging.always on|off`.
|
||||
It defaults off; turning it on keeps packet logs running through commands.
|
||||
See [live USB logging](cli_commands.md#control-live-usb-logging) for transport
|
||||
restrictions and Full Companion RAW output.
|
||||
|
||||
|
||||
+15
-1
@@ -1644,6 +1644,9 @@ set usb.logging on
|
||||
set usb.logging off
|
||||
set usb.logging on reboot
|
||||
set usb.logging off reboot
|
||||
get usb.logging.always
|
||||
set usb.logging.always on
|
||||
set usb.logging.always off
|
||||
get usb.debug
|
||||
set usb.debug on
|
||||
set usb.debug off
|
||||
@@ -1701,18 +1704,29 @@ still reports that saved setting. `set usb.logging on` or
|
||||
`set logging.output usb|both` resumes packet logs immediately after a successful
|
||||
save. No reboot is needed.
|
||||
|
||||
To keep packet logs running through commands on a shared USB console, use
|
||||
`set usb.logging.always on`. This choice is saved, ends any active pause
|
||||
immediately, and survives reboot. `get usb.logging.always` checks the setting.
|
||||
`set usb.logging.always off` restores the default five-minute pause for
|
||||
subsequent commands. The logging master remains separate: this option does
|
||||
not enable logging while `usb.logging` is off. With continuous logging,
|
||||
packet lines can appear between command replies.
|
||||
|
||||
The routine `stats-core`, `stats-radio`, and `stats-packets` polls do not start
|
||||
or extend this pause. A separate logging USB port and explicit Companion
|
||||
`usb.logging stream` mode also keep logging. The pause leaves command replies,
|
||||
noise-floor sampling, saved history, LoRa telemetry, and direct WiFi MQTT
|
||||
running. A collector reading USB packet logs misses those log copies during
|
||||
the pause, including telemetry packets; this is not buffered capture.
|
||||
The `usb.logging.always` setting is provided for shared consoles; nRF52 Full
|
||||
Companion already keeps its dedicated logging port or explicit stream running.
|
||||
|
||||
`meshcoretomqtt` polls these three stats commands every 300 seconds and
|
||||
publishes `noise_floor` from the `stats-radio` reply in its MQTT status. These
|
||||
polls keep working during the pause. Its startup identity queries do trigger
|
||||
a five-minute packet-capture gap on a shared console, as do ordinary commands
|
||||
sent through its remote serial feature.
|
||||
sent through its remote serial feature. Enable `usb.logging.always` to keep
|
||||
packet capture running through these commands too.
|
||||
|
||||
For packet-only capture, use these separate text commands:
|
||||
|
||||
|
||||
@@ -50,6 +50,8 @@ Interactive text commands on a shared USB console pause packet logs for five
|
||||
minutes after the last command. The three routine stats polls above keep
|
||||
their replies and renew the lease without starting or extending this pause.
|
||||
Dedicated logging ports and explicit Companion stream mode keep logging.
|
||||
On shared consoles, saved `set usb.logging.always on` also keeps packet logs
|
||||
running through commands; `off` restores pausing for subsequent commands.
|
||||
The pause does not disable measurements, LoRa telemetry, direct WiFi MQTT,
|
||||
or the saved logging master. USB packet collectors miss log copies during
|
||||
the pause. See [live USB logging](cli_commands.md#control-live-usb-logging).
|
||||
|
||||
Reference in new issue
Block a user