Brick Break Game
This is a simple brick break game that uses images from the SD card and loads them on the uLCD. The input devices to control the game is the potentiometer (to control the player) and the joystick to control other game functoins.
Schematic
uLCD and SD card
mbed | uLCD Header | uLCD Cable |
---|---|---|
5V=VU | 5V | 5V |
Gnd | Gnd | Gnd |
TX=p9 | RX | TX |
RX=p10 | TX | RX |
p11 | Reset | Reset |
Potentiometer
mbed | Potentiometer |
---|---|
gnd | - |
VCC | + |
p20 | Input |
Sparkfun 5-Way Tactile Switch Breakout
mbed | Breakout Board |
---|---|
gnd | - |
VCC | + |
p14 | C |
p13 | R |
p12 | L |
Setup
Gameplay Example
Press Fire on the Sparkfun breakout board to start the game. Use the potentiometer to control the player. If a ball gets stuck in the same pattern, toggle the Sparkfun board left or right to change the trajectory.
Code
Import programBrickBreak
Lab 4 Project
Please log in to post comments.