pub struct WheelCalibration { /* private fields */ }Expand description
Pairs wheel odometry with VIO poses and map localizations as they arrive and fits where the wheel odometry is measured.
Implementations§
Source§impl WheelCalibration
impl WheelCalibration
Sourcepub fn new(config: WheelCalibrationConfig, imu_from_body: SE3) -> Self
pub fn new(config: WheelCalibrationConfig, imu_from_body: SE3) -> Self
Pairs with a VIO, imu_from_body being the robot description’s
transform from the odometry’s body (e.g. base_link) to the VIO’s
IMU.
Sourcepub fn without_vio(config: WheelCalibrationConfig) -> Self
pub fn without_vio(config: WheelCalibrationConfig) -> Self
Pairs with map localizations only, until
Self::set_imu_from_body.
Sourcepub fn with_prior(self, prior: WheelCalibrationEstimate) -> Self
pub fn with_prior(self, prior: WheelCalibrationEstimate) -> Self
Values for what the pairs do not show yet (e.g. a saved calibration).
Sourcepub fn set_imu_from_body(&mut self, imu_from_body: SE3)
pub fn set_imu_from_body(&mut self, imu_from_body: SE3)
Where the VIO’s IMU sits on the body; VIO poses pair from now on.
pub const fn has_imu_from_body(&self) -> bool
Sourcepub fn turned_deg(&self) -> f64
pub fn turned_deg(&self) -> f64
Total turn of the wheel odometry over the VIO pairs, in degrees.
Sourcepub fn travel_m(&self) -> f64
pub fn travel_m(&self) -> f64
The wheel odometry’s path length over the VIO pairs, in its own units.
Sourcepub fn fix_turned_deg(&self) -> f64
pub fn fix_turned_deg(&self) -> f64
Turn and path of the wheel odometry between map localizations.
pub fn fix_travel_m(&self) -> f64
Sourcepub fn is_ready(&self) -> bool
pub fn is_ready(&self) -> bool
Whether the VIO pairs have seen enough turning and travel to give the offset.
Sourcepub fn fixes_ready(&self) -> bool
pub fn fixes_ready(&self) -> bool
Whether there are enough map localizations to give the level.
Sourcepub fn fixes_travelled(&self) -> bool
pub fn fixes_travelled(&self) -> bool
Whether the map localizations have also travelled enough to give the scale.
Sourcepub fn add_vio(&mut self, timestamp_ns: i64, world_from_imu: &SE3)
pub fn add_vio(&mut self, timestamp_ns: i64, world_from_imu: &SE3)
Adds a VIO pose (the IMU in the VIO’s gravity-aligned world), in time order.
Sourcepub fn add_wheel(&mut self, timestamp_ns: i64, odom_from_wheel: &SE3)
pub fn add_wheel(&mut self, timestamp_ns: i64, odom_from_wheel: &SE3)
Adds a wheel odometry pose (its point, level), in time order.
Sourcepub fn add_fix(&mut self, timestamp_ns: i64, map_from_body: &SE3)
pub fn add_fix(&mut self, timestamp_ns: i64, map_from_body: &SE3)
Adds a localization against a map: the body’s pose in the map (gravity-aligned), at its image’s stamp. It pairs with the wheel odometry interpolated to that stamp, now or once the wheel odometry gets there.
Sourcepub fn estimate(&self) -> Option<WheelCalibrationEstimate>
pub fn estimate(&self) -> Option<WheelCalibrationEstimate>
Trait Implementations§
Source§impl Clone for WheelCalibration
impl Clone for WheelCalibration
Auto Trait Implementations§
impl Forget for WheelCalibration
impl Freeze for WheelCalibration
impl Move for WheelCalibration
impl RefUnwindSafe for WheelCalibration
impl Send for WheelCalibration
impl Sync for WheelCalibration
impl Unpin for WheelCalibration
impl UnsafeUnpin for WheelCalibration
impl UnwindSafe for WheelCalibration
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.