-   Ubuntu (
-   -   ACPI events in /etc/acpi/events (

alienDog 12-22-2010 07:30 PM

ACPI events in /etc/acpi/events
I've been trying to get Fn+F3 to toggle the backlight on my trusty old Thinkpad R50 running Linux Mint 9 (~ Ubuntu 10.04 with some added codeds and stuff). I tried to do this by adding an event handler (backlight) in /etc/acpi/events:


event=button[ /]screenlock

and a script ( for it in /etc/acpi:


if [ -e /tmp/screenoff ]; then
  sudo /usr/sbin/radeontool light on
  rm -f /tmp/screenoff
  sudo /usr/sbin/radeontool light off
  touch /tmp/screenoff

The result was that it doesn't work. However, if I run a second instance of acpid, the hotkey starts working. Then I took a look at this:

From which I found out that ACPI events are passed to HAL through a socket in /var/run (is that why the /etc/apci/events doesn't work anymore?). In the same document it says that:


hal-addon-acpi currently only handles a very limited set of ACPI events (button, ac_adapter, battery).
Bummer. So it can't be done with HAL and it doesn't work "the old fashioned way". How exactly does it work?

All times are GMT -5. The time now is 06:51 AM.