Skip to main content

pymavswarm

PyPI Version Contribution Frequency License: GPLv3 Open Issues Documentation Status

What is pymavswarm?

pymavswarm is a Python library implemented to enable interaction with drone swarms using the MAVLink protocol. This library supports reading MAVLink messages sent from multiple agents in a swarm and sending MAVLink messages to agents within the swarm. Such functionality ultimately enables development of new swarm applications such as ground control stations.

Main features

Here are some of the main features of pymavswarm:

  • Easily send MAVLink commands to multiple drones, simultaneously

  • Monitor the state of swarm drone agents

  • Implement custom commands and swarm algorithms

  • Develop applications for on-board companion computers

  • Implement custom swarm ground control stations

  • Log incoming MAVLink messages for future evaluation and debugging

  • Construct pre-planned missions

  • Multi-agent collision avoidance using reachability analysis

Installation

pymavswarm may be installed from PyPI by running:

$ python3 -m pip install pymavswarm

To build pymavswarm from source, first ensure that at least Python 3.10 is installed. Once this dependency has been met, refer to the steps below:

  1. Clone the project repository

  2. Navigate to the pymavswarm/ base directory

$ cd path/to/pymavswarm/
  1. Install the pymavswarm Python package

$ python3 -m pip install .

Quick start

pymavswarm has been implemented to enable easy interfacing with drone swarms. Refer to the following code snippet for a simple example to get started with the library. Additional examples may be found in the project examples.

import time

from pymavswarm import MavSwarm

# Create a new pymavswarm interface
mavswarm = MavSwarm()

# Establish a connection with a USB telemetry device
mavswarm.connect('/dev/ttyUSB0', 115200, 255, 0)

# Wait for the swarm to be populated
while not mavswarm.agents:
    pass

# Arm each agent in the swarm
mavswarm.arm()

# Briefly delay to allow all agents to arm
time.sleep(5.0)

# Disarm each agent in the swarm
mavswarm.disarm()

# Close the pymavswarm connection
mavswarm.disconnect()

Getting help

If you have questions regarding pymavswarm usage or contribution please ask a question on our Discussions board!

Contributing

All contributions and ideas are welcome! Detailed guidelines regarding how to contribute can be found in the contribution guidelines.

License

pymavswarm is released under the GNU General Public License v3 or later

Metadata

Release files for pymavswarm 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pymavswarm 1.2.0
File Size Uploaded
pymavswarm-1.2.0.tar.gz 67.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pymavswarm 1.2.0
File Interpreter ABI Platform
pymavswarm-1.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 161.4 kB

Release files / pymavswarm-1.2.0.tar.gz

Download URL pymavswarm-1.2.0.tar.gz
Size 67.7 kB
Tags Source
SHA-256 checksum
How to use checksums
5b253a285d8279dcac074ab64967d2383f78a7ec09e5e5c11f04f908045fb018
BLAKE2b-256 checksum
How to use checksums
6faef128dea6eae5e46115ac2814faa589421bff0d2a9db82441719f12b19826
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.14

Release files / pymavswarm-1.2.0-py3-none-any.whl

Download URL pymavswarm-1.2.0-py3-none-any.whl
Size 93.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
52e8837f5947c4b55b20d9ae7627e51f31d128dd9004f3ed87791eb4c732ccad
BLAKE2b-256 checksum
How to use checksums
b6195c1578698316cc1f097567525f125a8f43f01769566ec46a22e83033bfe8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.14

Release history Release notifications | RSS feed

This release

1.2.0 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page