Differences between revisions 15 and 16
Revision 15 as of 2008-02-13 09:29:58
Size: 7031
Editor: PeMac
Comment:
Revision 16 as of 2008-02-13 09:38:17
Size: 7122
Editor: PeMac
Comment:
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
----
(!) [:/Talk:Talk]
Line 63: Line 65:
 * [http://packages.debian.org/ndiswrapper-utils ndiswrapper-utils] -Userspace utilities for ndiswrapper. You will also need the kernel module package.
Line 64: Line 67:
 * [http://packages.debian.org/ndiswrapper-utils ndiswrapper-utils] -Userspace utilities for ndiswrapper.
Line 148: Line 150:
  ----
CategoryHardware

["WiFi"]


(!) [:/Talk:Talk]


Some vendors do not release specifications of the hardware, and don't provide a linux driver for their wireless network cards. Ndiswrapper project provides a linux kernel module that loads and runs Windows kernel API and NDIS (Network Driver Interface Specification) API drivers supplied by the vendors within the Linux kernel. A Windows driver for wireless network card is then linked to this implementation so that the driver runs natively, as though it is in Windows, without binary emulation.

Ndiswrapper uses the Windows *.inf driver files that came with your hardware to operate your wireless card on Linux. Most likely you will need to uncompress a *.cab file which contains your drivers.

Packages

Make sure the following packages are installed:

  • ndiswrapper
  • ndiswrapper-kmp-[default|smp|xen]
  • wireless-tools

Choose the proper kernel module package (kmp) for your architecture. Most people will just need to use "ndiswrapper-kmp-default".

Source package

If you compiled a ["custom kernel"], you will most likely need to compile a custom version of this module as well. The ndiswrapper-source package has been provided for this purpose.

Download the source package and compile it.

To download and install ndiswrapper tools and modules with debian ( provided you have the standard debian kernel )

  • apt-get install module-assistant  ndiswrapper-utils ndiswrapper-source 
    m-a prepare
    m-a update
    module-assistant auto-install ndiswrapper

You find more instruction in /usr/share/doc/ndiswrapper*/README*

Assuming you have downloaded the Windows driver in ~/Desktop/Downloads/V11.1.1.0_XP_DRIVERS.ZIP :

  • $mkdir /usr/local/i4965/ 
    $cd /usr/local/i4965/
    $unzip -q ~/Desktop/Downloads/V11.1.1.0_XP_DRIVERS.ZIP
    $ndiswrapper -i /usr/local/i4965/NETw4x32.INF

Let's make sure it's configured :

  • $ndiswrapper -l
    installed drivers:
    netw4x32                driver installed, hardware (8086:4233) present

Then add ndiswrapper in /etc/modules

  • # added ndiswrapper to load XXXXX Network driver.
    ndiswrapper 

You can either reboot you system to get the module loaded... or simply run modprobe ndiswrapper this time ;).

This should be it.

Binary packages (.deb)

Installing the drivers

ToDo: Merge with instructions above.

The drivers you find may be packaged as an executable file. In the List of cards above, there may be more there. Some of the EXE files are just ["zip"] files, so you can run ["unzip"] and obtain driver files. Some EXE files are CAB files, so run cabextract and/or unshield on CAB file, typically named data2.cab

Open up a ["terminal"] window, execute ["su"] command and type:

  • ndiswrapper -i /path/to/drivers/*.inf

You might refer directly to any windows owned folder. If the way to this folder (the pathname) contains white spaces, e.g. "Program Files", it is recommended first to move with ["cd"] to the folder containing the required *.inf file:

  • cd '/windows/where the inf file is'
    ndiswrapper -i this_and_that.inf   

If all goes well, type:

  • ndiswrapper -l

If you did it right it will display something like this:

  • Installed ndis drivers:
    <driver name> driver present, hardware present

If it says "invalid driver" then you need to uninstall that driver and try another one.

To uninstall a driver, you need to type:

  • ndiswrapper -e <then the name of the driver to uninstall>

An additional check can be to look at

  • /etc/ndiswrapper 

if a directory named as the installed driver is there available.

==Configure interface==

Use ["iwconfig"] to configure wireless network interface.

Configure on insert / Hotplug

According to a DebianEtch entry on the ndiswrapper wiki, an 'allow-hotplug wlan0' entry in /etc/network/interfaces is about all it takes to get the card to be automatically configured and brought up when inserted (beyond the required steps to configure the card for manually bringing the interface up.)

http://ndiswrapper.sourceforge.net/mediawiki/index.php/InstallDebianEtch

On Sarge this does not appear to be the case. Adding that line does not make hotplug 'just work'. This is most likely due to the lack of an entry for ndiswrapper in /lib/modules/<kernel version>/modules.pcimap. According to the hotplug overview when new hardware is detected the MODULE_DEVICE_TABLE map is consulted to determine which module is responsible for the device. Without that entry or some other help hotplug will not 'just work' for the device.

The easiest workaround is to require the ndiswrapper module at boot so that it is always loaded and ready to claim the hardware. Just add it to the list in /etc/modules.

The most difficult workaround (for many) may be to edit the ndiswrapper source and recompile so that it will make MODULE_DEVICE_TABLE entries for your hardware.

http://www.linuxquestions.org/questions/showthread.php?t=360483 http://sourceforge.net/mailarchive/message.php?msg_id=6713442

An inbetween workaround may be to modifiy /etc/hotplug/pci.agent to parse an /etc/hotplug/pci.handmap and have it include the hardware details necessary to load ndiswrapper when your card is inserted, like you can do with usb.handmap. This step and the re-coding are probably best left to the developers which leaves us with /etc/modules.

There seems to be a couple different ways documented to enable hotplugging on interfaces (once hotplugging is working for ndiswrapper). Mentioned in the DebianEtch page on the ndiswrapper wiki is the line allow-hotplug wlan0. The man page for the interfaces file confirms that this is the intended way to enable hotplug. In /etc/hotplug/net.agent, you are directed to include mapping hotplug stanzas in /etc/network/interfaces.

On a Debian 3.1 / Dell Inspiron 1200 system the allow-hotplug entry did not seem to be necessary. The map stanza seemed to be enough, once ndiswrapper was already loaded. YMMV.

Cab

You can try unpacking *.cab files with any of the following:

  • cabextract - a program to extract Microsoft Cabinet files

  • unshield - extracts CAB files from ?InstallShield installers (If it doesn't succeed, you might want to try using i5comp or i6comp under Windows. search it in google)


CategoryHardware