Tic Tac Toe Machine
This week’s objectives
- Mechanical Design
- design a machine that includes mechanism+actuation+automation+application ✅
- build the mechanical parts and operate it manually ✅
- Machine Design
- actuate and automate your machine ✅
- Document the group project and your individual contribution (this page!) ✅
Application a device designed to help the user to perform specific tasks
The application for our machine is to play tic-tac-toe against a human adversary, using an aggressive play-to-win AI.
Automation describes a wide range of technologies that reduce human intervention in processes.
Our machine provides full end-to-end automation for the entire game of tic-tac-toe.
Actuation. An actuator is a component of a machine that is responsible for moving and controlling a mechanism or system, for example by opening a valve. In simple terms, it is a “mover”.
From the point of view of machine design, Actuators are the parts of the machine that operate in its environments ( to affect it/change it, in some way), while the sensors are the parts that receive information from its environment.
In terms of actuation, our machine has a moving pen, whose tip can be arbitrarily positioned in any position in the operating space/volume.
For all intents and purposes, however the pen will only occupy 2 planes in space:
- the paper plane: when the tip of the pen is touching the surface below the machine. This setting can be used to paint, draw on it or mark it in some way.
- the hover plane: when the tip of the pen is held away from the floor/paper/whiteboard. This position allows us to freely move the pen without leaving marks or painting anything.
Mechanism (engineering), rigid bodies connected by joints in order to accomplish a desired force and/or motion transmission
The machine that we have built has various mechanisms to operate and perform action in all 3 spacial dimensions:
- 1 mechanism to operate on the X axis (1 degree of freedom) using dual stepper motors
- 1 mechanism to operate on the Y axis (1 degree of freedom) using a single stepper motor
- 1 mechanism to operate on the Z axis (1 degree of freedom) using a single servo motor
The combination of these mechanisms allow the machine to have an operating space/volume of approx:
412 mm x 420 mm x 18 mm = 3,114,720 mm3 = 3114 cm3
Here’s a short excerpt of the code used to control the machine over the operating space.
This week’s responsibilities
- TO DO
- TO DO
Mechanical Design and assembly We started out with an already existing frame made with aluminium and had to add, - X AXIS: 2 acrylic plates as holders for 2 steppers working in unison. - Holders laser cut in 5mm acrylic sheet to hold the stepper motor, wheels and a provision for endstoppers. - Y AXIS: Aluminium frame attached to the 2 X axis acrylic plates and an extension for the Z axis. - Z AXIS: A stationary plate extension and a Servo motor with a pen attached to it.
- Software Development
- Backend implementation
- Frontend design
- Analysis and evaluation of tic-tac-toe algorithms
- Integration of existing algorithms into the backend code
- Parametrization and configuration of the application
- Validation (in GCode Simulators)
- integration of GCode into backend
- Implementation of Serial comms between backend app and Arduino/GRBL
- Software Development
During mechanical design and assembly
We started out with an already existing frame made with aluminium but,
- We had to use an aluminium frame that somehow had to be connected to the 2 acrylic holder plates, as the Y axis.
- We needed to move the pen up and down without the addition of an extra axis/motor.
- The initial iteration of the assembly had the pen too far away from the bed and adding a plate as an extension made it flimsy.
- We needed a stable and reliable bed at the base for a lot of testing.
During electronics design and implementation
During software programming
The software development part ended up being a demanding beast, and we encountered several issues as the days went by:
- We had issues with GRBL and the use of Relative coordinates (but that turned out to be a ghost, and GRBL actually worked perfectly)
- We accidentally burned one arduino board, and we still don’t know how
- We almost got our computers infected with a virus while trying to find a fix for a Serial communications library
- And we had serious issues while trying to get Serial communications working because we forgot to add 1 critical byte at the end of the commands.
If you want to read about all the issues that we encountered during the software development/programming, check out Edu’s page
Sending custom commands to arduino via Serial Interface
Iteration 2 - The product, as we presented it
Sending GCODE commands to Arduino with GRBL installed
Iterations with the assembly
The first iteration of the assembly had the Y axis above the base frame and we were planning to make an extension arm as the Z axis. Eventually, we realised that flipped it upside down would make the Z axis shorter and makes the machine more stable.