One of my new year’s resolutions is com …

One of my new year’s resolutions is complete: contribute code to an open source project! It was just a simple rewrite of a function and some cleanup in a Python script of a dice game for the Freerunner. It’s available here:

Couple of notes. (1) It’s fun tweaking code that’s already been written: I don’t have the stamina to put down all the boilerplate, but once it’s there, aha! I can learn from it. (2) Mixing tabs and spaces in Python code is annoying. (3) The guys on the mailing list are really nice and give lots of feedback. It’s great fun!

warmer… warmer… iced

In short, I had some fun following the wiki and configuring the Freerunner, getting my first taste of installing applications from opkg. Something broke when I tried installing a browser from Angstrom repository, and now the phone doesn’t boot. The problem now is to re-flash and retry a little more carefully. Another problem I have is with working with wifi. I seem to have it configured with wpasupplicant, but I can’t seem to connect anywhere after I remove the USB cable. Also, I will work from my Gentoo partition because it’s way easier setting up and tearing down the USB connections with the Freerunner.

That sums the day up. Below are my notes for the day.

opkg update gives errors from missing signature files, but update is otherwise successful.

I ran nohup opkg upgrade dropbear & first of all, which ran without a hitch.

opkg upgrade runs smoothly, stopping in between to prompt for replacing some configuration files. It took about 15 minutes, I think. In the process, I got an Enlightenment Error pop up on the screen of my Freerunner. Maybe a reboot will set things in order.

Towards the end of the process, the Xserver automatically restarts itself. This seems to work without a hitch as the home screen comes up. Then the screen blanks and I’m still waiting for a response from the terminal. Did it shut down on me?

It won’t answer any pings. Seems it shut down. Hopefully an interrupted upgrade doesn’t mess things up.

Actually, it just went into suspend: the upgrade replaced my settings and set it back to suspend after 30 seconds. I set it back, hope it doesn’t suspend any more.

Suspend is pretty annoying as it breaks the fragile USB network configuration on OS X. Any attempt to reconnect gives null ethernet interfaces under System Preferences > Network. I have to restart.

A little fed up with OS X so now interfacing with a Gentoo Linux host. Now compiling modules to enable USB networking (

Modules all loaded. I had to manually use modprobe to load the modules and then add them to /etc/modules.autoload.d/kernel-2.6 to be autoloaded during the boot. Is there an easy way to do this?

Noticed the boot time for the Freerunner is drastically improved. By the time I have X up in Gentoo, the Freerunner is up and ready to go.

Upon plugging the Freerunner to my Macbook, I get this reaction from dmesg | tail:

usb 3-1: new full speed USB device using uhci_hcd and address 2
usb 3-1: configuration #1 chosen from 2 choices
usb0: register 'cdc_ether' at usb-0000:00:1d.1-1, CDC Ethernet Device, 32:cd:62:9e:4c:6e
usb 3-1: New USB device found, idVendor=1457, idProduct=5122
usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 3-1: Product: RNDIS/Ethernet Gadget
usb 3-1: Manufacturer: Linux 2.6.24/s3c2410_udc

Brought up the interface with

sudo ifconfig usb0 netmask

Pinging the interface works. ssh into the phone works. We’re in business!

Apparently masquerading requires additional configuration via iptables.

iptables -I INPUT 1 -s -j ACCEPT
iptables -I OUTPUT 1 -s -j ACCEPT
iptables -A POSTROUTING -t nat -j MASQUERADE -s
echo 1 > /proc/sys/net/ipv4/ip_forward

The last directive to iptables handles masquerading. The last line signals the kernel to begin forwarding. (

Added the automatic configuration on the wiki and un/plugging the Freerunner works very smoothly.

Trying instructions here to install a full keyboard: Well not really – just got the name of the package and found that it was in the OM repository. I did a regular install from there.

It works. Now how about a terminal? openmoko-terminal2

There’s this Angstrom repository with extra apps including mplayer and openmoko-browser2. ( Installing the browser now, which pulls in a ton of components. Do I have enough space?

I thought I nuked my phone when I disconnected the USB cable and simultaneously hit the power button, putting it into suspend. For some reason, it wouldn’t come out of suspend. I had to take out the battery and put it back. Upon reboot, the hardware clock was reset. Otherwise, everything looks intact.

After installing openmoko-browser2, I suddenly get application execution errors for pretty much all the apps. After restarting the phone, the phone doesn’t finish booting. I’m wondering if it’s because of something caused by the failed suspend, or the fact that I plugged into the Angstrom repository. The instructions on the wiki are the same as what I did. The final screen shows segmentation faults and illegal instruction errors. Now’s a good time to try re-flashing with the backup files.

The backup files are flawed, and flashing with them failed. I’ll have to start from fresh images… tomorrow.

(weekly?) progress report

Initial play with the Freerunner was pretty limited: the preloaded distribution was pretty barebones and probably no longer supported (opkg points to, which is offline).

I flashed the Freerunner yesterday with OM 2008.9 from Mac OS X using Openmoko Flasher (instructions). After getting into u-boot mode, I had some trouble getting the USB connection to register and clicking flash fails. Re-connecting the USB cable and retrying does the trick, and there was no problem once the transfer was underway.

OM 2008.9 comes with some more stuff, though I haven’t gotten much working. SSH’ing into the phone, opkg does point to a functional repository at, but I haven’t been able to run opkg update successfully for some reason. At the time, I had both the USB connection and wireless connection up but I’m not sure if that’s a problem.

Hoping for some better luck tomorrow as I would like to fetch some applications and play around with the phone as I still haven’t seen the hardware in action. There are still newer distributions to try out. There’s FSO where I read that people are focusing on. Community based SHR is built on top of that, probably where people are developing apps. There’s also FDOM, which is everything that seems interesting chucked into the system.

freerunner arrived

My Freerunner kit arrived in the mail today. I’m pretty excited.

I’ve been going through the wiki trying to get started setting up the phone. I don’t have a SIM card (we have Verizon). But at this point, all I’m worried about is getting the factory image updated to a more recent image. I managed to set up a USB connection between my laptop and the phone, sharing the internet connection. opkg, the package management system, fails with some missing signature errors. The wiki mentions there would be a problem, though it doesn’t offer much more to solve it. That leaves the second alternative of manually flashing the phone.

Seems also that I’m not the only one getting started as there is a guy on the community list who’s also getting his Freerunner flashed and all. I guess I’ll be riding in his coattails as well as reading around on the wiki; it seems everything is there, somewhere. More to come soon!