Rate guessing code
Søren Hansen
sh at linux2go.dk
Wed Nov 2 12:32:24 PST 2005
ons, 02 11 2005 kl. 19:46 +0000, skrev Richard Hughes:
> > Some laptops don't provide the rate information, but that's not reason
> > for HAL not to provide it. That's what this change does. The first time
> > around it stores the chargeLevel. On each subsequent run it uses the
> > chargeLevel from the previous run to determine the rate at which it
> > drops (during discharge) or rises (during charge).. That info is passed
> > on to the time calculation code and voila!
> Clever, I like it.
*blush* :-D
> > It stores the info about each battery in a hashmap with the udi as key,
> > so it also supports multiple batteries.
> Cool. You might want to add a multi-line comment in the code to explain
> to mere mortals what you're doing.
Done. I've attached a new version of the patch.
> Other than that the patch looks good. I'll give it a try (i will nobble
> my rate reporting..) sometime tonight.
Great. Thanks a lot for your input!
--
| Søren Hansen | Linux2Go | http://Linux2Go.dk/ |
| Seniorkonsulent | Lindholmsvej 42, 2. TH | +45 46 90 26 42 |
| sh at linux2go.dk | 9400 Nørresundby, Denmark | GPG key: E8BDA4E3 |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Dette er en digitalt underskrevet brevdel
Url : http://lists.freedesktop.org/archives/hal/attachments/20051102/3256a1fc/attachment.pgp
More information about the hal
mailing list