Struct rustduino::sensors::AHT10 [−][src]
#[repr(C, packed)]pub struct AHT10<'a> { /* fields omitted */ }
Expand description
Used to control the AHT10 Arduino sensor
Elements
address
- a u8, used to store the address to control the functioning AHT10 sensor.i2c
- atwi
struct object, which would be used to interface the functioning of sensor with communication protocol I2C.vec
- a vector with u8 objects, It would be used to store the data read through the sensors.
Implementations
Creates a new memory mapped IO at the correct location including a 20ms reset delay for wake-up.
Returns
a reference to AHT10 structure
- Which would be used to control the sensor.
Returns reference to the structure without any reset delay.
Returns
a reference to AHT10 structure
- Which would be used to control the sensor.
Initiates the transmission by self initiating the sensor.
Returns
a boolean
- Which is true if transmission initiated otherwise false.
Restart sensor, without power off in around ~20ms with all registers restored to default.
Reads data from slave mode using the I2C protocol.
Triggers the AHT10 to read temperature/humidity.
Adds a delay of 5ms when the sensor is already busy with some processing.
Performs measurement of temperature using the functions trigger_slave()
and read_to_buffer()
.