Introduction: ​From a Wooden Box to a Retro Console

Picture of ​From a Wooden Box to a Retro Console

My wife mentioned that she wanted to play the games she grew up with again, and with our little one getting bigger, I thought it would make a great Christmas present to her and our family to build a little on-shelf console.

This was my first attempt at anything like this. Someone with more skill could clearly clean this up, and make a beautiful box.

As a precursor, prior to this project, I hadn't touched a Dremel in years, and I'd never been brave enough to solder. Both of these were required for the project. I highly recommend that you do NOT let this dissuade you, especially the soldering part. YOU CAN DO IT.

As with many things, this is built off of the work of many other people, this is simply my twist on it.

All materials were purchased at either Adafruit, Amazon, or Radio Shack (local). Total cost out of pocket was around $125. I had controllers ready, so add ~$30 to that for two controllers. I had to restock a lot of standard DIY electronics supplies, and I didn't own a soldering gun, so that upped my personal costs.

Step 1: Materials Needed

Picture of Materials Needed

Step 2: Tools/Software/Hardware Needed

Picture of Tools/Software/Hardware Needed

Step 3: The RetroPie Software Setup

Picture of The RetroPie Software Setup
  1. First head over to http://blog.petrockblock.com and do some light reading. I loosely followed this guide: http://supernintendopi.wordpress.com/
    Note: A lot of Super Nintendo Pi is from an old release, so some folders have changed, so it’s not perfect for a walk through – but it is a very good guide.
    Note 2: I'm going to be relatively brief, as there are lots of good guides on this part of the process. I'm going to cover everything, and focus on the common problem areas, but this in large part this process is covered better elsewhere.
  2. Hardware wise, I applied the heatsink to the Pi’s CPU – most Pi experts will tell you these are largely unnecessary, even for a full ‘Turbo’ overclock. It makes me feel better, so I did it.
  3. Plug in the Wifi Adapter or Hardwire to your network. Plug in Keyboard/Mouse.
  4. I used Win32DiskImager to make the image on a Windows PC. There are Mac and Linux options. This was the current 2.3 image from petrockblock.com
  5. I booted, went to command line, ran sudo raspi-config - set my memory split to 256/256 (other splits caused issues) – and Overclocked to 950 – used expand_rootfs to allow full use of the mSD card.
  6. Exit ES again - back to command line - run startx to get to the GUI and setup Wifi though the GUI – note the IP address, and rebooted. You can also use ifconfig if you forget your IP address.
  7. Setup Emulation Station controller support through the ES menus for both controllers. The menu in ES guides you through this.
  8. At this point some guides recommend using the RetroPie config to setup the controllers. I recommend AGAINST this, as everyone I have talked to has had issues with using it. I simply ran the retroarch joystick config from command line, then manually edited the config file to add emulator exit / hotkeys. Then I copied my player 1 setup, to a player 2 setup. I just had to change 1 to 2, and change the index (will see what I mean by this when you look at the file). This step is the most commonly asked about step. Here’s the short and sweet of how I did it:
    cd /opt/retropie/emulators/RetroArch/installdir/bin
    sudo ./retroarch-joyconfig -j 1 >> /opt/retropie/configs/all/retroarch.cfg

  9. Then I just did a sudo nano /opt/retropie/configs/all/retroarch.cfg to add custom stuff, and players 2-4 (I did 2), emulation exit, and hotkeys.
  10. Emulation Exit can be achieved by enabling a hotkey in the config file:

    input_enable_hotkey_btn = 8
    input_exit_emulator_btn = 9

    Where 8 and 9 are your select and start buttons - or whatever you choose. Hold the first button, then hit the second button. You can also add save-state / load-save-state commands using this method.
  11. Since MAME and Gameboy (gbSP) don’t run off the RetroArch core, I set those up through their GUIs, by hitting TAB and F10 respectively while in games. You’ll also need to setup exit buttons, since they are not run from the config file above.
    Note: The RetroArch controls can be setup through GUI as well, with F1 - they can also be changed for EACH system.
  12. Add the necessary BIOS and ROMs with WinSCP from a Windows PC connected to the Pi (via previously noted IP address). WinSCP functions basically like any FTP program does. It’s great for drag and drop and moving files to your Pi. The ROMs themselves go in each system's folder on the Pi. I’m NOT going to go into where to get ROMs/BIOS, as the correct answer is, these should only come from items you own.
    Note: Neither PSX nor N64 were worth running. 2D games on both were ok, but I ended up stripping them from my system for simplicity sake.
  13. Aside from MAME, all ROMs should be unzipped. MAME ROMs must be version 037b5.
  14. I ran the ES scraper for each system (individually) from the ES menu, and manually modified any games that did not scrape properly. 3-letter games, never scrape properly - so be prepared to fix every Pac Man title for instance.
    Note: I don’t really exceed 200 ROMs per system. Doing so caused me some minor issues. I’ve seen people with thousands, but I stuck to what we might actually play.
  15. I made backups of my image after each major step. This saved my bacon a couple of times. To do this, just plug the SD card into your PC, use Win32Imager, and use the READ option. I HIGHLY recommend doing this frequently.
  16. At this point you can remote access your system via either WinSCP or Putty for any maintenance. The default user is pi with password raspberry. I recommend changing the password at least.

