An ARM On Four Cylinders

Iwzxhzdk:14ve been trying out a Ferrari.

Well, sort of. Letwzxhzdk:15s put it this way: If the [Raspberry Pi][rpi] is todaywzxhzdk:16s ARM computing equivalent of the Volkswagen, then the [ODROID-U2][od] is probably its Ferrari, at least under the hood.

Hardware

Physically, the thing looks like the result of an unlikely marriage between an oversized postage stamp and a heat sink.

The PCBwzxhzdk:18s somewhat smaller than a [Raspberry Pi][rpi], but even considering this is a development board, the end result is a lot tidier wzxhzdk:17 the heat sink actually makes it somewhat reminiscent of a shrunken down NeXTCube, and tacking on a couple of pieces of matte black cardboard on the open sides completes the effect.

But the most important hardware characteristic of the [ODROID-U2][od] is its quad-core [Exynos 4412][ex] CPU, which is very snappy indeed. In fact, this is the fastest [Android][an] device I’ve used yet by all accounts, although the 8GB EMMC I ordered along with it has to take part of the credit (running the OS from an SD card works fine, but is somewhat slower).

I hooked mine up to a full HD (1920x1080) monitor via an HDMI-DVI adapter[^1], plugged in a Bondi Blue iMac USB keyboard I had lying around as well as a bog-standard USB webcam and mouse, and stuck to Ethernet for connectivity.

Software

So what do you run on it? Well, I chose [Android][an] wzxhzdk:19 in fact, part of the reason I got one was that [Ricardo Cerqueira][rc] ported [CyanogenMod][cm] 10.1 to it with nearly complete hardware support (more on that in a moment), so I pretty much ignored the stock AOSP version and the (then incipient) [Ubuntu][ub] port and just went ahead and flashed that.

Most people would probably look at using this as a media centre (for which it is eminently suitable), to run arcade emulators (which I did, but mostly to be amazed at the speed of the thing), and, of course, for testing apps.

Me, I set up [Evernote][ev], Facebook Messenger and Flipboard on it (besides a number of Google Apps and a couple of terminal emulators), and soon had a couple of [Android][an] apps of my own running on it wzxhzdk:20 one of them compiled locally using [AIDE][aide].

Given my [previous dalliance][b1] in [Android][an] for [x86][x86], using [Android][an] as a “desktop” is hardly a problem klzzwxh:0007 aside from somewhat oversized fonts and lack of multitouch (or even a working secondary mouse button), switching between apps with Alt+Tab works smoothly and intuitively enough, and most well-written apps support a minimal amount of keyboard navigation – so (rather ironically) moving about with a keyboard alone is a more viable proposition than on an [iPad][ipa].

Zooming (which can only really be handled via pinching) remains the only hassle, but there are a few nice touches ’ for instance, and rather unexpectedly, I can switch it ’on– and ”off’ (i.e., switch off the display via DPMS) using the power button on the USB keyboard, and most ’normalwzxhzdk:9 key combinations for caret movement and text handling just work.

Remote Access

One of the reasons I bought an [ODROID-U2][od] was that itwzxhzdk:11s a perfect, zero-hassle smart terminal wzxhzdk:10 I just sit, tap the power button on the keyboard and get instant access to a decent default desktop with a few different browsers[^3], a perfectly usable terminal emulator[^2] and working builds of tmux and [ssh][ssh], so the basics were covered right off the bat.

Running [Android][an] is just the icing on the cake, really. But full HD is sort of wasted on terminal windows, so I also looked for ways to replicate [my remote desktop setup][rdppi].

After some experimentation, I settled on [Jump Desktop][jd] as my [VNC][vnc] and [RDP][rdp] client wzxhzdk:12 it not only handles [ssh][ssh] tunnelling without any issues and is very speedy, it also works well in uncommon configurations (such as using VNC with Mac authentication or RDP-over-SSH to a Linux machine).

And, of course, it blows [my earlier Raspberry Pi setup][rdppi] out of the water in terms of speed and flexibility.

Interestingly enough, despite Android not supporting more than one mouse button and handling the scroll wheel inconsistently, [Jump Desktop][jd] handles right-clicking and scrolling without any issues, and (much to my delight) had no trouble whatsoever with Portuguese keyboard layouts at any end.

So this VPS (where I keep a container with Chrome and development tools to use on the go) and a number of other servers are just a couple of clicks away, and itwzxhzdk:13s awesome.

Kinks

There are a few minor niggles with the whole setup, though.

The first is that Android applications are (naturally) unprepared for being used in a desktop environment and/or with a physical keyboard klzzwxh:0024 even [Jump Desktop][jd] persists in displaying an on-screen toolbar and keeps trying to “help out” by adding a black margin around the remote display (likely to allow your finger to touch the very edges of the screen), something I worked around by setting my remote desktops to be 1920x1016 (i.e., exactly the right size).

Also, [Bluetooth][bt] is, alas, not supported yet, for changes in the Android 4.2 [Bluetooth][bt] stack mean that USB dongles (the only practical way to add a transceiver) require a substantial bit of internal re-plumbing at the kernel and driver levels to get working.

But overall, and considering that Iwzxhzdk:14m running [CyanogenMod][cm] nightly builds, the whole thingwzxhzdk:16s a lot more stable than youwzxhzdk:15d expect.

Penguin Inside

Using the [ODROID-U2][od] as an Android desktop and thin client was all fine and good for a few weeks, but this weekend I decided Iwzxhzdk:23d have a go at running [Python][p] on it locally wzxhzdk:22 partly because I like to pull weird stunts like that, and partly because Iwzxhzdk:24ve been porting stuff from threading to the multiprocessing module and it was a good opportunity to get a better feel for the [Exynos][ex] quad-core.

[Python for Android][pya] worked fine (after some tweaking), but I then realised I was going to need to install some packages locally.

So I started thinking about setting up a chroot environment of some sort, gradually drifted onto the notion of using standard Linux ARM binaries and after a few (mercifully short) tries eventually came across [Linux on Android][loa], which is nothing more than a chroot environment mounted from a filesystem image[^4].

As it turns out, running a [Ubuntu][ub] userland alongside Android processes works very well indeed (since itwzxhzdk:20s all running atop the same kernel, therewzxhzdk:21s zero overhead). So much so that even though Iwzxhzdk:19m not interested in running X applications locally, setting up a [VNC][vnc] server and running Firefox just worked wzxhzdk:18 and at impressively snappy speeds, too.

wzxhzdk:13

The only serious drawback with this is the amount of extra storage required for the extra luggage a [Linux][l] system brings along with it, but itwzxhzdk:17s perfectly doable and, at least for my purposes, much better than trying to install [Ubuntu][ub] natively.

So I can see myself getting quite some mileage from this as soon as I get my hands on a largeish SD card and move the [Ubuntu][ub] filesystem over to it.

Who knows, I might even go crazy and try to run Unity on it, just for kicks[^5].