A repository with the source code for launching an operator program for a swarm of Pioneer-Max drones.
- Python 3.8 (Download: https://www.python.org/downloads/)
-
Clone gs_swarm_drones_operator repository.
git clone https://github.com/SeriousBanan/gs_swarm_drones_operator.git
-
Install required python modules.
python3 -m pip install -r <path to gs_swarm_drones_operator>/requirements.txt
-
Go to folder with gs_swarm_drones_operator repository.
cd <path to gs_swarm_drones>
-
Connect to network with drones.
-
Fill json configuration file.
You need to remove
...and fill fields in configuration.json file:- drones count: int value of amount of drones.
- drones initial positions: dict where keys - drone's ids, values - ids of vertexes where drone start it program (from field.json file).
{ "0": 0, "1": 6 }-
addresses: dict where keys - drone ids or operator, values - dict with ips and ports.
For example:
"0": { "ip": "192.168.1.19", "port": 10000 }
This information used to communication between drones and operator.
Example of full filled configuration file:
{ "drones count": 2, "drones initial positions": { "0": 6, "1": 0 }, "addresses": { "operator": { "ip": "192.168.1.1", "port": 10000 }, "0": { "ip": "192.168.1.2", "port": 10000 }, "1": { "ip": "192.168.1.3", "port": 10000 } }, "image file path": "received_image.png" }
-
Go to folder with operator application file:
cd <path to gs_swarm_drones_operator>
-
Launch python script:
python3 application.py