Step 4: ​Adding an On/Off Switch and Power Indicator LED

Picture of ​Adding an On/Off Switch and Power Indicator LED

I wanted a real on/off switch for the device. The Pi draws very little power so it's not required, but it's really nice to have, and makes it look a lot cleaner. This method will put the Pi in a low power-draw state, that is effectively off. It does not cut power entirely but for that matter neither does turning off your home computer. This method allows for a safe shutdown, that should help keep your mSD healthy for awhile (that said, backup, and backup often!). Some other methods only turn off the Pi, and others cause a hard reset - neither is recommended and a hard reset can potentially damage your mSD card/data.

We'll be using the GPIO pins (General Purpose Input/Output). There are two ways to number these, by Pin number on the board, which is a simple 1 2 , 3 4, 5 6... or by GPIO number (see image). I use both methods of naming, so please take note.

  1. I used some Female to Female Jumper wires, and just stripped one end off. This made connecting to the GPIO pins very easy, and did not require that I solder the board itself.
    A note on soldering – You can do it. It’s not hard. I taught myself with the help of youtube for this project. It only took a bit of practice and patience. I agonized over which iron to buy probably too much – and ended up just getting the one from Adafruit – it worked perfect. Yes soldering is required. Do NOT try to make these connections with electrical tape and twists. Just solder them.
  2. I had to solder a total of 6 connections. For the switch, I soldered the stripped ends to each connector. On the LED I soldered a 68 or 85 ohm ¼ watt resistor on the ground side (either works, 85 ohm is dimmer). Typically the shorter lead or the flat side on an LED is the ground. And a jumper wire on the other side. After the solder cooled, I used heat shrink tubes over all connections.

    Note: If you are following this exactly you're safe to use those resistors but if you have different LEDs, or are trying to wire to the 5V power lead on the GPIO, then you'll need to recalculate the resistor to use.
  3. Wire your Momentary Switch to GPIO3 (Pin 5), with the other lead going to ground pin. Any ground pin will do, but Pin 6, is conveniently a ground. See image.

    GPIO3 (Pin 5) is a special GPIO pin, as it can wake a Pi from Halt. No other pin can do this. It’s also right across from a ground, which is nice. That why it’s ideal for this.
  4. Wire your LED’s positive side to any available GPIO pin. I choose GPIO 17. Take the other side, with the resistor to and wire it to a ground pin.
  5. Now, we need a script to make these little wires do their thing. I wrote (well modified) a small python script, that does a few things. It flashes and then leaves on the LED GPIO and it monitors GPIO3 for input. On input to GPIO3, it flashes then leaves off the LED GPIO, and issues the shutdown command. No coding is needed to wake the Pi, GPIO3’s wake function is a HARDWARE function.
    My shutdown script Looks like this: http://pastebin.com/XQk3R5C1

    Almost all the code’s base comes from the commented author rather than myself, since they did exactly what I needed. You will need to save that code as shutdown.py on your Pi. You can either transfer the shutdown.py file to your raspberry or create it through SSH directly on your Pi. I choose the former and simply used WinSCP to transfer it over. Where you save the script doesn't really matter, I believe I put mine in /opt/retropie/shutdown.py
  6. Now you need this script to always run, and start on boot. To do that, we're going to add the call to the rc.local:
    From command line or via remote connect/SSH (Putty) and issue this command:
    sudo nano /etc/rc.local
    Before the exit 0 line, write python /opt/retropie/shutdown.py

    As an aside, normally using the GPIO pins requires the python script to be executed with sudo, that's not required as rc.local executes as root.

Step 5: What's in the Box?!

