Perl programmer for hire: download my resume (PDF).
John Bokma MexIT
freelance Perl programmer

Compiling and installing NDISwrapper on the Acer Aspire 4320

Saturday, December 29, 2007 | 8 comments

After I had downloaded the Windows driver and removed madwifi I installed NDISwrapper with a Windows driver that supported the Wi-Fi hardware in my Acer Aspire 4320. Because I was afraid that the version that came on the Ubuntu 7.10 Gutsy Gibbon CD was too old, I decided to compile the latest version of NDISwrapper myself.

Downloading NDISwrapper

I downloaded the source of NDISwrapper via the ndiswrapper page at SourceForge.net. Next I copied the file, named ndiswrapper-1.51.tar.gz (198330 bytes) into the ndis directory I had made in my home directory when I downloaded the AR5006EG Windows driver.

The md5sum of the file I dowloaded is as follows:

john@throy:~/ndis$ md5sum ndiswrapper-1.51.tar.gz 
ba8f8cf43e7e05427a0c221a284a516c  ndiswrapper-1.51.tar.gz

Next I unpacked the tarball, and changed to the newly created directory:

john@throy:~/ndis$ tar zxvf ndiswrapper-1.51.tar.gz 
john@throy:~/ndis$ cd ndiswrapper-1.51/

Compiling NDISwrapper

In order to be able to build ndiswrapper I first had to install the build essential package:

sudo apt-get install build-essential

When I executed this command I had to insert the Ubuntu installation CD I burned a week ago:

Media change: please insert the disc labeled
 'Ubuntu 7.10 _Gutsy Gibbon_ - Release i386 (20071016)'
in the drive '/cdrom/' and press enter

Don't forget to remove the installation CD afterwards.

Next I used make uninstall. Somehow, even thought hadn't installed ndiswrapper some related files were available on my system:

john@throy:~/ndis/ndiswrapper-1.51$ sudo make uninstall

This removed the following file:

/lib/modules/2.6.22-14-generic/ubuntu/misc/ndiswrapper/ndiswrapper.ko

I followed the advice reported by this command: "Run uninstall as many times as necessary until no "removing" messages appear below.". When I ran the make uninstall one more time, no more "removing" messages showed up.

Next I did a make, which ran successful, followed by a make install, also successful:

make
sudo make install

Installing NDISwrapper

After the succesful compilation of NDISwrapper I changed to the directory holding the Windows driver for the Atheros AR5006EG, and installed the driver. Note that you have to give the inf file as a parameter to ndiswrapper -i:

cd ../Atheros/
sudo ndiswrapper -i net5211.inf

This gave the following result:

installing net5211 ...
forcing parameter MapRegisters from 256 to 64
forcing parameter MapRegisters from 256 to 64
:
:
forcing parameter MapRegisters from 256 to 64
				

The 177 lines of "forcing parameter MapRegisters from 256 to 64" worried me a bit, but it was unnecessary.

When I listed the installed drivers with ndiswrapper -l I got:

john@throy:~/ndis/Atheros$ ndiswrapper -l
net5211 : driver installed
        device (168C:001C) present (alternate driver: ath_pci)

Before I added the ndiswrapper module to the kernel, I first checked again the wireless network, and as expected:

john@throy:~/ndis/Atheros$ iwconfig
lo        no wireless extensions.

eth0      no wireless extensions.

Then I added the ndiswrapper module to the kernel as follows:

sudo modprobe ndiswrapper

When I did another iwconfig I did get the result I wanted:

john@throy:~/ndis/Atheros$ iwconfig
lo        no wireless extensions.

eth0      no wireless extensions.

wlan0     IEEE 802.11g  ESSID:off/any  
          Mode:Managed  Frequency:2.412 GHz  Access Point: Not-Associated   
          Bit Rate:54 Mb/s   
          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

Moreover, my own wireless router, a Linksys WRT54GL, was now visible in the list of wireless networks provided by the network applet on the desktop.

List of available wireless networks.
List of available wireless networks.

Next, I used the -m option of ndiswrapper to write the configuration for modprobe:

john@throy:~/ndis/Atheros$ sudo ndiswrapper -m

Note that this, at least on my Ubuntu system, doesn't make the ndiswrapper module to be automatically loaded after a reboot (or power on). I had to open /etc/modules:

sudo gedit /etc/modules

and to add the following line to the end of the file:

ndiswrapper

If you're using a Linksys router you might want to read My Linksys WRT54GL and Ubuntu wireless settings.

Was this useful to you?

If you could make your wireless network work by following these instructions, but on a different notebook, please post a comment. A comment to just thank me is also very welcome, it took quite some time to compile this information into something readable.

NDISwrapper related

Also today

Please post a comment | read 8 comments, latest by Frank Bernhardt | RSS feed