Struct bme680::SettingsBuilder

source ·
pub struct SettingsBuilder { /* private fields */ }
Expand description

Builder to construct the desired settings

Example

use bme680::{IIRFilterSize, OversamplingSetting, SettingsBuilder};
use std::time::Duration;
let settings = SettingsBuilder::new()
    .with_humidity_oversampling(OversamplingSetting::OS2x)
    .with_pressure_oversampling(OversamplingSetting::OS4x)
    .with_temperature_oversampling(OversamplingSetting::OS8x)
    .with_temperature_filter(IIRFilterSize::Size3)
    .with_gas_measurement(Duration::from_millis(1500), 320, 25)
    .with_temperature_offset(-4.25)
    .with_run_gas(true)
    .build();

Implementations

Temperature offset in Celsius, e.g. 4, -8, 1.25

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.