pm5: hw bwm powersave
New `hw bwm powersave [on|off]` (CMD_PM5_BWM_POWERSAVE 0x0181) shows or sets the ESP's persisted power-save switch (companion Proxmark5_BWM_esp32 PR: DFS, light sleep and slow advertising after a 30 s fast phase, or the stock always-on behaviour), so the two can be A/B measured and the saving turned off when chasing a link problem. `hw status` prints the state next to the BWM firmware version. Both module queries in `hw status` are time-bounded (version 2 x 800 ms, power save 300 ms): a module that is silent, or a firmware without the command, cannot push the report past the client's timeout. Verified on hardware: state read/set/persist across an ESP reboot, `hw status` after 4, 15 and 40 s idle in power-save mode and after 6 s idle with it off. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
4f4acedbdd
commit
552276c75f
8 files changed
+148
-11
No files matched your search
@@ -926,6 +926,11 @@ typedef struct {
|
||||
#define BWM_BLE_NAME_MAX_LEN 15 // usable chars; ESP name buffer is 16 incl NUL
|
||||
// PM5, toggle the power-save idle (48 MHz + WFI when idle). Used by `hw powersave`.
|
||||
#define CMD_PM5_POWERSAVE 0x0180
|
||||
// PM5, BWM power-save switch on the ESP (DFS, light sleep, low-duty advertising;
|
||||
// persisted on the BWM). Used by `hw bwm powersave`.
|
||||
#define CMD_PM5_BWM_POWERSAVE 0x0181 // payload: [action:u8][state:u8 if SET]; resp: u8 applied state
|
||||
#define BWM_POWERSAVE_ACTION_GET 0x00
|
||||
#define BWM_POWERSAVE_ACTION_SET 0x01
|
||||
#define BWM_OTA_ACTION_BEGIN 0x00
|
||||
#define BWM_OTA_ACTION_WRITE 0x01
|
||||
#define BWM_OTA_ACTION_END 0x02
|
||||
|
||||
Reference in new issue
Block a user