Install Atheros AR242x 802.11abg Wireless Driver in Ubuntu

Recently I had a chance to install Ubuntu 9.04 in an ASUS EEE PC for a friend of mine. Everything was working smoothly except wireless which was  Atheros Communications Inc. AR242x 802.11abg Wireless PCI Express Adapter (rev 01). Eventhough available drivers were listed on Hardware Driver, it was already in active mode and still not working. Finally i got it working. Here is what i did.

  •  Goto System > Administration > Hardware Drivers and disable both Atheros HAL and the Atheros wireless listed and then reboot.
     
  • Now install build-essential and subversion. Goto Applications > Accessories > Terminal and type as follows.
     sudo apt-get install build-essential subversion
  • Now make a new directory  in you home.
     cd ~
     mkdir madwifi
  • Now cd into the newly created  directory, madwifi.
      cd madwifi
  • Download the code now.            
svn co https://svn.madwifi-project.org/madwifi/branches/madwifi-hal-0.10.5.6
  • After finishing downloadusing subversion cd into directory madwifi-hal-0.10.5.6
      cd madwifi-hal-0.10.5.6
  • Run make to build the driver.
       make
  • Install the driver.
        sudo make install
  •  Now you have to add the Atheros kernel module to the list of modules to be automatically loaded at boot by adding " ath_pci " (without the quotes) to the end of the /etc/modules file. I used gedit here. You can use the editor of your choice.
        sudo gedit /etc/modules
  • Reboot. It should work now. Let me know if there is any problem with this guide.
Your rating: None Average: 4.3 (8 votes)

Thanks for the great tutorial. Works like a charm on my HP Pavilion DV9720US with an atheros Wi Fi adapter. Must advice, On inputting svn from madwifi.org, the terminal shows the certificate of madwifi.org and asks to (r)eject or accept (t)emporarily, or (p)ermanently. input p to let the download take place,
Thanks, lot for this wonderful tutorial, though the fix does not enable the LED indicator on the laptop to change colour from amber (deactivated) to blue (active) the led remains amber but network manager shows wifi connection is active and gives the ssid of the connection that it is connected to. Any help on this from other HP users is welcome.

thx

thx for your tutorial...

i use a Toshiba U400 with Atheros wireless driver and now is working....

cheers ^^

Tried to do this because my Asus eeepc wireless doesn't work after installing Ubuntu.
But the system says that I don't have the subversion package! Where do I find the suitable package and what is the easiest way of installing it or can I install the madwifi thing without the subversion? If so how? i am new to this. Thanks

Did you followed the steps as given, i have to ask beacause first step in this tutorial is regarding subversion installation. Can you confirm.

Thanks

i heart you!
i was at my wits end, i tried reading all of the lessons in the beginner manual thing. TRIED... but i found this! you saved me!

This procedure fails (for at least one user).
"When I go to disable the drivers as recommended [...] I get an error of "You removed the configuration file /etc/modprobe.d/blacklist-ath_pci.conf". I am not able to proceed past that point. To be specific, when I go to Hardware Drivers I am immediately shown the Alternate Atheros madwifi driver is activated. The error comes up when I click on 'Deactivate'."
Thread is here:
https://answers.launchpad.net/ubuntu/+source/gnome-nettool/+question/855...

Do you have a suggested work-around? Many thanks!

Thanks for this great HOWTO. I have my atheros wireless working on my Karmic Koala. Best Regards

Super, now I have INTERNET in my room. It wasn't very comfortable to be disturbing my neighbor everytime I needed internet. Thank you!! you are a magician.

But, sometimes there appears an error an says something like "autentification needed", I mean, I don't know why it happens several times when I try to connect to any wireless although I have inserted the key.

sorry for my English. ¡¡Saludos desde México a todos!!

Excellent! Thanks, I sort of f****d the original driver up, this fixed it.

Merci beaucoup pour cette solution!!!!

Thank you so much. I had spent about 8 hours fighting Microsoft to load XP on my netbook but I gave up and decided to go it alone on linux(im still a Linux newb so I wanted my Windows backup) and when the wireless on ubuntu all of a sudden stopped working I was ready to give up on the netbook all together. Thanks to this walk through my beautiful netbook is working again. Thank you.

Thank you very much. Finally I can access internet with my acer emachines d725 via its wireless hardware. Thanks again!

but then somehow my totem player cannot play mp3 audios anymore (only the first 3 second and than the machine hang). other player can play them well, so i think it's not a codec problem. i don't know whether it is relevant with the topic but before it stop functioning i did nothing except your instruction. any suggestions to fix this problem?

That is some seriously weird issue, probably because of some totem updates, I am just speculating. But why do you need Totem( ! ) when you have VLC, Smplayer, amarok , exaile, banshee and a host of other really good multimedia players out there. Totem has always been a real pain in the neck for me. I am just suggesting, it is all your choice. :-)

