Template:FAQ/Questions/USB-wifi-dongle

How do I get a gumstix to talk through a USB wifi dongle to a wireless network?
With this setup:

verdex motherboard <-> breakout-vx or console-vx expansion board <-> USB gender switcher <-> USB wifi module

(The connex and basix motherboards cannot be a USB host, so they cannot use a USB wifi module peripheral. To get them to talk to a wireless network, use one of the wifi expansions boards).

Once the gumstix boots:


 * 1) lsmod
 * 2) modprobe ohci-hcd

Your wifi module should now be detected, and if you had done a depmod -a after adding its module, it should have its module loaded automatically by udev. You can then add an interface definition in the file

/etc/network/interfaces

by copying and modifying one of the existing definitions for your wifi dongle. You can then issue the command

ifup rausb0

replacing "rausb0" with whatever your wifi dongle's interface name is.

More detailed instructions found on the mailing list, works for D-Link with the rt2570 driver:

First, I had to add the following line to /etc/modprobe.conf :

alias rausb0 rt2570

Next, I added this to /etc/network/interfaces :

auto rausb0 iface rausb0 inet dhcp
 * 1)       pre-up /sbin/iwconfig rausb0 essid
 * 2)       pre-up /sbin/iwconfig rausb0 enc

I think the last two lines are commented out, but I'm not 100% sure how that works in this file.

Finally, I created a file in /etc/init.d called 'S45wireless' (which is really just a copy of one of the other files, with mods in the start function):

# # start { echo "Starting wifi..." modprobe ohci-hcd mount -t usbfs none /proc/bus/usb;lsusb -v ifconfig rausb0 up       ifup rausb0 iwconfig rausb0 essid iwconfig rausb0 enc } stop { echo -n "Stopping wifi..." } restart { stop start } case "$1" in               start)        start        ;;  stop) stop ;; restart|reload)        restart        ;;  *) echo $"Usage: $0 {start|stop|restart}" exit 1 esac exit $?
 * 1) !/bin/sh
 * 1) Start the wifi....

You have to have the wifi dongle plugged in when you reboot the verdex in order for this to work.

Posted by Jon Hylands

note on /etc/modprobe.conf

aliases in here just allow you to modprobe from either name not much more Its ussually unneeded. to acctually get the device to use a different name you would have to pass an argument to the driver.

Posted in mailing list by Jeff Sadowski