pub struct AsyncDfu<'a> { /* private fields */ }Expand description
Handle for box-side DFU (from crate::AsyncLagerBox::dfu).
Implementations§
Source§impl AsyncDfu<'_>
impl AsyncDfu<'_>
Sourcepub async fn list(&self) -> Result<Vec<DfuDevice>>
pub async fn list(&self) -> Result<Vec<DfuDevice>>
List DFU-capable devices on the box’s bus (dfu-util -l).
Sourcepub async fn download(
&self,
firmware: &[u8],
opts: &DfuOptions,
) -> Result<DfuOutput>
pub async fn download( &self, firmware: &[u8], opts: &DfuOptions, ) -> Result<DfuOutput>
Download firmware to the selected device (dfu-util -D). Returns
the captured dfu-util output.
Sourcepub async fn detach(&self, opts: &DfuOptions) -> Result<DfuOutput>
pub async fn detach(&self, opts: &DfuOptions) -> Result<DfuOutput>
Detach the selected device from DFU mode (dfu-util -e).
Trait Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for AsyncDfu<'a>
impl<'a> !UnwindSafe for AsyncDfu<'a>
impl<'a> Freeze for AsyncDfu<'a>
impl<'a> Send for AsyncDfu<'a>
impl<'a> Sync for AsyncDfu<'a>
impl<'a> Unpin for AsyncDfu<'a>
impl<'a> UnsafeUnpin for AsyncDfu<'a>
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