Enum embedded_can::ErrorKind
source · [−]#[non_exhaustive]
pub enum ErrorKind {
Overrun,
Bit,
Stuff,
Crc,
Form,
Acknowledge,
Other,
}
Expand description
CAN error kind
This represents a common set of CAN operation errors. HAL implementations are free to define more specific or additional error types. However, by providing a mapping to these common CAN errors, generic code can still react to them.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
Overrun
The peripheral receive buffer was overrun.
Bit
A bit error is detected at that bit time when the bit value that is monitored differs from the bit value sent.
Stuff
A stuff error is detected at the bit time of the sixth consecutive equal bit level in a frame field that shall be coded by the method of bit stuffing.
Crc
Calculated CRC sequence does not equal the received one.
Form
A form error shall be detected when a fixed-form bit field contains one or more illegal bits.
Acknowledge
An ACK error shall be detected by a transmitter whenever it does not monitor a dominant bit during the ACK slot.
Other
A different error occurred. The original error may contain more information.
Trait Implementations
sourceimpl Ord for ErrorKind
impl Ord for ErrorKind
1.21.0 · sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
1.21.0 · sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
sourceimpl PartialOrd<ErrorKind> for ErrorKind
impl PartialOrd<ErrorKind> for ErrorKind
sourcefn partial_cmp(&self, other: &ErrorKind) -> Option<Ordering>
fn partial_cmp(&self, other: &ErrorKind) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more