Skip to main content

Settings

Struct Settings 

Source
pub struct Settings {
    pub reaction: Reaction,
    pub off1_deceleration: f64,
    pub off3_deceleration: f64,
    pub pulse_off_speed: f64,
    pub following_window: f64,
    pub standstill_window: f64,
    pub standstill_time: f64,
    pub blocked_speed: f64,
    pub blocked_time: f64,
    pub torque_band: f64,
}
Expand description

One drive’s fault reaction and monitoring, from [drive] (and its motor’s [drive.<id>]). Angles and speeds at the motor, rad and rad/s (m and m/s for a linear motor).

Fields§

§reaction: Reaction§off1_deceleration: f64

The ramps’ decelerations, rad/s^2: the rated speed over drive.off1_ramp_s and off3_ramp_s, the times from the rated speed to standstill. The drive’s p1121 and p1135 count from its maximum speed p1082 instead (S120 List Manual p. 528, 530): p1121 = off1_ramp_s x p1082 / rated speed, as sim-cli parameters converts it.

§off3_deceleration: f64§pulse_off_speed: f64

Once its ramp is down, a drive takes its pulses off below this speed (p1226).

§following_window: f64§standstill_window: f64§standstill_time: f64§blocked_speed: f64§blocked_time: f64§torque_band: f64

The band around the expected torque, as a share of the peak torque; 0: that monitor is off. The expected torque is the feedforward (Drive::torque_ff) and, with drive.torque_feedforward_model = "inertia" (no gravity in it), the torque that holds the planned pose (Drive::torque_hold), and the friction the machine’s own model takes of the motor’s torque at its state (motor.<id>.torque_friction, given to Watch::check); where the machine does not report that, the friction at the planned speed (the characteristic of the friction feedforward where the drive has one, else Machine::steady_friction) in Drive::torque_hold. A held load and the friction are expected, a lasting extra load is not.

Implementations§

Source§

impl Settings

Source

pub fn from_config(cfg: &Config, p: &DriveParams) -> Result<Self, ConfigError>

From a motor’s config (catalog::motor_config). A config without the keys (one written before 14 November 2026) gets the values of the shipped configs.

Source

pub fn deceleration(&self) -> Option<f64>

The deceleration of its stop ramp, rad/s^2: infinite at the current limit, None for STO (no ramp).

Trait Implementations§

Source§

impl Clone for Settings

Source§

fn clone(&self) -> Settings

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 Debug for Settings

Source§

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

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

impl<'de> Deserialize<'de> for Settings

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for Settings

Source§

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

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · 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 Serialize for Settings

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Settings

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> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.