This project used Raspberrypi, Blynk, dht11 (with python)
This project doesn’t working, I don’ t know what should I do
just only the word ‘Blynk’ appears on the screen
please help me !!!
import Adafruit_DHT as dht
import blynklib
BLYNK_AUTH = ‘U7MxSD2HyQbRwILuFGzrvE3AEgQ_man-’
blynk = blynklib.Blynk(BLYNK_AUTH)
sensor = dht.DHT11
pin = 4
while True :
h,t = dht.read_retry(sensor,pin)
if t is None and h is None :
print("Fail")
else :
print("Temp={0:0.1f}*C, Humidity={1:0.1f}*%".format(t,h))
blynk.virtual_write(2, t)
blynk.virtual_write(3, h)
blynk.run()