element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products & Partners
    Products & Partners
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
    About the element14 Community
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      •  Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Arduino Projects
  • Products & Partners
  • Arduino
  • Arduino Projects
  • More
  • Cancel
Arduino Projects
Blog MeArm TicTacToe
  • Blog
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • More
  • Cancel
  • New
Join Arduino Projects to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: lucaeffe03
  • Date Created: 28 Oct 2026 11:05 AM Date Created
  • Views 65 views
  • Likes 4 likes
  • Comments 0 comments
Related
Recommended

MeArm TicTacToe

lucaeffe03
lucaeffe03
28 Oct 2026

An interactive robotic system (MeArm) capable of challenging a human to a game of Tic-Tac-Toe

image

Devices & Components

1image

Arduino Uno Rev3

1 image

Robot Arm Kit

TrisVision MeArm

Mixed Reality and Computer Vision

Introduction

The project consists of the development of an interactive robotic system based on a 4 degrees of freedom (4DOF) arm with a parallelogram structure (MeArm). The system is capable of challenging a human to a game of Tic-Tac-Toe, identifying moves (X) on a sheet of paper via a webcam and physically responding on the board (O).The software is written in Python and communicates with a microcontroller via a BT-24 Bluetooth Low Energy module.

Software

The architecture is modular, separating the vision logic, artificial intelligence, and hardware communication:Vision/Main (`trisvision.py`): Uses OpenCV to track the playing field, recognize symbols (X and O), and render graphics in Mixed Reality.Logic (`tris_logica.py`): Contains the algorithm (Minimax) to calculate the robot's move.Communication (`ble_link.py`, `config.py`): Interface using the `bleak` library for asynchronous sending of commands (servo motor angles) to the Arduino via Bluetooth.

Calibration

To allow the robot to interact accurately with the real world, several calibration phases were necessary.

Spatial Calibration

Since the camera frames the table, the image has perspective distortions. The software dynamically searches for the 4 sides of the white paper and applies perspective correction (`warpPerspective`). By pressing the 'B'*key (Memory Lock), the system freezes the transformation matrix, allowing the robot to enter the scene without disrupting the geometric recognition of the board.

Color Calibration

Target objects were isolated from the environment by adjusting the Min/Max thresholds for Hue (H), Saturation (S), and Value (V). In this case, the color of a yellow circle glued to the gripper was calibrated (`calibra_EE.py`), which is essential for visually tracking the position of the end-effector.

Electromechanical Calibration

The hardware (SG90 micro-servo motors) has significant mechanical tolerances. Instead of using complex kinematic calculations, the system uses a static mapping (`MAPPA_CASELLE`) where a safe combination of angles (Base, Shoulder, Elbow) has been saved for each of the 9 Tic-Tac-Toe squares. This decouples the mathematical model from the physical problem, offloading hardware imperfections onto a manually tunable configuration file (via `test_ble.py`).

CODE --> MeArm_Tic_Tac_Toe

  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2026 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube