embedded-devices 0.10.3

Device driver implementations for many embedded sensors and devices
Documentation
1
2
3
4
5
6
7
8
9
10
/// A device which supports any form of software-triggered reset.
#[maybe_async_cfg::maybe(sync(feature = "sync"), async(feature = "async"))]
#[allow(async_fn_in_trait)]
pub trait ResettableDevice {
    /// The error type which may occur when resetting the device
    type Error: core::fmt::Debug;

    /// Performs a best-effort soft-reset of the device.
    async fn reset(&mut self) -> Result<(), Self::Error>;
}