Hey,
I just finished of a quick library of functions for controlling some
of the hardware features on Apple computers when running under Mac OS
X. So far, I have been able to control the screen brightness;
control the keyboard backlight brightness and fade time; get data
from the "sudden motion sensor" or built-in accelerometer; and get
data from the built-in light sensors.
It's included in the nightly builds as the 'apple' library, check
5.reference -> apple in the Help Browser for help patches.
Also, this should be pretty easy to do for other computers. For
example, the Thinkpad features are pretty well documented under
Windows and GNU/Linux:
http://www.almaden.ibm.com/cs/people/marksmith/tpaps.html http://www-128.ibm.com/developerworks/linux/library/l-knockage.html http://www.almaden.ibm.com/cs/people/marksmith/sdl.html http://www.gnome.org/~fherrera/gtollina.c
Or for Apple hardware, there is pbbuttonsd: http://pbbuttons.berlios.de/
.hc
¡El pueblo unido jamás será vencido!