Source: https://mokxi.com/teachers/plans/build-handheld-rpg
Updated: 2026-11-19

Lesson plan

# Build a handheld RPG lesson plan

Make a role playing game for a handheld you wire yourself: a tile map, a hero, dialogue, turn based battles, saves, music and a quest.

3 chapters, 7 lessons, about 7 hours, on the Arduino Uno R3. Every lesson runs in the browser, with nothing to install.

Start a class from this course

The unit

## Objectives and materials

### By the end, students can

- A map of characters in flash, and someone to walk it.
- Words in flash, flags that open doors, and turns that decide fights.
- Saves that survive a reset, a score, and the whole quest.

### Materials for the whole unit

- Arduino Uno R3
- Full-size breadboard
- Piezo speaker
- TFT display, 240x320
- Thumb stick

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.

Chapter 1. About 1 h 50 min

## A world and a hero

A map of characters in flash, and someone to walk it.

Lesson | Time | What students do

Tile maps Draw a whole world from ten lines of characters in flash, paint it on a color TFT a tile at a time, and look up any tile under a frame you steer. | 55 min

- A world in characters
- Paint time
- Look up a tile
- Steer the frame
- Solid ground

A hero Put Wren on the map and walk her a tile at a time: collisions from the map, a facing direction, and only the two tiles that change repainted. | 55 min

- Meet Wren
- Walk
- Bump
- Over the bridge
- The river

### Materials

- Arduino Uno R3
- Full-size breadboard
- Piezo speaker
- TFT display, 240x320
- Thumb stick

### Check for understanding

Each student finishes "A hero" on their own, without opening the hints. The simulator checks 5 of its 5 steps as they go.

Then ask each one to explain, in a sentence or two, the last thing it asked of them: "The river".

Chapter 2. About 2 h 10 min

## Story and battles

Words in flash, flags that open doors, and turns that decide fights.

Lesson | Time | What students do

Dialogue Give the elder a voice: lines kept in flash, typed into the panel a word at a time with word wrap, a press to go on, and a story flag that changes the world. | 65 min

- The narrator
- Face the elder
- Talk
- The lantern
- Too dark
- Into the cave

Battles Turn based battles: encounters in tall grass, a three item menu on the stick, a damage formula with a dice roll, experience, level ups and a boss. | 65 min

- Into the grass
- Fight
- Victory
- Level up
- The Fog Warden
- Run away

### Materials

- Arduino Uno R3
- Full-size breadboard
- Piezo speaker
- TFT display, 240x320
- Thumb stick

### Check for understanding

Each student finishes "Battles" on their own, without opening the hints. The simulator checks 6 of its 6 steps as they go.

Then ask each one to explain, in a sentence or two, the last thing it asked of them: "Run away".

Chapter 3. About 2 h 55 min

## Finish the game

Saves that survive a reset, a score, and the whole quest.

Lesson | Time | What students do

Save games Save the whole hero to the Uno EEPROM at the ember stone, with a magic number, a version and a checksum, and load it again after a reset. | 55 min

- A new game
- The ember stone
- Eighteen bytes
- Press reset
- Why not save every step?

Music Score the game on a piezo: a world theme, a battle loop and a victory jingle, stored as notes in flash and played with tone() while the game keeps running. | 55 min

- The theme
- Up an octave and a bit
- The game never waits
- Battle music
- The victory jingle

Project: a short quest Play Emberfold from start to finish: the elder, the meadow, the Fog Warden and the ending, then make the world your own and share it. | 65 min

- Begin
- The lantern
- The meadow
- The Fog Warden
- The end
- Make it yours

### Materials

- Arduino Uno R3
- Full-size breadboard
- Piezo speaker
- TFT display, 240x320
- Thumb stick

### Check for understanding

Each student finishes "Project: a short quest" on their own, without opening the hints. The simulator checks 6 of its 6 steps as they go.

Then ask each one to explain, in a sentence or two, the last thing it asked of them: "Make it yours".

Your class

## Teach this unit as a class

Start a class from this course and its 7 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.

Start a class from this course See the demo class

More units

## Other lesson plans

Electronics basics 20 lessons, about 10 h. Embedded on the Arduino Uno 16 lessons, about 12 h. Embedded on the ESP32-C3 13 lessons, about 11 h. Embedded on the Raspberry Pi Pico 7 lessons, about 6 h. Build your own fight stick 5 lessons, about 4 h. Embedded on the STM32F411 6 lessons, about 6 h. C++ on a board 13 lessons, about 10 h. Digital logic and memory 4 lessons, about 4 h. Interactive devices on the Uno 9 lessons, about 8 h. From gates to a computer 23 lessons, about 16 h. Build a claw machine 8 lessons, about 6 h. Every unit All the courses as ready-made units, on the teachers page.
