What the circuit basically consists of is an 8x8 array of Hall effect switches that are scanned a row at a time. As for the software, it's already written and is available in the downloads. It might be possible to build the hardware on a breadboard of some sort, but it will take some effort with all the connections that are necessary. If you can make your own board, that will save you some money. I designed mine using the free software available from ExpressPCB and then uploaded my design to them when ordering the boards. The main cost was the printed circuit board (PCB). The hardware for this project is fairly minimal. Teensy 3.1 pins 0, 1, 9, and 10, RX1, TX1, RX2, and TX2 were left unused and brought out to pads, allowing for an interface to a PC. This project can be expanded on and if you're interested in chess programming, it has the potential to add intelligent responses or even game play. The chessboard operation does not include the three more esoteric moves - castling, en passant, and promotion - although these could be added. Illegal moves are detected, as well as when the king is in check. The LEDs light up to show a player where a piece can be moved, and whether there is an opponent’s piece that can be taken. This makes it a nice learning device for the beginning chess player. The chessboard is used by two players, and the basic objective is to keep track of the board and the rules of the game for both players. This chessboard does not play a chess game against you. Download information and instructions can be found at. You'll need to download and install the Teensyduino software package to program the Teensy 3.1 with the Arduino GUI. It can also be easily programmed with the Arduino GUI. I also moved from using an Arduino Mega 2560 to a Teensy 3.1, which has more RAM and a 72 MHz clock, as opposed to 16 MHz for the Arduino. The chess pieces have a small magnet in their base to trigger the Hall effect sensors. My previous experience had me deciding against using IR detectors, so I went instead with Hall effect sensors. Once an LED is turned on, it doesn't need to be continually refreshed. This coupled with the fact that as the ambient light in the room changed, the IR detector’s values changed as well, it was just a matter of a few chess moves before the IR detectors gave an error.Īfter some experience using RGB LED strips, it occurred to me that this might be an easier way of driving the LEDs on an electronic chessboard. Their output was read with an Arduino Mega 2560 analogRead() which gave differing values for each IR detector. Scanning 256 LEDs is not simple, but worked fairly well. For the detector, I tried using reflective IR sensors.Īfter many attempts, I got a prototype to barely work. I experimented with an array of 256 individual RGB LEDs placed in a 16x16 array, using a block of 2x2 LEDs for each board square. Our discussion led me to thinking about building a chessboard using an array of RGB LEDs and some sort of detector to monitor the position of the chess pieces. Some time back, my grandson mentioned a circuit board for gaming he was working on in his college program. The X positions mark where the pawn can capture an opponent’s piece, which is limited to a diagonal move forward of one square. After the pawn’s first move, it can only move forward one square if empty. The pawn’s first move can be either one or two squares forward if those squares are empty. The knight is the only piece that can jump over other pieces. The black circles represent the squares where each piece can move. The more esoteric castling, en passant, and promotion moves are not included in this project, although they could be added to the software. The chessboard layouts shown here illustrate the various allowable moves for each chess piece. If you're not familiar with chess, Wikipedia has an excellent introduction to the game at. The number of distinct 40 move games is far greater than the number of electrons in the observable universe. What makes things complicated is the total number of different ways a game can progress.Īfter each side has played three moves, the pieces could form any one of over nine million possible positions on the board. Actually, the rules of how the chess pieces can move are fairly simple and easily learned. The game of chess is considered by many to be very complicated and played by people who enjoy a challenge.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |