0x1001 · batteryVoltage
Battery state as a big-endian millivolt reading and charging flags for wireless G-series devices.
batteryVoltage reports a measured battery voltage and a charging-flags byte.
G915, G903 LIGHTSPEED, and G502 LIGHTSPEED expose it without 0x1000 or 0x1004.
The feature contains no percentage.
Spec: No public Logitech specification. Layout reverse-engineered from Logi Options+ 2.8 (static analysis). Cross-checked: Linux HID++ driver, Solaar. Used by: device inventory and
openlogi list.
Function reference
BatteryVoltageFeature (0x1001) implements one request method.
Methods
| Function | HID++ fn | Signature | Returns |
|---|---|---|---|
get_battery_info | 0 | () | VoltageBatteryInfo |
is_status_broadcast | event helper | (function_id: u8) | bool |
get_battery_info is async and returns Result<VoltageBatteryInfo, Hidpp20Error>.
The wrapper has no show_battery_status method for function 1.
Types
VoltageBatteryInfo
| Field | Type | Description |
|---|---|---|
voltage_mv | u16 | Battery voltage in millivolts. The code describes a single-cell Li-Po range of about 3,500–4,200 mV. |
status | VoltageChargingStatus | Charging state decoded from the flags byte. |
critical | bool | Firmware critical-charge marker from bit 5. |
VoltageChargingStatus
| Variant | Description |
|---|---|
Discharging | Battery power; external-power bit is clear. |
Charging | External power with standard charging. |
ChargingFast | External power with the fast-charge bit. |
ChargingSlow | External power with the slow-charge bit. |
Full | External power with charge-status value 1. |
NotCharging | External power with charge-status value 2. |
Unknown | External power with an undefined charge-status value. |
Events
This wrapper does not implement EmittingFeature or expose a typed event.
is_status_broadcast(function_id) returns true only for function 0.
Wire format
get_battery_info (fn 0)
Request: [0x00, 0x00, 0x00] (no parameters).
Response:
| Byte | Field | Notes |
|---|---|---|
| 0–1 | voltage_mv | u16, BE, in millivolts. |
| 2 | flags | Link, charging, charge-rate, and critical markers. |
Flags:
| Bit or bits | Meaning | OpenLogi decoding |
|---|---|---|
| 7 | External power present | Clear means Discharging; other flag bits do not change that result. |
| 0–2 | Charge status while external power is present | 0 is charging, 1 is Full, and 2 is NotCharging. Values 3–7 become Unknown. |
| 3 | Fast-charge marker | With status 0, produces ChargingFast. |
| 4 | Slow-charge marker | With status 0 and bit 3 clear, produces ChargingSlow. |
| 5 | Critical marker | Exposed independently as critical. |
| 6 | / | No meaning is modeled. |
With external power, a low status of 0x03 means Unknown.
For example, the full flags byte 0x83 is not Full.
showBatteryStatus (fn 1, not implemented)
Logi Options+ calls function 1 and checks that it receives a nonempty reply.
Its request layout, reply layout, and physical effect are not established.
OpenLogi does not expose or call this function.
Status broadcast (event fn 0)
An unsolicited function-0 report carries the same three bytes as get_battery_info.
It announces a changed voltage or charging state.
How OpenLogi uses it
Inventory selects this source only after 0x1004 and 0x1000 are absent.
It prefers this voltage source over 0x1F20 ADC measurement.
OpenLogi estimates a percentage from a 13-point single-cell Li-Po curve.
The curve clamps at 3,500 mV for 0% and 4,186 mV for 100%.
The critical flag overrides the estimated display level.
Since v0.8.14, PR #1768 maps undefined external-power status values to Unknown.
This includes a low status of 0x03.
OpenLogi does not call function 1 because its effect is unverified.
Since v0.8.14, PR #1787 records this feature's runtime index.
An unsolicited software-ID-0, function-0 report queues one coalesced inventory reconciliation.
OpenLogi re-reads the authoritative state instead of trusting the event payload.
OpenLogi only reads this feature.
Open questions
Logi Options+ uses showBatteryStatus at function 1 and requires a nonempty reply.
Static analysis does not establish whether it controls an LED, an on-screen indicator, or another device action.
OpenLogi leaves it uncalled until hardware capture establishes its effect.
Usage (Rust)
use hidpp::{
device::Device,
feature::battery_voltage::BatteryVoltageFeature,
};
// `channel` and `device_index` identify an already opened HID++ device.
let mut device = Device::new(channel, device_index).await?;
device.enumerate_features().await?;
if let Some(feature) = device.get_feature::<BatteryVoltageFeature>() {
let info = feature.get_battery_info().await?;
println!("{} mV: {:?}", info.voltage_mv, info.status);
}See also: 0x1000 batteryStatus and 0x1004 unifiedBattery.