Skip to main content

Run Your Own Robot Swarm Testbed.

Project description

SwarmIT

SwarmIT provides a embedded C port for nRF53 as well as Python based services to easily build and deploy a robotic swarm infrastructure testbed. ARM TrustZone is used to create a sandboxed user environment on each device under test, without requiring a control co-processor attached to it.

Features

  • Experiment management: start, stop, monitor and status check
  • Deploy a custom firmware on all or on a subset of robots of a swarm testbed
  • Resilient robot state: even when crashed by buggy user code, the robot can be reprogrammed remotely and wirelessly

Usage

Get the code

Swarmit depends on the DotBot-firmware and Mari repositories. They are included in the codebase as Git submodules.

Use the following command to clone the Swarmit codebase locally:

git clone --recurse-submodules https://github.com/DotBots/swarmit.git

Embedded C code

SwarmIT embedded C code can be built using Segger Embedded Studio (SES). Use Tools > Package manager to install the CMSIS 5 CMSIS-CORE, CMSIS-DSP and nRF packages.

To provision a device, follow the following steps:

  1. open netcore.emProject and bootloader.emProject (or bootloader.emProject depending on your robot version) in SES
  2. build and load the netcore application on the nRF53 network core,
  3. build and load the bootloader application on the nRF53 application core.

The device is now ready.

Gateway

The communication between the computer and the swarm devices is performed via a gateway board connected via USB to the computer.

This gateway uses the mari network stack and must run the Mari gateway firmware.

The documentation to setup a Mari gateway is located here.

Python CLI script

The Python CLI script provides commands for flashing, starting and stopping user code on the device, as well as monitoring and checking the status of devices in the swarm.

The Python CLI script connects via a virtual COM port to the gateway connected to the computer.

The Python CLI script is available on PyPI. Install it using:

pip install swarmit

Print usage using swarmit --help:

Usage: swarmit [OPTIONS] COMMAND [ARGS]...

Options:
  -p, --port TEXT                 Serial port to use to send the bitstream to
                                  the gateway. Default: /dev/ttyACM0.
  -b, --baudrate INTEGER          Serial port baudrate. Default: 1000000.
  -H, --mqtt-host TEXT            MQTT host. Default: localhost.
  -P, --mqtt-port INTEGER         MQTT port. Default: 1883.
  -T, --mqtt-use_tls              Use TLS with MQTT.
  -n, --network-id INTEGER        Marilib network ID to use. Default: 1
  -a, --adapter [edge|cloud]
                                  Choose the adapter to communicate with the
                                  gateway.  [default: edge]
  -d, --devices TEXT              Subset list of devices to interact with,
                                  separated with ,
  -v, --verbose                   Enable verbose mode.
  -V, --version                   Show the version and exit.
  -h, --help                      Show this message and exit.

Commands:
  flash    Flash a firmware to the robots.
  message  Send a custom text message to the robots.
  monitor  Monitor running applications.
  reset    Reset robots locations.
  start    Start the user application.
  status   Print current status of the robots.
  stop     Stop the user application.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

swarmit-0.5.0rc1.tar.gz (15.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

swarmit-0.5.0rc1-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

Details for the file swarmit-0.5.0rc1.tar.gz.

File metadata

  • Download URL: swarmit-0.5.0rc1.tar.gz
  • Upload date:
  • Size: 15.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.27.2

File hashes

Hashes for swarmit-0.5.0rc1.tar.gz
Algorithm Hash digest
SHA256 a1b6105397f20e2df9c138729c4063c0af8e9f695c62de6e453a56cf58e06f04
MD5 7f76ff3c812d2db97648683a4e8b86b1
BLAKE2b-256 98b4a982096c58aad4bb391b1e021d894b052a8f2e17203c1dcfbf661998b720

See more details on using hashes here.

File details

Details for the file swarmit-0.5.0rc1-py3-none-any.whl.

File metadata

  • Download URL: swarmit-0.5.0rc1-py3-none-any.whl
  • Upload date:
  • Size: 17.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.27.2

File hashes

Hashes for swarmit-0.5.0rc1-py3-none-any.whl
Algorithm Hash digest
SHA256 2b109620f776970bf1ceadb7526ded9ec23676641cbd2e6f7a96f2b995e6dad1
MD5 079e172b9fc9b948abda168ea85a9f37
BLAKE2b-256 86f91c02a8ad64f59df4fd21c515ddb247ec0809e85b082c92ae28897f110eb4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page