You are not logged in.

#1 2011-04-28 15:17:49

MkFly
Member
From: Mars
Registered: 2009-12-10
Posts: 141

[SOLVED] Remaining battery charge way off when resuming from suspend

This has been bugging me for a while now.  When I resume from suspend, more often than not my battery level is reported as critical by xfce4-power-manager (I now use gnome-power-manager, and it's been giving me the same problem).  Sometimes it will correct itself within a few minutes, but most of the time it doesn't.

Restarting the power manager doesn't do anything, restarting X doesn't do anything.

The acpi command always seems to report the correct battery life:
15me0br.png

If there's some command to refresh whatever these power managers are reading from, I could just add it to a hook in /etc/pm/sleep.d ...

Last edited by MkFly (2011-04-29 03:12:59)

Offline

#2 2011-04-28 15:53:02

MkFly
Member
From: Mars
Registered: 2009-12-10
Posts: 141

Re: [SOLVED] Remaining battery charge way off when resuming from suspend

Offline

#3 2011-04-28 19:23:39

MkFly
Member
From: Mars
Registered: 2009-12-10
Posts: 141

Re: [SOLVED] Remaining battery charge way off when resuming from suspend

I think the next time this comes up, I'll try restarting upowerd ... if that works, I could make a hook for it.

Offline

#4 2011-04-29 03:11:15

MkFly
Member
From: Mars
Registered: 2009-12-10
Posts: 141

Re: [SOLVED] Remaining battery charge way off when resuming from suspend

smile

This seems to have done the trick:

/etc/pm/sleep.d/10-upowerd

#!/bin/bash

case $1 in
  resume | thaw)
    UPOWERD=/usr/lib/upower/upowerd

    /usr/bin/killall -9 ${UPOWERD}
    ${UPOWERD} &
  ;;
esac

Offline

Board footer

Powered by FluxBB