Custom hot key programming with acpid
Hooking the Script to acpid
Getting acpid to use your script is really just a matter of editing the /etc/acpi/event/ibm-videobtn file and replacing the action= line with a pointer to your script. On my system, the script is /usr/local/sbin/video-switch, so my ibm-videobtn file looks like this:
event=ibm/hotkey HKEY 00000080 00001007 action=/usr/local/sbin/video-switch
When you modify the files under /etc/acpi/events, you'll need to restart acpid to get it to pick up the changes.
Additionally, you'll want to get acpid out of debug mode, so hit Ctrl+C in the window in which acpid is currently running then enter /etc/init.d/acpid start as root to fire up the daemon normally. At this point, hitting Fn+F7 on the laptop should cycle it through the three display settings programmed in the script. Because this very simple hack works as advertised, I've gotten tons of "geek cred" at various Linux User Group meetings.
Programming your own hot key hacks is equally simple. First, run acpid in debug mode to figure out exactly which event is triggered by your key presses. Then check the /etc/acpi/event directory to see whether a configuration file related to this event already exists. If not, feel free to create one from scratch – you really only need the event= and action= lines for most simple events. From there, it's just a matter of scripting what you want to happen. In many cases, you might be able to find example scripts on the web to use as a starting point.
Read full article as PDF:
Version 16 of the popular Linux desktop reveals new tools, edge-snapping, and performance improvements.
Symantec says Linux-Darlioz burrows in through PHP.
Dell renews its quest for the ultimate developer machine.
Innovative back door looks like normal SSH traffic.
One of CeBITs most successful forums opens the new year with a new name. The popular Open Source Forum continues in 2014 under the name Special Conference: Open Source. This year, the forum will be bigger and offer a wider range of possibilities for sponsors.
New release offers better graphics drivers and expands filesystem support.
New mail protocol will shut out the NSA and prevent snooping on metadata.
A new web application helps users visualize distributed denial-of-service attacks.
Ubuntu 13.10 takes a step toward convergence, with lots of mobility, but Mir only partly here.
Galileo board is targeted to embedded developers and educational institutions.