Arduino Project 7 - Build A Retro Gamebox - APC
Arduino Project 7 - Build A Retro Gamebox - APC
Arduino Project 7 - Build A Retro Gamebox - APC
Tweet
Parts list
Part
Cost
Source
Arduino Uno R3
$13.20
eBay
$8.79
eBay
Arcade pushbutton
$3.50
eBay
Dupont wires
$2.55
eBay
$0.95
Jaycar
$0.95
Jaycar
$2
Local $2 shop
$0.46
Jaycar
$0.46
Jaycar
TOTAL COST
$32.86
Games
The inspiration forthis projectof ourscame from the Hackvision system developed by Nootropic Design. Its a basic cut-down custom Arduino with four direction buttons and a fire button
all built onto a single printed circuit board. You can buy it as a prebuilt device ($44) or a kit you put together yourself ($34). However since the Arduino code for a number of games
including Space Invaders Asteroid Tetris and Sudoku has been released to open source we decided a game box with existing Arduino hardware would be a worthy inclusion into our
project list.
The main problem with the Hackvision system is the lack of USB connectivity requiring you to come up with your own USB-to-TTL adapter cable to program it. By using a standard Arduino
in our Retro Gamebox changing games is as simple as plugging the Gamebox into your PCs USB port and compiling the new Arduino sketch.
How it works
Our Retro Gamebox is surprisingly simple when it comes to hardware: five switches three resistors a couple of RCA sockets and thats about it. Well its a little more complicated than that
but when you boil it down thats all there is from an electronics viewpoint.
switch to the direction of movement. So pushing the bar up activates the bottom switch; pushing it left operates the right switch and so on.
Video/audio output
Thanks to some impressive coding from Myles Metzler and others the video and audio output that connects to your TV requires only three resistors and one of those is optional. We wont
cover how it works here but briefly composite video requires two electronic signals: the analogue video data plus the synchronisation pulses that tell the telly where the data is meant to be
on the screen. Two resistors are all thats required to combine the signals into one composite video output with the correct voltage ratios your TV will understand.
The Gamebox features composite video out and 8-bit sound via its two RCA ports.
The audio output is really simple. The Arduino creates genuine 8-bit pulse-width modulated (PWM) sounds straight out of pin D11. Weve added a simple 470ohm current-limiting resistor
to ensure that output pin doesnt blow up if its accidently grounded. That output goes directly to your TVs audio input and gets blasted out the speakers.
Putting it together
You can put the Retro Gamebox into any container you want so weve chosen a food container for its low cost and transparency. Full-size arcade games are impressive but we wanted you
to see whats going on inside and hopefully give you the idea that its not that complicated.
Place washers directly against the plastic so you dont split it.
The fire button itself comes apart grab hold of the microswitch bottom section twist and pull it to unlock. Thatll give you the top shaft section which you can feed through your case and
anchor with the large plastic collar nut. There are different types of arcade pushbutton switches so your mileage may vary.
We raised the Arduino board off the bottom of the container using 5mm spacers (Jaycar) and 15mm M3 bolts (Bunnings) which fit into the Arduinos four mounting holes. Dont forget the
washers on either side of the plastic before you add in those spacers. Using a see-through container makes it easy to mark out the mounting hole positions with a Sharpie before you drill.
Finally dont forget the holes for the DC power socket and the USB port.
You can use proper spade lugs to solder the joystick and fire button switches or solder direct as we did.
Just make sure you dont wire everything so short that you cant take the lid off easily. Really how you build it is up to you as long as you follow the circuit diagram you can build it on a
lump of wood if you like and it should still do the job.
Hooking it up to your TV
This is the fun bit. Use a standard stereo pair RCA cable and connect one side into the Retro Gamebox and the other end into the composite video and audio inputs of your TV or monitor.
Go with a 3m or 5m cable to give you enough length that youre not sitting on top of the telly to play. Powering the Gamebox youll need a 9VDC or 12VDC power brick with the centre pin
positive and the other ring negative. The Arduino pulls no more than 50mA so just about any correct voltage/polarity power brick should work. You could also power the Gamebox with a
USB power adapter from your smartphone or tablet and plug a USB cable into the Arduino weve tested this and it works just fine.
Weve soldered the output resistors directly to the RCA sockets. Its not ideal but its quick.
PAL or NTSC?
By default Gamebox is set to deliver US-based NTSC-standard video. Thats not a problem for modern TVs as they all handle NTSC and Australias PAL video system but if youre
planning to run this on an older CRT TV thats PAL only add a wire from D12 to ground to tell the Arduino you want PAL video output. Apparently this also speeds up gameplay for some
reason we havent figured out yet; most likely due to the change in video frame rate from 60Hz to 50Hz. Arduino only does monochrome video so dont expect to see flashy colours.
Turn the TV volume down a bit before you start as the Arduinos audio output can be a maximum 5V peak to peak and dont forget to select the appropriate TV input to see the video.
To reset the Gamebox just pull the power out and plug it back in again. You could add in a small pushbutton switch that pulls the RESET pin to ground but thats entirely optional.
Search Site
Search
Follow us
Recent Comments
Darren Yates on Arduino Masterclass
Part 4: Build a mini robot
Darren Yates on Arduino Project 5:
Digital audio player
HarryDGrif on Best iPhone and iPad
apps, February 2014
SicaBixby on The best PC gaming
accessories: 8 gaming keyboards
reviewed and rated
Raquib Buksh on Arduino Masterclass
Part 4: Build a mini robot
Magazine Resource
APC Tutorial Files
Arduino Source Codes
Tweets by @APCmag
Vote
View Results Polldaddy.com
Top
Future is AOP & PPA Digital Publisher of the Year and BMA Media Company of the Year.
This siteis part of Future plc, an international media group and leading digital publisher. We produce content across five core areas:
About Future
Jobs
PR
Advertising
Digital Future
Privacy Policy
Cookies Policy
Subscriptions
Investor Relations
Contact Future
Future Publishing (Overseas) Limited, Beauford Court, 30 Monmouth Street, Bath BA1 2BW. All rights reserved. England and Wales company registration number 06202940. Australian Office: Suite 3, Level 10, 100 Walker Street, North Sydney, NSW
2060 T: +61 2 9955 2677