#[repr(u8)]pub enum BootState {
Idle = 255,
Updating = 127,
Validating = 63,
}Expand description
Current stage in the firmware update lifecycle.
Each state is a contiguous run of 1-bits from bit 0.
Advancing clears the MSB: next = state & (state >> 1).
0xFF Idle (8 ones)
0x7F Updating (7 ones)
0x3F Validating (6 ones)Variants§
Idle = 255
No update in progress. Normal app boot. Erased flash default.
Updating = 127
Firmware transfer in progress.
Validating = 63
New firmware written, trial booting the app.
Implementations§
Trait Implementations§
impl Copy for BootState
impl StructuralPartialEq for BootState
Auto Trait Implementations§
impl Freeze for BootState
impl RefUnwindSafe for BootState
impl Send for BootState
impl Sync for BootState
impl Unpin for BootState
impl UnsafeUnpin for BootState
impl UnwindSafe for BootState
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