pub struct TargetRelative {
pub timestamp: u64,
pub id: u8,
pub frame: TargetObsFrame,
pub x: f32,
pub y: f32,
pub z: f32,
pub pos_std: [f32; 3],
pub yaw_std: f32,
pub q_target: [f32; 4],
pub q_sensor: [f32; 4],
pub type_: LandingTargetType,
}Expand description
MAVLink TARGET_RELATIVE message.
The minimum supported MAVLink version is MAVLink 2.
§Description
The location of a target measured by MAV’s onboard sensors.
§Encoding/Decoding
Message encoding/decoding are provided by implementing core::convert::TryFrom<Payload> for
TargetRelative (encoding) and [IntoPayload] (decoding) traits.
These traits are implemented by Message proc macro.
Fields§
§timestamp: u64MAVLink field timestamp.
Timestamp (UNIX epoch time)
id: u8MAVLink field id.
The ID of the target if multiple targets are present
frame: TargetObsFrameMAVLink field frame.
Coordinate frame used for following fields.
x: f32MAVLink field x.
X Position of the target in TARGET_OBS_FRAME
y: f32MAVLink field y.
Y Position of the target in TARGET_OBS_FRAME
z: f32MAVLink field z.
Z Position of the target in TARGET_OBS_FRAME
pos_std: [f32; 3]MAVLink field pos_std.
Standard deviation of the target’s position in TARGET_OBS_FRAME
yaw_std: f32MAVLink field yaw_std.
Standard deviation of the target’s orientation in TARGET_OBS_FRAME
q_target: [f32; 4]MAVLink field q_target.
Quaternion of the target’s orientation from the target’s frame to the TARGET_OBS_FRAME (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
q_sensor: [f32; 4]MAVLink field q_sensor.
Quaternion of the sensor’s orientation from TARGET_OBS_FRAME to vehicle-carried NED. (Ignored if set to (0,0,0,0)) (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
type_: LandingTargetTypeMAVLink field type.
Type of target
Implementations§
Source§impl TargetRelative
impl TargetRelative
Sourcepub const fn spec() -> MessageInfo
pub const fn spec() -> MessageInfo
Returns specification for this message.
Sourcepub const fn message_id() -> MessageId
pub const fn message_id() -> MessageId
Message ID.
Sourcepub const fn min_supported_mavlink_version() -> MavLinkVersion
pub const fn min_supported_mavlink_version() -> MavLinkVersion
Minimum supported MAVLink version for this message.
Trait Implementations§
Source§impl Clone for TargetRelative
impl Clone for TargetRelative
Source§fn clone(&self) -> TargetRelative
fn clone(&self) -> TargetRelative
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for TargetRelative
impl Debug for TargetRelative
Source§impl Default for TargetRelative
impl Default for TargetRelative
Source§impl<'de> Deserialize<'de> for TargetRelative
impl<'de> Deserialize<'de> for TargetRelative
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl From<TargetRelative> for Development
impl From<TargetRelative> for Development
Source§fn from(value: TargetRelative) -> Self
fn from(value: TargetRelative) -> Self
Source§impl IntoPayload for TargetRelative
impl IntoPayload for TargetRelative
Source§impl MessageSpec for TargetRelative
impl MessageSpec for TargetRelative
Source§impl MessageSpecStatic for TargetRelative
impl MessageSpecStatic for TargetRelative
Source§fn spec() -> MessageInfo
fn spec() -> MessageInfo
Source§fn message_id() -> MessageId
fn message_id() -> MessageId
ID.Source§fn min_supported_mavlink_version() -> MavLinkVersion
fn min_supported_mavlink_version() -> MavLinkVersion
Source§impl NamedType for TargetRelative
impl NamedType for TargetRelative
fn sid() -> SpectaID
Source§fn named_data_type(
type_map: &mut TypeCollection,
generics: &[DataType],
) -> NamedDataType
fn named_data_type( type_map: &mut TypeCollection, generics: &[DataType], ) -> NamedDataType
Source§fn definition_named_data_type(type_map: &mut TypeCollection) -> NamedDataType
fn definition_named_data_type(type_map: &mut TypeCollection) -> NamedDataType
Source§impl PartialEq for TargetRelative
impl PartialEq for TargetRelative
Source§impl Serialize for TargetRelative
impl Serialize for TargetRelative
Source§impl TryFrom<&Payload> for TargetRelative
impl TryFrom<&Payload> for TargetRelative
Source§impl Type for TargetRelative
impl Type for TargetRelative
Source§fn inline(type_map: &mut TypeCollection, generics: Generics<'_>) -> DataType
fn inline(type_map: &mut TypeCollection, generics: Generics<'_>) -> DataType
Source§fn reference(type_map: &mut TypeCollection, generics: &[DataType]) -> Reference
fn reference(type_map: &mut TypeCollection, generics: &[DataType]) -> Reference
definition will be put into the type map.