pub struct CommandInt {}Expand description
MAVLink COMMAND_INT message.
The minimum supported MAVLink version is MAVLink 1.
§Description
Send a command with up to seven parameters to the MAV, where params 5 and 6 are integers and the other values are floats. This is preferred over COMMAND_LONG as it allows the MAV_FRAME to be specified for interpreting positional information, such as altitude. COMMAND_INT is also preferred when sending latitude and longitude data in params 5 and 6, as it allows for greater precision. Param 5 and 6 encode positional data as scaled integers, where the scaling depends on the actual command value. NaN or INT32_MAX may be used in float/integer params (respectively) to indicate optional/default values (e.g. to use the component’s current latitude, yaw rather than a specific value). The command microservice is documented at https://mavlink.io/en/services/command.html
§Encoding/Decoding
Message encoding/decoding are provided by implementing core::convert::TryFrom<Payload> for
CommandInt (encoding) and [IntoPayload] (decoding) traits.
These traits are implemented by Message proc macro.
Fields§
§target_system: u8MAVLink field target_system.
System ID
target_component: u8MAVLink field target_component.
Component ID
frame: MavFrameMAVLink field frame.
The coordinate system of the COMMAND.
command: MavCmdMAVLink field command.
The scheduled action for the mission item.
current: u8MAVLink field current.
Not used.
autocontinue: u8MAVLink field autocontinue.
Not used (set 0).
param1: f32MAVLink field param1.
PARAM1, see MAV_CMD enum
param2: f32MAVLink field param2.
PARAM2, see MAV_CMD enum
param3: f32MAVLink field param3.
PARAM3, see MAV_CMD enum
param4: f32MAVLink field param4.
PARAM4, see MAV_CMD enum
x: i32MAVLink field x.
PARAM5 / local: x position in meters * 1e4, global: latitude in degrees * 10^7
y: i32MAVLink field y.
PARAM6 / local: y position in meters * 1e4, global: longitude in degrees * 10^7
z: f32MAVLink field z.
PARAM7 / z position: global: altitude in meters (relative or absolute, depending on frame).
Implementations§
Source§impl CommandInt
impl CommandInt
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 CommandInt
impl Clone for CommandInt
Source§fn clone(&self) -> CommandInt
fn clone(&self) -> CommandInt
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CommandInt
impl Debug for CommandInt
Source§impl Default for CommandInt
impl Default for CommandInt
Source§impl<'de> Deserialize<'de> for CommandInt
impl<'de> Deserialize<'de> for CommandInt
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<CommandInt> for All
impl From<CommandInt> for All
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl From<CommandInt> for CommandInt
impl From<CommandInt> for CommandInt
Source§fn from(value: CommandInt) -> Self
fn from(value: CommandInt) -> Self
Source§impl IntoPayload for CommandInt
impl IntoPayload for CommandInt
Source§impl MessageSpec for CommandInt
impl MessageSpec for CommandInt
Source§impl MessageSpecStatic for CommandInt
impl MessageSpecStatic for CommandInt
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 CommandInt
impl NamedType for CommandInt
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 CommandInt
impl PartialEq for CommandInt
Source§impl Serialize for CommandInt
impl Serialize for CommandInt
Source§impl TryFrom<&Payload> for CommandInt
impl TryFrom<&Payload> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl TryFrom<CommandInt> for CommandInt
impl TryFrom<CommandInt> for CommandInt
Source§impl Type for CommandInt
impl Type for CommandInt
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.