An Atari 2600 in a Cartridge

You know when you’re having that long-overdue clean-out and you find a few things stashed away you’d forgotten about? From when you said “that’ll make a great project one day” then tossed it in your equivalent of the bargain bin? Just happened to me.

A few years ago, I got a great Atari 2600 VCS job lot. Two consoles (a light-sixer and a Vader – now both composite modded) and a stack of games. Out of all the games only one appeared to be beyond repair. That cartridge, Activision’s F-14 Tomcat, was duly placed in the bits and bobs box until a project came to light for it.

Almost simultaneously, I came across the cart and a couple of 9-pin sub-D joystick ports. The brain, it ticked. And tocked. And finally came up with a Raspberry Pi Zero. Of course, an Atari 2600 in a cartridge! Why not? Why? Who cares.

Before I did anything else, I prototyped the build on a Raspberry Pi 2 and a breadboard. My requirements were:

  • Inputs for two joysticks
  • A power button
  • A method for shutting the Pi down cleanly
  • The TV colour switch
  • The difficulty switches for both players
  • Select and reset
  • Some method of access to the console

Thankfully, the newer Pis have enough GPIO inputs to handle all this.

The Atari emulation itself is very straightforward. I decided to use the excellent RetroPie operating system as it handles all the game selection menus for you. I would then use Stella for the actual emulation of the Atari 2600.

The trick now was how to couple-up the joysticks and buttons to the emulator. The easiest approach is to trigger keypresses and map the emulator to them. After some research and a few false-starts, I settled on Adafruit’s Retrogame package, which did exactly what I needed. With a simple config file, I could map changes on the GPIO pins to keypresses. It worked perfectly. Soon I had a breadboard mockup where I was controlling the games by shorting the pins to ground.


Another problem with keys was to be able to shutdown the Pi cleanly. I ended up writing a short Python script using the python-uinput package. This does a similar job to Retrogame but I was able to configure things so if the power button was pressed once it would quit the current game (and return to the selection menu) but if held for three seconds, it would trigger a system shutdown. Implementing this script also gave me the chance to add an LED to the front so I could see when the system had finished shutting down (I also really like LEDs).

The last part was adding a barrel connector hooked up to the UART pins so should I ever need to, I can get console access without having to take everything apart. I tend to do this just out of habit with build like this and have a ready-made USB-to-UART lead with a 3.5” stereo jack on the end.

To work!

First off, lets get that cartridge cleanup, open and remove all that complex circuitry. Oh.

Next, get rid of all the interior posts and bits with a pair of pilers and some deft craft-knife work to get it as smooth as possible. Didn’t need to be perfect.
I wanted to not only have the joystick ports (which, let’s be honest, are kinda important) but also all the switches that the original Atari VCS has. So, I measured up the front area and made up a template to make sure everything would fit.
With the template in place and looking good, next up was to cut the holes. I only had one shot at this, so time was taken. The holes for the switches were done with a low-speed drill and the larger joystick holes with a rotary tool.
A little scraping later, and the ports fit nicely.
Now to get a bit more artistic. The Atari cart font was easy enough to track down (it’s called MumboSSK) and I made a little mock-up of a cart with labels for all the controls. The graphics were, ahem, borrowed from the cover of ‘Art of Atari’. I suggest you buy it as it’ll make me feel better.

Apologies for the wobble-vision

Time to get the soldering iron out. Thankfully the Pi Zero (I’m using the original, not the W) has enough GPIO pins to cover all my requirements. I needed five controls per player (up, down, left, right, fire) and a further six for my control buttons. Luckily the Zero could accommodate this without needing to resort to any kind of space-destroying input extender.
With everything tested, time to fix things in place. Superglue did the trick nicely for the ports, but the Pi is mounted with (non-conductive!) sticky foam pads.
Time to very carefully fold things up.
I’m not quite prepared to get the glue out yet, so an elastic band is helping hold the cart together in the meantime.
I mapped the Emulationstation (RetroPie’s UI) controls to the same as the left joystick so you can select your game. Once in a game, a tap on the power button will drop you back to the main menu.

