Struct sbp::messages::system::msg_ins_status::MsgInsStatus
source · pub struct MsgInsStatus {
pub sender_id: Option<u16>,
pub flags: u32,
}
Expand description
Inertial Navigation System status message
The INS status message describes the state of the operation and initialization of the inertial navigation system.
Fields§
§sender_id: Option<u16>
The message sender_id
flags: u32
Status flags
Implementations§
source§impl MsgInsStatus
impl MsgInsStatus
sourcepub fn ins_type(&self) -> Result<InsType, u8>
pub fn ins_type(&self) -> Result<InsType, u8>
Gets the InsType stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known InsType
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of InsType
were added.
sourcepub fn set_ins_type(&mut self, ins_type: InsType)
pub fn set_ins_type(&mut self, ins_type: InsType)
Set the bitrange corresponding to the InsType of the flags
bitfield.
sourcepub fn motion_state(&self) -> Result<MotionState, u8>
pub fn motion_state(&self) -> Result<MotionState, u8>
Gets the MotionState stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known MotionState
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of MotionState
were added.
sourcepub fn set_motion_state(&mut self, motion_state: MotionState)
pub fn set_motion_state(&mut self, motion_state: MotionState)
Set the bitrange corresponding to the MotionState of the flags
bitfield.
sourcepub fn odometry_synch(&self) -> Result<OdometrySynch, u8>
pub fn odometry_synch(&self) -> Result<OdometrySynch, u8>
Gets the OdometrySynch stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known OdometrySynch
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of OdometrySynch
were added.
sourcepub fn set_odometry_synch(&mut self, odometry_synch: OdometrySynch)
pub fn set_odometry_synch(&mut self, odometry_synch: OdometrySynch)
Set the bitrange corresponding to the OdometrySynch of the flags
bitfield.
sourcepub fn odometry_status(&self) -> Result<OdometryStatus, u8>
pub fn odometry_status(&self) -> Result<OdometryStatus, u8>
Gets the OdometryStatus stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known OdometryStatus
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of OdometryStatus
were added.
sourcepub fn set_odometry_status(&mut self, odometry_status: OdometryStatus)
pub fn set_odometry_status(&mut self, odometry_status: OdometryStatus)
Set the bitrange corresponding to the OdometryStatus of the flags
bitfield.
sourcepub fn ins_error(&self) -> Result<InsError, u8>
pub fn ins_error(&self) -> Result<InsError, u8>
Gets the InsError stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known InsError
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of InsError
were added.
sourcepub fn set_ins_error(&mut self, ins_error: InsError)
pub fn set_ins_error(&mut self, ins_error: InsError)
Set the bitrange corresponding to the InsError of the flags
bitfield.
sourcepub fn gnss_fix(&self) -> Result<GnssFix, u8>
pub fn gnss_fix(&self) -> Result<GnssFix, u8>
Gets the GnssFix stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known GnssFix
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of GnssFix
were added.
sourcepub fn set_gnss_fix(&mut self, gnss_fix: GnssFix)
pub fn set_gnss_fix(&mut self, gnss_fix: GnssFix)
Set the bitrange corresponding to the GnssFix of the flags
bitfield.
Trait Implementations§
source§impl Clone for MsgInsStatus
impl Clone for MsgInsStatus
source§fn clone(&self) -> MsgInsStatus
fn clone(&self) -> MsgInsStatus
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl ConcreteMessage for MsgInsStatus
impl ConcreteMessage for MsgInsStatus
source§const MESSAGE_TYPE: u16 = 65_283u16
const MESSAGE_TYPE: u16 = 65_283u16
source§const MESSAGE_NAME: &'static str = "MSG_INS_STATUS"
const MESSAGE_NAME: &'static str = "MSG_INS_STATUS"
source§impl Debug for MsgInsStatus
impl Debug for MsgInsStatus
source§impl<'de> Deserialize<'de> for MsgInsStatus
impl<'de> Deserialize<'de> for MsgInsStatus
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 FriendlyName for MsgInsStatus
impl FriendlyName for MsgInsStatus
fn friendly_name() -> &'static str
source§impl From<MsgInsStatus> for Sbp
impl From<MsgInsStatus> for Sbp
source§fn from(msg: MsgInsStatus) -> Self
fn from(msg: MsgInsStatus) -> Self
source§impl PartialEq for MsgInsStatus
impl PartialEq for MsgInsStatus
source§fn eq(&self, other: &MsgInsStatus) -> bool
fn eq(&self, other: &MsgInsStatus) -> bool
self
and other
values to be equal, and is used
by ==
.