Reaction Time
This is a game designed to test reaction speed between two players. It uses a pushbutton as one controller, and a phone paired through bluetooth as the other controller. The results are then displayed over serial.
These are the parts that were used:
- microSD Transflash Breakout
- Speaker
- SparkFun Mono Audio Amp Breakout - TPA2005D1
- Pushbutton
- Adafruit Bluefruit LE UART Friend
- iOS/Andriod Phone with Bluefruit application
Wiring
microSD Transflash Breakout
mbed | Breakout |
---|---|
p8 | CS |
p5 | DI |
Vout | Vcc |
p7 | SCK |
GND | GND |
p6 | DO |
Mono Audio Amp Breakout
mbed | TPA2005D1 | Speaker |
---|---|---|
gnd | pwr - (gnd), in - | |
Vout (3.3V) or 5V | pwr + | |
p26 (PWM) | in + | |
out + | + | |
out - | - | |
Any DigitalOut px(optional) | S (low for shutdown) |
Adafruit Bluefruit LE UART Friend
mbed | =Adafruit BLE |
---|---|
gnd | gnd |
VU(5v) | Vin |
nc | RTS |
Gnd | CTS |
p27 (Serial RX) | TXO |
p28 (Serial TX) | RXI |
PushButton
mbed | Button |
---|---|
GND | - |
p14 | + |
Breadboard with a finished game shown on mbed LEDs.
Code for Game
Import programReactionGame
A game testing reaction time between two people using a pushbutton as one controller and a phone connected with bluetooth as the other.
Please log in to post comments.