This is the wrapper for drone control and swarming library.
The wrapper is based on pymavlink and server/client communicating written in python-socket. To use the wrapper server called "swarm" function to running on the same system by multiple threading.
- Python 3.7+ is required (threading will be duprecated, instead of asyncio).
- You may need to run
pip3
instead ofpip
andpython3
instead ofpython
, depending of your system defaults.
first, build up a virtual enviroment
python3 -m venv [YOUR_ENV]
and then run:
source [YOUR_ENV]/bin/activate
install requirments:
pip3 install -r requirments.txt
The package contains mavsdk_server
already (previously called "backend"), which is started automatically when connecting (e.g. await drone.connect()
). Have a look at the examples to see it used in practice. It will be something like:
from ctl.control import Core, Drone, ConnectionType
...
core = Core()
# you can choose type for udp or serial_port
core.connect(ConnectionType.udp, [PORT])
drone = Drone(core)
drone.initialize()
Note: core.connect --help
will show detail information for uav connection.
Once the package has been installed, the examples can be run:
python3 ./gcs.py