[Debian-eeepc-devel] Problem with wireless hotkey

Gilles Mocellin gilles.mocellin at free.fr
Tue Aug 12 22:04:54 UTC 2008


Hello EeePC users,

I've never seen my wireless key working.
So, I investigate.

Here's what I found:

1) There's only one key
   So, one code to handle by /etc/acpi/actions/hotkey.sh.
   /etc/acpi/actions/wireless.sh must be a toggle script.
   
2) The wifi hardware and led are enabled by hardware (like the brightness)
   With the "echo 1 > /proc/acpi/asus/wlan", I saw my wifi led disabled one or 
two seconds after having been light up.
   I simply remove them.

In case there's an interaction,
I use a 701 4G Linux model
My BIOS is 1101
The interesting packages:
linux-image-2.6.25-2-686
eeepc-acpi-modules-2.6.25-2-686
eeepc-acpi-scripts_1.0.4
acpi-support-base_0.109-5

I will have to test with the 2.6.26 kernel…

Finaly, there's my scripts:
gilles at eeepc:/etc/acpi/actions$ cat wireless-toggle.sh
===========================================================================
#!/bin/sh

wlan_control=/sys/devices/platform/eeepc/wlan
[ -e $wlan_control ] || wlan_control=/proc/acpi/asus/wlan # pre-2.6.26

if [ $(cat $wlan_control) = 1 ]; then
    modprobe -r pciehp
    modprobe pciehp pciehp_force=1
    modprobe ath_pci
    # adding a sleep here, due to some bug the driver loading is not atomic 
here
    # and could cause ifconfig to fail
    sleep 1
    ifconfig ath0 up
else
    ifdown --force ath0
    modprobe -r ath_pci
fi
===========================================================================

gilles at eeepc:/etc/acpi/actions$ diff hotkey.sh.ori hotkey.sh
===========================================================================
2d1
< echo "$@" >> /tmp/hotkeys.log
63,66c62,65
<     00000010)
<       /etc/acpi/actions/wireless.sh on
<       show_wireless
<       ;;
---
> #    00000010)
> #     /etc/acpi/actions/wireless.sh on
> #     show_wireless
> #     ;;
68c67
<       /etc/acpi/actions/wireless.sh off
---
>       /etc/acpi/actions/wireless-toggle.sh
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://lists.alioth.debian.org/pipermail/debian-eeepc-devel/attachments/20080813/01be95d9/attachment.pgp 


More information about the Debian-eeepc-devel mailing list