Skip to content

A chessboard with built in piece detection and Stockfish engine. From turning the pieces on a lathe, to soldering the components, to coding the Raspberry Pi. This is true full stack development.

License

Notifications You must be signed in to change notification settings

2kofawsome/full-stack-chessboard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python version License

full-stack-chessboard

Description

A chessboard with built in piece detection and Stockfish engine. From turning the pieces on a lathe, to soldering the components, to coding the Raspberry Pi. This is true full stack development.


This Project Includes:

A Wood Working component with turning the pieces and building the board

An Electrical Engineering component of wiring and soldering it together

A Software component with coding the logic of the board on a Raspberry Pi Zero

While I had more experience in some (Software) than others (Wood Working), each took a tremendous amount of time to accomplish the parts necessary for this project.

Now that's full stack


Circuitry

First created and tested on breadboards, final soldering was done in this layout (created using KiCAD): Schematics

With the boards (pre-soldering):

MCP23017s Pi Extender LEDbar - Front LEDbar - Back

In the general layout (pre-soldering, pre-wires):

Pieces and Layout Layout

And the layout of the reed switches was (pre-soldering):

Lid w/o Top Lid w/ Top

Piece and Board creation

Thank you to Paul (Grandpa) for buiding the board for me:

Board - Back Board - Shelf

And for building the pieces with me (first time on a lathe!):

Board - Overhead Board - Front

Pieces contain magnets for reed switches (top) and RFID chips for scanning (bottom):

Piece - Front Piece Magnet RFID Piece - Bottom

Python Modules

Take a look at the code for full details, but here is a brief overview of the modules I used/created for the project.

import string, time, os, datetime, sys, re
import RPi.GPIO as GPIO

I contributed to make this work in my project: Github

from stockfish import Stockfish

I built this to run the 74HC595 Github PyPI

import pi74HC595

Editied from: Github to run the LCD1602 display With accompanying Video

import lcddriver

Used to run the MFRC522 RFID reader: Github

from mfrc522 import SimpleMFRC522

Used to run the MCP23017s: Github

import board, busio
from adafruit_mcp230xx.mcp23017 import MCP23017

Engine

The engine ended up being a fair bit of effort to get working since the Python module Stockfish needed some changes to make it work how I wanted.

And the engine itself here: Stockfish Download

Compiled by running "sudo make -j4 profile-build ARCH=armv7 LDFLAGS="-latomic -lpthread -lgcov" on the source code

Components


Credits

License

MIT License. Please see License File for more information.

About

A chessboard with built in piece detection and Stockfish engine. From turning the pieces on a lathe, to soldering the components, to coding the Raspberry Pi. This is true full stack development.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages