Skip to main content
Version: ACS CC

PicoSudoku

A microcontroller-powered Sudoku game, designed for the Raspberry Pi Pico 2

info

Author: Ionescu Mihai-Cosmin
GitHub Project Link: https://github.com/UPB-PMRust-Students/proiect-COSSS02

Description

This project aims to provide a simple and engaging way to play the classic logic game Sudoku, featuring three difficulty levels. The game grid is displayed on an LCD screen connected to a Raspberry Pi Pico 2 microcontroller. The user can interact with the game using intuitive hardware controls: a joystick for navigating between cells and a keypad for number input. The system includes input validation to ensure correct moves.

Motivation

This project combines my passion for logic puzzles with the challenge of creating a clean, self-contained implementation. Sudoku's structured nature makes it an ideal candidate for an embedded environment project.

Architecture

Diagram

Hardware

The project uses four main hardware components: a Raspberry Pi Pico 2 as the microcontroller, a 2.8-inch ST7789 SPI TFT LCD to display the Sudoku grid, a 3x4 matrix keypad for number input, and a dual-axis XY joystick for navigating between cells.

Bill of Materials

DeviceUsagePrice
Raspberry Pi Pico 2The microcontroller42 RON
2.8 Inch ST7789 LCDThe display38 RON
3X4 Matrix Switch KeypadThe keypad12 RON
Dual-axis XY Joystick ModuleThe joystick8 RON

Software

LibraryDescriptionUsage
embassy-rpRaspberry Pi Pico HALGPIO, SPI, ADC setup
embassy-syncSynchronization primitivesMutex for SPI bus
embassy-timeTime handling mechanismsMeasure Game Runtime
mipidsiCrate for generic display driversDisplay driver for ST7789
embedded-graphics2D graphics libraryDrawing primitives to the display