Comment 27 for bug 1093543

Revision history for this message
bwalex (ahornung) wrote :

Well, here go 3 more patches.... 1 for upower, 2 for the kernel.

The upower one just fixes a logic bug that will allow the design capacity to be read via charge, even though the current energy is read directly as energy.

The kernel patches are:
1) Fix a bug in a previous patch - even though the datasheet says that energy_now is in units of 10 mWh, it turns out it isn't - it is in units of mWh.
2) Add charge_full and charge_full_design nodes.

With these patches, upower seems to report the right percentage, time to empty, etc.

Would appreciate some testing from someone suffering from the problem. Remember to apply all the patches (the upower one, these two kernel ones, and depending on which kernel you are running, also the patches that add the current_now and energy_now fields - although those are committed already).

Cheers,
Alex

PS: launchpad only supports one attachment per comment, it seems, so the rest are in separate comments.