Trybotics Logo

Autonomous Chess Playing Robotic Arm

DESCRIPTION

Software Description:

  • · Python Idle : This is the coding platform used in this project. Whole Robot is coded in Python language on Python Idle.
  • · Open Cv : This is an Image processing Library used for giving Robot the vision of the chessboard.
  • · Pyfirmata: This is used to code Arduino in Python Language. Basically this connects Arduino to Python Idle instead of Arduino Ide.


Concepts for Autonomous Chess playing Robotic Arm: Working of robotic Arm involves series of concepts and mechanisms:

1. Forward Kinematics : Given the angles of servo motor Forward kinematics deals with finding Desired Position of End Effector.(ie given the servo angles such as theta_1, theta_2 and theta_3 Forward kinematics helps to find X, Y and Z coordinates or position of the end effector).This is also used to check whether angles obtained by inverse kinematics are correct or not. The video is provided in this zip file’s “Videos” folder.

2. Inverse Kinematics : Given the X, Y AND Z coordinates of end effector the inverse kinematics deals with finding the desired angles of the Servos to reach the desired location. (for example : For picking an object which is placed at position (X, Y, Z) Inverse kinematics can be used to reach that particular object and grab it. The video is provided in this zip file’s “Videos” folder.

3. Kinematic Diagrams : These are the diagrams used to derive and solve the equations of forward and inverse kinematics. I solved kinematic diagram for an 3DOF articulated Manipulator.

4. Denavit–Hartenberg parameters : This is a method to solve Forward kinematics easily by making a Parameter table.

5. Rotational Matrices and Displacement Vectors : These are used in finding homogenous Transformation Matrix and also for converting camera coordinates into Robots base frame coordinates.

6. Image Processing : This is used to give Robot vision of what’s happening on chess board like if move is played or not or if move is played by white or black.

Step by step working of Robotic Arm:

· Step 1: First input from the player is given whether he wants black or white. If the player chooses white then Robotic arm takes black color and black color is given as input and vice versa if players chooses black suppose player chooses white here

· Step2: Game starts. As soon as the game begins, image processing starts to check if white played the move. The detection of movement is detected by simple subtraction of two images first one is original image and second is the new image formed to changes of position of pieces on board. If subtraction results in nothing that means no move is played. If subtraction results in a non zero matrix then move is played by white. This lets Robot understand if move is played or not.

· Step 3: Suppose white plays move E4 here. Move is detected by image processing. Then robot fetches the move from its chess opening dictionary I created and then plays the move accordingly. The dictionary is like { “e5”:coordinates }. From this the Robot gets the desired coordinates and then by Inverse Kinematics picks up the pawn from e7 square and places it at e5 square. This is how picking and placing of piece works.

· Step 4: This whole process keeps on repeating itself unless game comes to conclusion. The whole Robot is controlled by Arduino pro mini which controls and provides necessary PWM to Motors.

Conclusion: The robot successfully detects the moves played and also successfully picks up and place the chess pieces accurately and precisely on the chessboard using Image processing.

WorkingVideo :Feel free to check the working video of this project below :)


Description:

11113 01
SparkFun Arduino Pro Mini 328 - 5V/16MHz
This is the microcontroller which is the brain of this project. It sends commands about what to do and what not to do
×1
servo motor Mg995
This acts as an actuator
×4
USB webcam
Used for capturing high quality Images of Chessboard .
×1
5v 2.5a power supply box 600  75335.1455146831.500.659
Digilent 5V 2.5A Switching Power Supply
This is used to power the Motors and Arduino. Basically this the power supply for the Robot. Note:These servo Motors need stable Power Supply to function smoothly. Ac adapters are perfect for this !
×1
Pppc102lfbn rc sml
Female Header 20 Position 2 Row (0.1")
×1
Te connectivity 4 103741 0 image 75px
Male Header 40 Position 1 Row (0.1")
×1
Pcb products
Custom PCB
×1

Description:

Software Description:

  • · Python Idle : This is the coding platform used in this project. Whole Robot is coded in Python language on Python Idle.
  • · Open Cv : This is an Image processing Library used for giving Robot the vision of the chessboard.
  • · Pyfirmata: This is used to code Arduino in Python Language. Basically this connects Arduino to Python Idle instead of Arduino Ide.


Concepts for Autonomous Chess playing Robotic Arm: Working of robotic Arm involves series of concepts and mechanisms:

1. Forward Kinematics : Given the angles of servo motor Forward kinematics deals with finding Desired Position of End Effector.(ie given the servo angles such as theta_1, theta_2 and theta_3 Forward kinematics helps to find X, Y and Z coordinates or position of the end effector).This is also used to check whether angles obtained by inverse kinematics are correct or not. The video is provided in this zip file’s “Videos” folder.

2. Inverse Kinematics : Given the X, Y AND Z coordinates of end effector the inverse kinematics deals with finding the desired angles of the Servos to reach the desired location. (for example : For picking an object which is placed at position (X, Y, Z) Inverse kinematics can be used to reach that particular object and grab it. The video is provided in this zip file’s “Videos” folder.

3. Kinematic Diagrams : These are the diagrams used to derive and solve the equations of forward and inverse kinematics. I solved kinematic diagram for an 3DOF articulated Manipulator.

4. Denavit–Hartenberg parameters : This is a method to solve Forward kinematics easily by making a Parameter table.

5. Rotational Matrices and Displacement Vectors : These are used in finding homogenous Transformation Matrix and also for converting camera coordinates into Robots base frame coordinates.

6. Image Processing : This is used to give Robot vision of what’s happening on chess board like if move is played or not or if move is played by white or black.

Step by step working of Robotic Arm:

· Step 1: First input from the player is given whether he wants black or white. If the player chooses white then Robotic arm takes black color and black color is given as input and vice versa if players chooses black suppose player chooses white here

· Step2: Game starts. As soon as the game begins, image processing starts to check if white played the move. The detection of movement is detected by simple subtraction of two images first one is original image and second is the new image formed to changes of position of pieces on board. If subtraction results in nothing that means no move is played. If subtraction results in a non zero matrix then move is played by white. This lets Robot understand if move is played or not.

· Step 3: Suppose white plays move E4 here. Move is detected by image processing. Then robot fetches the move from its chess opening dictionary I created and then plays the move accordingly. The dictionary is like { “e5”:coordinates }. From this the Robot gets the desired coordinates and then by Inverse Kinematics picks up the pawn from e7 square and places it at e5 square. This is how picking and placing of piece works.

· Step 4: This whole process keeps on repeating itself unless game comes to conclusion. The whole Robot is controlled by Arduino pro mini which controls and provides necessary PWM to Motors.

Conclusion: The robot successfully detects the moves played and also successfully picks up and place the chess pieces accurately and precisely on the chessboard using Image processing.

WorkingVideo :Feel free to check the working video of this project below :)



YOU MIGHT ALSO LIKE