Skip to content

Repository files navigation

Gridopoly

A modular electronic board game platform with smart tiles, player control screens, physical pieces, and a Raspberry Pi authority server.

Chinese · Gallery · Status · Quickstart · Docs · Raspberry Pi server

Status Tile MCU Authority Player console Bus

Project Gallery

Gridopoly smart tile PCB design
Smart tile PCB. ESP32-S3, display, RFID, RS485, 24 V power distribution, current sensing, and edge contacts in one rearrangeable grid module.
Gridopoly player control screen design
Player control screen. Round 480x480 player terminal for turn actions, cash, assets, dice, trade, and game prompts.
Gridopoly physical smart tile module
Physical tile module. A real smart tile assembly with screen, USB-C, side contacts, LEDs, and board-level bring-up hardware.
Raspberry Pi 5 used as the Gridopoly game authority server
Raspberry Pi authority. The central game server for rules, accounts, board state, web UI, player synchronization, and persistence.

Why This Exists

Gridopoly explores what a physical board game can become when the board itself is programmable. Instead of a fixed printed board, the system is built from independent smart tiles that can display their own state, detect pieces, animate LEDs, and communicate with a central authority.

The goal is not to copy the brand, map, art, cards, or product appearance of any existing commercial board game. Gridopoly keeps the social feeling of moving pieces around a real table, while replacing paper money, manual rent calculation, and fixed board content with software-controlled rules, assets, player screens, and dynamic maps.

Current Status

Gridopoly has moved beyond an early single-tile concept. Most major software and interaction subsystems are now implemented or integrated in the repository:

  • Raspberry Pi 5 authority server linked to the shared C++ game core and protocol stack.
  • Web board/testing UI with map assets, owner badges, robot players, game creation, and forced-roll debugging.
  • Authenticated Wi-Fi/UDP player-console protocol with HMAC sessions, replay protection, heartbeat, resync, and player detail queries.
  • Player console UI specification for a 2.1 inch 480x480 round screen, including dice, assets, players, trades, payments, auctions, cards, debt, and reconnect flows.
  • Bidirectional trade protocol with request/response flows, revisions, idempotency, counter-offers, robot responses, and atomic settlement.
  • Persistent game state, room identity, device-to-seat binding, avatar setup, name setup, countdown, and final avatar publishing.
  • Hardware baseline for smart tiles: ESP32-S3, ST7789, WS2812, HTRC110 RFID, RS485, ORDER chain, INA226 current sensing, 24 V bus, USB-C debug power, and 6-layer PCB design.
  • Mechanical player-console stand assets and verification scripts.

Tile V0.32 uses Wi-Fi/HTTP and physical ORDER beacons. Two-board order discovery, reassignment from either manual anchor, and preserving additional manual assignments have been verified on hardware. RS485 is reserved hardware and has not been enabled. The repository includes 36 web tile images, 36 player-screen RGB565 tile images, and 30 avatar components.

As of September 22, 2026, the board variants are the long PCB2_1 and corner PCB2_5. The corner uses direct regulated 24 V input with a center-positive 5.5 x 2.1 mm connector; a 24 V / 5 A adapter is recommended. USB-PD and its NVM configuration have been cancelled. Both boards retain TPS26621 branch protection and LMR16030SDDAR conversion. The 60 W board-wide target and roughly 1 W per-module budget require physical verification; the adapter's 120 W rating is not a PCB rating.

Remaining work includes final PCB routing and DRC, mechanical fit and ORDER/A/B data-chain endpoints, multi-board power and thermal validation, and full playtesting. Player-screen flicker/shift validation remains open, and the current core1 build's Retarget timing still exceeds its acceptance limit. See the current handoff and hardware report for evidence and scope.

System Architecture

flowchart TB
    Pi["Raspberry Pi 5 authority<br/>rules, turns, accounts, persistence"]
    Web["Web board / test UI"]
    Console["Player round screens<br/>Wi-Fi/UDP actions + snapshots"]
    Bus["24 V + ORDER; RS485 reserved"]
    TileA["Smart tile A<br/>ESP32-S3 / LCD / LED / RFID"]
    TileB["Smart tile B"]
    TileN["Smart tile N"]
    Piece["Physical pieces<br/>125 kHz RFID tags"]

    Pi <--> Web
    Pi <-->|"WPA2 / HMAC UDP / HTTP assets"| Console
    Power["24 V DC input"] --> Bus
    Pi <-->|"Wi-Fi / HTTP"| TileA
    Bus --> TileA
    TileA --> TileB
    TileB --> TileN
    Piece -. placed on .-> TileA
