atheros wireless- how to turn it off

Solaris, RedHat, FreeBSD and the like
Post Reply
Message
Author
magneto
Posts: 24
Joined: Fri Sep 23, 2005 7:33 am
Location: Toulouse, France

atheros wireless- how to turn it off

#1 Post by magneto » Fri Oct 14, 2005 7:28 am

Hi,

I have a t43p with a atheros wireless andI am trying to find a safe way to turn off the wireless card. I have found this script that puts 3 to the power state and turn it off (I think..):

#!/bin/bash
# Find and enable/disable wireless devices

for DEVICE in /sys/class/net/*; do
if [ -d $DEVICE/wireless ]; then
# $DEVICE is a wireless device. Check if it's powered on:
if [ `cat $DEVICE/device/power/state` = 0 ]; then
# It's powered on. Switch it off.
ifdown ath0
echo -n 3 > $DEVICE/device/power/state;
else
# It's powered off. Switch it on.
echo -n 0 > $DEVICE/device/power/state;
fi
fi
done

Or another alternative is to remove ath modules. But I don't know if I remove them (ath_pci, ath_rate_onoe and wlan) the card is turned off.

Do anyone uses atheros wireless and how you turn it off??

Thanks....

rossman
Posts: 26
Joined: Tue May 03, 2005 5:53 am

#2 Post by rossman » Mon Oct 17, 2005 11:15 pm

Fn F5

or

in terminal: sudo ifdown ath0

T42 2373-3UU, Ubuntu Hoary

magneto
Posts: 24
Joined: Fri Sep 23, 2005 7:33 am
Location: Toulouse, France

#3 Post by magneto » Tue Oct 18, 2005 3:02 am

Fn F5 doesn't work for wireless (for me). It only switch on/off bluetooth. And ifdown turns off only the interface not the card. The card still consumes energy even the interface is shutted down.

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

#4 Post by kaiser » Tue Oct 18, 2005 10:49 am

What OS are you using? SuSE 9.3?
i can only speak for Ubuntu on a T42, the Fn+F5-Combi is bound by default to a script switching the state of BT and WLAN together.

And it seems to work (at least if i can trust the WLAN-LED). The Script controlling WLAN is exactly what you quoted.
now mine: T42 2373-VMH - 1.5 GB RAM, 60 GB HDD, BT, WLAN, SXGA, 9cell
--
url=www.thinkwiki.org

magneto
Posts: 24
Joined: Fri Sep 23, 2005 7:33 am
Location: Toulouse, France

#5 Post by magneto » Tue Oct 18, 2005 12:05 pm

Yes, I forgot to mention. I'm using suse 9.3 .

I wonder if it's safe to use that script. I think it shuts down directly the card. Is it safe to use??

rossman
Posts: 26
Joined: Tue May 03, 2005 5:53 am

#6 Post by rossman » Tue Oct 18, 2005 12:31 pm

Seems like for everone else but me Fn F5 controls BT. I don't know why. Kaiser and I went around about this in another post awhile back. My wireless light goes out when I ifdown ath0. But that may not mean squat. Seems the battery last much longer though...
magneto wrote:Fn F5 doesn't work for wireless (for me). It only switch on/off bluetooth. And ifdown turns off only the interface not the card. The card still consumes energy even the interface is shutted down.

Post Reply
  • Similar Topics
    Replies
    Views
    Last post

Return to “Linux Questions”

Who is online

Users browsing this forum: No registered users and 4 guests