Have tried connecting the VCC to both 3.3V and 5V
Have tried with both Adafruit_DHT.DHT11 and Adafruit_DHT.DHT22 in the code for the same sensor but I get None None
import Adafruit_DHT # Sensor should be set to Adafruit_DHT.DHT11, # Adafruit_DHT.DHT22, or Adafruit_DHT.AM2302. sensor = Adafruit_DHT.DHT22 pin = 26 while True: humidity, temperature = Adafruit_DHT.read_retry(sensor, pin) print(temperature, humidity)
Is the sensor broken??Should I replace it or is there any other solution??
Thanks in Advance