Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
using asus-acpi & acpi-supp -help w/ putting it all togethe
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
stardotstar
l33t
l33t


Joined: 10 Feb 2006
Posts: 887
Location: 2074/SYD/NSW/AU

PostPosted: Mon May 26, 2008 11:47 pm    Post subject: using asus-acpi & acpi-supp -help w/ putting it all toge Reply with quote

Now I am using the asus-acpi from the arcon overlay and the acpi-support from sunrise (need fake-key for the wifi script I am trying to get working)

I have the necessary modules built and inserted (pci express hot plug) but the script does not find the expected structure in /proc/acpi

so I have missed something.

here is some of the details:

Code:
mineeepc stardotstar # cd /usr/local/bin
mineeepc bin # ls
eee-wifi-on-off.sh  mount-device.sh  mountport.sh  umountport.sh
mineeepc bin # cat eee-wifi-on-off.sh
#!/bin/sh

#FILE: /sbin/eee-wifi-on-off.sh
# main wifi toggle script (loads/unloads modules)

#. /usr/share/acpi-support/key-constants

# The sequence here *may* be important.
# (It seems to fail intermittently if you deviate.)
unload_modules() {
    rmmod ath_pci
    rmmod ath_rate_sample
    rmmod wlan_tkip
    rmmod wlan_scan_sta
    sleep 2
    rmmod ath_hal
    rmmod wlan
}

# At least this one's straightforward.
load_modules() {
   modprobe ath_pci
}

wifi_on() {
    rmmod pciehp
    sleep 1
   # pciehp_force may be unnecessary; Xandros did it.
   modprobe pciehp pciehp_force=1
   sleep 1
   # Switch on the hardware
   echo 1 >/proc/acpi/asus/wlan
   sleep 1
   load_modules
}

wifi_off() {
    /etc/init.d/net.ath0 stop
   unload_modules
   echo 0 >/proc/acpi/asus/wlan
}

case $1 in
   on)
      acpi_fakekey $KEY_PROG1
      wifi_on
      ;;
   off)
      acpi_fakekey $KEY_PROG2
      wifi_off
      ;;
   toggle)
      STAT=`cat /proc/acpi/asus/wlan`
      if [ "$STAT" = "1" ];
         then wifi_off;
         else wifi_on;
      fi
      ;;
esac

mineeepc bin # ls /proc/acpi/
ac_adapter  alarm  battery  button  dsdt  embedded_controller  event  fadt  fan  info  power_resource  processor  sleep  thermal_zone  wakeup
mineeepc bin # ./eee-wifi-on-off.sh off
 * Stopping ath0
 *   Bringing down ath0
 *     Stopping dhcpcd on ath0 ...                                                                                                                        [ ok ]
 *     Shutting down ath0 ...                                                                                                                             [ ok ]
 *     Stopping wpa_cli on ath0 ...                                                                                                                       [ ok ]
 *     Stopping wpa_supplicant on ath0 ...                                                                                                                [ ok ]
./eee-wifi-on-off.sh: line 40: /proc/acpi/asus/wlan: No such file or directory
mineeepc bin #


I am hacking my way through the wiki on acpi and the script above to grok it well enough to get working but I would appreciate any insight anyone can give me on this:

\\'

[update] despite this the script seems to work - ie when "off" ath0 is No such device and when brought back on it appears and associates ok...
_________________
]8P
Back to top
View user's profile Send private message
IncredibleMrT
Tux's lil' helper
Tux's lil' helper


Joined: 07 Mar 2008
Posts: 109
Location: Rotherham, UK

PostPosted: Mon Jul 07, 2008 11:51 am    Post subject: Can't find ASUS_ACPI_071126.rar Reply with quote

stardotstar, having seen your post I have decided to give asus-acpi a whirl. I've added the arcon overlay but emerge cannot find the file ASUS_ACPI_071126.rar.
I don't suppose you still in distfiles do you? If so could you post it online somewhere or perhaps someone else might know where I could download it?

Thanks
Back to top
View user's profile Send private message
stardotstar
l33t
l33t


Joined: 10 Feb 2006
Posts: 887
Location: 2074/SYD/NSW/AU

PostPosted: Tue Jul 08, 2008 12:33 am    Post subject: Reply with quote

I have not looked at the acpi front for a while - but made great progress elsewhere (compiz-fusion//xfce4/wireless/multimedia and so on)

but that should still be available. I will have a look - having built several times since posting I don't know if I still have it in distfiles...

Would put it up for you if I can.
_________________
]8P
Back to top
View user's profile Send private message
IncredibleMrT
Tux's lil' helper
Tux's lil' helper


