! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Battery incorrectly declared as charging
Status:
RESOLVED: INVALID
Product:
Xfce4-power-manager
Component:
General

Comments

Description haarp 2012-11-01 13:53:40 CET
Some Thinkpad users can use the tp-smapi kernel module to set charge thresholds. For example, I can set the battery to stop charging at 90% and only start charging again when it drops below 75%.

However, when the battery is idle, below 99% and running on AC power, power-manager incorrectly declares the battery as "charging" when it is not.

A simple check would be to verify /sys/class/power_supply/BAT1/status. It is "Unknown" when the battery is idle and "Charging" or "Discharging" otherwise.

Alternatively, one could check /sys/class/power_supply/BAT1/current_now. If it is 0, the battery is idle.
Comment 1 haarp 2013-07-14 15:56:11 CEST
I discovered that the power manager ALWAYS seems to declare the battery as charging when it is unsure.

If /sys/class/power_supply/$BATTERY/status contains "Unknown" or is missing altogether, the power manager will always state it as charging. That should not happen, IMO.
Comment 2 haarp 2013-10-09 15:38:44 CEST
This seems to be a bug within Upower, not Xfce.

https://bugs.freedesktop.org/show_bug.cgi?id=70321

Bug #9436

Reported by:
haarp
Reported on: 2012-11-01
Last modified on: 2013-10-09

People

Assignee:
Ali Abdallah
CC List:
0 users

Version

Attachments

Additional information