pub struct ImuPayload {
pub accel_x: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub accel_y: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub accel_z: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub gyro_x: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub gyro_y: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub gyro_z: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
pub temperature: Quantity<dyn Dimension<Th = PInt<UInt<UTerm, B1>>, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn TemperatureKind, T = Z0>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
}Expand description
Standardized IMU payload carrying acceleration, angular velocity, and optional magnetometer data.
Fields§
§accel_x: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§accel_y: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§accel_z: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§gyro_x: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§gyro_y: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§gyro_z: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>§temperature: Quantity<dyn Dimension<Th = PInt<UInt<UTerm, B1>>, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn TemperatureKind, T = Z0>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>Implementations§
Source§impl ImuPayload
impl ImuPayload
Sourcepub fn from_raw(
accel_mps2: [f32; 3],
gyro_rad: [f32; 3],
temperature_c: f32,
) -> ImuPayload
pub fn from_raw( accel_mps2: [f32; 3], gyro_rad: [f32; 3], temperature_c: f32, ) -> ImuPayload
Build an IMU payload from plain scalar values.
accel_mps2- acceleration in m/s².gyro_rad- angular velocity in rad/s.temperature_c- temperature in °C.
Sourcepub fn from_uom(
accel_x: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
accel_y: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
accel_z: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
gyro_x: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
gyro_y: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
gyro_z: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
temperature: Quantity<dyn Dimension<Th = PInt<UInt<UTerm, B1>>, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn TemperatureKind, T = Z0>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>,
) -> ImuPayload
pub fn from_uom( accel_x: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, accel_y: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, accel_z: Quantity<dyn Dimension<Th = Z0, L = PInt<UInt<UTerm, B1>>, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn Kind, T = NInt<UInt<UInt<UTerm, B1>, B0>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, gyro_x: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, gyro_y: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, gyro_z: Quantity<dyn Dimension<Th = Z0, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn AngleKind, T = NInt<UInt<UTerm, B1>>>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, temperature: Quantity<dyn Dimension<Th = PInt<UInt<UTerm, B1>>, L = Z0, M = Z0, N = Z0, I = Z0, J = Z0, Kind = dyn TemperatureKind, T = Z0>, dyn Units<f32, length = meter, mass = kilogram, electric_current = ampere, luminous_intensity = candela, amount_of_substance = mole, time = second, thermodynamic_temperature = kelvin>, f32>, ) -> ImuPayload
Build an IMU payload from unit-carrying types.
Trait Implementations§
Source§impl Clone for ImuPayload
impl Clone for ImuPayload
Source§fn clone(&self) -> ImuPayload
fn clone(&self) -> ImuPayload
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ImuPayload
impl Debug for ImuPayload
Source§impl Decode<()> for ImuPayload
impl Decode<()> for ImuPayload
Source§fn decode<D>(decoder: &mut D) -> Result<ImuPayload, DecodeError>
fn decode<D>(decoder: &mut D) -> Result<ImuPayload, DecodeError>
Attempt to decode this type with the given Decode.
Source§impl Default for ImuPayload
impl Default for ImuPayload
Source§fn default() -> ImuPayload
fn default() -> ImuPayload
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ImuPayload
impl<'de> Deserialize<'de> for ImuPayload
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ImuPayload, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ImuPayload, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Encode for ImuPayload
impl Encode for ImuPayload
Source§impl PartialEq for ImuPayload
impl PartialEq for ImuPayload
Source§impl Serialize for ImuPayload
impl Serialize for ImuPayload
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,
Serialize this value into the given Serde serializer. Read more
impl Copy for ImuPayload
impl StructuralPartialEq for ImuPayload
Auto Trait Implementations§
impl Freeze for ImuPayload
impl !RefUnwindSafe for ImuPayload
impl Send for ImuPayload
impl Sync for ImuPayload
impl Unpin for ImuPayload
impl !UnwindSafe for ImuPayload
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