Skip to content

traveling salesman problem implemented with a mavlink drone

Notifications You must be signed in to change notification settings

tomasz-lewicki/traveling-salesdrone

Repository files navigation

Traveling Salesdrone

Showcase of traveling salesman problem on a mavlink drone. Demo video: https://www.youtube.com/watch?v=jAG2CS-mqwM

Description

The program generates random points within given boundaries (here it's SJSU campus). Then, it looks for the optimal (shortest total distance) order to visit the points (traveling salesman problem).

Quickstart

  1. First, run gazebo simulation. Here, for simplicity it is run in a docker container. You can set the starting location using flags (e.g. PX4_HOME_LAT=37.335404)
docker run --rm -it --env PX4_HOME_LAT=37.335404 --env PX4_HOME_LON=-121.883400 --env PX4_HOME_ALT=488.0 jonasvautherin/px4-gazebo-headless:v1.9.2
  1. Run mavproxy to route traffic from simulation to multiple ports
mavproxy.py --master=udp:0.0.0.0:14550 --out=udp:localhost:14551 --out=udp:localhost:14552
  1. Install required packages:
pip3 install -r requirements.txt
  1. Run the program
python3 control/mission.py
  1. Run Qgroundcontrol to observe real-time trajectory of the drone.

Demo

Below there are non-optimized and optimized flight paths.

Non-optimized: non-optimized

Optimized (video, 10x speed):

Watch the video

About

traveling salesman problem implemented with a mavlink drone

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published