Picture of What's in the Box?!
  1. The box is a simple wooden box from a hobby shop. The wood is VERY soft, which is both a pro and a con. In most instances you may want to use masking tape when drilling holes/cutting, to help prevent splintering the wood.
  2. First I drilled two holes in the front of the box. None of my bits or spades were the right size, so I did a bit of Dremel sanding for perfection. One for the Momentary Switch, and one for the LED holder. I found the box to be a bit wide – so the backer nuts that would have normally held them on, were almost worthless. To combat this I just made sure the holes were very tight... The threading on the switch and the holder both went right into the soft wood. Adafruit has some cool Switch+LED in one combos, which you might use – they were sold out in Red when I was building my project – it would have saved me the time of all the LED wiring and coding – and I think it even has a built in resistor which would have been nice.
  3. Next I tried to cut holes for the Panel Mounts. This proved almost impossible for a few reasons. The first and foremost being that I suck with a dremel, the other being that the width of the box walls were too wide to make a connection between the mounted port and the cable. My failures turned into me cutting out a giant panel.
  4. I tried to make the panel look retro and cool, but mostly it’s just functional, and a bit ugly. I may touch it up with paint later.
  5. Initially I bought some ‘shelving’ wood, a very thin set of wood, you might find in a kitchen drawer's bottom. I ended up not actually using this, but I did use it to plan out what I did use - and it would have worked perfectly.
  6. I dug through my kit of misfit toys, and I took an old PC drive slot cover from a standard PC case - that I had laying around, and went to town with the Dremel saw on it. Overall this hole panel mount section was by far the hardest part of the entire project and I violated multiple standard safety protocols to get it done. Again, I suck with a Dremel. To help me, I did something, that you probably should not do, but I did anyways because I’m a rebel. I went ahead and screwed the panel mounts to the cover. The cover was see through and I used it to guide my cuts. This resulted in some lightly cut rubber casing of the panel mounts, but no damaged parts. I touched up my more horrible cuts with some black paint.
  7. I took the cover and drilled the holes, then hand screwed the screws into the case (again soft wood). I wanted it to be flush, so I did this from the inside, a tiny bit of screw ended up sticking out, which I just sawed off with the Dremel. This is really not pretty, but ended up better than I thought it might. If I had not run out of time, I would have painted black over this section, in sort of a starburst pattern.
  8. With the Panel Mounts mounted, and the LED/power switch done, it was time to mount the Pi. I originally wanted to use some standoffs, and have the pi be naked, but that proved mildly challenging, and I was running out of time. As luck would have it, the case my Pi came with had two holes for screws on the bottom panel. I opted to simply drill the plastic case to the bottom, and Dremel off any sticking out screw from the bottom. Despite there being plenty of clearance, I put a small piece of electrical tape over the screws. I ensured that I mounted everything so I could still get to the mSD card in an emergency and the cables were basically self-guided.
  9. With everything done, I covered any holes/electrical parts with masking tape. In retrospect this should have been done prior to all the panel mounting, etc, but I wasn’t sure everything would work until now.
  10. I also drilled some air-holes on the side, these allow a bit more airflow, and probably more importantly, a tiny bit less resistance for my wireless controller’s signal. The Pi itself runs cool so I don’t see a reason to do this beyond personal choice.

Step 6: Pretty Her Up

Picture of Pretty Her Up

Now for the part you've been waiting for. I used this method:

  1. I grabbed some pictures of my old game friends from the internet, with bright colors and simple but heavy black lines. I also snagged some free fonts for a retro text and an old arcade feel text. The exact names were Retro Wide and Karmac Arcade. Any text you use, will need to be reversed in your favorite image editing program. Gimp is a free and exceptionally powerful image editing software.
  2. Take the labels off of the Avery labels, put the sheet in your printer, so that the waxy side is the side that is printed to.
    You have some options, you can set your printer to print to transparency, some report this ends up with better images with more ink – but I had issues with smudging on this setting – it was too much ink, and on larger images ended up pooling ink in places. I did use “best” quality color prints though. Print to your Avery sheet, some images and text for your wood. I highly recommend against images that are more than 5 inches large, I had issues with my printer when trying those – they’d smudge on the printer itself – but it could have been my printer. In the youtube video he uses an almost full 8x11 picture, but I simply could not get that to work for me.
  3. You can, and probably should either wet the wood, or give it a good light sanding (60-80 grain), or both. I failed to do this – which caused my images to be more washed out, and not fully apply in some cases. I ended up actually really liking the look – as it caused it to look older, so I stuck with it for the purposes of this project.
  4. Simply take your printed sheet, and CAREFULLY lay it on your wood – I recommend doing small cut outs for each picture. You do NOT have to move fast, it won’t dry to the waxy side of the paper. Take your time.
  5. Now that it’s down, apply some firm pressure – being VERY careful to not smudge. Some guides recommend using a credit card to smooth it out and apply pressure and/or taping a side down. I tried this and it made little difference for me.
  6. The wood will almost instantly absorb the ink, and will dry very quickly. I added some flair text, to show the power button, and my ‘picade.’ Once you’ve sorted out all your images and text, apply a couple of coats of clear lacquer to your box. This will make your images pop a bit, and provide some light protection. The wood of these boxes really absorbs this, so I recommend at least 3 coats, if not 5-6.

Step 7: ENJOY

Assuming all has gone well, this little device should be almost entirely plug and play on any modern TV with a HDMI port!

Shout-out to :

http://www.reddit.com/r/RetroPie/

and

http://www.reddit.com/r/raspberry_pi/

Both are great resources if you need more help.

Comments

Olliegilbert (author)2014-12-29

What a great project! Any plans to make a few and sell them? I'm sure there's a market for this. I'm inspired to try and make my own.. Thanks!!

Izod517. (author)Olliegilbert2014-12-29

Thanks! I have no plans to sell as emulation is a murky area in many places, and more importantly the code that drives the heavy lifting it is not mine.

seamster (author)2014-12-29

Excellent project!

I love seeing people jump in and learn new skills, like you did with the soldering iron. There are so many great resources out there to learn from, so there's really no excuse not to try new things. Awesome work!