g-p-m can't choose the right icon

Bug #38632 reported by Nicolò Chieffo
16
Affects Status Importance Assigned to Milestone
gnome-power-manager (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

this seems to be a startup bug! this is how I can reproduce it:

shutdown with the battery not fully charged,
plug the ac before turning on the pc,
gnome-power-manager shows me this icon: battery-charging-000.png but the battery, as it tells me is at 79% and in charge

ulpglugging+replugging the AC shows the correct icon

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

I wanted to specify that I'm using a

ASUSTeK Computer Inc.
M6Ne
1.0

maybe it might be an acpi-implementation issue... But I don't think it's difficoult to fix it,

Revision history for this message
Paul Sladen (sladen) wrote :

It says 'shutdown' above, do you mean 'suspend' or 'hibernate'?

Revision history for this message
Nicolò Chieffo (yelo3) wrote : Re: [Bug 38632] Re: gpm can't choose the right icon

no! a real shutdown!
simple steps to be as much clear as possible:
1) unplug AC and wait for the battery to be a bit discharged (a good
value to make sure this happens is 80%)
2) do a "sudo halt" or halt using the system menu
3) wait the complete shutdown
4) plug in the AC and start the computer (we need battery to be enough
low, otherwise it gets fully charged before n-m starts)
5) now the icon is wong! (but the text popup is ok)

I've noticed a recent n-m upgrade, tomorrow I will test if this bug is
still present!

Revision history for this message
Lauri Kainulainen (luopio) wrote :

On my laptop the issue rises (at least) when the laptop is started with AC disconnected and battery not totally full. The tooltip is correct ("running on battery..."), but the icon is the one displayed when the battery is charging.

By plugging AC in and taking it out again the icon changes to the correct one. Tooltips are correct all the time.

Revision history for this message
Corey Burger (corey.burger) wrote :

The above comment is exactly the situation I see. It only happens on a cold start, not from hibernation or suspension.

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

using edgy and the bug is still present! again only after a normal shutdows (no hibernate or suspend)

Revision history for this message
Simon Law (sfllaw) wrote :

It sounds like your battery might not be reporting the correct levels.

Could you run:
  $ (for i in /proc/acpi/battery/*; do echo = $i =; cat $i; done) | tee /tmp/battery.log
and attach /tmp/battery.log to this bug report?

Also, information as mentioned in https://wiki.ubuntu.com/DebuggingKernelProblems would be really helpful.

Changed in gnome-power-manager:
assignee: nobody → sfllaw
importance: Medium → Untriaged
status: Unconfirmed → Needs Info
Revision history for this message
Nicolò Chieffo (yelo3) wrote :

little error in the script:
(for i in /proc/acpi/battery/*; do echo = $i =; cat $i;/* done) | tee /tmp/battery.log

anyway the output is correct, and even gnome power manager gives only the correct tooltip over the icon (which is wrong, as if the laptop has no battery, and yes the icon is NOT shown if I choose "show icon only when the battery is charging/decharging", I have to choose "always show icon")

"the laptop is working under AC. battery: 29 minutes to complete charge"

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

dmesg shows
[17179603.400000] ACPI: Battery Slot [BAT0] (battery present)

Revision history for this message
Simon Law (sfllaw) wrote :

Yup. It looks like the logic to decide which icon to use is busted.

Changed in gnome-power-manager:
assignee: sfllaw → nobody
importance: Untriaged → Medium
status: Needs Info → Confirmed
Revision history for this message
Nicolò Chieffo (yelo3) wrote :

not only that!
remember that the icon is not shown if you choose "show icon only when the battery is charging/decharging"
I don't know how this is implemented, but it can be that g-p-m thinks that there is no battery.

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

Ok that's fixed now

Changed in gnome-power-manager:
status: Confirmed → Fix Released
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.