Arcade Control Board

I’ve finally got round to posting about the raspberry pi arcade.   I’ve build an ATMega based board to convert all the controls to SPI for the raspberry pi, modded the ada-friut retro arcade library to use the SPI based control inputs and etched a PCB for the control board.

I home etched the PCB using the toner transfer method which I find to be a bit of a pain to get a decent result.  The best way I’ve found is to print on magazine paper, then iron on for 5 minutes and finally run through a laminator four or five times.  Here is the result:-



The board does a few thing.   It has 2 9-Pin D connectors for the player 1 and player 2 controls.   The layout is the same as an old atari joystick (in theory you could plug in old Atari comparable joysticks).   The unused pins on the D connector are used for the extra buttons and the player 1/2 buttons.  The joystick axis connect to analogue inputs on the ATMega to save a few pins.  There is also an input for a coin mech to add credits, at the coin mech requires 12v the board requires a 12v and 5v supply.   The 5v supply goes thorough a regulator so that the board runs at 3.3V (8Mhz) this removes the need for logic level conversion between the board and PI.

The above pictured board had a few issues (it also had a zener for the coin op mech which has been removed).   I put a few jumper wires on the bottom to correct the issues, most of which were due to eagle not connecting nodes so I should probably pay more attention to the ERC check.  An updated design is checked int github at  Here is the populated board connected up:-


The other thing I’ve done is sprayed the cabinet black, added the coin mech and stated to put on the plexi glass:-


Only a couple of more things to finish (bevel and marquee) so will post later in the week with the finished result!



Arcade Controls

The Raspberry Pi arcade now has controls!


The controls have been connected to an Arduino which then uses SPI to connect to the Raspberry Pi.   The following hardware design was used:-


Its important to use a logic level converter for the 5v to 3.3v conversion.

After hunting around for good ways to simulate key presses on the Pi I stumbled across the Adafruit retrogame code which uses GPIO as inputs.   I’ve forked this on github and changed it to request the state of the buttons over SPI and update the presses.  It currently polls and doesn’t seem to be using much CPU, although it would be possible to use a separate GPIO pin to tell the Pi that there is a change in state.   The code is available at   This also includes the Arduino code to connect the inputs too.

The SPI protocol basically send an 0xFF command to the Arduino which returns 3 byte, which are P1 status,P2 Status and Aux Status.   The Aux status is used for P1/P2 button and the coin mech.

I’m currently building an input board to replace the Arduino which is basically the ATMega broken out with some connector for P1/P2 and aux.   I’ll publish this at the end of the week.

I also added some audio amplifier and speaker this week.  There is still a bit to do on this project such as getting some artwork printed, painting the cabinet and fixing up the monitor mounts!