March 24, 2014
Since Alexander and I built our wacky Analog Defender game back in 2011 I’ve wanted to rebuild. I decided to take our acceptance into the Alt.Ctrl.GDC exhibit as an opportunity to do a complete re-build on the hardware.
The original build was a success creatively, but technically it was a nightmare to setup: two laptops, a USB hub, a router, various power supplies and a bundle of wiring… I decided to drop the internal LCD from the console and to use a new Arduino Leonardo as the guts of the machine. The Arduino would take all the analog inputs and communicate them to the laptop as simple keypresses (the Leo can present itself to a computer as a standard USB keyboard).
The original build was a spaghetti mess of wires and there was way too many fixed connections – no good for replacing controls that have been mashed a little too enthusiastically. This time I went much more organised. Using ribbon cable and IDC connectors with the rotary switches and lots of shrink wrap and polarised connectors for the rest of the controls.
The original used an Arduino Mega, with its generous number of input pins, but this time I was using the Leonardo so I needed to do some multiplexing to get all my inputs connected to the limited number of pins. I used the CD4021 shift register and followed this tutorial to pack a lot of rotary switch inputs onto just one Arduino input pin.
I wanted to build the new console inside a portable case – for easy and safe carrying. I used a briefcase format flightcase that I inherited from Bill, my father-in-law. I built a plywood frame to fit exactly inside the case and support the control panel. Threaded inserts in the top edges of the framing plywood provided a place to attach the panel using machine screws.
The panel itself was in two layers. A base layer of 6mm birch plywood for strength and a 3mm layer of clear acrylic over the top. Both layers were laser cut to mount the individual buttons and controls exactly.
If I were doing this again I might build the flight case from scratch to provide the mounting and support needed for the project. Using an existing case and fitting a new structure inside was a lot of work and added some unnecessary redundancy in the structure.
I used a vinyl cutter to cut the labels out of sticky vinyl (in reverse) and fixed them to the reverse side of the clear acrylic top panel. This worked pretty well, it meant I needed to be very careful about avoiding air bubbles when sticking the vinyl as they’re much more obvious from the back. My assumption is that this setup will be much more robust, with no front side vinyl to get scraped or peeled up.
With hindsight I would try the wet method for applying the vinyl as that gives some possibility for repositioning of the vinyl which I would have really used when I was doing this at 5am after another sleepless night.
Using the Arduino Leonardo’s ability to pretend to be a USB keyboard seemed to work really well. It was a dramatic simplification over the previous serial and OSC based system and worked just as well in practice. The Arduino collected all the button/jack/slider/rotary switch events and reported them to the USB attached laptop as simple keystrokes.
Even the analogue slide pots went as keypresses. The range of each slider was divided into 24 segments and a unique keypress fired as the slider passed each boundary between segments. I’m not sure this would work for an application where more definition was required, but it worked fine for our purposes. I was concerned that the torrent of keypresses this method could generate might jam up the works somewhere along the line, but in our case (attached to a Macbook Pro running the Python) it worked great.
There are a ton of people who I thank for helping make Analog Defender Mk II a reality. I won’t repeat myself, it’s a long list and I appreciate every last generous one of them.
© 2018 Patrick Dinnen | Theme by Eleven Themes