...only once.
Until recently, my Toshiba Satellite A135-S4666 had great connectivity in Hardy. Then it crashedt, but only on my home network. Using WICD, it either hung on "authentication" or while it was waiting for an IP. When it did get an IP, it was very, very slow. This is on a Linksys WRT56GL, running Tomato. (Was using DD-WRT, but switched while trying to solve this problem.
Went through the easy-to-follow tutorial, logged on at home and everything rocked. A rock-solid, fast connection. Shut down and went to sleep.
Next morning, I was back to the same situation. Perhaps it was all a dream.
Or perhaps someone has a suggestion.
Thanks.

-- neil

Great work! :) Thanks.

Worked a treat thanks, newish to Linux and these instructions worked first time

hi,
It's working on my laptop (Toshiba-Satellite-A215-S6816) now.

thanks for guidance.

-2f@n-

This is my first ever comment on web....
After lost all the hope to find some solutions for my Compaq Presario C700 wifi driver finally i got in urs manual....hats off..gud work yaar[Friend]...keep going...[:)]

When i have conected it works fine but after 20 s connection fall down

it is not working on ubuntu 9.04 on aspire 5530G when i establish connection it is working fine but after 20 s connection fall down My kernel is 2.6.28-11-generic #42-Ubuntu SMP Fri Apr 17 01:57:59 UTC 2009

Very nice guide to getting it up and running, just a couple of quick suggestions to add

1) for the svn checkout, you can use
svn co https://svn.madwifi-project.org/madwifi/branches/madwifi-hal-0.10.5.6 madwifi

this negates needing to first create the madwifi folder, svn will create it for you on checkout. You can then just cd madwifi (instead of the second level with the versioned folder) and make/sudo make install from there

2) after install, you can also run the following to avoid requiring a reboot

sudo rmmod ath5_pci ath5k
sudo modprobe ath5_pci

Finally, a web page where one just follows the instructions and it works.

Acer 4220 with ubuntu 8.04

Thank you very much for this guide. It worked prefectly and got the wireless working on my HP dv6000 series laptop!

Since the ath5k had loaded I had to do this to make it work. " sudo gedit /etc/modprobe.d/blacklist-ath_pci.conf " Then I changed the file to this " # For some Atheros 5K RF MACs, the madwifi driver loads buts fails to
# correctly initialize the hardware, leaving it in a state from
# which ath5k cannot recover. To prevent this condition, stop
# madwifi from loading by default. Use Jockey to select one driver
# or the other. (Ubuntu: #315056, #323830)
# blacklist ath_pci
blacklist ath5k
" Then the madwifi driver loaded and the stability was much better.

hi... its nice to see your webpage, my ACER 4520 wifi work good. i buy my laptop Jan 2008, last one and half month trying for wifi problem. Today one i fix my problem... Thanks lot

Thx for your post, it's very clear and easy even for a noob like me.

I'm facing significant issues with Wifi access, with Ubuntu 9.04 on Asus eeePC 1002HA. 1Go RAM, 160 Go HD)

Unfortunately I'm the owner of this Atheros AR928X card for which it looks like dreaming to find a working setup, even with my google's friend or on the Ubuntu's numerous forums.

I guess the answer depends on madwifi drivers, but :

Any chance your post also applies for AR928X ?

Thx in advance

PS: the "low cost" Captcha : a so real nice idea !

Thanks for the comment. I don't think the above post is going to work with your hardware. Check the thread below, may be it could help you.

http://ubuntuforums.org/showthread.php?t=894177

I have an Averatec 2500 with Ubuntu 9.04 O.S, initially my wireless signal was poor, about 20%, even though my laptop was near to the Router, I did Exactly what you said and now It Works Perfectly!!, my signal strength is about 90-95%. Thank you so much, very nice post.

I don't normals comment on things like this, but after days of reading ,trying various things and pulling my hair out I found this site. I managed to get it working with No problems ,Everything went smooth step by step.
AWESOME JOB

Hi,

I have a LG R400 laptop and lspci | grep Wireless gives:

05:00.0 Ethernet controller: Atheros Communications Inc. AR242x 802.11abg Wireless PCI Express Adapter (rev 01)

I tried your method above, but NetworkManager still does not detect that I have a Wireless card.

lsmod | grep ath
ath_pci 217784 0
wlan 237936 1 ath_pci
ath_hal 312160 1 ath_pci
ath5k 107008 0
mac80211 217464 1 ath5k
led_class 12036 1 ath5k
cfg80211 38288 2 ath5k,mac80211

iwconfig
lo no wireless extensions.

eth0 no wireless extensions.

wmaster0 no wireless extensions.

wlan0 IEEE 802.11bg ESSID:""
Mode:Managed Frequency:2.412 GHz Access Point: Not-Associated
Tx-Power=20 dBm
Retry min limit:7 RTS thr:off Fragment thr=2352 B
Power Management:off
Link Quality:0 Signal level:0 Noise level:0
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0

pan0 no wireless extensions.

Please let me know what else i can try.

Regards,
Chris

