pub enum ConfigError {
Show 13 variants
ParseError(String<128>),
InvalidMicrosteps(u16),
MotorNotFound(String<32>),
TrajectoryNotFound(String<32>),
DuplicateMotorName(String<32>),
DuplicateTrajectoryName(String<32>),
InvalidVelocityPercent(u8),
InvalidAccelerationPercent(u8),
InvalidGearRatio(f32),
InvalidMaxVelocity(f32),
InvalidMaxAcceleration(f32),
InvalidSoftLimits {
min: f32,
max: f32,
},
IoError(String<128>),
}Expand description
Configuration-related errors.
Variants§
ParseError(String<128>)
Failed to parse TOML configuration
InvalidMicrosteps(u16)
Invalid microstep value (must be power of 2: 1, 2, 4, 8, 16, 32, 64, 128, 256)
MotorNotFound(String<32>)
Motor name not found in configuration
TrajectoryNotFound(String<32>)
Trajectory name not found in configuration
DuplicateMotorName(String<32>)
Duplicate motor name in configuration
DuplicateTrajectoryName(String<32>)
Duplicate trajectory name in configuration
InvalidVelocityPercent(u8)
Invalid velocity percent (must be 1-200)
InvalidAccelerationPercent(u8)
Invalid acceleration percent (must be 1-200)
InvalidGearRatio(f32)
Invalid gear ratio (must be > 0)
InvalidMaxVelocity(f32)
Invalid max velocity (must be > 0)
InvalidMaxAcceleration(f32)
Invalid max acceleration (must be > 0)
InvalidSoftLimits
Invalid soft limits (min must be < max)
IoError(String<128>)
File I/O error (std only)
Trait Implementations§
Source§impl Clone for ConfigError
impl Clone for ConfigError
Source§fn clone(&self) -> ConfigError
fn clone(&self) -> ConfigError
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 ConfigError
impl Debug for ConfigError
Source§impl Display for ConfigError
impl Display for ConfigError
Source§impl Error for ConfigError
Available on crate feature std only.
impl Error for ConfigError
Available on crate feature
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<ConfigError> for Error
impl From<ConfigError> for Error
Source§fn from(e: ConfigError) -> Self
fn from(e: ConfigError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ConfigError
impl PartialEq for ConfigError
impl StructuralPartialEq for ConfigError
Auto Trait Implementations§
impl Freeze for ConfigError
impl RefUnwindSafe for ConfigError
impl Send for ConfigError
impl Sync for ConfigError
impl Unpin for ConfigError
impl UnwindSafe for ConfigError
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