ACPI time remaining
ee21rh at surrey.ac.uk
Mon Feb 7 10:57:04 PST 2005
After studying the battstat source, I've found a property that we don't
currently export, and need to.
present rate: 25822 mW
For this we need a battery.rechargeable.rate (int) key in HAL.
With this, we can do:
Time to discharge (m) = remaining (mWh) / rate (mW) * 60
Time to charge (m) = (max_capacity (mWh) - remaining) / (rate * 60)
Also on the topic, what about making the key
*battery.charge_level.percentage* mandatory? It would make the
applications much easier to code, and we could always rely on this value,
and not have to have "special cases" for things (the whole idea of an
Note: this is quite a simple formula. My ideas are changing about the
battery.time_to_discharge idea. Maybe it should be in the HAL addon. If
APCI, PMU and APM have it, then maybe it should be in the spec. Comments?
hal mailing list
hal at lists.freedesktop.org
More information about the Hal