Skip to content

Rajneesh04/Spot-ify

 
 

Repository files navigation

Spot-ify: The 4 musketeers

Reactive Control Model with FSM for navigation,with the help of aruco markers, computer vision and ESP8266 module.

We built a system of 4 robots, capable of communicating with each other and aligning themselves according to given patterns with as much accuracy and speed as attainable.Each bot is able to detect its initial coordinates and orientation and reach the final position (in any orientation). On reaching the final destination, Bots provide an indication/signal.

We designed this for Inter Hostel Tech Competetion-Kriti 2019.

  • The setup for this consists of:
    • A camera placed on top.
    • A local Wi-Fi server.
    • 4 Aruco Markers with known Id.

Dependencies and Requirements

  • Python 3.7
  • Arduino IDE
  • OpenCV
  • Aruco 3.0+

BOT Making

Each Bot is a three wheel system designed as small as possible to reduce the probability of collision.

  • Each Bot Consists of :
    • A ESP8266 (NodeMcu) : Reading Coordinates File and Controlling Motor Drivers.
    • Two Geared DC Motor and Wheel : Motion of the Bot
    • A Castor Wheel : Helps in Stability and Rotation
    • A Motor Driver (LM298) : control Motors
    • 9V Duracell Batteries : Power Source

Working

  • The camera placed on top records the real time coordinates of Bots i.e Aruco markers.

  • Real-Time Position Coordinates and Goal Coordinates keep updating in file.
  • ESP8266(NodeMcu) access the file on local server and read coordinates by sending a GET request.
  • The Motion of Bot follows the following Finite State Machine(FSM) to reach desired goal position without Collision: picture alt
  • The Control Architecture follows a closed loop control system. picture alt

Files and their Use

NodeMcu Related

align_n_go.ino

Bots align themselves with the line to goal point and keep moving towards their goal without taking care collision with other bot.

Version_1.ino

In addition of aling_n_go, bots take care of collision except head to head and head to tail collision.

Version_2.ino

In addition of aling_n_go, bots take care of all type of collisions.

Setup Related

aruco_detect_camera.py

Detect Aruco markers placed on each bot and update the file data.txt

data.txt

Coordinates file,Real Time Updating by aruco_detect_camera.py

server.py

Python programme to host local server on desired adress and port.

Test

Calibrate.ino

The two Dc motors used differ sligtly due to their mechanical properties, so the speed on providing same PWM is not same. We can calibrate or tune the two values of PWM for straight movement

Releases

No releases published

Packages

No packages published

Languages

  • C++ 93.8%
  • Python 6.2%