Stuff I'm Working On

September 13, 2011

Enabling Wifi AP Mode on a Gumstix Overo

Filed under: gumstix — Tags: , , , , — corysohrakoff @ 11:38

This guide demonstrates how to enable Wifi AP mode for a Gumstix Overo, running Linux Kerenel 3.0.3 and Ubuntu 10.04. Setting up AP mode has very little documentation, so I hope this helps to bridge the gap.

Get the required files

  1. Download the latest thin-firmware from
  2. Rename the file sd8686tf.bin
  3. Get the required helper firmware from Marvell (SD-8686-LINUX26-SYSKT-9.70.3.p24-26409.P45-GPL)
  4. Extract the downloaded zip file, then extract SD-8686-FEDORA26FC6-SYSKT-GPL-9.70.3.p24-26409.P45.tar within it. Navigate to the FwImage directory.
  5. Inside FwImage there is helper_sd.bin. Rename helper_sd.bin to sd8686_helper.bin and save it for later.
  6. Get the libertas_tf_sdio driver.
  7. Download the latest version of hostapd from: (Dependencies: libssl-dev, libnl-dev)

Driver set-up

To get the Libertas SDIO thin-firmware driver working, you need to build the modules for your kernel. If you’re using a script to build your kernel see the note below first.

Copy the directory libertas_tf in drivers/net/wireless/ from the driver source tree into your own kernel source tree. You must patch the file drivers/net/wireless/Kconfig to include the following after the “config LIBERTAS_THINFIRM_USB” section.

 tristate "Marvell Libertas 8686 SDIO 802.11b/g cards with thin firmware"
 A driver for Marvell Libertas 8686 SDIO devices and those that include
 the 88W8686 core, such as the Wi2Wi devices. Special SDIO specific
 firmware is required to use this driver, see the OLPC site for details:


Prepare to build the kernel with the new modules. In menuconfig navigate to: Device Drivers—>Network device support—>Wireless LAN.

Select the following to build as modules.

  • Marvell 8xxx Libertas WLAN driver support with thin firmware
  • Marvell Libertas 8686 SDIO 802.11b/g cards with thin firmware

You should also ensure that Networking support—>Wireless—>Generic IEEE 802.11 Networking Stack (mac80211) is selected. I also took out the regular Marvell Libertas driver since I didn’t need its functionality. You may want to do the same.

NOTE: If you’re using a script to build your kernel, make sure it doesn’t replace the files you added to the source tree.

If you’re using this guide to build your kernel/filesystem. You will need to perform the following steps to get it working.

In comment out a few lines near the bottom of the file.


Run to do the basic set-up for you. Afterwards, change the file in the same place to look like:


Perform the driver set-up steps above and then run build_kernel again. This will build the kernel. Next, in comment out a few lines near the bottom of the file.


Finally, run

Firmware set-up

The thin-firmware and firmare helper must be placed in the /lib/firmware/ directory on the filesystem. Simply copy sd8686tf.bin and sd8686_helper.bin to /lib/firmware/ on the Gumstix filesystem.

hostapd set-up

The wireless interface cannot be manually set into AP mode, thus the hostapd software must be used. This involves natively compiling hostapd on the Gumstix Overo, so gcc and related tools are required to be installed. Cross-compilation has not been tested.

Copy the hostapd tarball to a suitable location on your Gumstix, extract it and navigate to the directory. Next, create the .config file.

$ cd hostapd
$ cp defconfig .config

Edit the file by by uncommenting the line “#CONFIG_DRIVER_NL80211=y”, i.e. removing the #. Then, build the program and then install it (as root).

$ make
# make install

Next you’ll want to set-up a configuration file for hostapd. In the directory that you just compiled hostapd, there is a sample hostapd.conf file you can use. Alternatively, here is a link to a basic hostapd.conf file that will get the wireless up and running with no encryption and the SSID set to “gumstix”. You can learn more about configuration here.

Put the .conf file somewhere that makes sense, i.e. /etc/hostapd.conf.


You probably want your wireless card to be put into AP mode when the Gumstix boots. Below is an example of how to do that. (This is not the only way to do this.)

Create/edit the file /etc/network/interfaces to look like below. The wireless part is what is important so if you have some custom configuration already done in this file just edit/copy the wireless part (wlan0).

# /etc/network/interfaces
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

auto wlan0
iface wlan0 inet static
post-up /usr/local/bin/hostapd -B /etc/hostapd.conf

The example also assigns a static IP address to the wireless card. If you don’t do this, the network won’t work. Wireless clients also must have static IP addresses assigned unless you run a DHCP server on the Gumstix to automatically assign clients IP addresses. In Ubuntu the package dhcp3-server will provide that functionality. Here is an example .conf file for a dhcp3 server.

# /etc/dhcp3/dhcpd.conf
default-lease-time 600;
max-lease-time 7200;
option subnet-mask;
option broadcast-address;
option routers;

subnet netmask {

With all this work done, your Gumstix should now be able to act as a Wifi access point!

Create a free website or blog at