[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: apmd doesn't log battery status

R Poss <raph@burp.hostns> writes:

>> Hi,
>> I'm using a TP310E, which works quite well, even with
>> suspend-to-disk (hibernation mode), thanks to the "hdparm -u1
>> /dev/hda" trick. 
>> However, the APM bios doesn't seem to report battery status unless the
>> power state changes (i.e. when I plug in or out the power supply), and the
>> consequence is that I have no idea of the evolution of the remaining
>> battery life until the laptop starts to complain loudly (<5% left).

same problem here with a TP385.  Please check the docu for the TP310
series whether the batteries actually support this information.
I.e. my batteries only "know" the critical state (< 10%?), the normal
state (>10%, <80%) and the fully charged state (>80%).

>> So, this is the question, what can I do to have the kernel check
>> (or report, or "be informed bye the bios", or whatever) the battery
>> status ? I guess that this is an apm bios probem, but I couldn't yet
>> figure out where I'm doing wrong. And of course, I don't always have the
>> power supply with me to force the check by doing a power cycle...

you can randomly check by using either of the following two commands:

$ apm
AC on-line, battery status high: 80%
$ cat /proc/apm 
1.2 1.1 0x03 0x01 0x00 0x09 80% -1 ?

>> Thanks in advance for any help,
>> raph
>> PS: for information, I'm using a bare slink with a 2.2.12 kernel and apmd
>> 3.0beta5 and pcmcia-cs 3.1.2, but I had the same problem with my first
>> slink install.

Hmm, you could start logging the output of /proc/apm over time and
together with the average load figure out a formula for the


Reply to: