pub struct SerialControl {
pub device: SerialControlDev,
pub flags: SerialControlFlag,
pub timeout: u16,
pub baudrate: u32,
pub count: u8,
pub data: [u8; 70],
pub target_system: u8,
pub target_component: u8,
}
Expand description
MAVLink SERIAL_CONTROL
message.
The minimum supported MAVLink version is MAVLink 1
.
§Description
Control a serial port. This can be used for raw access to an onboard serial peripheral such as a GPS or telemetry radio. It is designed to make it possible to update the devices firmware via MAVLink messages or change the devices settings. A message with zero bytes can be used to change just the baudrate.
§Encoding/Decoding
Message encoding/decoding are provided by implementing core::convert::TryFrom<Payload>
for
SerialControl
(encoding) and [IntoPayload
] (decoding) traits.
These traits are implemented by Message
proc macro.
Fields§
§device: SerialControlDev
MAVLink field device
.
Serial control device type.
flags: SerialControlFlag
MAVLink field flags
.
Bitmap of serial control flags.
timeout: u16
MAVLink field timeout
.
Timeout for reply data
baudrate: u32
MAVLink field baudrate
.
Baudrate of transfer. Zero means no change.
count: u8
MAVLink field count
.
how many bytes in this transfer
data: [u8; 70]
MAVLink field data
.
serial data
target_system: u8
MAVLink field target_system
.
System ID
target_component: u8
MAVLink field target_component
.
Component ID
Implementations§
Source§impl SerialControl
impl SerialControl
Sourcepub const fn spec() -> MessageInfo
pub const fn spec() -> MessageInfo
Returns specification for this message.
Sourcepub const fn message_id() -> u32
pub const fn message_id() -> u32
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 SerialControl
impl Clone for SerialControl
Source§fn clone(&self) -> SerialControl
fn clone(&self) -> SerialControl
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for SerialControl
impl Debug for SerialControl
Source§impl Default for SerialControl
impl Default for SerialControl
Source§fn default() -> SerialControl
fn default() -> SerialControl
Source§impl<'de> Deserialize<'de> for SerialControl
impl<'de> Deserialize<'de> for SerialControl
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SerialControl, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SerialControl, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl From<SerialControl> for Common
impl From<SerialControl> for Common
Source§fn from(value: SerialControl) -> Common
fn from(value: SerialControl) -> Common
Source§impl IntoPayload for SerialControl
impl IntoPayload for SerialControl
Source§impl MessageSpec for SerialControl
impl MessageSpec for SerialControl
Source§impl MessageSpecStatic for SerialControl
impl MessageSpecStatic for SerialControl
Source§fn spec() -> MessageInfo
fn spec() -> MessageInfo
Source§fn message_id() -> u32
fn message_id() -> u32
ID
.Source§fn min_supported_mavlink_version() -> MavLinkVersion
fn min_supported_mavlink_version() -> MavLinkVersion
Source§impl NamedType for SerialControl
impl NamedType for SerialControl
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 SerialControl
impl PartialEq for SerialControl
Source§impl Serialize for SerialControl
impl Serialize for SerialControl
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Source§impl TryFrom<&Payload> for SerialControl
impl TryFrom<&Payload> for SerialControl
Source§impl Type for SerialControl
impl Type for SerialControl
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.