Hand tools and fabrication machines
The Arcade Machine comes programmed with two games: Reflex Tester and Simon Says. To pick one, press one of the lit up buttons on boot up and the button will start blinking. Press the same button again to confirm game selection or leave alone to go back to main screen. In Reflex Tester, will randomly light up after a random period of time. Once pressed, the screen will display your reaction time in milliseconds and return to selection screen. In Simon Says, the buttons will light up in a pattern and you must repeat the pattern by pressing the buttons in the correct order. Points are added for consecutive correct button presses.
The Arcade Machine's main component is the PocketBeagle, which serves as the processor for this unit. It has female headers soldered to it to facilitate connections between the PocketBeagle, buttons, display and buzzer. The arcade buttons have two pairs of GPIO connections, one pair for receiving input through button presses and the other for turning on an LED. The display uses an i2c channel, and the buzzer a PWM.
Here's a picture of the Fritzing diagram for the Arcade Machine. The file can be downloaded at the bottom of the page.
it is important to note that although the arcade buttons hardware has both LED and button pins in the main case, Fritzing does not contain that symbol. The connections shown for the LEDs with the PocketBeage actually connect with these pins on the actual hardware.
The electronic hardware is encased by a laser cut wooden box designed to protect them while still remaining portable. The wood used was 0.200 in thick and the laser cutting machine had a kerf of 0.04. The Adobe Illustrator file is included in the files section below.
The code runs soon after connecting the device to power. There is a boot up sequence where the display initializes and a music scale plays while the buttons light up in sequence.
Main or Selection Screen
- Buttons 0 and 1* are lit up. Display shows only zeros.
- Press a button to choose a game. Button 0 selects Reflex Tester and the display shows 1. Button 1 selects Simon Says and displays 2.
- Press the button while blinking again to confirm selection. Otherwise in a few seconds it will return to the selection screen
- All LEDs will turn off
- After 3 to 10 seconds, a random button LED will turn on
- Press it as soon as you can to record your reaction time (in milliseconds), which will be displayed
- All buttons will blink 3 times, then return to main screen
- All LEDs will turn off
- After 0.5 seconds, one LED will turn on and a note will play for 0.5 seconds, then it will turn off
- Pressing the correct button will trigger the above event again, but with an extra button added to the sequence. Each correct input pattern adds a button.
- Points are added for consecutive correct button presses.
- My high score is 36. Can you beat it?
*Note: The original model has a damaged Button 1 (Red), so code was altered to pass its role to Button 2 (Blue) and ignore it.
- More games can be added
- More music can be coded into different buttons
- Box can be decorated or replaced with transparent acrylic
For the files' repository, check out my github