Obtener un reporte de la batería del notebook

Quisiera obtener un reporte de la batería de mi notebook, que indique la cantidad de ciclos, la capacidad de diseño, la capacidad real actual, etc. tal como el que se saca en windows con el comando: powercfg /batteryreport

Es posible?

At first, you need to enumerate the Power devices in your system (like the Main battery, Wireless Mouse battery, …) with the following command:

upower --enumerate

This will output something like:

/org/freedesktop/UPower/devices/keyboard_hidpp_battery_4
/org/freedesktop/UPower/devices/mouse_hidpp_battery_5
/org/freedesktop/UPower/devices/DisplayDevice

(mine isn’t a Notebook, so it has no Main battery). Take the Path which corresponds to the device you want to get information about (e.g. copy it to the Clipboard), and then run:

upower -i /org/freedesktop/UPower/devices/keyboard_hidpp_battery_4

Now, you get information about the battery stats for this device:

  native-path:          hidpp_battery_4
  model:                Wireless Keyboard
  serial:               4023-00-00-00-00
  power supply:         no
  updated:              Thu 21 Jan 2021 06:34:15 AM CET (98 seconds ago)
  has history:          yes
  has statistics:       yes
  keyboard
    present:             yes
    rechargeable:        yes
    state:               discharging
    warning-level:       none
    battery-level:       normal
    percentage:          55% (should be ignored)
    icon-name:          'battery-low-symbolic'

Alternatively, if you just want a one-liner for displaying all devices and their stat:

upower --enumerate | xargs -n1 upower -i

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.