Skip to main content
Version: ACS CC

Wordle

A Rust-based embedded implementation of the popular word-guessing game.

Author: Suliman Edis
GitHub Project Link:https://github.com/UPB-PMRust-Students/proiect-Edis9955 :::

Description

The project replicates the popular Wordle game developed by the New York Times, implemented using Rust on embedded hardware. Players must guess a secret 5-letter English word in 6 tries, receiving feedback on each guess through color-coded hints:

Green: Correct letter in the correct position

Yellow: Correct letter in the wrong position

Gray: Letter not in the word

Motivation

This project is a nice first dip into the world of embedded systems. Wordle is a simple but engaging game, making it a great candidate to explore user interaction on low-power hardware while familirizing myself with Rust in an embedded environment.

Architecture

The core components of the project architecture include:

Game Engine (Rust): Handles word selection, guess evaluation, and game logic.

Input Handler: Receives user input from a connected keypad.

Display Driver: Outputs the game state on an LCD using color indicators. Architecture Overview:

[Keypad/Touch Input] ---> [Input Handler] | v [Game Logic Engine] | v [Display (ILI9341)]

Log

Week 5 - 11 May

hardware acquisition debugger wiring and testing display wiring keypad wiring kicad schematic start implementing game loop in terminal

Week 4 - 10 May

finish game loop in terminal correct display wiring display dummy test start using the display in the game loop

Week 11 - 18 May

show cursor on screen show green/tellow feedback on screen show attempts on screen win/lose screen

=======

Week 12 - 18 May

Week 19 - 25 May

Hardware

The project is built on a Raspberry Pi Pico platform with peripheral components for input, output, and storage. The display provides visual feedback while the keypad serves as the main input method.

Schematics

KiCAD Schematic

lose_screen  game_screen  lose_screen

Bill of Materials

astatura matriceala 4x4

DeviceUsagePrice
2 x Raspberry Pi Pico 2WThe microcontroller79 RON
Raspberry Pi Ecran LCD ILI9341Display67 RON
Breadboard2 x Breadboard7 RON
4x4 input keypadkeypad7 RON
wires wires for breadboard8 RON
mother-father wireswires for display RON
usb cablecable7 RON

Software

LibraryDescriptionUsage
st7789Display driver for ST7789Used for the display for the Pico Explorer Base
embedded-graphics2D graphics libraryUsed for drawing to the display
randRandom number generationRandom word selection
coloredTerminal color outputColor-coding of letters
display_interface_spiInteface for displayusing the display
  1. New York Times Wordle
  2. ILI9341 Driver Resources
  3. Raspberry Pi Pico Documentation