Fn+F6 and Ubuntu

Solaris, RedHat, FreeBSD and the like
Post Reply
Message
Author
Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

Fn+F6 and Ubuntu

#1 Post by Edward Mendelson » Mon Oct 24, 2005 10:26 am

Question about the Fn keys and a T4x with Bluetooth.

Under Ubuntu, Fn+F5 seems to toggle all wireless devices. I'm trying to set up Fn+F6 to toggle Bluetooth only, as described in the second message here:

http://www.ubuntuforums.org/showthread. ... oth+marius

Can't get this to work under Ubuntu Breezy on a T42. Has anyone else tried this with any success?

kaiser
Freshman Member
Posts: 68
Joined: Sat Jul 09, 2005 2:59 am

#2 Post by kaiser » Mon Oct 24, 2005 10:59 am

you will have to enable all Fn+FX-Combinations. by default only the ones which are predefined (i.e. got a function-symbol) are enabled.
ibm-acpi README wrote:Hot keys -- /proc/acpi/ibm/hotkey
---------------------------------

Without this driver, only the Fn-F4 key (sleep button) generates an
ACPI event. With the driver loaded, the hotkey feature enabled and the
mask set (see below), the various hot keys generate ACPI events in the
following format:

ibm/hotkey HKEY 00000080 0000xxxx

The last four digits vary depending on the key combination pressed.
All labeled Fn-Fx key combinations generate distinct events. In
addition, the lid microswitch and some docking station buttons may
also generate such events.

The following commands can be written to this file:

echo enable > /proc/acpi/ibm/hotkey -- enable the hot keys feature
echo disable > /proc/acpi/ibm/hotkey -- disable the hot keys feature
echo 0xffff > /proc/acpi/ibm/hotkey -- enable all possible hot keys
echo 0x0000 > /proc/acpi/ibm/hotkey -- disable all possible hot keys
... any other 4-hex-digit mask ...
echo reset > /proc/acpi/ibm/hotkey -- restore the original mask
after "echo 0xffff > /proc/acpi/ibm/hotkey" i used my Fn+F6 successfully for a Bluetooth-Switch-Script, but i don't know how to enable all Hotkeys on every Startup.
now mine: T42 2373-VMH - 1.5 GB RAM, 60 GB HDD, BT, WLAN, SXGA, 9cell
--
url=www.thinkwiki.org

Edward Mendelson
**SENIOR** Member
**SENIOR** Member
Posts: 583
Joined: Mon May 24, 2004 10:11 am

#3 Post by Edward Mendelson » Mon Oct 24, 2005 12:39 pm

Yes, that's the answer. The next (but not, unfortunately, the last) step is to put this into a script that you make executable in /etc/init.d - something like this:

Code: Select all

#! /bin/sh
# /etc/init.d/my-custom-startup.sh

echo 0xffff > /proc/acpi/ibm/hotkey &
exit 0
Save it as /etc/init.d/my-custom-startup.sh, make it executable with sudo chmod +x.

But I can't seem to make this run at the right time (after acpid is loaded), not even with the command "sudo update-rc.d my-custom-startup 99 ."

Any suggestions would be helpful here...

Post Reply
  • Similar Topics
    Replies
    Views
    Last post

Return to “Linux Questions”

Who is online

Users browsing this forum: No registered users and 3 guests