User Tools

Site Tools


dh22

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revisionBoth sides next revision
dh22 [2021/12/14 22:32] – created admindh22 [2021/12/19 20:58] admin
Line 2: Line 2:
  
 <code python> <code python>
-#!/usr/bin/python+#!/usr/bin/python3
  
 import os, sys import os, sys
Line 22: Line 22:
 sensor = Adafruit_DHT.DHT22 sensor = Adafruit_DHT.DHT22
  
-# The GPIO17 - Board number 11 +# The GPIO17 - Board number 3 
-pin = '17'+pin = '2'
  
 humidity, temperature = Adafruit_DHT.read_retry(sensor, pin) humidity, temperature = Adafruit_DHT.read_retry(sensor, pin)
dh22.txt · Last modified: 2021/12/19 21:07 by admin