8 releases

new 0.6.4 Mar 15, 2025
0.6.3 Mar 15, 2025
0.6.1 Feb 22, 2025

#352 in Robotics

Download history 222/week @ 2025-02-15 307/week @ 2025-02-22 33/week @ 2025-03-01 84/week @ 2025-03-08

646 downloads per month
Used in 4 crates (2 directly)

MIT/Apache

540KB
188 lines

MAVLink message definitions for MAVSpec

πŸ‡ΊπŸ‡¦ repository crates.io docs.rs issues

⚠️ All issues related to this project should be submitted to MAVSpec.

This is a very simple crate with the whole purpose to collect MAVLink message definitions using MAVInspect. It is used by MAVSpec as a source of truth about MAVLink dialect specification.

Upstream crates that use Mavka libraries toolchain can use Cargo patch mechanism to replace this crate and therefore change which dialects will be packaged.

Usage

This crate exposes just one protocol function that allows to obtain metadata for the entire set of MAVLink dialects.

fn main() {
    let protocol = mavlink_message_definitions::protocol();
    let common = protocol.get_dialect_by_name("common").unwrap();
    let heartbeat_message = common.get_message_by_name("HEARTBEAT").unwrap();
    assert_eq!(heartbeat_message.defined_in().unwrap(), "minimal");
}

Message Definitions

All MAVLink message definitions live in the message_definitions directory.

  • standard β€” standard MAVLink dialects. These dialects enabled by dlct-* feature flags.
  • test β€” MAVLink dialects for test purposes. These dialects enabled by test-dialects feature flag.
  • extra β€” extra dialects. These dialects enabled by test-dialects feature flag. You can put your own message definitions here and patch this crate to generate additional dialects for upstream crates.

Development

The main development workflow for this crate involves inclusion into MAVSpec as a submodule.

We reserve a special extras branch to test extra dialects' generation.

License

Here we simply comply with the suggested dual licensing according to Rust API Guidelines (C-PERMISSIVE).

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~11MB
~188K SLoC