48: Power Info
See how much power is or has been used by the device, as well as current power usage and if the device is charging. Field availability depends on hardware, firmware and charging state. The conditional fields below describe firmware build 2644; do not assume that every device sends every field. Numeric values are little-endian. Integer fields may omit high zero bytes; float32 fields retain their four-byte IEEE 754 representation.
Header
| Field | Name | Description | Type |
|---|---|---|---|
| 5 | Method | Request a service to be perform an action Possible values:
| uint8 |
Payload
| Field | Name | Description | Type | Unit |
|---|---|---|---|---|
| 3 | Total power since profile | Accumulated charge usage in mAh. In build 2644, starting a power-profile subscription resets the shared accumulator; GET returns that same accumulator. Before any such reset it covers usage since startup. Present only when current monitoring is available. | float32 | mAh |
| 4 | Current | Instantaneous Current power usage | float32 | mA |
| 5 | Charging | Is the device currently charging | bool | |
| 6 | External Voltage | Measured external voltage; omitted when the cached voltage is zero. | float32 | V |
| 7 | Total power since last TX | Charge used since the last transmission; present only when the build has a current monitor and its current-usage object is available. | float32 | mAh |
| 8 | Charge Current | Firmware-labelled cached charge-current value; present only while charging and when nonzero. Physical interpretation depends on the charger driver. | float32 | mA |
| 9 | Input Current | Firmware-labelled cached input-current value; present only while charging and when nonzero. On BQ2589x-based devices (including Viper 6 build 2644), this comes from REG13 IDPM_LIM: the input-current limit in effect, not measured input current. Do not interpret it as actual device consumption. Physical interpretation on other hardware depends on its charger driver. | float32 | mA |
| 10 | Average Current | Average current in mA, rounded to the nearest integer and clamped to 0..65535. In build 2644 this is always included, and is zero before current samples are available. Uses the accumulated current-sampling window when nonempty, otherwise the previous completed window (nominally 3 seconds). Encoded in one or two little-endian bytes. | uint16 | mA |
Examples
Get request
📡 Real example from Generate tool on 2025-10-14Created using the generate tool, this was tested against an RH2 device, sent from Toit.
Get response
📡 Real example from RH2 P1 v2296 on 2025-10-14Response to the above GET request, captured from an RH2 device as part of normal communications over I2C with the ESP32 co-processor.
Subscription Request
📡 Real example from Generate tool on 2025-10-14Created using the generate tool, this was tested against an RH2 device, sent from Toit.
Subscription ACK
📡 Real example from RH2 P1 v2296 on 2025-10-14Response to the above SUBSCRIBE request, captured from an RH2 device as part of normal communications over I2C with the ESP32 co-processor.
Subscription update, while on charge
📡 Real example from RH2 P1 v2296 on 2025-10-14Response to the above subscription, captured from an RH2 device as part of normal communications over I2C with the ESP32 co-processor.
Code
For convenience, the following constants can be used to reference this message type.