0% found this document useful (0 votes)
41 views15 pages

Building A Chess Playing Machine Part0

This document describes the progress made on building a chess playing machine (CPM) that can move chess pieces on a physical board in response to human or computer moves. It discusses the system components like the computer, controller card, stepper motors, and chess board sensor matrix. It also outlines next steps to complete the project like assembling detection circuitry and solving issues with jumping pieces and captured pieces.

Uploaded by

Luis Migliorero
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views15 pages

Building A Chess Playing Machine Part0

This document describes the progress made on building a chess playing machine (CPM) that can move chess pieces on a physical board in response to human or computer moves. It discusses the system components like the computer, controller card, stepper motors, and chess board sensor matrix. It also outlines next steps to complete the project like assembling detection circuitry and solving issues with jumping pieces and captured pieces.

Uploaded by

Luis Migliorero
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

Building a Chess Playing Ma hine

Part 0

Joe Coand
Department of Computer S ien e
Boise State University

Abstra t
The hess playing ma hine (CPM) is an exer ise in omputer automation as well as an attempt to give one advantage
ba k to the human player by putting the game on a physi al hess board. This proje t is basi ally a roboti extension to
a personal omputer running the GNU Chess program. The omputer is then able to dete t a human move and respond
by me hani ally moving a hess pie e.

This olloquium will des ribe the progress already made on the CPM and plans for its ompletion. Subtopi s will in-
lude information on making ir uit boards at home, working with stepper motors, and some of the diÆ ulties of linear
motion. The urrent apabilities and de ien ies of the proje t will be demonstrated.

Proje t home page: http://shiva.rootuser.net/CPM


Building a Chess Playing Ma hine 1

System Overview

Computer Computer

Java Chess Client Java Chess Client

CPM Electronics

GNU Chess Limit Sensors Controller Card

Dual Stepper Motor Chess Board


Electromagnet
Controller Card Matrix

Stepper Motor 0 Stepper Motor 1


Building a Chess Playing Ma hine 2

Basi Fun tionality (Movement)

 Java Client re eives a move from the opponent.


 The move is onverted into a list of one or more hess pie e movements whi h are sent
to the mi ro ontroller.
 The mi ro ontroller translates the hess pie e movements into sequen es of motor steps,
dire tions and magnet operations.
Building a Chess Playing Ma hine 3

Basi Fun tionality (Dete tion)

 Ea h hess pie e has a magnet on the bottom.


 The plexi-glass board ontains an embedded matrix of Hal-e e t sensors.
 While a motor movement is not being exe uted the mi ro ontroller s ans the matrix of
Hal-e e t sensors. A representation of the state of the hess board is kept in memory
and is ompared with new s an results.
 Upon dete ting a hange in the hess boards state a message is sent to the Java Chess
Client.
 Java Chess Client onverts board hanges into hess moves and sends the results to the
opponent.
Building a Chess Playing Ma hine 4

Dual Stepper Motor Controller

 Outputs: Two 5 line unipolar stepper motor ports.


 Inputs:
{ Enable (low)
{ Two motor dire tion lines
{ Two step lines
Power:
{ 24v Motor Supply
{ 5v Logi Supply
Fun tionality:
{ Isolates logi ir uitry from stepper motors.
{ When enabled pulsing a step line high then low auses the orresponding motor to
turn one step.
{ Both motors an be operated simultaneously.
Building a Chess Playing Ma hine 5

Controller Card

 Atmel AT90S2313 AVR Risk Mi ro ontroller


{ Up to 10 MIPS at 10MHz
{ 128 Bytes of SRAM
{ 2K Bytes of Flash Memory
{ 2K Bytes of EPROM
{ On board UART (Serial port interfa e)
{ 8 and 16-bit timers
{ 15 programmable I/O lines
 82C55A I/O Expander - Nets 12 more I/O lines.
 RS232 driver/re eiver
Building a Chess Playing Ma hine 6

Chess Board Matrix

 12 x 8 = 96 matrix of Hal-e e t sensors


 The extra 32 squares, 16 on ea h side of the board, are for storing aptured pie es. At
the nish of a game the CPM an then reset the board.
 There is no way for the mi ro ontroller to dete t whi h pie e is whi h, so only one pie e
may be removed from the board at a time.
 A 16-bit demultiplexer sele ts one of the 12 olumns. The outputs from ea h of the
eight rows then indi ate whi h squares on the sele ted olumn are o upied.
 By s anning the matrix 100's of times per se ond dete tion appears instant.
Building a Chess Playing Ma hine 7

Java Chess Client

 Operates in one of three modes.


{ Chess Board - Client an onne t into a hess server, nd an opponent, and play a
game.
{ GNU Chess Bot - Conne ts to a server and a epts all hallenges, using GNU Chess
to de ide moves.
{ CPM Interfa e - Conne ts CPM into a hess server allowing network or lo al play.
 Uses Java RMI (Remote Method Invo ation) to ommuni ate with the hess server.
 If two CPMs are ever built they ould play ea h other from any where in the world using
this software.
Building a Chess Playing Ma hine 8

Mis .

 Limit Sensors - These two sensors enable the mi ro ontroller to nd position (0,0) on
the XY-Table.
 Ele tromagnet - Swit hed on and o by relay.
 Power Supply - Provides 5v (logi ), 20v (stepper motor), and 50v (ele tromagnet).
Building a Chess Playing Ma hine 9

To Do

 Assemble dete tion ir uitry.


 Print, et h, drill, and solder ontroller board.
 Write dete tion ode.
 Solve jumping knight and aptured pie e problem.
 Fix magneti problems.
 Complete CPM Java Interfa e.
 In rease power to stepper motors.
Building a Chess Playing Ma hine 10

Making Cir uit Boards at Home

 Layout PCB with Eagle for Linux from CADSoft. The free version is somewhat limited.
( g 0)
 Print PCB layout on Press-n-Peel toner transfer paper with a laser printer.
 Iron Press-n-Peel on to opper lad board and peel away.
 Agitate board in warm et hant solution until all of the exposed opper is removed.
 Rinse board and s rub o toner.
 Set board in warm TIN-IT solution for about 5 mins. This leaves a thin oat of tin on
the opper tra es whi h redu es oxidation and in reases solderability
 Drill board.
 Solder on omponents.
Building a Chess Playing Ma hine 11

Stepper Motors and Linear Motion

 General goals of a linear motion system:


{ Predi tability
{ Repeatability
{ A ura y
 The Stepper Motor ( g 1)
{ Operate by alternately harging sets of oils with in the motor. Fixed magnets on
the motors axle turn to the harged oil.
{ Ea h step is a pre ise number of degrees.
{ Errors in a ura y are not ompounded by repeated use.
{ Mu h more diÆ ult to ontrol than standard motors.
Building a Chess Playing Ma hine 12

Mu h Thanks To

 Boise State University Computer S ien e Dept. - esp. Dr. Amit Jain
 Boise State University Ma hine Tool Te hnology - esp. Dave Sperry
 Advan ed Pre ision Ma hining
 Mi ronas
 The following individuals
{ Kelly Beale
{ Brett Davis
{ Mike Durller
Building a Chess Playing Ma hine 0

Figure 0
Building a Chess Playing Ma hine 1

Figure 1

You might also like