You are on page 1of 9

HOWTO Install compat-wireless drivers for WNA1100 USB adapter

2010- October 8th

Attention: Linux is in constant improvement. Linus Thorvald has already implemented 
the required driver in the recent kernel versions. Today Ubuntu and Kubuntu are using 
older kernel versions than the kernels which support the WNA1100 adapter.  It is only 
time (months/weeks?) until this adapter is supported as plug and play!

This document is written and has been tested on Kubuntu 10.04. Please try to find 
information whether your device should work out of the box, or not.  
Introduction

Hello,

This quick start manual initially started as a quick post on the Ubuntu forums just to write of 
some of my own frustration regarding getting the wireless card to work with my newly built 
system. Make­errors during compiling the sources got me to call a friend, who was able to find 
a way and solve my problem. Finally after 2.5 hours of fiddling it compiled and installed ! 
Immediately I posted my findings to share it with the rest of the world. 

My error in posting the quick post  was not including Linux command line specifics. Leaving 
people unfamiliar with Linux out of the loop. As with most things, simplification is best. This 
rewritten manual should help in installing the WNA1100 USB adapter which is based on the 
Atheros       AR9271   chipset.     The   Linux   wireless   driver   package   for   this   chipset   is   named 
ath9k_htc.       See  http://linuxwireless.org/en/users/Drivers/ath9k_htc/devices    for   similar 
devices built with the AR9271 or AR7010 chipset. 

Note: Many more adapters are supported by the compat­wireless driver package. I have only  
tried to get MY adapter working. It is possible this Howto describes 90% of what will need to  
get a similar adapter working. Please check if your adapter is listed on the compat­wireless  
home page, or go directly to their devices section : http://wireless.kernel.org/en/users/Devices

Terminal commands are displayed by yellow high-lighting. Please read the text carefully before
entering the terminal commands. If this document works entirely as intended, copy-pasting the
commands into your terminal SHOULD work.
Verify
Verify that your adapter is the actual adapter that this document is written for. 

However, if you have ensured yourself that your adapter is supported by the compat­wireless 
driver package you may ignore the 'exact' statement in the following command line results. 

Open a command line terminal and enter the following command, followed by an enter or 
return.

 lsusb <ENTER>

Does one of the lines in your result match exactly ID 0846:9030 NetGear, Inc.   ?
Then your adapter is exactly the adapter which made me write this manual !

Continue to next chapter: The download 
The Download

To continue the following packages need to be downloaded & installed.
1 Linux­headers
2 build­essential
3 compat­wireless­2.6.tar.bz2
4 Atheros Firmware

Please connect your computer to the Internet using a network­cable directly to your (wireless) 
router LAN port.   Other solutions may work also, just get it connected :­)

To download these two packages enter the following commands on the command line. Be 
prepared to type your administrator password.

sudo apt­get install linux­headers­$(uname ­r) <ENTER>
sudo apt­get install build­essential           <ENTER>
wget http://wireless.kernel.org/download/compat­wireless­2.6/compat­
wireless­2.6.tar.bz2<ENTER>

Open in your internet browser the following page:
http://git.kernel.org/?p=linux/kernel/git/dwmw2/linux­firmware.git;a=tree

Click on snapshot & store the 
archive into the same location as 
the compat­wireless archive.

For Your Information

Linux is sensitive to upper and lower­cases in filenames. It is important to follow filenames carefully. (Windows is  
not sensitive to filename upper/lower cases)
apt­get  is a program which allows you to install packages from the repository.  The parameter install instructs  
the following names are to be downloaded & installed . 
uname   provides information regarding your kernel version. It is important that the correct kernal version header  
files are downloaded for making kernel­modules / drivers.  
build­essential is a package needed for building packages. 
Untar & Change Directory & Script

The last two steps from previous chapter involved downloading compressed tape­archive files. 
These compressed tar archives (may) contain  many files and folders.  To extract these files 
and folders, the archive must be extracted. (Not meant cynical)

To extract the tar archive type the following command.  (in the same terminal window)

tar xf compat­wireless­2.6.tar.bz <ENTER>
tar xf linux­headers <TAB><ENTER>

TIP: Try to complete the filename after typing only the first characters of a filename by pressing the TAB key on  
your keyboard. This auto completes the filename, or gives suggestions from to choose from. This greatly  
improves typing efficiency.  Also it reduces the chance for typo's.

If the extract operation completed successfully, a new folder will be created with a name 
starting with compat­wireless.   Lets hop into that directory to start with some actual build­
preperation work.

Hop into the directory by typing
cd compat­wireless <TAB><ENTER>

Run a script which selects the correct device to create a driver for.
./scripts/driver­select ath9k_htc <ENTER>

Good! 
Next chapter will fix some details in the files in order to make the driver work.

