Coder Social home page Coder Social logo

sousannah / moving-dji-tello-drone-using-hand-gestures Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 601 KB

License: MIT License

Python 100.00%
airsim airsim-simulator dji finger hand handgesture handgesture-recognition handgesture-recognizer mediapipe mediapipe-hands python tello tello-drone tellodrone

moving-dji-tello-drone-using-hand-gestures's Introduction

Hand Gesture Control for DJI Tello Drone

Alt Text

Overview

This repository provides a demonstration of controlling a DJI Tello drone in the AirSim environment using hand gestures detected via the MediaPipe library. By utilizing computer vision techniques, the code interprets hand movements captured by the webcam to command the drone to perform specific actions.

Features

  • Hand Gesture Recognition: Utilizes MediaPipe's Hand module to detect and analyze hand landmarks in real-time from the webcam feed.
  • Drone Control: Interprets recognized hand gestures to control the DJI Tello drone's movements in the AirSim simulator.
  • Gesture Mapping: Maps specific finger configurations to predefined drone movements (e.g., up, down, left, right).
  • User Interface: Displays a live feed with hand landmarks drawn and a label indicating the recognized gesture.

Requirements

  • Python 3.x
  • OpenCV (cv2)
  • MediaPipe (mediapipe)
  • AirSim Python API (airsim)
  • Tello Python library (tellolib)

Installation

  1. Clone this repository.
  2. Install required libraries by running: pip install -r requirements.txt.

Usage

  1. Connect to AirSim: Ensure AirSim is running and connect to the simulator.
  2. Connect DJI Tello Drone: Ensure the Tello drone is connected and accessible.
  3. Run the Python script airsim_hand_gesture_control.py.
  4. Perform hand gestures in front of your webcam.
  5. The recognized gestures will control the Tello drone's movements within the AirSim environment.

Code Structure

This repository provides four distinct code files catering to different functionalities:

AirSim Integrated Control with Gesture Recognition

  • File Name: airsim_hand_gesture_control.py
  • Description: This script integrates both hand gesture recognition using MediaPipe and control commands for the DJI Tello drone in the AirSim environment.

MediaPipe Hand Gesture Recognition Only

  • File Name: mediapipe_hand_gesture.py
  • Description: This script focuses solely on hand gesture recognition using MediaPipe's Hand module. It serves as a standalone demonstration of hand gesture recognition without drone control functionalities.

AirSim Controlled DJI Tello Drone with Limitations

  • File Name: tello_control.py
  • Description: This script provides a simplified version of the AirSim integration for controlling the DJI Tello drone based on hand gestures. It imposes certain limitations on the drone's movements to ensure safer operation.

AirSim Controlled DJI Tello Drone with Safety Measures

  • File Name: airsim_limitations.py
  • Description: Similar to tello_control.py, this script adds additional safety measures to drone movements, preventing continuous or excessive maneuvers.

Users can choose the script based on their requirements:

  • Use airsim_hand_gesture_control.py for integrating hand gesture control with the DJI Tello drone in the AirSim simulator.
  • Use mediapipe_hand_gesture.py for a standalone demonstration of hand gesture recognition without drone control functionalities.
  • Use tello_control.py for controlling the DJI Tello drone with added limitations on movements for safety.
  • Use airsim_limitations.py for a version with extended safety measures in drone control.

Acknowledgments

  • AirSim: Utilized for the drone simulation environment.
  • MediaPipe: Used for real-time hand landmark detection.
  • OpenCV: Employed for image processing and webcam capture.
  • Tello Python library: Used for communication with the DJI Tello drone.

License

This project is licensed under the MIT License.

Contribution

Contributions are welcome! Feel free to fork this repository, create pull requests, or open issues for any improvements, bug fixes, or suggestions.

moving-dji-tello-drone-using-hand-gestures's People

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.