[ltp] udev rule and bluetooth

Thomas Breitner linux-thinkpad@linux-thinkpad.org
Wed, 02 Aug 2006 20:55:54 +0200


nothing is wrong with ibm_acpi - but if this functionality is already in
an more generic way implemented in the kernel, why should i bother a
module designed only for thinkpads? 
using udev, i could move my installation from one notebook to another,
only changing the hardware-specific configurations. thats what i've done
when switching from an inspiron to my thinkpad.

ok, its not very important, but i handle my other hardware-specific
scripts/device naming etc by udev - so why not the bluetooth stuff also?

but thanks a lot - perhaps i should use your solution :-)
thomas


Am Mittwoch, den 02.08.2006, 09:58 +0200 schrieb Torsten Wolf:
> * Thomas Breitner <mail@tombreit.de> [06-08-02 09:43]:
> 
> >does anyone have some working udev-rules for the fn+f5-bluetooth-switch?
> [...]
> >any ideas about some thinkpad-udev-rules for someone who dislike binding
> >this action to/on(?) ibm_acpi?
> 
> What's wrong with ibm-acpi? I simply added a file containing
> 
>   event=ibm/hotkey HKEY 00000080 00001005
>   action=/usr/local/bin/toggle_bluetooth.sh
> 
> to /etc/acpi/events with all the scripts in toggle_bluetooth.sh. The
> state of the bluetooth device can be determined as follows:
> 
>   STATUS=`grep "status:" /proc/acpi/ibm/bluetooth | awk '{print $2}'`
> 
> Certainly the above line is not very elegant but on the whole it works
> without problems.
> 
> Cheers,
> Torsten
-- 
_____________________________________________
Thomas Breitner

mail@tombreit.de   |   http://www.tombreit.de