Regression: devicekit-power does not display remaining battery time

Bug #439783 reported by Ryan Waldroop
154
This bug affects 30 people
Affects Status Importance Assigned to Milestone
DeviceKit-Power
In Progress
Medium
devicekit-power (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

Binary package hint: devicekit-power

I'm using a Dell mini 9 with two separate batteries: the stock factory battery and an aftermarket extended battery.

In Jaunty, when hovering over the battery icon in the top panel, gnome-power-manager would report a percentage of battery life remaining, along with an approximate battery life remaining.

Karmic no longer gives an approximate remaining battery time now that Ubuntu has switched from hal to devicekit-power. This is unlike other bugs in that the percentages listed are *correct*, except for the failure to list remaining time.

Additionally, when the battery life reaches the "critically low" stage, I receive a notification that I have "x% battery life remains. (Unknown battery time remaining)"

Let me know if you need more information. Thanks!

ProblemType: Bug
Architecture: i386
Date: Wed Sep 30 23:28:45 2009
DistroRelease: Ubuntu 9.10
ExecutablePath: /usr/lib/devicekit-power/devkit-power-daemon
NonfreeKernelModules: wl
Package: devicekit-power 010+git20090913-0ubuntu1
ProcEnviron:

ProcVersionSignature: Ubuntu 2.6.31-11.36-generic
SourcePackage: devicekit-power
Tags: ubuntu-unr
Uname: Linux 2.6.31-11-generic i686

Revision history for this message
Ryan Waldroop (ryan.waldroop) wrote :
Revision history for this message
Martin Pitt (pitti) wrote :

Can you please copy&paste the output of

  /usr/share/gnome-power-manager/gnome-power-bugreport

here?

Changed in devicekit-power (Ubuntu):
status: New → Incomplete
Revision history for this message
Ryan Waldroop (ryan.waldroop) wrote : Re: [Bug 439783] Re: Regression: devicekit-power does not display remaining battery time
Download full text (3.7 KiB)

Distro version: squeeze/sid
Kernel version: 2.6.31-11-generic
g-p-m version: 2.28.0
HAL version: 0.5.13
System manufacturer: missing
System version: missing
System product: missing
AC adapter present: yes
Battery present: yes
Laptop panel present: yes
CPU scaling present: yes
Battery Information:
  battery.charge_level.current = 42180 (0xa4c4) (int)
  battery.charge_level.design = 84360 (0x14988) (int)
  battery.charge_level.last_full = 84360 (0x14988) (int)
  battery.charge_level.percentage = 50 (0x32) (int)
  battery.charge_level.rate = 0 (0x0) (int)
  battery.is_rechargeable = true (bool)
  battery.model = '' (string)
  battery.present = true (bool)
  battery.rechargeable.is_charging = false (bool)
  battery.rechargeable.is_discharging = true (bool)
  battery.reporting.current = 3800 (0xed8) (int)
  battery.reporting.design = 7600 (0x1db0) (int)
  battery.reporting.last_full = 7600 (0x1db0) (int)
  battery.reporting.rate = 0 (0x0) (int)
  battery.reporting.technology = 'Li-ion' (string)
  battery.reporting.unit = 'mAh' (string)
  battery.serial = '11' (string)
  battery.technology = 'lithium-ion' (string)
  battery.type = 'primary' (string)
  battery.vendor = 'DELL' (string)
  battery.voltage.current = 11100 (0x2b5c) (int)
  battery.voltage.design = 11100 (0x2b5c) (int)
  battery.voltage.unit = 'mV' (string)
DeviceKit data:
Device: /org/freedesktop/DeviceKit/Power/devices/battery_BAT1
  native-path:
 /sys/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:2a/PNP0C0A:00/power_supply/BAT1
  vendor: DELL
  serial: 11
  power supply: yes
  updated: Thu Oct 1 21:07:01 2009 (11 seconds ago)
  has history: yes
  has statistics: yes
  battery
    present: yes
    rechargeable: yes
    state: discharging
    energy: 42.18 Wh
    energy-empty: 0 Wh
    energy-full: 84.36 Wh
    energy-full-design: 84.36 Wh
    energy-rate: 0 W
    voltage: 11.1 V
    percentage: 50%
    capacity: 100%
    technology: lithium-ion

Device: /org/freedesktop/DeviceKit/Power/devices/line_power_ACAD
  native-path:
 /sys/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:2a/ACPI0003:00/power_supply/ACAD
  power supply: yes
  updated: Wed Sep 30 18:58:21 2009 (94131 seconds ago)
  has history: no
  has statistics: no
  line-power
    online: no

Daemon:
  daemon-version: 011
  can-suspend: yes
  can-hibernate yes
  on-battery: yes
  on-low-battery: yes
  lid-is-closed: no
  lid-is-present: yes
GNOME Power Manager Process Information:
ryan 1984 0.0 1.1 29856 11964 ? S Sep30 0:07
 \_ gnome-power-manager
HAL Process Information:
111 928 0.0 0.4 6508 4104 ? Ss Sep30 0:01 hald
--daemon=yes
root 1006 0.0 0.1 3564 1204 ? S Sep30 0:00 \_
hald-runner
root 1145 0.0 0.1 3636 1192 ? S Sep30 0:00 \_
/usr/lib/hal/hald-addon-rfkill-killswitch
root 1160 0.0 0.1 3632 1140 ? ...

Read more...

Revision history for this message
In , Martin Pitt (pitti) wrote :

Hello Richard,

I got a report in Ubuntu that dk-p does not show the remaining battery life any more on a Dell Mini 9 with two separate batteries: the stock factory battery and an aftermarket extended battery

This reportedly worked well with hal, so I guess from a hardware POV it should be supported.

I attach the gnome-power-bug result here. Is there something else I need to get from the reporter?

Thank you!

Martin

P.S. We currently have a git head snapshot from 20090913, so it should be pretty recent.

Revision history for this message
In , Martin Pitt (pitti) wrote :

Created an attachment (id=30088)
gnome-power-bug output

Martin Pitt (pitti)
Changed in devicekit-power (Ubuntu):
importance: Undecided → Low
status: Incomplete → Won't Fix
status: Won't Fix → New
Martin Pitt (pitti)
Changed in devicekit-power (Ubuntu):
status: New → Confirmed
Changed in devicekit-power:
status: Unknown → Confirmed
Revision history for this message
In , Richard Hughes (richard-hughes) wrote :

Battery is broken:

>energy-rate: 0 W

So we need to fallback to the time estimation code, which isn't turned on by default yet in DeviceKit-power. I'll look more at how much work it would be to switch it on after the release today.

Changed in devicekit-power:
status: Confirmed → In Progress
Revision history for this message
giorgio130 (gm89) wrote :

I'm affected from the same bug on a COMPAL JHL90.
gnome-power-bugreport attached.

Revision history for this message
William Davis (hotshotdj) wrote :

I can confirm this bug on a System76 PanP5 (Clevo M740TX). i think this is the same issue as Bug #444881
Output of /usr/share/gnome-power-manager/gnome-power-bugreport attached.

Revision history for this message
In , William Davis (hotshotdj) wrote :

Created an attachment (id=30904)
Output from gnome-power-bugreport whilst AC disconnected

I can confirm this bug on my System76 Pangolin (PanP5). I'm happy to provide any additional information to help you squash this bug.

Revision history for this message
hackel (hackel) wrote :

Also seeing this on my Dell Mini 9 after upgrading, and seems like a dupe of #444881.

I just wanted to add that the powertop utility *does* give an ACPI power usage "time remaining" estimate, though it takes a while to get it so I would guess it is simply calculating the discharge rate manually. Gnome-power-manager should definitely fall back to this behaviour. All the information is right there in the power history, and it is trivial to calculate--I've got an almost perfectly straight line there, losing approx 7% every 12 minutes. Even this crude estimate would be better than nothing!

Revision history for this message
krzlew (krz-lewandowski) wrote :

I have the same problem on HP Pavilion dv3500.

Additionaly when I start laptop on battery I have information that battery is charged and laptop is on AC. When click on gnome-power-manager icon I get information about battery charge level, but it didn't warn if battery is low. It discharge until my laptop turn off (due to no power). To change "state" to discharging I have to plug in AC and plug out. It is really annoying when I travel, because I have to manualy take care of my battery status and it can cause data loss (when working on something and don't save it).

