Introduction: Notendo Gamebox

This is a portable handheld games console built with an Arduino and mounted into the cardboard box it came in. Thus the name - Gamebox.

Step 1: The History

A short while ago, I attended an Arduino tutorial at the London Perl Workshop. As part of the workshop, you get to keep the Arduino Ethernet board you had been experimenting with, and one 'major' component from the box. These major components included things like LCD displays, LEDs, motors, tilt switches, arcade buttons, and so on. My major component was a 16x2 alpha-numeric display. Wondering what to do with it, I decided to see what sort of game I could build with only one button and a 16x2 LCD.

The 'Arduino Runner' was that game. Source code from https://github.com/MarquisdeGeek/gamebox

However, I was triggering the 'jump' button by touching wires to resistors, which is not very rock and rock. Nor was the lack of case. So, when I got home, I decided to mount the Arduino in the cardboard box that the kit had arrived in. And added real buttons. And a speaker.

Step 2: Prototype Board

I start by building the circuit with jumpers and long cables because, at the workshop, this was all I had. It looked pretty awful. But it worked, and let me experiment. However, the mounting and the position of the LCD remain fixed. We use this as a positioning guide later on.

The circuit is identical to the one that comes with the LCD instructions!

All I added were the buttons, and the piezo, but I'm sure you can see that, already.

Step 3: Use Tight Wiring

Once I got the board home, I rewired it so all the wires were flat against the board. This is essential - NO wire should extend above the height of the green circuit board from the LCD. If it does, the LCD will not lie flat against the box casing.

Step 4: ​Prepare the Box

Begin by taking a look at your box. Mine had triple thickness card on one side, and double on the other. I therefore reasoned that I would place the ethernet port (which would be used more often) on the double-thickness side. I could have cut through the triple thickness for easy access to the serial port, but reasoned that this prototype would suffice as is.

a) Hole for the display

b) Holes for the buttons

Find a good place to mount the buttons. My criteria for 'good' are:

* In a position where it's comfortable to hold the box, and press both buttons

* In a position with (at least) double thickness card, so they don't move or fall inside the box

I found that a place near the corners was a good trade-off.

Since the buttons are large and circular you can either use a circular cutter (as I did for my MAME cabinet[0]) or poke lots of small holes in a circle, using a screwdriver, until the card between the holes weakens. I chose the latter. Because the buttons have a lip on them, you can push them quite snugly into ill-fitting holes, and the lip covers the workmanship. The buttons come with rather nice plastic backing mounts, too, which really hold the buttons in place.

They come with rather handy connectors, so insert two wires into them - one to +5v , the other to a pull-down resistor and an Arduino pin.

Note: Due to my board choice, a lot of Arduino pins are taken up with the Ethernet component. Consequently, one of the buttons is attached to an analogue pin. I dislike the long wires across the circuit board, so I chose to have 1 analog & 1 digital pins, rather than uniforming them both to analog.

[0] http://marquisdegeek.com/making_mame

Step 5: The Other Bits

Attach a speaker. Or, to be correct, a piezo buzzer. This is a simple affair, attached between analog pin 2 and ground, with its outer edge blu-tacked to the lid of the box. Use long wires on your piezo, if you have them, as it will stop the buzzer coming detached whenever you open the lid.

Then add a battery, so it can be self-contained. I didn't have an on/off switch to hand, but one could easily be added. I also soldered the wires of a battery holder to some pins, to ensure a good connection. You could also power it via the power cable, but then it wouldn't be hand held!

There is also a barrel jack to battery connector device available, which is available in most littleBits kits.

WARNING: The Vin socket comes after the power diode circuit, which means if the polarity is inverted at the Vin point you will most likely damaged your Arduino. If powering via the barrel jack then you're safe, since it is before the diode.

Step 6: The Other Bits (2)

LEGO! My go-to prototype tool of choice. This project used LEGO as a stand for the circuit since, when the LCD is visible without the window, its base is floating in mid-air, and reliant on the connection between LCD and cardboard. I simply measured the height of the box, subtracted the height of the circuit board, and built a LEGO platform that high. My board has tiny feet on it, so I had to leave a one brick gap at certain points on the base.

Fixing the laser cut surround is a precise job. My LCD came with the rather attractive laser-cut mount you can see in the picture. Because the ethernet socket is a little bit too high, the circuit board won't fit perfectly behind the card. Therefore, the surround won't perfectly clamp the LCD to the card. Instead, the bottom two pegs will hold it still, with the other two being mostly cosmetic.

The best way to affix the pegs is to take them apart and insert the inner tube first. This is a guide, and goes through the holes your bore out with a small screwdriver. Once the tube is in place, place the pin into the top. This will force the tube to splay apart, trapping the LCD and surround to the card.

Step 7: Final Steps

Software

The software can be loaded as normal, and downloaded from https://github.com/MarquisdeGeek/gamebox

Change the IP address, if necessary, or omit this section entirely with the #define at the top of the source.

Future versions of the code will include a selection of different games, and a menu. In fact, depending on when you're reading this guide, that code might already be available!

Hardware

Attach the battery, close the lid, put a fancy label on the front, and start playing!

Video

http://youtu.be/HIUWMhp4MzU