Interactive Tic-Tac Toe Game Controlled With Arduino

by TejB1 in Circuits > Microcontrollers

1026 Views, 0 Favorites, 0 Comments

Interactive Tic-Tac Toe Game Controlled With Arduino

F8TBWYNJNOVL6PT.jpeg

The goal of the Physical Tic-Tac-Toe project is to move a well-known game into the physical realm. Originally, the game is played by two players on a piece of paper - by putting ‘X’ and ‘O’ symbols in turns. Our idea was to examine players’ behavior when confronted with a radically different form. Additionally, we really liked to explore Steampunk aesthetics by combining the mechanics of gears with electronics.

The key idea behind our project is that the game fields’ states can be represented by the shape of the bendable material. Fields have 3 different states: ‘X’, ‘O’ and NULL (unused field). We had to come up with a way to reduce the number of actuators needed to make a transition from one to another state. Having drawn a few sketches we realized this number can be reduced to just one. Sketch below summarizes our design process.

Tools and Materials

download (15).jpg

With the following materials, you should be able to make 9 game-boxes. Each game-box is an independent element and can be used in any configuration. Without much hassle, the board might be extended to 16 (4×4) or 25 (5×5) boxes.

Tools:

  • Programmable laser cutter
  • Glue gun
  • Soldering station


Materials:

  • 9 × SG90 servo (https://components101.com/servo-motor-basics-pinout-datasheet)
  • 2 sqm. of 3mm MDF board
  • 0.5 sqm. of transparent 4mm acrylic board
  • Breadboard
  • Jumper wires
  • Arduino board
  • 9 Push buttons
  • Elastic thread
  • 80 cm of 8mm hollow tube (acrylic/aluminum)
  • 9 Resistors of 10 Kilo Ohm
  • Breadboard

Laser Cutting

final board.jpg

Each box requires approximately 0.3 sqm of 3mm MDF board. Placement of elements on the canvas does not matter. Note that gears are not redundant - all of them are required to make the box work.

Provided SVG file might have to be adjusted to work properly on different printers.

Downloads

Gear Assembly

Capture-59.PNG
Capture-60.PNG

To construct the mechanism inside the box we need to laser cut the required gear assembly and glue it together

Input Box Making and Assembly

WhatsApp Image 2018-10-06 at 3.18.50 PM.jpeg
IMG_20181026_131255.jpg

The second part of the process is to create a physical input boxboard. It is a 3X3 board where each of the buttons corresponds to the respective boxes on the game board.

  • The parts are laser cut and assembled.
  • The buttons have been soldered together on a solderable board.
  • To reduce complexity the power wires are all joined at one point and a single comes out.
  • The ground wires need to have separate 10K ohm resistor and then they can be joined together.
  • In the end, a single wire is connected to the Arduino.

Arduino Circuit

Capture-62.PNG

The connections with the Arduino are as follows. Now regarding the input box, the connections were done on a solder board and the entire assembly is present inside the box. The digital pins and the power and ground pins from the input board to connect with the Arduino. The servo connections are as shown in the image above.

The code for the Interactive artifact consists of 3 files. TicTacToe.ino is the main file and solver is the algorithm used to play the 'X' and 'O' steps.

Prototype Demonstration

Tictactoe