
Autore: debtown
Ho dovuto fare il lavoro per un cliente, installare e configurare una Wireless-lan DWL122 USB.
E la prima volta che uso un vecchio "prism-2.5" chip.
Realizzato con debian sarge, vailla-kernel-2.6.14.4
La configurazione usa hotplug.
Se usate un kernel vanilla guardate mettete questo: "CONFIG_NET_RADIO=y".
Scaricate linux-wlan-ng
$ wget ftp://ftp.linux-wlan.org/pub/linux-wlan-ng/linux-wlan-ng-0.2.3.tar.gz
$ tar xvzf linux-wlan-ng-0.2.3.tar.gz
$ cd /path/linux-wlan-ng-0.2.3
$ ./Configure (andate avanti come vedete sotto)
-------------- Linux WLAN Configuration Script -------------
The default responses are correct for most users.
Build Prism2.x PCMCIA Card Services (_cs) driver? (y/n) [y]: n
Build Prism2 PLX9052 based PCI (_plx) adapter driver? (y/n) [n]:
Build Prism2.5 native PCI (_pci) driver? (y/n) [n]:
Build Prism2.5 USB (_usb) driver? (y/n) [n]: y
Linux source directory [/lib/modules/2.6.14.4/build]:
The kernel source tree is version 2.6.14.4.
Kernel 2.5/2.6 support is highly experimental.
The current kernel build date is PREEMPT Thu Dec 15 19:12:15 2005.
Alternate target install root directory on host []:
Module install directory [/lib/modules/2.6.14.4]:
It looks like you have a System V init file setup.
Prefix for build host compiler? (rarely needed) []:
Build for debugging (see doc/config.debug) (y/n) [n]:
Configuration successful. Now type 'make' and pray.
-------------- Linux WLAN Configuration Script -------------
$ make
$ make install (checkinstall > dpkg -i linux-wlan-ng_0.2.3-1_i386.deb)
Ok! Il driver è installato.
In /etc/wlan trovate il file per la configurazione, ma questo ignoriamolo in quanto faremo partire il tutto via hotplug.
Ora configuriamo la rete wireless-lan per hotplug,etc...
Create una usermap per hotplug:
$ touch /etc/hotplug/usb/wlan.usermap
$ nano /etc/hotplug/usb/wlan.usermap
ed editatelo così:
wlan 0x0003 0x2001 0x3700 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
A chi interessa "wlan" e lo script che deve partire quando viene riconosciuto l'hardware:
"(0x2001) e la VendorID", (0x3700) e la ProductId" etc... questo lo trovate con usbview.
Ora ci serve lo script per la configurazione dell'USB Wlan-Stick. (/etc/hotplug/usb/wlan)
#--------------------------------------------------------------------------------------
#!/bin/sh
wlanctl-ng wlan0 lnxreq_ifstate ifstate=enable
wlanctl-ng wlan0 lnxreq_autojoin ssid=
#WEP Configuration (optional)
# Default-Key
wlanctl-ng wlan0 dot11req_mibset mibattribute=dot11WEPDefaultKeyID=0
# Non Cryptata
#wlanctl-ng wlan0 dot11req_mibset mibattribute=dot11ExcludeUnencrypted=true
# WEP attivare
wlanctl-ng wlan0 dot11req_mibset mibattribute=dot11PrivacyInvoked=true
# WEP-Key (qui esempio WEP128)
wlanctl-ng wlan0 dot11req_mibset mibattribute=dot11WEPDefaultKey0=00:01:02:03:04:05:06:07:08:09:0a:0b:0c
ifconfig wlan0
route add default gw
#--------------------------------------------------------------------------------------
$ chmod +x /etc/hotplug/usb/wlan
ok, riavviate il vostro "hotplug-subsystem", attacate lo USB-Wlan Stick, controllate con "iwconfig".
- that's it, dead simple. ;-)






