[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

sysfs not updating battery status



Hi there,
since a couple of weeks ago I started having problems with
gnome-power-manager on my Acer TM2303Wlmi. It stopped updating the
battery power level; it updated only on ac connect/disconnect.
I traced the problem to the sysfs: it appears the sysfs power
measurement is updated only after a read on the procfs, but it doesn't
update by himself; here's a short example:

castor:/# cat /proc/version 
Linux version 2.6.26-1-686 (Debian 2.6.26-13lenny2) (dannf@debian.org)
(gcc version 4.1.3 20080704 (prerelease) (Debian 4.1.2-25)) #1 SMP Fri
Mar 13 18:08:45 UTC 2009
castor:/# cat /sys/class/power_supply/BAT0/energy_now 
26210000 
castor:/# cat /proc/acpi/battery/BAT0/state
present:                 yes
capacity state:          ok
charging state:          charging
present rate:            38336 mW
remaining capacity:      38120 mWh
present voltage:         16548 mV
castor:/# cat /sys/class/power_supply/BAT0/energy_now
38120000

I googled about the problem and it appears something similar was
noticed in the past, but I found no clue about current bugs or fixed
in lenny for this problem. 
The very strange thing is that the problem has come out all of sudden
and a couple of weeks ago everything was working fine. Only changes in
the system in the recent weeks are security updates, and I don't
remember anything power-related.
Before I file a bug, I would be grateful if you can give me your
opinion!

Thanks!

Lorenzo Masellis


Reply to: