#[derive(Debug, PartialEq, Eq)]
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
pub enum Error<E> {
Communication(E),
ParityError,
SensorError,
}
impl<E: Clone> Clone for Error<E> {
fn clone(&self) -> Self {
match self {
Error::Communication(e) => Error::Communication(e.clone()),
Error::ParityError => Error::ParityError,
Error::SensorError => Error::SensorError,
}
}
}