Saturday, 28 July 2012

using an Edimax wifi stick (EW-7317LDg) with the raspberry pi

i decided to try and get an old usb wifi stick working on my raspi. it draws too much power to plug directly into the pi; i am using a Belkin 4 port powered USB hub.

upon plugging in i got the following message appearing frequently in dmesg
[ 3702.766311] usb 1-1.2.4: Could not load firmware file zd1211/zd1211b_ub. Error number -2
[ 3702.766362] zd1211rw 1-1.2.4:1.0: couldn't load firmware. Error number -2
to suppress the messages for the time being i issued in a terminal
sudo rmmod zd1211rw
a quick search of the apt cache reveals just the ticket
pi@raspberrypi ~ $ sudo apt-cache search zd1211
zd1211-firmware - Firmware images for the zd1211rw wireless driver
so to install the firmware
sudo apt-get install zd1211-firmware
then issue
sudo modprobe zd1211rw
then check the message log
[  759.572694] usb 1-1.2.4: reset high speed USB device number 6 using dwc_otg
[  759.677485] ieee80211 phy2: Selected rate control algorithm 'minstrel_ht'
[  759.683501] zd1211rw 1-1.2.4:1.0: phy2
[  759.683764] usbcore: registered new interface driver zd1211rw
[  759.996976] usb 1-1.2.4: firmware version 0x4810 and device bootcode version 0x4802 differ
[  760.151815] zd1211rw 1-1.2.4:1.0: firmware version 4725
[  760.191834] zd1211rw 1-1.2.4:1.0: zd1211b chip 0ace:1215 v4802 high 00-0e-2e AL2230_RF pa0 ---NS
now we have to set up the wireless network....
sudo nano /etc/wpa.config
enter the following, replacing ssid and passphrase with the appropriate details
pairwise=CCMP TKIP
save and exit, then
sudo nano /etc/network/interfaces
add the following
auto wlan0
iface wlan0 inet dhcp
wpa-conf /etc/wpa.config
save and exit. now we can restart the network:
sudo /etc/init.d/networking restart
and with a bit of luck it will come back up using the usb stick rather than eth0.

No comments:

Post a Comment