In the forum and elsewhere, we have seen people asking for CoovaChilli for their Ubiquiti routers. Of course, one easy way to use CoovaChilli is to be using the open-mesh / ROBIN firmware. Another way is to build CoovaChilli right into the Ubiquiti firmware using the Ubiquiti AirOS SDK.
Jan 16 2010: Updated for CoovaChilli 1.2.1 (rev 281)
The Ubiquiti AirOS SDK lets you make changes to the standard Ubiquiti firmware. Here is how to add CoovaChilli and the embedded captive portal. Follow the directions from Ubiquiti on how to setup the SDK on Ubuntu.
In this example, we will be building and installing the latest CoovaChilli from subversion. We have been busy with CoovaChilli, wanted to get those changes in, and also we added some files to make it easier to build in AirOS SDK.
Before proceeding, be sure you are familiar with how to upgrade the Ubiquiti router firmware and the firmware recovery procedure.
Once you have the necessary toolchain installed and have downloaded the SDK, go into the SDK directory (we are using version SDK.UBNT.v3.5.4499).
cd /path/to/SDK.UBNT.v3.5.4499/Install the necessary source code and build files. In this case, we link to an existing CoovaChilli source directory (see here) and we download haserl for the embedded miniportal.
cd apps/gpl ln -s /path/to/svn/coova-chilli coova-chilli ln -s coova-chilli/distro/ubnt/coova-chilli.mk . ln -s coova-chilli/distro/ubnt/haserl.mk . wget http://downloads.sourceforge.net/project/haserl/haserl-devel/0.9.26/haserl-0.9.26.tar.gz tar xzf haserl-0.9.26.tar.gz mv haserl-0.9.26 haserl cd -
Now, we configure the xs2 target with CoovaChilli by apply the patch:
patch -p1 < apps/gpl/coova-chilli/distro/ubnt/xs2.patchThe above patch will do several things, including:
To patch the Ubiquiti web interface for simple CoovaChilli configurations, apply the patch:
patch -p1 < apps/gpl/coova-chilli/distro/ubnt/apps.web.patch
Build the new firmware:
PATH=$PATH:. make clean xs2If everything goes well, you should have the binary firmware, as shown here:
$ ls rootfs/XS2.ar2316.v3.5.latest/XS*.bin rootfs/XS2.ar2316.v3.5.latest/XS2.ar2316.v3.5.SDK.100122.0850-8M.bin rootfs/XS2.ar2316.v3.5.latest/XS2.ar2316.v3.5.SDK.100122.0850.binIn our example we are using a Bullet2, so we used the XS2.ar2316.v3.5.SDK.100122.0850.bin file.
Install the firmware under the System tab:

Click on Upgrade to have a file selection window appear. Find and select the AirOS firmware .bin file. Proceed to upgrade your router, being CAREFUL NOT TO UNPLUG YOUR ROUTER OR DISTURB THE UPGRADE IN ANY WAY. When done, will will find new options under the Services tab.
Basic required configurations:
To demonstrate the CoovaChilli settings, we have configured our router to be use with CoovaNET. In our CoovaNET account, under the Account tab on the My network page we find the information we need. Essentially, you need to know the RADIUS server, RADIUS shared secret, RADIUS Administrator-User username and password, and the UAM Server URL.

Once your settings are entered, save the changes. You will see that when the Hotspot is configured to be active, the configuration page changes a bit to show a rudimentary status page.

To go back to the Hotspot settings, click on Setup and they will re-appear. You can toggle back and forth to the configuration settings, start and stop the service, and see the basic status information from this page.

Need to restore your firmware? You can get an original firmware here: http://www.ubnt.com/support/downloads.php
Need to recover the hard way? Follow the Firmware Recovery directions. You might also find CoovaFlash (shown below) from the CoovaFX Firefox plug-in (shown in browser above) to help with the TFTP flashing. Note: Only TFTP an original firmware, even though we show otherwise in the screen shot.

We hope this helps you to get up and running with CoovaChilli on your Ubiquiti gear!