So there you go. Hours of fun on Combat ahead. Think I’ll skip E.T. though. The Pi Zero has enough grunt to run Stella very well indeed, although it finds Emulationstation a bit of a struggle (but not bad enough to be unusable).

I’ll be bringing this little gizmo to the Milton Keynes Raspberry Jam on the 15th July 2017. Hopefully I’ll see you there!


Building The ZX Raspberry – Part Four

In which our hero is unable to leave well alone

A little epilogue to the ZX Raspberry project. I came into possession of a very dead ZX Spectrum+ and, following my own personal rule of ‘it gets fixed or it gets modded’, I decided that it was time for a ZX Raspberry+. This project did away with the USB keyboard option, so just a standalone Raspberry Pi-driven unit.

ZX Raspberry+ Innards

ZX Raspberry+ Innards

I made a few improvements and discoveries along the way.

  1. It’s a lot easier to put all this gubbins in a Plus case rather than an original.
  2. The Raspberry PI + variant (+ or 2) is conveniently sized to place the HDMI and power alongside the expansion port (less cables!).
  3. The +’s reset switch makes a handy keyboard mode switch.
  4. A conclusion I reached during the first project was right, I didn’t need the resistors on KB1. Leave them and the power line out, wire the connector directly to the Pro Micro and just set the inputs to INPUT_PULLUP in the Arduino sketch. It does everything for you.

Finally, I was able to really speed up boot time by using PipaOS instead of the standard Rasbian distribution. It’s still Raspbian, but optimised for fast bootup and without a lot of the stuff you don’t need anyway. The results on a Raspberry PI 2 with a Class 10 SD card are quite something. Here’s a boot video:

Just a shade over 10 seconds. Not bad eh?


Building The ZX Raspberry – Part One

In which our hero plans and schemes

Despite wanting to convert a ZX Spectrum into a USB keyboard for some time, I held off to wait for the unlikely duo of the ZX Spectrum Vega and the Recreated ZX Spectrum. Sadly, neither buttered my parsnips, and the reasons why have been discussed at length around this Internet of ours, so I shall say no more here. What I really wanted a combination of the two: The stand-alone operation of the Vega and the keyboard of the ‘Recreated’.

Not being one to re-invent the wheel, I’d been reading over this Instructable wot I found and occasionally drooling over the excellent kits offered by Tynemouth Software. Then, a battered old Speccy case and the parts needed for a USB interface found their way onto a Facebook group for just £20, their current owner being caught between retro-project-awesomeness and ‘having a life’ and ‘friends’. Clearly making the wrong choice, he put them up for sale. … 


Restoring a VIC-20

I purchased this poor thing last week. After some initial mucking about, life was breathed into it once more. I had a a bit of fun getting the keyboard working but now she’s 100% operational and a welcome addition to the collection.

If you’re unfamiliar with the VIC-20, it was Commodore’s entry to the home computer market and a pre-cursor to the wildly successful C64. The VIC, despite boasting colour and sound at a time that the ZX81 was considered exotic, was held back to 3.5k of RAM (expandable to 16K) and poor resolution. Nevertheless, it was, and still is, a cracking little computer that saw the likes of Llamasoft’s Jeff Minter cutting their teeth in the gaming world.

This slideshow requires JavaScript.


Breathing New (Composite) Life Into a Binatone Pong Console

Pong! What more could a young child want in 1978? Despite my formative years, I was already hooked on my friend’s magic-filled box of delights he described as a ‘TV Game’ (for ‘console’ was a word of the future). We would Pong, Pong and Pong some more. Then, in a rare moment of wish-fulfilment for a working-class lad from Liverpool, Santa brought me my very own TV Game, a Binatone no less! … 


Binatone Pong


2014-04-28 12.47.49 2014-04-28 12.48.26The first computer game I ever owned was this Binatone ‘TV Master MK IV’ – a simple unit that could play the standard Pong variants with a pair of analogue paddles. Yes, it may be simple, but I had hours of fun playing it. Sadly this isn’t my original but I did find it for just 99p on eBay. It Turned up filthy and I was pretty convinced it wouldn’t work. I’m very happy to say I was wrong.