4 releases
0.3.0 | Oct 3, 2024 |
---|---|
0.2.2 | Jun 4, 2024 |
0.2.1 | Nov 4, 2021 |
0.2.0 | Oct 1, 2021 |
#246 in Hardware support
191 downloads per month
Used in 2 crates
42KB
824 lines
Crazyflie link
Link implementation for the Crazyflie quadcopter.
This crates implements low-level link communication to a Crazyflie using the Crazyradio dongle or the direct USB connection. It allows to scan for Crazyflies and to open a bidirectional link.
This crate API is async, it is implemented using the Tokio executor.
Limitations
This crate currently only supports 2Mbit/s datarate over Crazyradio.
This crate currently only supports the Tokio executor.
lib.rs
:
Crazyflie Link
This Crate implement the Crazyflie radio link connection using Crazyradio. It allows to scan for Crazyflies and to open a safe bidirectional radio connection using a Crazyradio.
The entry point to this Crate is the [LinkContext], it keeps track of Crazyradio dongles and provides functions to open a link [Connection].
A connection can then be used to send and receive packet with the Crazyflie.
Example:
// Create a link Context
let context = crazyflie_link::LinkContext::new();
// Scan for Crazyflies
let cf_found = context.scan([0xe7; 5]).await?;
if let Some(uri) = cf_found.first() {
let connection = context.open_link(uri).await?;
let packet = connection.recv_packet().await?;
println!("Packet received: {:?}", packet);
}
Dependencies
~6–13MB
~169K SLoC