RGB LED matching
Overview
For our project we used a randomly generated pattern that is output in the forms of colors on the RGB LED. The user matches this pattern and, if correct, the pattern increases by one in length. If the user beats the high score they will be prompted to input their initials for the high score screen.
Components
- mbed
- uLCD
- RGB LED
- 3 Pushbuttons
uLCD | Mbed | |
tx | p9 | |
rx | p10 | |
res | p11 | |
3.3v | Vout | |
gnd | gnd |
Push Button | Mbed | |
PB1 | p21 | |
PB2 | p22 | |
PB3 | p23 |
RGB LED | Mbed | |
Red | p18 | |
Green | p19 | |
Blue | p20 |
Program
Import programPatternMatching
Uses a randomly generated pattern that is output in the forms of colors on the RGB LED. The user matches this pattern and, if correct, the pattern increases by one in length. If the user beats the high score they will be prompted to input their initials for the high score screen.
Please log in to post comments.