Loading

Core Features

  • Rearrangeable smart tiles: each grid module can be manufactured, tested, replaced, and rearranged independently.
  • Physical-piece sensing: each tile is designed around 125 kHz RFID detection for tagged game pieces.
  • Dynamic tile display: ST7789 screens and WS2812 LEDs show ownership, events, status, and feedback.
  • Central game authority: a Raspberry Pi owns the rules, turns, cash, assets, trades, auctions, debts, and persistence.
  • Player terminals: round screens give each player their own cash, assets, dice, trade, payment, and reconnect interface.
  • Original Grid City content: the repo includes board maps, visual systems, tile assets, avatars, contracts, and game rules.
  • Protocol-first design: C++ core, binary protocol, UDP envelope, HTTP assets, and generated contracts are tested as first-class artifacts.

Tech Stack

Layer Technology Purpose
Tile hardware ESP32-S3, ST7789, WS2812, HTRC110, RS485, INA226 Local display, lighting, RFID sensing, Wi-Fi/HTTP communication, reserved RS485, current monitoring.
Player console ESP32-S3, 480x480 round LCD, LVGL-oriented UI specs, Wi-Fi/UDP Per-player controls, snapshots, actions, reconnect, and UI workflows.
Authority server Raspberry Pi 5, C++17, systemd Rules, persistence, HTTP board UI, UDP player sessions, and deployment.
Game core C++ libraries Board catalog, game engine, protocol codec, state machine, trades, auctions, cards, and bots.
Assets/contracts JSON schemas, generated docs, PNG/RGB565/GAVC assets Stable game content, tile art, avatars, and protocol contracts.
Hardware design EasyEDA project snapshots, 6-layer PCB baseline Smart tile PCB design, BOM, power, bus, and connector documentation.

Quickstart

Build and run the host-side C++ tests:

cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
cmake --build build
ctest --test-dir build --output-on-failure

Build and test the Raspberry Pi server using the native guard script:

GRIDOPOLY_NATIVE_BUILD_DIR=/tmp/gridopoly-build \
  Server/RaspberryPi/tools/build-and-test-native.sh

Deploy on Raspberry Pi after building the server binary:

sudo sh Server/RaspberryPi/deploy/install.sh build-pi/gridopoly_server
sudoedit /etc/gridopoly/server.env
sudoedit /etc/gridopoly/ap.env
sudo systemctl enable --now gridopoly-ap gridopoly-dnsmasq gridopoly-ap-watchdog gridopoly

Player network endpoints after deployment:

  • Web board on the player AP: http://10.42.0.1/
  • Player binary protocol: UDP 10.42.0.1:4242

Documentation Map

Start here when working on a specific area:

Repository Layout

Gridopoly/
|-- Assets/                  Grid City tile art, avatars, manifests, and generated assets
|-- Docs/                    Product, hardware, firmware, game, player-console, and design docs
|-- Firmware/                ESP32 test server, shared core/protocol libraries, LVGL baseline
|-- GameData/                Schemas, generated contracts, and game data artifacts
|-- Mechanical/              Player console stand models, scripts, tests, and reports
|-- PCB Files/               EasyEDA project snapshots and PCB backups
|-- Server/RaspberryPi/      Formal authority server, deploy scripts, web/UDP services
|-- Tools/                   Contract generation tools and tests
|-- tests/host/              Host C++ tests for core, protocol, authority, UDP, HTTP, avatars
`-- CMakeLists.txt

Safety And Release Notes

Gridopoly is an integrated prototype, not a manufacturing release. Before treating a board revision as production-ready, the project still needs final DRC, no-unrouted checks, component orientation review, switching-regulator layout review, current-path calculations, RFID tuning, and measured multi-module testing.

No open-source license has been selected yet. Public code and design files are available for inspection, but they are not automatically licensed for reuse, modification, or commercial use.

About

Modular electronic board game platform with smart tiles, player round screens, RFID pieces, and a Raspberry Pi authority server.

Topics

Resources

Stars

30 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages