The library requires &'static
string for connection, even though the underlying library tonic
doesn't. This limits how one can specify connection url.
You can run the Rust book for drones by using mdbook
:
mdbook serve
A MAVSDK
gRPC client ( HTTP/2 ) for communicating with a drone, built from proto
files using tonic
.
You need to be running the MAVSDK
Server (see https://github.com/mavlink/MAVSDK/releases) in order to use this crate.
docker-compose up --detach
cargo run -p mav-sdk --example takeoff
Prerequisite:
- Make sure you have SSH key set for your Github account.
See Github articles:
Building the project:
- Clone the repository and change dir:
git clone [email protected]:AeroRust/mav.git && cd mav
- Install
protoc
:
- For Linux & mac
- For Windows
- Initialize the
mavsdk-proto
submodule:
git submodule init && git submodule update
- Build the project
cargo build
Useful documentation regarding the Gazebo simulation and the PX4 flight software:
- PX4 with Gazebo docs: https://dev.px4.io/master/en/simulation/gazebo.html
- Setting up Wind speed: https://dev.px4.io/master/en/simulation/gazebo.html#change-wind-speed
- GPS noise: https://dev.px4.io/master/en/simulation/gazebo.html#simulating-gps-noise
- World location: https://dev.px4.io/master/en/simulation/gazebo.html#set-world-location
- Survey camera (simulated MAVLINK camera) + geotagging: https://dev.px4.io/master/en/simulation/gazebo.html#simulated-survey-camera
- Video streaming: https://dev.px4.io/master/en/simulation/gazebo.html#video-streaming
Supported only on the
Typhoon H480
frame and requiresGstreamer 1.0
- Creating a world with (SD Format is used by Gazebo): http://sdformat.org/tutorials?tut=spec_world&cat=specification
- Physics and other setup like wind:
- SD Format - http://sdformat.org/spec?ver=1.4&elem=physics#physics_gravity
- "Windy world" file from PX4 - Gazebo with (SITL): https://github.com/PX4/PX4-SITL_gazebo/blob/master/worlds/windy.world#L15-L26
- Advanced configuration - Complete Parameter List: https://ardupilot.org/copter/docs/parameters.html#parameters
- Vehicle frame types to choose from: https://ardupilot.org/dev/docs/using-sitl-for-ardupilot-testing.html#frame-types
- Starting SITL without MAVProxy (
--no-mavproxy
): https://ardupilot.org/dev/docs/using-sitl-for-ardupilot-testing.html#connecting-other-additional-ground-stations - Using STIL: https://ardupilot.org/dev/docs/using-sitl-for-ardupilot-testing.html
- SITL Serial mapping: https://ardupilot.org/dev/docs/sitl-serial-mapping.html
- SITL Parameters: https://ardupilot.org/dev/docs/sitl-parameters.html
Docker images:
- https://github.com/radarku/ardupilot-sitl-docker
- https://github.com/gmyoungblood-parc/docker-alpine-ardupilot
Gazebo doesn't yet have built-in support for ArduPilot and it requires a plugin to be installed.
- MAVLink basics: https://ardupilot.org/dev/docs/mavlink-basics.html#mavlink-basics
- MAVLink Routing in ArduPilot: https://ardupilot.org/dev/docs/mavlink-routing-in-ardupilot.html