I attached 3 logs from /usr/share/gnome-power-manager/gnome-power-bugreport in one file.
First is when I start laptop on battery, second when I plug in AC and third when I plug it out.

Revision history for this message
Scott Minster (sminster) wrote :

I've been experiencing this bug as well on my HP Pavilion dv6000 ever since Karmic. I think the problem is related to the 'rate' that is reported through lshal and devicekit. The former reports the rate as -1:

$ lshal | grep battery | grep rate
  battery.charge_level.rate = 0 (0x0) (int)
  battery.reporting.rate = -1 (0xffffffff) (int)

Devicekit reports the rate as way too little:

$ devkit-power --dump | grep energy
    energy: 47.8336 Wh
    energy-empty: 0 Wh
    energy-full: 69.1456 Wh
    energy-full-design: 88.8 Wh
    energy-rate: 0.0148 W

When I divide the full value by the rate, I get 4672 hours, which is much more than I can get out of my battery. Just playing with numbers, it looks like the rate may be off by a factor of 1500. If it were 22.2 watts, then the energy-full/energy-rate would be about 3.1, which is much closer to what I can actually get from this battery.

Of course, this is assuming that GPM even uses the devicekit numbers at all. If I get motivated later, maybe I'll look through the GPM source to see if I can find where and how the time remaining is calculated.

