Overview
As part of my Principles of Integrated Engineering course, I worked with a team
to create an automatic chess board - a physical board where pieces
could move themselves, allowing a person to play against a chess AI in real life.
The board concealed an electromagnet mounted on a two-axis gantry system, controlled
by an Arduino. A laptop ran a Python-based chess AI and sent commands to the Arduino,
which moved magnetic pieces across the board. An array of hall effect sensors
detected when a human moved pieces manually, keeping the system synchronized.
While the system did not reach full gameplay, I successfully built the communication and control infrastructure that made autonomous chess piece movement possible.
My Contributions
I focused on building the control and communication system between
the Arduino and the Python chess controller. My work included:
-
Writing Arduino code
to parse commands, control stepper motors and the electromagnet,
and read hall effect sensors.
-
Designing a custom serial communication protocol that minimized data
transfer while still allowing fine-grained control of motors, sensors,
and electromagnet states.
-
Writing Python classes
to abstract hardware devices - from low-level
serial connection
to gantry/motor control.
With these abstractions, moving a piece became as simple as calling
move_to("A5"), while the system handled the motor updates
and sensor checks in the background.
Outcome
While we didn’t fully complete a playable chess match by the project deadline,
the communication system worked reliably and made integration with higher-level
chess logic straightforward. Once subsystems were ready, new piece movements
could be programmed with just a few lines of code, enabling rapid iteration.