Joined: 07 Mar 2008
Posts: 109
Location: Rotherham, UK

PostPosted: Tue Jul 08, 2008 9:58 am    Post subject: Reply with quote

Did a google and found the file, thanks anyway.

Installed it and now have a button that controls the wireless (fn-F2). That's it!

Didn't seem to get the following to work

Fn-F1 - sleep (but I need to do some work to get this going)
Fn-F5/F6 LCD Brightness
Fn-F10 Mute
Fn-F11 volume -
Fn-F12 volume +

Hmmm.... Anybody have any ideas how I could get them to work? The laptop is an Asus X51RL.
Back to top
View user's profile Send private message
stardotstar
l33t
l33t


Joined: 10 Feb 2006
Posts: 887
Location: 2074/SYD/NSW/AU

PostPosted: Tue Jul 08, 2008 9:52 pm    Post subject: Reply with quote

Fn-F3/4 for LCD Brightness work out of the box for me.

I can toggle the wireless with Fn-F2 but it only works properly with the patched asus-acpi

I get nothing for Volume or mute or sleep (Zz) without the patched module - I will be looking at this later today so if I get anywhere I will post back.

Glad you got the file.

\\'
_________________
]8P
Back to top
View user's profile Send private message
IncredibleMrT
Tux's lil' helper
Tux's lil' helper


Joined: 07 Mar 2008
Posts: 109
Location: Rotherham, UK

PostPosted: Wed Jul 09, 2008 8:44 am    Post subject: Reply with quote

Is asus-acpi supposed to be able to control the LEDs too? On my laptop I have a panel on the front edge with, among others, a wireless indicator. When I toggle fn-f2 this led works as expected. I also have another panel above the keyboard where the power button is - that wireless led doesn't ever illuminate.
Hmmm... maybe i'll check to see if my kernel has the additional led support.
Back to top
View user's profile Send private message
stardotstar
l33t
l33t


Joined: 10 Feb 2006
Posts: 887
Location: 2074/SYD/NSW/AU

PostPosted: Wed Jul 09, 2008 10:01 am    Post subject: Reply with quote

which e do you have ? I m with the 701 original machine and the wireless blue led is hardware controlled from the box but does not necessarily work properly - as far as I can tell until the acpi is properly configured. Not really across all this yet. I don't have a light where the power button is.

I'm playing with the acpi now and especially the cpufrequtils and the eee overclocking module - works a charm!
_________________
]8P
Back to top
View user's profile Send private message
IncredibleMrT
Tux's lil' helper
Tux's lil' helper


Joined: 07 Mar 2008
Posts: 109
Location: Rotherham, UK

PostPosted: Wed Jul 09, 2008 4:57 pm    Post subject: Reply with quote

I don't have an Eee-PC. It's an Asus X51RL

Having a bit of a 'mare trying to get dual screens working with the onboard ATI too, but that's a whole other story. Never had a problem running Gentoo on my workstation - why do laptops have to be so awkward, eh?

Cheers
Back to top
View user's profile Send private message
ReDirEct__
Guru
Guru


Joined: 16 Mar 2006
Posts: 300
Location: Nola (NA) - Italy

PostPosted: Wed Nov 26, 2008 1:03 pm    Post subject: Reply with quote

hi all... someone tried to use the new asus-laptop module??? On my 904hd don't work... i have to use the acpi-asus from arcon overlay... the scripts in the first post, they are from ubuntu wiki right?
Back to top
View user's profile Send private message
_sil
n00b
n00b


Joined: 31 Dec 2007
Posts: 37
Location: UK

PostPosted: Wed Nov 26, 2008 2:59 pm    Post subject: Reply with quote

Hi there,

Quote:

I don't have an Eee-PC. It's an Asus X51RL


I have asus X71SR. Using asus-laptop module from kernel (CONFIG_ASUS_LAPTOP), following keys work out of the box:
Fn+F2 - thath's for bluetooth in my case
Fn+F5,6,7 - LCD brightness (Fn+F7 switches LCD off)

All other other keys are generating ACPI events, so it's just matter of catching those events and writing scripts for appropriate action (though I was too lazy to do that ;) ). It's also possible to control LEDS (in my laptop I have email and touchpad LEDS) by writing to sysfs interface.

Regards
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum