adafruit_shtc3¶
A helper library for using the Sensirion SHTC3 Humidity and Temperature Sensor
- Author(s): Bryan Siepert
Implementation Notes¶
Hardware:
- Adafruit SHTC3 Temperature & Humidity Sensor (Product ID: 4636)
Software and Dependencies:
- Adafruit CircuitPython firmware for the supported boards: https://circuitpython.org/downloads
- Adafruit’s Bus Device library: https://github.com/adafruit/Adafruit_CircuitPython_BusDevice
- Adafruit’s Register library: https://github.com/adafruit/Adafruit_CircuitPython_Register
-
class
adafruit_shtc3.SHTC3(i2c_bus)¶ A driver for the SHTC3 temperature and humidity sensor.
Parameters: i2c_bus (I2C) – The I2C bus the SHTC3 is connected to. Quickstart: Importing and using the SHTC3 temperature and humidity sensor
Here is an example of using the
SHTC3. First you will need to import the libraries to use the sensorimport board import adafruit_shtc3
Once this is done, you can define your
board.I2Cobject and define your sensori2c = board.I2C() # uses board.SCL and board.SDA sht = adafruit_shtc3.SHTC3(i2c)
Now you have access to the temperature and humidity using the
measurements. it will return a tuple with thetemperatureandrelative_humiditymeasurementstemperature, relative_humidity = sht.measurements
-
low_power¶ Enables the less accurate low power mode, trading accuracy for power consumption
-
measurements¶ both
temperatureandrelative_humidity, read simultaneously
-
relative_humidity¶ The current relative humidity in % rH. This is a value from 0-100%.
-
reset()¶ Perform a soft reset of the sensor, resetting all settings to their power-on defaults
-
sleeping¶ Determines the sleep state of the sensor
-
temperature¶ The current temperature in degrees Celsius
-