Sunday, March 3, 2013

Building an Arcade Cabinet


Building a Cabinet

So for my office I spent some time working a new project, related to gaming. I built a fully functional arcade cabinet using Raspberry Pi as the base.

The goal wasn't to try and fleece my co-workers (that's just a side benefit) but instead to show it could be done. Furthermore, all the collected funds will go to a local charity in December.

Selecting a Game

This turned out to be harder than I thought. Upon doing some research I found that I could not use Mame for anything that required money. Even if I could there's the whole legal issue of running a ROM, which I didn't want to deal with. Instead I went with a nice Asteroids clone I remember from the 90's. I use to play this on my Mac. Of course I'm talking about the classic, Maelstrom.

As it turns out, right before the turn of the millennium, the entire code base was open sourced. I got to finally see into the game which tormented me for so long. What I found frankly amazed me. Beautifully structured code with easy to understand names and flow. I hacked in support for credit processing as well as some audio changes and I was good to go.

Hardware

So I had my Raspberry Pi going and had a donated monitor. But this was a far cry from what I wanted to have done. I started searching Craigslist every day looking, and then I found it. It was a little abused, mangled, and left to rot in the corner.  For $50 it was mine.

The image to the left shows the sad state things were in.  Apparently a kid had been playing as the insides contained goldfish, crumbs and other unmentionables.

But it gets worse, the wiring was a fire hazard. Three prong outlets supplied by two prong plugs. Cords held together by good intentions and twisted wires. It all had to go. I ripped everything out that night. I was left with the bare wood.

The Build

So I started off by laying down a shelf I had obtained from a hardware store weeks before. It fit like a glove. I immediately started to build up the play area, add in the Plexiglass and so on. The entire thing came together quickly and easily.
This project was just meant to be.
And then, disaster struck. I had my buttons and everything ready to order from Spark Fun, but couldn't get my hands on a coin acceptor. I waited for weeks.  Nothing.  Finallyit came in. They had to replace the 2 coin with a 3 coin version. I was good to go.

The Keyboard

But wait I hear you say, how did you make the buttons work? It couldn't be magic!

Well you're right and wrong. I found something magical, the PSoC3Pim board. Taking this board and coupling it with an app note, I was able to get up and running in about 20 minutes. If that isn't magic, I don't know what is.

In the Gutter

I still had a problem, the coins dropped on one side, but I wanted them on the other so I could access them via a small door and combo lock.  I was thinking about the problem, explained it to my wife and she suggested I use a gutter.  After some work, it is flawless.  Coins drop down and show up in the bucket at the bottom.

I've set the prices such that 10 cents is a credit, and a quarter will buy you three credits.  Everything is set up for Monday, I cant wait to see it in action.
 
Real Time Web Analytics