mavlink 0.18.0

Implements the MAVLink data interchange format for UAVs.
#[cfg(all(feature = "dialect-ardupilotmega", feature = "arbitrary"))]
mod random_tests {
    use mavlink::{Message, dialects::ardupilotmega::MavMessage};
    use rand::{SeedableRng, rngs::StdRng};

    #[test]
    fn test_random_message_generation() {
        let seed = 42;
        let mut rng: StdRng = SeedableRng::seed_from_u64(seed);

        let known_ardupilotmega_ids = &[
            0, 1, 2, 4, 5, 6, 7, 8, 11, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
            35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 54, 55, 61, 62, 63,
            64, 65, 66, 67, 69, 70, 73, 74, 75, 76, 77, 80, 81, 82, 83, 84, 85, 86, 87, 89, 90, 91,
            92, 93, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
            116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132,
            133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 146, 147, 148, 149, 150,
            151, 152, 153, 154, 155, 156, 157, 158, 160, 161, 162, 163, 164, 165, 166, 167, 168,
            169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185,
            186, 191, 192, 193, 194, 195, 200, 201, 214, 215, 216, 217, 218, 219, 225, 226, 230,
            231, 232, 233, 234, 235, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252,
            253, 254, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270,
            271, 275, 276, 280, 281, 282, 283, 284, 285, 286, 287, 288, 290, 291, 299, 300, 301,
            310, 311, 320, 321, 322, 323, 324, 330, 331, 332, 333, 334, 335, 336, 339, 340, 350,
            360, 370, 373, 375, 380, 385, 386, 387, 388, 390, 395, 397, 400, 401, 410, 411, 412,
            413, 9000, 9005, 10001, 10002, 10003, 11000, 11001, 11002, 11003, 11010, 11011, 11020,
            11030, 11031, 11032, 11033, 11034, 11035, 11036, 11037, 11038, 11039, 12900, 12901,
            12902, 12903, 12904, 12905, 12915, 12918, 12919, 12920, 42000, 42001, 50001, 50002,
            50003, 50004, 50005,
        ];

        for id in known_ardupilotmega_ids {
            let msg = MavMessage::random_message_from_id(*id, &mut rng).unwrap();
            let id2 = msg.message_id();
            assert_eq!(*id, id2, "Generated message had wrong ID");
        }
    }
}