Archery Game
Embedded game built on the AK Embedded Base Kit (STM32L151) — a hands-on project to learn event-driven programming through game design.
Overview
| Platform | AK Embedded Base Kit — STM32L151CBT6 |
| Display | 1.54” OLED LCD |
| Input | 3 push buttons |
| Audio | 1 buzzer |
| Flash | 128 KB (8 KB bootloader + 116 KB app) |
| RAM | 16 KB |
| Source | github.com/QuocBuu/archery_game |
Hardware
AK Embedded Base Kit — STM32L151 v3.0
Board view — Top & Bottom
Gameplay
Objective: Control the Archery (bow) to shoot Arrows and destroy incoming Meteoroids before they hit the Border.
| Button | Action |
|---|---|
| [Up] | Move archery up |
| [Down] | Move archery down |
| [Mode] | Shoot arrow |
Scoring: +10 points per Meteoroid destroyed. Speed increases every 200 points.
Gameplay screen and objects
Game Over screen — rating from the Mafia Dolphin
Architecture
The game is built on an event-driven kernel (AK Framework) using Tasks, Signals, Timers, and State-machines. UML is used to design each game object's behavior before implementation.
Basic game sequence logic
Programming view
Links
What I Learned
- Designing game objects with UML (sequence diagrams, state machines)
- Event-driven programming on a resource-constrained MCU (16 KB RAM)
- Bitmap rendering on an OLED over I2C
- EEPROM storage for persistent scores and settings
- Bootloader + application flash partition layout