This is the Code for an Arduino based video game, originally designed by Kris Temmerman (@neuroprod).
See this blog post for details of the original implementation: http://www.neuroproductions.be/arduino/arduino-video-game/
The game code can be run on an Arduino Due, using Cinder or using SDL on a Mac, Linux or Windows PC.
Prerequisites:
libraries
into your Arduino library folder (usually ~/Arduino/libraries
).PixelDisplayGame/PixelDisplayGame.ino
sketch in the Arduino IDEpixelGameController/pixelGameController.ino
sketch in the Arduino IDENow build the hardware as described here and enjoy the game!
TODO
Prerequisites:
Run build.sh
to compile everything. After that, start the binary build/PixelApp
.
Prerequisites:
Run build.sh
to compile everything. After that, start the binary build/PixelApp
.
The display is a 90x16 matrix of WS2812 RGB LEDs (16 strips, 90 LEDs each). The strips are connected in a "zigzag" configuration, that means the "DO" pad of one strip is connected to the "DI" pad of the next one. A single data line, connected to pin 2 of the Arduino, is sufficient to drive the whole display.
Power should be fed from both sides of each strip to avoid brightness falloff on one side. Depending on the brightness, the display can draw up to 60A at 5V, so a good power supply and thick cables should be used.
Each player has a 4-way arcade joystick and 3 buttons ("red", "yellow", "blue"), connected to Arduino pins 22 through 48 (see above diagram for the exact wiring). All buttons need a pulldown resistor.
The two Arduinos are connected using the "Serial3" serial port (pins 14 and 15). Make sure to swap RX and TX on one side.
The code is licensed under an MIT license, assets are licensed under Creative-Commons Attribution.