pub struct StorageDevice<'a, 'b, T: Addressable> {
pub sdmmc: &'a mut Sdmmc<'b>,
/* private fields */
}Expand description
Storage Device
Fields§
§sdmmc: &'a mut Sdmmc<'b>Inner member
Implementations§
Source§impl<'a, 'b> StorageDevice<'a, 'b, Card>
Card Storage Device
impl<'a, 'b> StorageDevice<'a, 'b, Card>
Card Storage Device
Source§impl<'a, 'b> StorageDevice<'a, 'b, Emmc>
Emmc storage device
impl<'a, 'b> StorageDevice<'a, 'b, Emmc>
Emmc storage device
Source§impl<'a, 'b, A: Addressable> StorageDevice<'a, 'b, A>
Card or Emmc storage device
impl<'a, 'b, A: Addressable> StorageDevice<'a, 'b, A>
Card or Emmc storage device
Sourcepub async fn read_block(
&mut self,
block_idx: u32,
data_block: &mut DataBlock,
) -> Result<(), Error>
pub async fn read_block( &mut self, block_idx: u32, data_block: &mut DataBlock, ) -> Result<(), Error>
Read a data block.
Sourcepub async fn read_blocks(
&mut self,
block_idx: u32,
blocks: &mut [DataBlock],
) -> Result<(), Error>
pub async fn read_blocks( &mut self, block_idx: u32, blocks: &mut [DataBlock], ) -> Result<(), Error>
Read multiple data blocks.
Trait Implementations§
Source§impl<'d, 'e, A: Addressable> BlockDevice<512> for StorageDevice<'d, 'e, A>
impl<'d, 'e, A: Addressable> BlockDevice<512> for StorageDevice<'d, 'e, A>
Source§async fn read(
&mut self,
block_address: u32,
buf: &mut [Aligned<Self::Align, [u8; 512]>],
) -> Result<(), Self::Error>
async fn read( &mut self, block_address: u32, buf: &mut [Aligned<Self::Align, [u8; 512]>], ) -> Result<(), Self::Error>
Read one or more blocks at the given block address.
Auto Trait Implementations§
impl<'a, 'b, T> Freeze for StorageDevice<'a, 'b, T>where
T: Freeze,
impl<'a, 'b, T> !RefUnwindSafe for StorageDevice<'a, 'b, T>
impl<'a, 'b, T> Send for StorageDevice<'a, 'b, T>where
T: Send,
impl<'a, 'b, T> Sync for StorageDevice<'a, 'b, T>where
T: Sync,
impl<'a, 'b, T> Unpin for StorageDevice<'a, 'b, T>where
T: Unpin,
impl<'a, 'b, T> !UnwindSafe for StorageDevice<'a, 'b, T>
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