Skip to content

Commit edd9b11

Browse files
committed
Merge pull request adafruit#28 from bahamas10/patch-1
dht script should exit non-zero if reading failed
2 parents 003b6c6 + 4ab86a3 commit edd9b11

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

examples/AdafruitDHT.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,4 @@
4848
print 'Temp={0:0.1f}*C Humidity={1:0.1f}%'.format(temperature, humidity)
4949
else:
5050
print 'Failed to get reading. Try again!'
51+
sys.exit(1)

0 commit comments

Comments
 (0)