Re: [POWER] battery calibration parameters from sysfs

From: Mark Brown
Date: Fri Dec 04 2009 - 05:49:43 EST


On Fri, Dec 04, 2009 at 11:42:22AM +0100, Linus Walleij wrote:

> Most devices of this kind does not need the stuff we're doing so we're
> the odd bird here. Other batteries are "smart" (contain factory
> calibration inside of them) or get calibration from some BIOS or such.

> In our code we have a number of (x,y) pair tables like this:

> /* Vbat mV to Battery capacity % */
> struct voltage_vs_capacity {
> int voltage;
> int capacity;
> };

Isn't the standard thing here to handle this voltage to capacity mapping
in userspace if we're just extrapolating from experimental results?
Even with the "smart" batteries in PCs there are some accuracy concerns
and obviously the performance of the battery will change over time.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/