Trait embedded_svc::ota::Ota

source ·
pub trait Ota: ErrorType {
    type Update<'a>: OtaUpdate<Error = Self::Error>
       where Self: 'a;

    // Required methods
    fn get_boot_slot(&self) -> Result<Slot, Self::Error>;
    fn get_running_slot(&self) -> Result<Slot, Self::Error>;
    fn get_update_slot(&self) -> Result<Slot, Self::Error>;
    fn is_factory_reset_supported(&self) -> Result<bool, Self::Error>;
    fn factory_reset(&mut self) -> Result<(), Self::Error>;
    fn initiate_update(&mut self) -> Result<Self::Update<'_>, Self::Error>;
    fn mark_running_slot_valid(&mut self) -> Result<(), Self::Error>;
    fn mark_running_slot_invalid_and_reboot(&mut self) -> Self::Error;
}

Required Associated Types§

source

type Update<'a>: OtaUpdate<Error = Self::Error> where Self: 'a

Required Methods§

source

fn get_boot_slot(&self) -> Result<Slot, Self::Error>

source

fn get_running_slot(&self) -> Result<Slot, Self::Error>

source

fn get_update_slot(&self) -> Result<Slot, Self::Error>

source

fn is_factory_reset_supported(&self) -> Result<bool, Self::Error>

source

fn factory_reset(&mut self) -> Result<(), Self::Error>

source

fn initiate_update(&mut self) -> Result<Self::Update<'_>, Self::Error>

source

fn mark_running_slot_valid(&mut self) -> Result<(), Self::Error>

source

fn mark_running_slot_invalid_and_reboot(&mut self) -> Self::Error

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<O> Ota for &mut O
where O: Ota,

§

type Update<'a> = <O as Ota>::Update<'a> where Self: 'a

source§

fn get_boot_slot(&self) -> Result<Slot, Self::Error>

source§

fn get_running_slot(&self) -> Result<Slot, Self::Error>

source§

fn get_update_slot(&self) -> Result<Slot, Self::Error>

source§

fn is_factory_reset_supported(&self) -> Result<bool, Self::Error>

source§

fn factory_reset(&mut self) -> Result<(), Self::Error>

source§

fn initiate_update(&mut self) -> Result<Self::Update<'_>, Self::Error>

source§

fn mark_running_slot_valid(&mut self) -> Result<(), Self::Error>

source§

fn mark_running_slot_invalid_and_reboot(&mut self) -> Self::Error

Implementors§