Temperature & Humidity in Python

Intermediate

Read the SHT40 sensor with `pybot.temperature()` and `pybot.humidity()` and display both values live on the OLED. Then add a heat alert that lights the RED LED whenever the temperature crosses a threshold.

20 min5 steps
SHT40TemperatureHumiditySensorOLEDIntermediate
0 of 5 steps

Step 1 of 5

Connect your board

Power on your Beaver Board — the OLED will show a PIN code. Click Connect in the toolbar, choose Connect via Bluetooth, and select your board. If it's your first time, enter the PIN shown on the screen.

The SHT40 sensor is built into the board on GP6 (SDA) and GP7 (SCL) — no extra wiring needed.