Datasheet
CircuitPython Code
It's easy to use the Si7021 sensor with CircuitPython and the Adafruit CircuitPython SI7021 module. This module allows
you to easily write Python code that reads the humidity and temperature, pressurefrom the sensor.
First wire up a SI7021 to your board exactly as shown on the previous pages for Arduino. Here's an example of wiring
a Feather M0 to the sensor:
Board 3V to sensor VIN
Board GND to sensor GND
Board SCL to sensor SCL
Board SDA to sensor SDA
Next you'll need to install the Adafruit CircuitPython SI7021 library on your CircuitPython board. Remember this
module is for Adafruit CircuitPython firmware and not MicroPython.org firmware!
First make sure you are running the latest version of Adafruit CircuitPython for your board.
Next you'll need to install the necessary libraries to use the hardware--carefully follow the steps to find and install these
libraries from Adafruit's CircuitPython library bundle. For example the Circuit Playground Express guide has a great
page on how to install the library bundle for both express and non-express boards.
Remember for non-express boards like the Trinket M0, Gemma M0, and Feather/Metro M0 basic you'll need to
manually install the necessary libraries from the bundle:
adafruit_si7021.mpy
adafruit_bus_device
© Adafruit Industries https://learn.adafruit.com/adafruit-si7021-temperature-plus-humidity-sensor Page 13 of 17










