pub enum KrakenError {
FanSpeedOutOfRange,
PumpSpeedOutOfRange,
Comms,
UsbError(HidError),
}
Expand description
A common error enum for errors returned from our API.
Variants§
FanSpeedOutOfRange
If the fan speed supplied is outside of the 25-100% range.
PumpSpeedOutOfRange
If the pump speed supplied is outside of the 60-100% range.
Comms
If the device did not return enough data to us.
UsbError(HidError)
Wrapper error for any underlying USB errors thrown by the hidapi.
Trait Implementations§
Source§impl Debug for KrakenError
impl Debug for KrakenError
Source§impl Display for KrakenError
impl Display for KrakenError
Source§impl Error for KrakenError
impl Error for KrakenError
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<KrakenError> for Error
impl From<KrakenError> for Error
Source§fn from(error: KrakenError) -> Self
fn from(error: KrakenError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for KrakenError
impl !RefUnwindSafe for KrakenError
impl Send for KrakenError
impl Sync for KrakenError
impl Unpin for KrakenError
impl !UnwindSafe for KrakenError
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