Skip to main content

Storage

Trait Storage 

Source
pub trait Storage: ReadStorage {
    // Required method
    fn write(&mut self, offset: u32, bytes: &[u8]) -> Result<(), Self::Error>;
}
Expand description

Transparent read/write storage trait

Required Methods§

Source

fn write(&mut self, offset: u32, bytes: &[u8]) -> Result<(), Self::Error>

Write a slice of data to the storage peripheral, starting the write operation at the given address offset (between 0 and self.capacity()).

NOTE: This function will automatically erase any pages necessary to write the given data, and might as such do RMW operations at an undesirable performance impact.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<'a, S> Storage for RmwMultiwriteNorFlashStorage<'a, S>

Source§

impl<'a, S> Storage for RmwNorFlashStorage<'a, S>
where S: NorFlash,