phosphor-service-upower

Battery and power-device status via UPower.

Exposes the system-bus org.freedesktop.UPower surface as Qt and QML types: the aggregate display device, the per-device list, and the OnBattery flag. It is a read-only D-Bus client, since UPower has no writable surface for the facts it reports. A shell binds the host's displayDevice for a single-battery indicator or the device model for a per-device list.

Full API →

Key types

UPowerHost
Owns the device set: onBattery, displayDevice (aggregate battery), add/remove signals.
UPowerDevice
One power source: percentage, state, type, timeToEmpty, iconName, healthPercentage.
UPowerDeviceModel
QAbstractListModel over the host's devices for QML.

Dependencies

See also

References