Skip to main content

Status

Enum Status 

Source
pub enum Status {
    Healthy,
    Degraded,
    Aligning,
    DeadReckoning,
}
Expand description

How far the estimate can be trusted: whether attitude has converged, and how well aided it is.

Payload-free, so State stays Copy and cheap to read on the hot path. The detail is in Diagnostics.

Declared in order of increasing severity. When more than one applies the most severe is reported, so Aligning hides Degraded — an attitude that has not converged is the larger problem — and DeadReckoning hides everything, since position is unusable whatever the attitude is doing. So a vehicle waiting on the ground for its first GNSS fix reads DeadReckoning rather than Aligning, although its barometer and magnetometer are arriving: Aligning is reachable only with horizontal aiding.

Variants§

§

Healthy

Every source that has ever been fused is still being accepted, and attitude has converged. The course constraint is not counted: it reads the filter’s own velocity rather than a sensor; see Eskf::fuse_course.

§

Degraded

At least one source has timed out against its own timeout, and horizontal position is still aided.

§

Aligning

The filter is running and aided, but its attitude has not converged: it was initialized without a static window, seeded coarsely, or started from a window with no magnetometer in it, and is still learning.

Position and velocity are being estimated and are usable to the extent the covariance says. Attitude is not yet good enough to fly on.

Two ways out, and neither is a timer or an acknowledgement. Tilt and a widened yaw leave on their own, as soon as the covariance falls within ALIGNED_TILT and ALIGNED_HEADING — fixed bars, not Config::accuracy, which is the mission’s and moves only Validity. A heading nothing has observed needs a measurement instead: stillness never supplies yaw, so a filter that started without a magnetometer stays here however small the covariance is, until a heading source — Eskf::fuse_mag_heading, fuse_gnss_heading or fuse_course — accepts one. A vehicle with none of the three therefore never leaves, and — since this hides Degraded — its source timeouts stop showing in Status and have to be read from Diagnostics.

Leaving is permanent, and that is a claim about this variant rather than about the estimate: it reports a start that has not been resolved yet, not attitude quality now. Quality now is Validity::tilt, which does fall back, and which an unaided filter loses within seconds of propagating. See Eskf::is_aligned for what re-entering this state cost on the corpus.

§

DeadReckoning

Neither GNSS position nor GNSS velocity has been accepted within Timeouts::dead_reckoning_after, or ever: horizontal position and velocity error grow without bound. A barometer or magnetometer still arriving holds height or heading, and does not change this; Validity says per quantity what is held.

Trait Implementations§

Source§

impl Clone for Status

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Status

Source§

impl Debug for Status

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Status

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Display for Status

One word or two, as an operator log carries it.

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Status

Source§

impl Format for Status

Available on crate feature defmt only.
Source§

fn format(&self, f: Formatter<'_>)

Writes the defmt representation of self to fmt.
Source§

impl PartialEq for Status

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Status

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> Scalar for T
where T: 'static + Clone + PartialEq + Debug,

Source§

impl<SS, SP> SupersetOf<SS> for SP
where SS: SubsetOf<SP>,

Source§

fn to_subset(&self) -> Option<SS>

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more
Source§

fn is_in_subset(&self) -> bool

Checks if self is actually part of its subset T (and can be converted to it).
Source§

fn to_subset_unchecked(&self) -> SS

Use with care! Same as self.to_subset but without any property checks. Always succeeds.
Source§

fn from_subset(element: &SS) -> SP

The inclusion map: converts self to the equivalent element of its superset.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.