To see your battery infos you can use acpi if you have it or directly see system files.
Upower command#
In both case you can use upower
command to get some usefull infos:
1 | upower -i /org/freedesktop/UPower/devices/battery_BAT0 |
Example output:
1 | native-path: BAT0 |
With acpi#
Many distributions don't use it so if you want to install it you can do:
1 | sudo zypper in acpi |
OR
1 | sudo yum install acpi && sudo yum install acpitool |
OR
1 | sudo apt-get install acpi && sudo apt-get install acpitool |
To check is you have it installed:
1 | acpi -V |
You can see battery health:
1 | cat /proc/acpi/battery/BAT0/info |
and the battery status:
1 | cat /proc/acpi/battery/BAT0/state |
OR
1 | acpi |
You can also display ac adpter information:
1 | acpi -a |
You can show thermal information:
1 | acpi -t |
OR
1 | cat /proc/acpi/thermal_zone/THM/temperature |
Without acpi#
Without acpi you will need to browse /sys/class/power_supply/BAT0
directory and display files that are inside.