atul-g / plasma-power-monitor

A KDE Plasma widget to monitor the power consumption of your battery.
GNU General Public License v2.0
23 stars 13 forks source link

When my laptop is fully charged,0.0W appeared #3

Closed abolast closed 2 years ago

abolast commented 2 years ago

When my laptop is charging, it works well When my laptop is on battery, it works well But when my laptop is fully charged and still connected to the power cord, 0.0W appeared My laptop has a mechanism that stops charging when the battery is fully charged.

abolast commented 2 years ago

I couldn't reproduce the 0.0W again, the last time that happened was after my laptop automatically slept(suspend to RAM). All in all, power-monitor is now working well on my laptop. So, I will turn off this issus

abolast commented 2 years ago

But when I was up from suspend for a small period of time, the 0.0w reappeared. My laptop is fully charged and still connected to the power cord. I guess this may have a connection with suspend to RAM. Please forgive me for turning on this issus again

atul-g commented 2 years ago

Hi @abolast , sorry for the delay in response as I got caught up with quite a lot of other work!

When laptop is fully charged, it is expected behavior that the power consumed from the battery is 0.0 W as at this state your laptop is completely consuming power from the power-outlet rather than battery. The power-monitor is a very simple widget which collects the Voltage and Current information from /sys/class/power_supply/BAT[a number]/current_now and /sys/class/power_supply/BAT[a number]/voltage_now which are interface files provided by the kernel. So you can check what the kernel reported usage is by running a cat command on the above files (eg: cat /sys/class/power_supply/BAT1/voltage_now) when your laptop is fully charged and verify if the power-monitor is functioning properly.