current/amd64 on a Thinkpad T400 (dmesg below).
The battery gets used, as batteries do.
With AC connected:
$ sysctl hw.sensors.acpibat0
hw.sensors.acpibat0.volt0=11.10 VDC (voltage)
hw.sensors.acpibat0.volt1=12.37 VDC (current voltage)
hw.sensors.acpibat0.power0=0.00 W (rate)
hw.sensors.acpibat0.watthour0=14.75 Wh (last full capacity)
hw.sensors.acpibat0.watthour1=0.74 Wh (warning capacity)
hw.sensors.acpibat0.watthour2=0.20 Wh (low capacity)
hw.sensors.acpibat0.watthour3=14.75 Wh (remaining capacity), OK
hw.sensors.acpibat0.watthour4=48.84 Wh (design capacity)
hw.sensors.acpibat0.raw0=0 (battery full), OK
With AC disconnected:
$ sysctl hw.sensors.acpibat0
hw.sensors.acpibat0.volt0=11.10 VDC (voltage)
hw.sensors.acpibat0.volt1=11.90 VDC (current voltage)
hw.sensors.acpibat0.power0=17.89 W (rate)
hw.sensors.acpibat0.watthour0=14.75 Wh (last full capacity)
hw.sensors.acpibat0.watthour1=0.74 Wh (warning capacity)
hw.sensors.acpibat0.watthour2=0.20 Wh (low capacity)
hw.sensors.acpibat0.watthour3=14.20 Wh (remaining capacity), OK
hw.sensors.acpibat0.watthour4=48.84 Wh (design capacity)
hw.sensors.acpibat0.raw0=1 (battery discharging), OK
It only charges now to 14.75 Wh out of the original 48.84 Wh.
Up to the last reboot, 'apm -l' used to tell that percentage.
After the last reboot, it says 100%, because 14.75 is indeed
100% of the "last full capacity".
My question is: what exactly makes 14.75 the last "full" capacity?
How is that determined? Does the code for hw.sensors somehow observe
the AC is connected, but it's not getting charged
for the last $N minutes, so this must be the full capacity
or is this just what the battery tells us via apcibat(4)?
Possibly via "hw.sensors.acpibat0.raw0=full"?
Perhaps this is intended; does it mean that once the battery gets
to a capacity of 1Wh, then having it charged to 1Wh will be a "full"
battery? Would it be better if apm -l said the battery is
(14.75 / 48.84) full now?
Jan