From 62df855847c12466f3094bd12b284939b5274d89 Mon Sep 17 00:00:00 2001 From: Joe Robinson Date: Sun, 17 Feb 2019 21:06:30 +0000 Subject: Add some debug output --- fruitfly.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'fruitfly.py') diff --git a/fruitfly.py b/fruitfly.py index 53d20e2..ea58818 100644 --- a/fruitfly.py +++ b/fruitfly.py @@ -14,11 +14,13 @@ client = paho.Client(client_id) print("connecting to broker " + broker) client.connect(broker) +print("connected") client.loop_start() while True: humidity, temperature = Adafruit_DHT.read_retry(sensor_type, sensor_pin) - + print(client_id+"/temperature: "+ temperature)) + print(client_id+"/humidity: "+ humidity) client.publish(client_id+"/temperature", temperature) client.publish(client_id+"/humidity", humidity) -- cgit v1.2.3