pub struct MagnetoMeter {Show 18 fields
pub header: TelemetryHeader,
pub temp: u16,
pub mag_x: u16,
pub mag_y: u16,
pub mag_z: u16,
pub acc_x: u16,
pub acc_y: u16,
pub acc_z: u16,
pub roll: u16,
pub pitch: u16,
pub yaw: u16,
pub mag_roll: u16,
pub mag_field: u16,
pub grav_field: u16,
pub expected_size: u64,
pub end_byte: u16,
pub zero: u8,
pub ndata: u8,
}
Fields§
§header: TelemetryHeader
§temp: u16
§mag_x: u16
§mag_y: u16
§mag_z: u16
§acc_x: u16
§acc_y: u16
§acc_z: u16
§roll: u16
§pitch: u16
§yaw: u16
§mag_roll: u16
§mag_field: u16
§grav_field: u16
§expected_size: u64
§end_byte: u16
§zero: u8
§ndata: u8
Implementations§
Source§impl MagnetoMeter
impl MagnetoMeter
Trait Implementations§
Source§impl Default for MagnetoMeter
impl Default for MagnetoMeter
Source§impl Display for MagnetoMeter
impl Display for MagnetoMeter
Source§impl Serialization for MagnetoMeter
impl Serialization for MagnetoMeter
const HEAD: u16 = 37_099u16
const TAIL: u16 = 0u16
Source§const SIZE: usize = 57usize
const SIZE: usize = 57usize
The SIZE is the size of the serialized
bytestream INCLUDING 4 bytes for head
and tail bytes. In case the struct does
NOT HAVE a fixed size, SIZE will be 0
(so default value of the trait
Source§fn from_bytestream(
stream: &Vec<u8>,
pos: &mut usize,
) -> Result<Self, SerializationError>
fn from_bytestream( stream: &Vec<u8>, pos: &mut usize, ) -> Result<Self, SerializationError>
Decode a serializable from a bytestream
Source§fn verify_fixed(
stream: &Vec<u8>,
pos: &mut usize,
) -> Result<(), SerializationError>
fn verify_fixed( stream: &Vec<u8>, pos: &mut usize, ) -> Result<(), SerializationError>
Verify that the serialized representation of the struct has the
correct size, including header + footer. Read more
Source§fn from_tofpacket(packet: &TofPacket) -> Result<Self, SerializationError>where
Self: Sized,
fn from_tofpacket(packet: &TofPacket) -> Result<Self, SerializationError>where
Self: Sized,
Decode a serializable directly from a TofPacket
Source§fn to_bytestream(&self) -> Vec<u8>
fn to_bytestream(&self) -> Vec<u8>
Encode a serializable to a bytestream
fn from_slice(
_slice: &[u8],
_start_pos: usize,
) -> Result<Self, SerializationError>where
Self: Sized,
Auto Trait Implementations§
impl Freeze for MagnetoMeter
impl RefUnwindSafe for MagnetoMeter
impl Send for MagnetoMeter
impl Sync for MagnetoMeter
impl Unpin for MagnetoMeter
impl UnwindSafe for MagnetoMeter
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoSql for T
impl<T> IntoSql for T
Source§fn into_sql<T>(self) -> Self::Expression
fn into_sql<T>(self) -> Self::Expression
Convert
self
to an expression for Diesel’s query builder. Read moreSource§fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
Convert
&self
to an expression for Diesel’s query builder. Read more