SI7021 temperature and humidity sensor
Constructor to create SI7021 sensor
arObj - the arduino parent object
propertyname, propertyvalue - optional property name, value pairs. Current known properties are: Current properties are:
I2C address of the SI7021 (default 0x40)
obj - created SI7020 object
a = arduino()
sensor = arduinosensor.SI7021(a)
Read the temperature
dsObj - the si7021 object
C - read temperature in deg C.
a = arduino()
s = arduinosensor.SI7021(a)
# get temp
temp = s.temperature
See also: arduinosensor.SI7021.
Read the relative humidity
dsObj - the si7021 object
relH - relative humidity as a percentage (0 - 100.0)
Read the sensor info
dsObj - the si7021 object
inf - structure containing the sensor information.
Structure fields are:
Chip firmware version
sensor id1,id2 value
String for detected chip type
Package: arduino