XO as AP: Difference between revisions

From OLPC
Jump to navigation Jump to search
Line 14: Line 14:
</pre>
</pre>


The latest tested version is b717ee2ab25c but more recent versions should work too.
The latest tested version is c5f5c91aeb3be but more recent versions should work too.


To compile it, go to the directory <tt>hostapd</tt>, copy <tt>defconfig</tt> to <tt>.config</tt>. On <tt>.config</tt>:
To compile it, go to the directory <tt>hostapd</tt>, copy <tt>defconfig</tt> to <tt>.config</tt>. On <tt>.config</tt>:

Revision as of 20:07, 5 June 2008

This documents describes how to set up the XO as an access point using the built-in wireless card.

Setting up the Thinfirm driver / firmware

The access point functionality only works with the libertastf driver, which is not the one bundled in the official builds. To set up this driver follow the instructions at Libertas Thinfirmware HOWTO.

Getting and compiling Hostapd

Hostapd requires a more recent version of libnl than the one included in the OLPC builds. An up to date libnl rpm can be downloaded here. (If you compile hostapd on a different host, you may also have to upgrade libnl there)

Download hostapd;

git-clone  git://w1.fi/srv/git/hostap.git

The latest tested version is c5f5c91aeb3be but more recent versions should work too.

To compile it, go to the directory hostapd, copy defconfig to .config. On .config:

  1. Uncomment CONFIG_DRIVER_NL80211=y.
  2. To make hostapd use the headers from a kernel different that the one running in you machine, at the end add the lines:
CONFIG_KERNEL_LOC = /path/to/your/kernel-tree
CFLAGS += -I$(CONFIG_KERNEL_LOC)/include

Then compile with make and copy hostapd and hostapd_cli to the target XO.

If hostapd was not compiledy in a fedora system, it may complain when executing about not finding the library /lib/libssl.so.0.9.8. If that is the case, you can easily fix it doing, on the target XO:

# cd /lib
# ln -s /lib/libssl.so.0.9.8b /lib/libssl.so.0.9.8
# ln -s /lib/libcrypto.so.0.9.8b /lib/libcrypto.so.0.9.8

Start hostapd

Copy a hostapd configuration file (example) and customize it. The most relevant fields are ssid and channel. Then start the access point with:

# hostapd -d hostapd.conf

Then other machines will be able to associate to the new created access point. A same-subnet IP address must be assigned to each machine, either manually, via dhcp or link-local, to make them able to connect to each other.