[−][src]Struct embedded_ccs811::Ccs811Awake
Already awake CCS811 device driver
This can be used when the nWAKE pin is connected directly to GND or when
handling the device waking manually instead of using the Ccs811
wrapper type.
Methods
impl<I2C> Ccs811Awake<I2C, Boot>
[src]
pub fn new(i2c: I2C, address: SlaveAddr) -> Self
[src]
Create new instance of an already awake CCS811 device.
impl<I2C, E, MODE> Ccs811Awake<I2C, MODE> where
I2C: Write<Error = E>,
[src]
I2C: Write<Error = E>,
Trait Implementations
impl<I2C, E> Ccs811AppMode for Ccs811Awake<I2C, App> where
I2C: Write<Error = E> + WriteRead<Error = E>,
[src]
I2C: Write<Error = E> + WriteRead<Error = E>,
type Error = ErrorAwake<E>
Error type
type ModeChangeError = ModeChangeError<ErrorAwake<E>, Self>
Boot/App mode change error
type BootModeType = Ccs811Awake<I2C, Boot>
Boot mode type
fn set_mode(&mut self, mode: MeasurementMode) -> Result<(), Self::Error>
[src]
fn has_data_ready(&mut self) -> Result<bool, Self::Error>
[src]
fn raw_data(&mut self) -> Result<(u8, u16), Self::Error>
[src]
fn data(&mut self) -> Result<AlgorithmResult, Self::Error>
[src]
fn set_environment(
&mut self,
humidity_percentage: f32,
temperature_celsius: f32
) -> Result<(), Self::Error>
[src]
&mut self,
humidity_percentage: f32,
temperature_celsius: f32
) -> Result<(), Self::Error>
fn baseline(&mut self) -> Result<[u8; 2], Self::Error>
[src]
fn set_baseline(&mut self, baseline: [u8; 2]) -> Result<(), Self::Error>
[src]
fn set_eco2_thresholds(
&mut self,
low_to_medium: u16,
medium_to_high: u16
) -> Result<(), Self::Error>
[src]
&mut self,
low_to_medium: u16,
medium_to_high: u16
) -> Result<(), Self::Error>
fn set_interrupt_mode(&mut self, mode: InterruptMode) -> Result<(), Self::Error>
[src]
fn software_reset(self) -> Result<Self::BootModeType, Self::ModeChangeError>
[src]
impl<I2C, E> Ccs811BootMode for Ccs811Awake<I2C, Boot> where
I2C: Write<Error = E> + WriteRead<Error = E>,
[src]
I2C: Write<Error = E> + WriteRead<Error = E>,
type Error = ErrorAwake<E>
Error type
type ModeChangeError = ModeChangeError<Self::Error, Self>
Boot/App mode change error
type TargetType = Ccs811Awake<I2C, App>
Application mode type
fn start_application(self) -> Result<Self::TargetType, Self::ModeChangeError>
[src]
fn verify_application(&mut self) -> Result<(), Self::Error>
[src]
fn erase_application(&mut self) -> Result<(), Self::Error>
[src]
fn download_application<D: DelayMs<u16>>(
&mut self,
bin: &[u8],
delay: &mut D
) -> Result<(), Self::Error>
[src]
&mut self,
bin: &[u8],
delay: &mut D
) -> Result<(), Self::Error>
fn update_application<D: DelayMs<u16>>(
&mut self,
bin: &[u8],
delay: &mut D
) -> Result<(), Self::Error>
[src]
&mut self,
bin: &[u8],
delay: &mut D
) -> Result<(), Self::Error>
fn software_reset(&mut self) -> Result<(), Self::Error>
[src]
impl<I2C, E, MODE> Ccs811Device for Ccs811Awake<I2C, MODE> where
I2C: Write<Error = E> + WriteRead<Error = E>,
[src]
I2C: Write<Error = E> + WriteRead<Error = E>,
type Error = ErrorAwake<E>
Error type
fn firmware_mode(&mut self) -> Result<FirmwareMode, Self::Error>
[src]
fn has_valid_app(&mut self) -> Result<bool, Self::Error>
[src]
fn hardware_id(&mut self) -> Result<u8, Self::Error>
[src]
fn hardware_version(&mut self) -> Result<(u8, u8), Self::Error>
[src]
fn firmware_bootloader_version(&mut self) -> Result<(u8, u8, u8), Self::Error>
[src]
fn firmware_application_version(&mut self) -> Result<(u8, u8, u8), Self::Error>
[src]
impl<I2C: Debug, MODE: Debug> Debug for Ccs811Awake<I2C, MODE>
[src]
Auto Trait Implementations
impl<I2C, MODE> RefUnwindSafe for Ccs811Awake<I2C, MODE> where
I2C: RefUnwindSafe,
MODE: RefUnwindSafe,
I2C: RefUnwindSafe,
MODE: RefUnwindSafe,
impl<I2C, MODE> Send for Ccs811Awake<I2C, MODE> where
I2C: Send,
MODE: Send,
I2C: Send,
MODE: Send,
impl<I2C, MODE> Sync for Ccs811Awake<I2C, MODE> where
I2C: Sync,
MODE: Sync,
I2C: Sync,
MODE: Sync,
impl<I2C, MODE> Unpin for Ccs811Awake<I2C, MODE> where
I2C: Unpin,
MODE: Unpin,
I2C: Unpin,
MODE: Unpin,
impl<I2C, MODE> UnwindSafe for Ccs811Awake<I2C, MODE> where
I2C: UnwindSafe,
MODE: UnwindSafe,
I2C: UnwindSafe,
MODE: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
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>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,