battery applet - charge time instead of charge percentage.

Chani chanika at gmail.com
Tue Jan 6 04:31:12 CET 2009


On January 5, 2009 18:32:04 Sebastian Kügler wrote:
> Hi Marcos,
>
> On Tuesday 06 January 2009 01:14:03 Marcos Dione wrote:
> >     as I mentioned in IRC, I have a patch for this. as sebas and aseigo
> > suggested, I'm sending it here.
> >
> >     now, right now there are 3 bugs: the remaining time, either for
> > total discharge when the AC is plugged off and the complete recharge
> > time when the AC is plugged back in.
> >
> >     the first one is that the time jumps a lot depending on the laptop's
> > laod. just IRC'ing and lkistening to music makes it change from 3h to
> > 2:50. not a big gap, but misleading anyways.
>
> It might not be misleading, the number depends on how much energy 
your
> machine sucks at that -more or less- moment. It doesn't take into 
account
> usage patterns, of course. Playing MP3 can make quite a difference, 
btw. In
> order to provide a decoded audio stream, you need the CPU all the 
time, so
> it cannot be put to sleep. Even if it doesn't do much, it still can't
> really sleep, and eats battery.

it does seem like some smoothing could be done, though. maybe take the 
last few samples and average them or something? although ideally I think 
HAL should offer something like that for us.

>
> >     the third one is avoidable, really. I coded it so when the battery
> > is fully charged it shows 'Charged' instead of 0:00. the problem is that
> > right now it doesn't set its width (not again!) so the tect fits. this
> > can be 'solved' just removing an simple if until I hack the final code.
>
> Hm, are you sure it makes sense to show the time when it's plugged in? 
Is
> that actually the "time remaining until fully charged"? I looked at getting
> this information some time ago, but I think I couldn't find it ...

in kde3 (pre-hal) I had that information, and I found it useful, so I hope it 
is. :)


-- 
This message brought to you by eevil bananas and the number 3.
www.chani3.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/plasma-devel/attachments/20090105/f84620f8/attachment.sig 


More information about the Plasma-devel mailing list