esp_idf_svc::ota

Struct EspFirmwareInfoLoad

Source
pub struct EspFirmwareInfoLoad;
Expand description

A firmware info loader that tries to read the firmware info directly from a user-supplied buffer which can be re-used for other purposes afterwards.

This is a more efficient version of the now-deprecated EspFirmwareInfoLoader.

Implementations§

Source§

impl EspFirmwareInfoLoad

Source

pub fn fetch( &self, data: &[u8], info: &mut FirmwareInfo, ) -> Result<bool, EspIOError>

Fetches firmware information from the firmware binary data chunk loaded so far.

Returns true if the information was successfully fetched. Returns false if the firmware data has not been loaded completely yet.

Source

pub fn load_firmware_info( info: &mut FirmwareInfo, app_desc: &esp_app_desc_t, ) -> Result<(), EspError>

Trait Implementations§

Source§

impl ErrorType for EspFirmwareInfoLoad

Source§

type Error = EspIOError

Error type of all the IO operations on this type.

Auto Trait Implementations§

§

impl Freeze for EspFirmwareInfoLoad

§

impl RefUnwindSafe for EspFirmwareInfoLoad

§

impl Send for EspFirmwareInfoLoad

§

impl Sync for EspFirmwareInfoLoad

§

impl Unpin for EspFirmwareInfoLoad

§

impl UnwindSafe for EspFirmwareInfoLoad

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.