Austin Goodnight

Robotics, Embedded

Autonomous Chess Board

A chess board that plays itself. A Raspberry Pi runs Stockfish and moves the pieces from underneath with an electromagnet on a custom XY gantry, routing them between occupied squares.

The assembled gantry on a table in sunlight: 3D-printed carriages on metal rods, NEMA 17 motors, and the electromagnet on the Y-axis carriage.

At a glance

  • Led a six-person team, designed the frame and XY gantry in Onshape, and wrote the path planning and game software.
  • An electromagnet under the board drags pieces along the lanes between squares, so moves never knock over neighbors.
  • Plays full games against a person or itself with Stockfish, for $192 against a $600 budget.

Overview

An autonomous chess board, built for GEEN 1400 in fall 2025. A Raspberry Pi runs the game in Python and moves the pieces itself: an electromagnet on an XY gantry beneath the board grabs each piece through the playing surface and drags it to its destination, with no visible mechanism. Moves come from the Stockfish engine, and the board plays full games against a person or runs engine-versus-engine games.

The board was designed as an assistive device for players with physical impairments as well as an automated opponent. The design goals were speed, a fully hidden mechanism, and a cost well below commercial alternatives: the target was under $600, and the finished build came in at $192.

I led the six-person team, made up mostly of first-year students. I designed the frame and gantry, and wrote the path planning and game code.

Motion system

I designed the frame and gantry from scratch in Onshape: a CNC-style XY stage built from 3D-printed parts running on metal rods and driven by belts and pulleys. Two NEMA 17 stepper motors drive the X axis together for extra torque and a third drives Y, all controlled directly from the Pi's GPIO with step and direction signals. The motors are microstepped to 3,200 steps per revolution, and every move starts and ends at a fixed home position, so piece positions are tracked open-loop from a known origin.

The electromagnet rides on the carriage and is switched by a transistor from a GPIO pin, turning on to pick up a piece and off to release it. Early on, the bare gantry was driven from a keyboard-control script to test motion before the game logic was connected.

Isometric CAD drawing of the gantry under a chessboard: two X-axis rods with sliders, a Y-axis rod with the magnet carriage, and the Y-axis motor carrier.
Gantry CAD in Onshape
A Raspberry Pi wired to three stepper driver boards on a breadboard, with a barrel-jack power input.
Raspberry Pi and stepper drivers
Early motion test

Collision-free paths

Dragging a piece in a straight line would knock over anything in its way, so pieces never travel through squares. Each move offsets half a square to reach the lanes between squares, travels along those lanes to the destination, and only then steps into the center of the target square. Pieces always pass through the gaps between their neighbors.

Captures

When a move is a capture, the captured piece is removed first. The gantry carries it along the same lanes to a storage area around the edge of the board, where each storage square holds two pieces in an edge slot and an inner slot. The attacking piece then makes its move as normal.

Game logic

The game state lives in python-chess, which validates moves and detects captures and the end of the game. Stockfish runs as a UCI engine with a half-second time limit per move, and each move it returns is translated from chess notation into gantry coordinates before being played on the physical board.

What was hard

The first frame wasn't strong enough, and it needed a lot of reinforcing before moves were reliable, which taught me to design for rigidity from the start rather than add it afterward.

The electromagnet took iteration too. It has to pull a piece firmly through the playing surface, so we tested several electromagnets before finding one with the right strength.

Project poster

The poster presented at the end of the course summarizes the requirements, design, budget and team process.

Project poster for the autonomous chess robot, covering the product pitch, approach, design goals, budget, CAD, tech overview, requirements and team growth.

Next project

Mono Watch

→