Struct MotionProfileStatus

Source
#[repr(C)]
pub struct MotionProfileStatus { pub top_buffer_rem: i32, pub top_buffer_cnt: i32, pub btm_buffer_cnt: i32, pub has_underrun: bool, pub is_underrun: bool, pub active_point_valid: bool, pub is_last: bool, pub profile_slot_select_0: i32, pub profile_slot_select_1: i32, pub output_enable: SetValueMotionProfile, pub time_dur_ms: i32, }
Expand description

Motion Profile Status This is simply a data transer object.

Fields§

§top_buffer_rem: i32

The available empty slots in the trajectory buffer.

The robot API holds a “top buffer” of trajectory points, so your applicaion can dump several points at once. The API will then stream them into the Talon’s low-level buffer, allowing the Talon to act on them.

§top_buffer_cnt: i32

The number of points in the top trajectory buffer.

§btm_buffer_cnt: i32

The number of points in the low level Talon buffer.

§has_underrun: bool

Set if is_underrun ever gets set. Only is cleared by clearMotionProfileHasUnderrun() to ensure robot logic can react or instrument it. @see clearMotionProfileHasUnderrun()

§is_underrun: bool

This is set if Talon needs to shift a point from its buffer into the active trajectory point however the buffer is empty. This gets cleared automatically when is resolved.

§active_point_valid: bool

True if the active trajectory point has not empty, false otherwise. The members in activePoint are only valid if this signal is set.

§is_last: bool§profile_slot_select_0: i32

Selected slot for PID Loop 0

§profile_slot_select_1: i32

Selected slot for PID Loop 0

§output_enable: SetValueMotionProfile

The current output mode of the motion profile executer (disabled, enabled, or hold). When changing the set() value in MP mode, it’s important to check this signal to confirm the change takes effect before interacting with the top buffer.

§time_dur_ms: i32

The applied duration of the active trajectory point

Trait Implementations§

Source§

impl Debug for MotionProfileStatus

Source§

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

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

impl Default for MotionProfileStatus

Source§

fn default() -> MotionProfileStatus

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

impl PartialEq for MotionProfileStatus

Source§

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

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for MotionProfileStatus

Source§

impl StructuralPartialEq for MotionProfileStatus

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> 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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.