Most of this manual, or similar, can be found from multiple differen web sites. This manual is a collection of procedures that worked for me. REMEMBER! do this on your own risk, because this can result into a bricked box.
The box itself is interesting, because it contains Atheros wireless and you can get it very cheaply or even for free. Check out La Fonera site.
You need to have the OpenWRT 7.09 kamikaze binaries (openwrt-atheros-2.6-vmlinux.lzma, openwrt-atheros-2.6-root.squashfs) and at least fping and tftpd packages installed on your machine. On the hardware side you will probably need an extra router.
If you have a La Fonera box that says to be version 0.7.2.r3. In that version all (?) of the bugs, used to get the box SSH enabled, were fixed. Luckily there is a work around. For the work around you need extra router that you can use to fool the box.
The basic idea in this work around is to set the extra router LAN IP to 126.96.36.199 and the mask to 255.255.255.0 and its DNS settings to static and both primary and secondary DNS addresses to address 188.8.131.52. Now connect the La Fon to the switch of the extra router. Remeber keep the WAN cable of the extra router at this point.
Now connect to the La Fons wireless access point. The La Fon box should be visible with ESSIDs LaFon (or something alike) and MyPlace. Connect to the MyPlace ESSID. When connection to the AP the WAP passphrace is the serial number on the bottom of the device. Access the La Fons web interface and go to the advanced menu and under it internet connection. In this menu you will have a change to select IP settings. If the box is new and nothing is changed the username/passwd for the advanced menu should be admin/admin. Now set the node to have a static IP 184.108.40.206 mask 255.255.255.0 and set the gateway to 220.127.116.11 and the DNS to the same address as the gateway. Now press submit on the page and the should down grade to older version. For me it was 0.7.0.r4. Now you can create the following file on your machine and open it in your browser.
After pressing the submit button on the page. The La Fon web interface complaining about invalid username. The consequence should be that you can open an ssh connection to the box with command "ssh email@example.com" with the root password admin. Below is the output from the Box.
Next you want to get the devices redboot enabled. The idea is to get couple of files and write the files to the flash with mtd. Below are the commands and their outputs. Remember to put the WAN cable back to the extra router (do not wait too long before the next steps because the fon box may try to upgrade).
Now the box should boot to redboot only and listening to telnet on port 9000. Connect your machine directly to the La Fons WAN port and setup your machines IP address to 192.168.1.161/24 and add the default route to the interface ("sudo ip addr add 192.168.1.161/24 dev eth0" and "sudo route add default dev eth0", it may be easier if you kill the NetworkManager process so it does not try to mess with the addresses). You can use the following script to connect to the box. This script is just a helper and it can be done manually. If this is an install to a "virgin" box just telnetting to the address 192.168.1.254 and port 9000 is enough. After the installation, if the fconfigs boot option is set to true you will have from 4 to 10 seconds to connect to the redboot before it starts loads and execs the linux partition.
Next you will have to have tftpd server running on your machine. Make /tftpboot directory on your machine and modify the /etc/inetd.conf to contain the following line (note the /tftpboot in the end, default is /srv/tftp, but usually the root is tftpboot).
Set the rights of the folder to 777 (sudo chmod 777 /tftpboot) and its owner to nobody (sudo chown nobody /tftpboot). Copy the OpenWRT files to the /tftpboot and chmod them to 777 and chown them to nobody. After this restart or start inetd service so it reads the new config.
Now to the interesting part, the rewriting of the flash. First telnet to the La Fon connected directly to your machine. Then setup the tftp on the La Fon. NOTE! that some of the commands can take even 20 minutes so no hurry.
After this you need to get the kernel, initialize the flash and create a partition for it. Below is the commands and the outputs on the Fon box. In the "fis create" do not change the memory addresses because otherwise the kernel won't be loaded.
After this you have to check the free space available
After this extract the first from the later.
Now load the root filesystem to the box and create the partition for it. In the "fis create" REMEMBER to add the extra 00 to the start of the length of the free space.
Now the flash layout should look something like this (this output is taken from box containing a modded version of OpenWRT so the lengths may vary a bit).
The boot configuration should look something like this.
Now power cycle the box and try to telnet to 192.168.1.1 port 23 and you should get into the Fon box.
If you got this far and everything is OK. From here it is just configuring the OpenWRT, like setting up the wireless and so on.
All of these manuals/tutorials are provided as is. They worked for me and that is all the help I give with them, so if I forgot something or there is a typo you can inform me but do not expect me to solve your problems :) Oh and almost forgot, use them at your own risk.