Struct hts221::Builder [] [src]

pub struct Builder<Comm, E> { /* fields omitted */ }

Builder for an HTS221 structure. This builder allows you to configure the chip without needing to access the device:device module.

Defaults are:

  • Averaged samples - untouched
  • Powered on
  • Block update mode
  • One-shot mode
  • No boot
  • Data ready polarity and output mode are unchanged
  • Data ready interrupt is disabled

Methods

impl<Comm, E> Builder<Comm, E> where
    Comm: Write<Error = E> + WriteRead<Error = E>, 
[src]

[src]

Initialize a new Builder for an HTS221 that will use comm for all communication.

[src]

Configures the number of internal temperature samples that will be averaged into one output sample.

[src]

Configures the number of internal humidity samples that will be averaged into one output sample.

[src]

Powers up the device on initialization (default).

[src]

Keeps the device powered down on initialization.

[src]

Sets the update mode on initialization

[src]

Sets the data rate on initialization

[src]

Boots the device (resets stored values) on initialization

[src]

Does not boot the device on initialization (default)

[src]

Sets the polarity of the data-ready output pin.

[src]

Sets the output mode of the data-ready output pin.

[src]

Enables the data-ready external interrupt pin.

[src]

Disables the data-ready external interrupt pin (default).

[src]

Builds an HTS221 handle using the current builder configuration. Consumes the builder.

Trait Implementations

Auto Trait Implementations

impl<Comm, E> Send for Builder<Comm, E> where
    Comm: Send,
    E: Send

impl<Comm, E> Sync for Builder<Comm, E> where
    Comm: Sync,
    E: Sync