I’ve been struggling to get this program working. I’m using a humidity sensor to turn a fogger on and off through a relay for an aeroponics project. First, I was getting “0” as the reading because the firmware hadn’t been upgraded. I updated the firmware after numerous failed attempts. Then, I got error messages, so I reinstalled the software. Now, it freezes up when I run the program. It just sits there with a gray cursor.
Here’s the program I’m running. I’m using a RPi B+ with a GrovePi running Raspbian, the digital temp/humidity sensor, and the Grove Relay. The relay worked fine when the sensor reading was coming out “0”. And I wrote a separate program just to turn the relay off and it worked.
Here is the program:
if humidity < 80:
I’ve rebooted the Pi multiple times. I put several print commands in and it appears to be freezing at the [temp, humidity]=grovepi.dht(sensor,1) line. It prints just before that but does not print just after that. The sensor is plugged into port D7 and the relay is plugged into D4.
Thanks in advance.