IVE BEEN TRYING TO DO THIS FOR 4 DAYS NONE STOP NOW AND TRYED EVERYTHING ALL I CAN SAY IS THANK YOU I WAS GETTING READY TO GIVE UP I WILL GO TO A LOT OF FORUMS AND POST THIS TO HELP OTHER PEOPLE NOW YOU HAVE MADE A LOT OF PEOPLE HAPPY THANKS AGAIN.

I followed the installation, now my network manager recognizes I have wireless but cant connect?? Also , it says I'm not connected via erthernet when I am. I followed some post that had me create a "blacklist " i few things?? I wonder if this is affecting it?

Thanks !!! It worked fine for me too!

DUDE I HAVE BEEN TRYING TO GET MY STUPID WIFI CARD TO WORK FOOOOOOOOOOOOOOOREVER THANK YOU SOOOOOOOOOO MUCH FOR THIS SUPER EASY AND AMAZING SOLUTION!!!!!

It is so good to see a lot of people getting their problem solved because of this post. But these informations are not just mine or anything. I had this same problem and so i had to search a lot in communities and forums to get it work.

What i did was to simply put together the info i got from a number of forums and sites so that some other may find it helpful. The real winner is open source community as such. Cheers to that :-)

I am curious if kernel updates major or minor affect your wifi? My machine every little kernel update and I am having to recompile the wifi drivers... Wish there was a solution to this. The Atheros chipset has been out a while and is quite common, one would think they would have it worked out by now...

Thanks bro, this was very usuful and easy to do.
Thanks a lot.

You are welcome friend :-) keep visiting

buildessential must be seperated by a "-" like build-essential

Thank you for suggesting. We have made appropriate changes. :-)

Thanks a lot. It worked fine for me :-)

I tried the above method, but the AR242.x card still does not work on an Acer Aspire One with Ubuntu 9.04 installed.

It worked in fine when i tried these steps in Asus EEE PC though. Let me know if you were able to go through the post without any problems. I mean, if it showed some error or something.

just tried it with an Acer Aspire One Netbook of the type that is sold at Costco Cell Phone Kiosks, but the wireless still didn't work at all.

DId you faced any issues while following the steps in the post? Or it went smoothly?

Please run the following command in terminal and copy paste it in your reply.

              lspci | grep Wireless

im a complete ubuntu noob, any way u can make something that just does this for me?

Copy and paste line by line in terminal! Its fun :)

Hi,

        These commands are not as scary as u think. It is rather simple. I know how you will be feeling like seeing all these commands at one go. Try doing it step by step.

Remember one thing. Everything written in 'box' in the above post are commands and you need to access Terminal to run these command. Goto Applications > Accessories > Terminal. Afterwards simply follow the above post and give your password when you are asked to. Let me know the issues you face no matter whatever it is. :-)

You may also want to look at this Quick list of things a newbie Ubuntu user should knew.

I am trying your posts here and ran into "you do not have permissions to save" after adding the "ath_pci

Sorry about that misunderstanding.

Simply do " sudo gedit /etc/modules "  instead of " gedit /etc/modules " (give your password  when prompted to) and then add "ath_pci".

Saving wont be a problem afterwards. I also have updated the post above accordingly. Hope it works for you. :-)

Thank you for helping solve what seemed to be an impossible problem- I went around googling and some of the material looked like allnighters with dependency hell for good measure, then I found yours.

I'm no unix wizard but my blundering around on http://www.linuxquestions.org/questions/linux-networking-3/atheros-ar242... might help others. I had to delve a little bit more. As you see I have ASUS X50RL, and at present have triple boot XP/Ubuntu/Debian.

Earlier posts had network disappearing after 20 seconds. Before I used "echo" to enable wireless, (script now added to rc.local), that was my experience too.

I really don't know whether the "compat-wireless" driver set was actually necessary- but in my case it seemed to make a difference. As an experiment, having used your advice on Ubuntu 9.04, I applied it to Debian Lenny, building wireless-compat first, and that didn't work. For me, it seems unlikely that both are necessary- after all, I think the Ubuntu live cd uses madwifi- but, not fully understanding these drivers, I can only guess.

Anyway thanks again, as you said this is the lifeblood of opensource, long may it continue.

Thanks - worked perfectly - first time.

An earlier visitor post mentioned problems with an acer. This has an Atheros but a different version. Connect to wired network then: # apt-get install linux-backports-modules-$(uname -r) you can see the origin of this at http://ubuntuforums.org/showthread.php?t=1244686 , not mine. Works on my aspire one. If you get trouble replace your gnome network admin package with wicd. Note that there is a wireless on off toggle slide control front left of the netbook. Hope I'm not stating the obvious but it trips people up. 

The last update of the backports from this segment was the part that did the trick for me, I am using wicd manager as well but finally after 4 days it finally works. Don't really know if it was only this guide that really did all of it, but imo it's solid!

Thanks so much!

Got my wifi working without ndiswrapper, and should be able to use aircrack too! :P