Enum NakReason
#[non_exhaustive]pub enum NakReason {
InvalidCommand,
WrongMode,
CommandTooLong,
DataIncorrect,
BufferFull,
Unknown {
code: u8,
},
}Expand description
NAK response reason code.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
InvalidCommand
The command byte is not recognised.
WrongMode
The modem is in the wrong mode for this command.
CommandTooLong
The command frame exceeds the maximum length.
DataIncorrect
The command payload contains incorrect data.
BufferFull
The TX buffer is full.
Unknown
Unknown NAK reason byte — the raw code is preserved.
Implementations§
Trait Implementations§
impl Copy for NakReason
impl Eq for NakReason
impl StructuralPartialEq for NakReason
Auto Trait Implementations§
impl Freeze for NakReason
impl RefUnwindSafe for NakReason
impl Send for NakReason
impl Sync for NakReason
impl Unpin for NakReason
impl UnwindSafe for NakReason
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