Page 1 of 1

bug in Letux400 APM implementaion

PostPosted: Mon Apr 27, 2009 9:15 pm
by rmottola
I think the kernel has serious problems with apm. A cat in /proc/apm shows for example

root@hobbit:~# cat /proc/apm
1.0 1.2 0x02 0x01 0x03 0x08 -106% 8640 min

this shows a lot of bogus information: obviously percentage and remaining time, but more subtle are the 0x03 and 0x08 values.
0x08 is absurd, it is not a valid battery flag.

More subtle is 0x03: it meabs battery status "charging". However in my case I running off battery.
When I run off the PSU, it says 0x04, which is invalid, according to the information I found around.

Why do I care? I think the kernel is plainly broken. I want to extend the GNUstep battery monitor to allow it to support the 2.4 kernel and APM. The skytone battery monitor is very crude too: it shows like 25%, 50%, charging... I suppose the use the flags.
But it appears to me the status btis are invalid: shifted by 1? But how can I hack that in my code, it would be awful, I do not how to detect it. Currently I detect bogus percentage information and try to resort to the flags, but that is not enough...

Re: bug in Letux400 APM implementaion

PostPosted: Sat May 16, 2009 11:13 am
by hns
Please wait for the new 2.6 kernel...
Nils has made some good progress recently.

-- hns