hugo-toha/content/posts/chess-robot/index.md
2025-01-09 15:18:54 -06:00

2.1 KiB

title date description hero author menu tags
Chess Robot 2022-06-08T09:00:00+00:00 Gantry style robot with a camera to play chess against a human player. images/chess.jpg
image
/images/sharwin_portrait.jpg
sidebar
name identifier weight
Chess Robot chess-robot 4
Python
OpenCV
Arduino
Stepper Motors

This robot utilized stepper motors, a camera, sensors, and a gantry style system to interact with the chess board and play against a human opponent.

System Hardware

The robot's frame was assembled using aluminum extrusion and 3D printed parts. 2 motors were used to drive the X-axis, and 1 motor was used to drive the Y-axis (horizontally).

Chess Robot Frame

In order to interact with the chess pieces and board, a gripper was developed to interface with each of the pieces' stem. The gripper assembly was mounted to a lead screw in order to raise and lower the gripper.

Chess Robot Gripper

Computer Vision

A standard USB camera was used to track the game state in real time. Our initial approach was to attempt to classify each piece on every square after breaking up the image by pixels for each square.

Since the beginning of a chess game is always the same and known to the computer, we can cheat a little bit with the computer vision in order to improve its performance. Instead of attempting to classify the piece, we only need to notice changes in the position compared to the previous position. For example if the squares e2 and e4 are marked as different from the starting position, we know that a white pawn started on e2 and has moved to e4.

Chess Robot Frame

Resetting the Board

Chess Robot Frame