VNC on the Raspberry Pi

Here’s a quick demo I’ve put together, showing the RaspPi running as a VNC client:

The setup is a slightly unusual one; instead of the client connecting to the server, it runs in listen mode, and the server initiates the connection. This allows the RaspPi to be used as a kind of shared, network display. The software on the RaspPi end is TightVNC, which is available in the Debiam ARM repository. On the server side, I used Vine Server, as the built-in server on Lion doesn’t support reverse connections (if you want to use the normal client/server arrangement, the built-in server is fine).

The reason that VNC supports this back-to-front arrangement is interesting in itself. ORL (later AT&T Labs Cambridge), the birthplace of VNC, also took a significant interest in location-aware computing, firstly with the Active Badge, which could track users to the granularity of a room, and then with the Active Bat, which could do so within a few centimetres. I worked at the lab for a year before starting my PhD (which they sponsored), in the project exploring the sort of applications you could build with this sort of technology.

One of the simplest and most effective was display teleporting. If you wanted to show someone your screen, you just held your Bat (or, in earlier versions, your Badge) against their monitor and pushed a button. Hey presto, via the magic of VNC reverse connection, there it was. Even though this application hasn’t exactly become ubiquitous, the reverse connection mode that was added to VNC to support it has remained a standard and useful feature. The location-aware technology lives on as well.

Mmmm... Pie...

I’ve been lucky enough to get my hands on one of the Raspberry Pi alpha boards. I have various plans for things to try with it, but I thought I’d post some initial thoughts about the experience of using the board, and the project as a whole.

If you’ve not heard the name before, it’s a charity that aims to “promote the study of computer science and related topics, especially at school level, and to put the fun back into learning computing”. To this end, they’re developing a $25 computer. Not a toy, or a working model, but a real computer that’s cheap enough to give to kids without worrying about them breaking it. This isn’t just pie in the sky1, either: they’ve already produced two generations of prototype hardware, and should be on course to have the final version in production, at the target price2, before the end of the year.

The board, pictured below, has at it’s heart a Broadcom system-on-a-chip based around an ARM CPU, with 128MB or 256MB of RAM stacked on top. There’s very little else on the board - the slightly more expensive version has a single-chip USB hub and Ethernet adapter, but that’s pretty much it. This simplicity is how they’ve managed to hit the ambitious price point.

Raspberry Pi Alpha Board

This kind of SoC is more often found in set-top boxes and the like, so it has reasonably good graphics and sound. It really is a complete system - you just plug a keyboard into the USB port, a TV (or monitor) into the HDMI, and you’re away.

On first booting the board, I was taken back. Not to primary school and the BBC Micro, but to my first exposure to Linux at University. The disk image I have boots to a console, and I found myself dredging up knowledge of things like runlevels and virtual consoles that I hadn’t used for years. My soft hands suitably re-calloused, I proceeded to poke around, install various packages (including, I admit, X Windows and LXDE), and generally having a play. The current OS image is based on Debian, and so hundreds of packages are only an apt-get away. The list isn’t as comprehensive as it is for x86, but there are still plenty of interesting packages (such as TightVNC) to install.

The thing that struck me as I used the Raspberry Pi was how familiar everything is. This isn’t some kind of esoteric embedded system, but a real computer, with a real OS, and standard languages and compilers right there, running on the board itself. Granted, it’ll never challenge the latest MacBook Pro in terms of raw horsepower, but for the intended use - programming education - it’s more than enough.

You could, of course, stick Firefox on the device, and get a dirt-cheap, tiny, low-power client for the web. There are also myriad things that become feasible when you can get a computer for the sort of money that Curry’s would charge for an HDMI cable not too long ago - smart screens, tiny servers, automation, and many others. You could even stick LibreOffice on it and equip a school computer lab for a fraction of the price today. However, doing so would miss the point.

The project stems in large part from the observation that fewer of the eighteen-year-olds arriving at Cambridge to read Computer Science had a good grasp off how computers actually work3. This is not, of course, to say that they’re any less bright, but just that their exposure to computers has been markedly different from that of those of use who grew up in the eighties (or even the nineties).

There are numerous factors behind this change, but a big one is the rise of the family computer. This is a device that has a myriad of uses - banking, shopping, gaming, watching TV - which means that parents are a lot less inclined to let an inquisitive seven-year-old poke around in it’s innards. A Commodore 64 or Acorn Electron, by contrast, was useful for… pretty much nothing, out of the box. Even getting a game to load involved reading the manual and getting some mysterious incantation just right.

This initial uselessness is not only part of the charm of early home computers, but also a key to their educational value. To make them do anything of interest, you had to program them at least a little, and this gave curiosity a way in. Even copy-typing listings from a magazine4 gives you the idea that, far from being some kind of magic, this box is something that could be understood if you put your mind to it.

Modern computers are increasingly black boxes, with a big implied or explicit “no user serviceable parts inside” notice discouraging people from wondering how they work. This is appropriate for tools that are increasingly central to our lives5, but raises the question of where the next generation of programmers and hardware engineers is going to come from. By providing a cheap, open machine that kids can tinker with to their heart’s content, Raspberry Pi are providing an answer. It’s not the complete solution, but it’s a big part of it. What they need now are software and ideas, and if you’re a programmer of teacher (or both) that’s something you can help with. You can also help by buying one of the final boards under their buy one, give one scheme. I’ll certainly be getting one or two.


  1. Sorry.

  2. There are actually two models (with a naming scheme that might seem familiar) - the model A for $25, and the model B for $35, which adds extra RAM, Ethernet, an additional USB port. The alpha board corresponds to the model B.

  3. Eben, one of the founders of the project, and I were both involved in interviewing prospective Computer Science undergraduates, for different colleges.

  4. Coverdisks? Cassettes? Checksums? Luxury! When I were a lad, we had copious syntax errors, and we were glad of it…

  5. This is one of the reasons I tend to buy Apple hardware these days - I’m willing to sacrifice some of the ability to upgrade and repair the kit myself for the integration and simplicity.

Rob Hague is a computer programmer by profession, and an amateur at everything else. This blog is where he posts pretty much anything that pops into his head. He's based near Cambridge in the UK. Mail him at rob@rho.org.uk.
Subscribe
Powered by Jekyll