Build a rhythm game lesson plan
A rhythm game in three builds: notes that fall in time, buttons that judge your timing, then the whole game with combos and a high score.
Objectives and materials
By the end, students can
- Make notes fall to a song, judge a press to the millisecond, then play the whole game.
Materials for the whole unit
- Addressable RGB LEDs
- Arduino Uno R3
- Character LCD with I2C backpack
- Half breadboard
- LED arcade button x 4
- Piezo speaker
- Resistor
Every part is already on the simulator’s bench, so there is nothing to buy or hand out. The counts are the most any one lesson uses, if you build it on real breadboards too.
Lanes, buttons, game
Make notes fall to a song, judge a press to the millisecond, then play the whole game.
| Lesson | Time | What students do |
|---|---|---|
| Make the notes fallA 16 x 8 WS2812 panel becomes four lanes of falling notes, timed so each one lands on the bottom row exactly as the piezo plays it. | 55 min |
|
| Hit the beatFour lit arcade buttons and a 16x2 LCD: press on the click and see perfect, good or miss, measured to the millisecond. | 45 min |
|
| Play the rhythm gameFalling notes, lit buttons, timing windows, combos, a score on the LCD, a song on the piezo and a best score that EEPROM keeps. | 80 min |
|
Materials
- Addressable RGB LEDs
- Arduino Uno R3
- Character LCD with I2C backpack
- Half breadboard
- LED arcade button x 4
- Piezo speaker
- Resistor
Check for understanding
Each student finishes "Play the rhythm game" on their own, without opening the hints. The simulator checks 7 of its 7 steps as they go.
Then ask each one to explain, in a sentence or two, the last thing it asked of them: "Best score".
Teach this unit as a class
Start a class from this course and its 3 lessons are assigned in one go, in order. Students join with a six-character code or printed login cards, and each one’s work comes back to you.
The class tools are free for 30 days for one class of up to 20 students, with no card. The lessons themselves are free either way.