pub struct LinkStatistics {
pub uplink_rssi_1: u8,
pub uplink_rssi_2: u8,
pub uplink_link_quality: u8,
pub uplink_snr: i8,
pub active_antenna: u8,
pub rf_mode: u8,
pub uplink_tx_power: u8,
pub downlink_rssi: u8,
pub downlink_link_quality: u8,
pub downlink_snr: i8,
}Expand description
Represents a Link Statistics packet.
This packet provides statistics about the connection quality. Uplink is the connection from the ground to the UAV and downlink the opposite direction.
Fields§
§uplink_rssi_1: u8Uplink RSSI Antenna 1 (dBm * -1).
uplink_rssi_2: u8Uplink RSSI Antenna 2 (dBm * -1).
uplink_link_quality: u8Uplink package success rate / link quality (%).
uplink_snr: i8Uplink SNR (dB).
active_antenna: u8The currently active antenna.
rf_mode: u8RF profile, e.g., 4fps = 0, 50fps, 150fps.
uplink_tx_power: u8Uplink TX power enum {0mW = 0, 10mW, 25mW, 100mW, 500mW, 1000mW, 2000mW, 250mW, 50mW}.
downlink_rssi: u8Downlink RSSI (dBm * -1).
downlink_link_quality: u8Downlink package success rate / link quality (%).
downlink_snr: i8Downlink SNR (dB).
Implementations§
Trait Implementations§
Source§impl Clone for LinkStatistics
impl Clone for LinkStatistics
Source§fn clone(&self) -> LinkStatistics
fn clone(&self) -> LinkStatistics
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl CrsfPacket for LinkStatistics
impl CrsfPacket for LinkStatistics
Source§const PACKET_TYPE: PacketType = PacketType::LinkStatistics
const PACKET_TYPE: PacketType = PacketType::LinkStatistics
The CRSF frame type identifier for this packet.
Source§const MIN_PAYLOAD_SIZE: usize = 10usize
const MIN_PAYLOAD_SIZE: usize = 10usize
The minimum expected length of the packet’s payload in bytes.
For fixed-size packets, this is the same as the payload size.
fn to_bytes(&self, buffer: &mut [u8]) -> Result<usize, CrsfParsingError>
Source§fn from_bytes(data: &[u8]) -> Result<Self, CrsfParsingError>
fn from_bytes(data: &[u8]) -> Result<Self, CrsfParsingError>
Creates a packet instance from a payload byte slice.
The slice is guaranteed to have a length of at least
MIN_PAYLOAD_SIZE.fn validate_buffer_size(&self, buffer: &[u8]) -> Result<(), CrsfParsingError>
Source§impl Debug for LinkStatistics
impl Debug for LinkStatistics
Source§impl PartialEq for LinkStatistics
impl PartialEq for LinkStatistics
impl StructuralPartialEq for LinkStatistics
Auto Trait Implementations§
impl Freeze for LinkStatistics
impl RefUnwindSafe for LinkStatistics
impl Send for LinkStatistics
impl Sync for LinkStatistics
impl Unpin for LinkStatistics
impl UnwindSafe for LinkStatistics
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more