This forum has been archived. All content is frozen. Please use KDE Discuss instead.

cannot get battery status

Tags: None
(comma "," separated)
xrfang
Registered Member
Posts
10
Karma
0
OS

cannot get battery status

Tue Apr 07, 2009 7:43 am
I am using the battery plasmoid, it failed to get battery status. I googled this problem, and found out that battery is indeed "not present" on my system:

cat /proc/acpi/battery/BAT1/inf
present: no

The strange thing is, while I was using gnome, battery display is ok, and after I switch to KDE4, it is ALSO ok, but now it is not. As far as I can remember what I did which is possibly related to battery display is that I tried to disable powerdevil, as I have the batter display I thought the "cpu policy" tray icon in the systray is no longer needed, hence I tried to disable Guidance Power Manager...

But now I have re-enabled powerdevil, still, there is no battery level display. Any suggestions? Especially, why /proc/acpi... displays no battery??

Thank you very much!
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

RE: cannot get battery status

Tue Apr 07, 2009 8:26 am
This data is retrieved from Solid I believe, which in turn uses HAL. Please ensure that when you disabled Guidance Power Manager, that you did not effect HAL. Powerdevil uses HAL for all of its actions also I believe.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
xrfang
Registered Member
Posts
10
Karma
0
OS

RE: cannot get battery status

Tue Apr 07, 2009 8:51 am
I don't know where to configure hal in KDE, I never touched hal intentionally, and I don't know where to control hal in ubuntu.

I ran a ps and get:

5256 ? Ss 0:14 /usr/sbin/hald
5260 ? S 0:00 hald-runner
5342 ? S 0:00 hald-addon-input: Listening on /dev/input/event3 /dev/input/event6 /dev/input/event4 /dev/input/event5 /dev/input/event1
5352 ? S 0:03 /usr/lib/hal/hald-addon-cpufreq
5353 ? S 0:00 hald-addon-acpi: listening on acpid socket /var/run/acpid.socket
5360 ? S 0:12 hald-addon-storage: polling /dev/scd0 (every 2 sec)

I think hal should be still running? How can I check further?

Thank you!
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

RE: cannot get battery status

Tue Apr 07, 2009 11:59 am
That is unusual. Does it work under a new user? Is the Solid HAL backend installed?


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
xrfang
Registered Member
Posts
10
Karma
0
OS

RE: cannot get battery status

Tue Apr 07, 2009 4:23 pm
bcooksley wrote:That is unusual. Does it work under a new user? Is the Solid HAL backend installed?


Hi Master,

Thank you for your continued help. To report the current status and findings:

1) It does NOT work under a new user.
2) I don't know what is "Solid HAL" backend and don't know how to check if it is installed or not.
3) In Service Manager, I see that PowerDevil is RUNNING, but in adept, I see that it is NOT installed!!! Then, I try to install it via apt (because adept did not explain why install failed), apt tells me that

- powerdevil cannot be installed because it relies on libplasma2, and that will not be installed;
- then I try to install libplasma2, it tells me that relies on kdebase-workspace-data version 4.1.4, but now version 4.2.2 is installed...

I have just upgraded to v4.2.2 via PPA source, but as far as I can remember, this battery display problem happens BEFORE I upgrade to v4.2.2, and after I play with powerdevil in the service manager.

I look forward to further instructions. Thank you!
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

RE: cannot get battery status

Wed Apr 08, 2009 5:32 am
Powerdevil was included with KDE 4.2, and is installed as part of KDE Workspace.

You can check Solid Backends in System Settings > Advanced > Hardware.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
xrfang
Registered Member
Posts
10
Karma
0
OS

RE: cannot get battery status

Wed Apr 08, 2009 7:09 am
bcooksley wrote:Powerdevil was included with KDE 4.2, and is installed as part of KDE Workspace.

You can check Solid Backends in System Settings > Advanced > Hardware.


I have no "Solid" backends... The following were listed:

Power Management Backend
HAL-Power

Network Management Backend
NetworkManager 0.7
Fake Net

Bluetooth Management Backend
BlueZ

Thanks!
User avatar
anda_skoa
KDE Developer
Posts
783
Karma
4
OS

RE: cannot get battery status

Wed Apr 08, 2009 7:20 am
xrfang wrote:Especially, why /proc/acpi... displays no battery??


This looks like the core of the problem. If the kernel does not know about the battery, how would any user space application know about it.

Did you do a system upgrade of some sort? Maybe including the kernel?

Cheers,
_


anda_skoa, proud to be a member of KDE forums since 2008-Oct.
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

RE: cannot get battery status

Wed Apr 08, 2009 7:23 am
* bcooksley didn't see that..... Apologies for leading you off track.
The HAL backend does appear to be correctly installed.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
xrfang
Registered Member
Posts
10
Karma
0
OS

RE: cannot get battery status

Wed Apr 08, 2009 7:55 am
I think this is the problem too, but WHY? As I said, it worked for gnome for a long time... what I recently did, is gradually remove gnome components using adept, as I plan to use KDE on this machine... May be I removed some critical battery thing?

As I understand all "lib" I remove that may possibly affect the problem is "user space" right?

I also noticed that I only have /proc/acpi/battery/BAT1

Is there supposed to be a BAT0? My kernel is:

Linux shuttler 2.6.27-14-generic #1 SMP Fri Mar 13 18:00:20 UTC 2009 i686 GNU/Linux

I always upgrade kernel when ubuntu offer one, I didn't do any manual compilation and installation of kernel or kernel modules.

Thanks!


anda_skoa wrote:
xrfang wrote:Especially, why /proc/acpi... displays no battery??


This looks like the core of the problem. If the kernel does not know about the battery, how would any user space application know about it.

Did you do a system upgrade of some sort? Maybe including the kernel?

Cheers,
_
xrfang
Registered Member
Posts
10
Karma
0
OS

RE: cannot get battery status

Wed Apr 08, 2009 5:05 pm
I found this in dmesg:

ACPI: Battery Slot [BAT1] (battery absent)

I tried acpi=on, acpi=force via grub, but no use. Strange thing happen again! I reboot the pc WITHOUT AC power, then plugin in the AC after using the laptop for about 30 minute, suddenly, the battery info comes alive after plugin AC power!

I will keep on monitoring this strange stuff. If any of you know how to trace down this problem, please let me know.

Thank you!


Bookmarks



Who is online

Registered users: abc72656, Bing [Bot], daret, Google [Bot], Sogou [Bot], Yahoo [Bot]