TIP: In Linux certain programs & scripts can be started from the command line by typing a .  (period) in front of  
the filename or path. 
Fix & Compile

During my first attempts of installing this driver causes 'build­errors'. Upon invoking the make 
command, it threw errors.  I'm not familiar with  Linux source code, nor am I much of a 
Makefile knight. This is where I  asked a friend to help me.  Here is what is needed to make it 
work.  These problems occoured with version date  compat­wireless­2010­09­28.

The compat­wireless  driver availible today apears to be working without the need for fixing 
the Makefile!    However, if  you may run again into make file errors try to fix these by following 
the following steps.

Now go back to the terminal window and type:

 make <ENTER>  
 sudo make install <ENTER>

Note: make and the make install commands may take several minutes to complete.

!ONLY if you have compile errors try!
Open your favourite file browser (Dolphin in Kubuntu) and navigate to the compat­wireless folder.    Hop al the way down­to
 compat-wireless-2010-##-##/drivers/net/wireless/ath

## a number

Open the file Makefile  with a text­editor and modify it contents so it looks very similar to  the following text. Do not change 
the content of the line itself. Only remove the last line which may
look like ath­$(CONFIG_ATH_DEBUG) += debug.o
Also make sure the hw.o and key.o lines are included.   Also make sure the back­slashes are like displayed below:
 obj­$(CONFIG_ATH9K_HW)          += ath9k/
 obj­$(CONFIG_ATH_COMMON)        += ath.o
 ath­objs :=     main.o \
                 regd.o \
                 hw.o \
                 key.o

Almost there. Now the only two steps left is copying the Arthos chipset firmware file into the 
filesystem firmware directory.
 cd.. <ENTER> 
 cd linux­firmware <TAB><ENTER> 
 sudo cp ar9271.fw /lib/firmware
Modprobe & Finish 

Lets test if it works!  
Reboot the computer,  type the following command to test if the driver can be located & 
loaded.
 modinfo ath9k_htc <ENTER>

The command should result in something very similar to the following:


steven@w00tbox:~/wna1100-2/compat-wireless-2010-09-28$ modinfo ath9k_htc
filename: /lib/modules/2.6.32-25-
generic/updates/drivers/net/wireless/ath/ath9k/ath9k_htc.ko
firmware: ar9271.fw
firmware: ar7010_1_1.fw
firmware: ar7010.fw
description: Atheros driver 802.11n HTC based wireless devices
license: Dual BSD/GPL
author: Atheros Communications
srcversion: 5E6A049E358760E23568DC5
alias: usb:v083ApA704d*dc*dsc*dp*ic*isc*ip*
alias: usb:v04CAp4605d*dc*dsc*dp*ic*isc*ip*
alias: usb:v13D3p3328d*dc*dsc*dp*ic*isc*ip*
alias: usb:v13D3p3327d*dc*dsc*dp*ic*isc*ip*
alias: usb:v07D1p3A10d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0846p9018d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0846p9030d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0CF3p7015d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0CF3p7010d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0CF3p1006d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0CF3p9271d*dc*dsc*dp*ic*isc*ip*
depends: ath9k_hw,compat_firmware_class,mac80211,led-
class,ath9k_common,ath,cfg80211
vermagic: 2.6.32-25-generic SMP mod_unload modversions 586
parm:           debug:Debugging mask (uint)

Then type the following command to start using the driver! 
 sudo modprobe ath9k_htc <ENTER>
Hopefully everything went as expected.  You now should have wifi. 
The blue LED will light up.   You can verify your driver is loaded into the kernel by typing. Look 
for lines which show ath9k???. 
 lsmod <ENTER>

Or if you want to be lazy rather than tired:
 lsmod | grep ath <ENTER>

The lsmod pipe grep ath command should result in something very similar to the following:

lsmod | grep ath
ath9k_htc              39034  0 
ath9k_common            2551  1 ath9k_htc
ath9k_hw              281287  2 ath9k_htc,ath9k_common
ath                    12177  2 ath9k_htc,ath9k_hw
compat_firmware_class     6200  1 ath9k_htc
mac80211              236308  1 ath9k_htc
cfg80211              143580  3 ath9k_htc,ath,mac80211
led_class               2864  2 ath9k_htc,sd

For your information
 The vertical bar |  is called pipe. It relays the output from the left side to a program / command on the right side.  
In this example its the program grep received the output from the first command. Grep is a text­search feature  
which then shows only lines containing your specified string.
Revert / Undo your work

To get rid of the ath9k driver go back to the the compat­wireless driver directory.
Type the following commands to uninstall it.
sudo modprobe ­r ath9k_htc
sudo modprobe ­r ath9k_common
sudo modprobe ­r ath9k_hw
sudo modprobe ­r ath

Sudo make uninstall

Kind regards,

Steven4601

For feedback : storage.depot@gmail.com

You might also like