Revision history for this message
Arnaud Soyez (weboide) wrote :

Same problem with a HP Mini 1000, Ubuntu 9.10 32bits. (gnome-power-bugreport output is attached.)
  battery.charge_level.rate = 0 (0x0) (int)
  battery.reporting.rate = -1 (0xffffffff) (int)
  energy-rate: 0.0111 W

Revision history for this message
Mark Baas (mark-baas123) wrote :

I have this issues on a HP presario CQ60, my HP Mini 1000 and my girlfriend AcerOne.

Revision history for this message
Joe Kraxner (kraxner) wrote : apport-collect data

Architecture: amd64
DistroRelease: Ubuntu 9.10
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release amd64 (20091027)
Package: devicekit-power 011-1ubuntu1
PackageArchitecture: amd64
ProcEnviron:
 SHELL=/bin/bash
 LANG=en_US.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-18.55-generic
Uname: Linux 2.6.31-18-generic x86_64
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

Revision history for this message
Joe Kraxner (kraxner) wrote : Dependencies.txt
Revision history for this message
Joe Kraxner (kraxner) wrote : XsessionErrors.txt
tags: added: apport-collected
Revision history for this message
Kim Alvefur (zash) wrote :
Revision history for this message
lucas (lucasmocellin-kktua) wrote :

I have the same problem on a Lenovo S10

Revision history for this message
keneida (keneida) wrote :

benq s53 and dell d830 also have this problem

Revision history for this message
coolacid (coolacid217) wrote :

Any fix already?

Revision history for this message
David Gordon (david-gordon-hughes) wrote :

I too have same issue on HP DV6000 running 9.10. Has there been a fix yet or no progress?

Revision history for this message
Anakin Starkiller (sunrider) wrote :

Still the same problem with a Toshiba Satellite L505 on Lucid...

Revision history for this message
krzlew (krz-lewandowski) wrote :

I confirm that it's the same on Lucid. Is there any progress? This bug is really annoying

Revision history for this message
Aleksander Demko (ademko) wrote :

"me too" for my Dell Mini 9. Both 10.04 and 9.10 do this.

The shipped/stock 8.04 worked fine in this respect, in contrast.

Thanks

Revision history for this message
PGScooter (pgscooter) wrote :

Same problem with System 76 Pangolin Performance

Revision history for this message
Benjamin Humphrey (humphreybc) wrote :

Same issue with Dell Mini 9 running Lucid.

Revision history for this message
franglais.125 (franglais.125-deactivatedaccount) wrote :

Hey everyone, I am not a Linux expert and like many of you I have had this problem since 9.10 (I use a HP pavilion as many of you do, now 10.04, amd64),and I could not get my battery applet to show the remaining/charge time.

Today I was trying out cairo-dock, and for my surprise it DID show the time remaining (and charging time as well). I don't know if it calculates the time remaining by its own method or if it gets this information in the same way as the regular battery applet does.

Anyhow, I hope this works also for you... You will get the time remaining until somebody can fix this bug. And if you know a little more on how this actually works, maybe it could be a hint for solving it.

Cheers to everyone

Changed in devicekit-power:
importance: Unknown → Medium
Revision history for this message
Ryan Waldroop (ryan.waldroop) wrote :

This is even worse in Maverick Netbook. Now instead of a percentage, all I get when clicking the battery icon is "Laptop battery (estimating...)"

And it stays like that no matter which battery I'm using or whether I'm on AC or not. Always (estimating...)

As a workaround, I've resorted to constantly running byobu whether I need it or not. At least the battery applet there can tell me what percentage of battery is remaining.

Revision history for this message
Dylan McCall (dylanmccall) wrote :

This has been reported against Maverick's power indicator, bug #629258, and it has a lot of duplicates leading to it.

Revision history for this message
Dylan McCall (dylanmccall) wrote :

I feel funny doing it since this bug report is older, but #629258 is firmly settled in and this tangle of bug reports has to be made sane somehow. This way we won't lose any patches as they arise.

I think it makes the most sense to make that one the master. Feel free to unduplicate if I've made a mistake. I won't be upset :)

Revision history for this message
cthulhu1987 (boris-baran) wrote :

Same here with my Lenovo 3000 N200 and Ubuntu 11.04 ;(

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.