Bug 89551 - Battery status on powerpc wrong
Summary: Battery status on powerpc wrong
Status: RESOLVED UNMAINTAINED
Alias: None
Product: klaptopdaemon
Classification: Miscellaneous
Component: general (show other bugs)
Version: unspecified
Platform: Debian testing Linux
: NOR normal with 20 votes (vote)
Target Milestone: ---
Assignee: Paul Campbell
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-15 11:11 UTC by matthiasgrimm
Modified: 2010-02-26 14:07 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description matthiasgrimm 2004-09-15 11:11:53 UTC
Version:            (using KDE KDE 3.2.3)
Installed from:    Debian testing/unstable Packages
OS:                Linux

I booted my powerbook with AC only (no batteries are plugged in) and the tooltip over klaptopdaemon says:
    "Running on batteries  -  -2147483648% charged"

This can't definitely be true. I'm running on AC.
All values of /proc/pmu/battery_% are zero.

My system is an Apple Powerbook G3 (powerpc), kernel 2.6.7 (hand made), debian distribution.

How to reproduce:
Run you powerbook on Battery, put it to sleep, plug in AC, remove all batteries, wake your machine -> It still thinks that it is running on battery
or
Just boot without any batteries plugged in.

This is actually a kernel problem. The kernel on powerbooks gets the AC plug information from the batteries, but without batteries the kernel sticks with the last read status (multiply bug reports have been filed, but nothing changed till today).

The battery monitor gkrellm-PMU 2.3 cope with this problem and react correctly. It uses the help from pbbuttonsd to get the information if a battery is present or not. I think this is not the solution you would prefer but you may lend some of their code to fix your problem.
Comment 1 Jeremy Kerr 2005-04-24 15:02:33 UTC
I'm having a similar issue on a PowerBook G4: the percentage shown by the battery monitor is correct, but the time left is way off. I'm using Debian unstable, KDE 3.3.2, kernel 2.6.12-rc2.

The battery monitor says: "35% charged, 53:01 time left"

However, there's no way that I have 53 *hours* left :)

Because the 'time left' is way too high, klaptopdaemon doesn't warn me when I'm running low on power (as configured to do so when there's 5 mins left).

from /proc/apm:
0.5 1.1 0x00 0x00 0x00 0x01 35% 52 min

(/proc/pmu/battery_0 contains similar info)

So the values read are being parsed incorrectly?

Thanks!

Jeremy
Comment 2 Steve Przybylski 2006-02-25 17:37:17 UTC
Issue still exists in KDE 3.5.1 (Kubuntu Dapper), Powerbook G4 17" 1.33.

/proc/apm reports:
0.5 1.1 0x00 0x00 0x01 0x02 15% 23 min

Battery monitor shows:
15% charged (23:36 hours left)

-steve
Comment 3 Dario Andres 2010-02-26 14:07:11 UTC
I have personally contacted the KLaptopDaemon author/assigned and he confirmed that the tool is deprecated in KDE SC 4 (replaced by PowerDevil) and that there are no current efforts to support/maintain the KDE SC 3 version.
Because of this, I will close the reports as UNMAINTAINED.
Regards