Merge pull request #47 from jongho123/master

update dht.cpp. mod readHumidity().
This commit is contained in:
Paint Your Dragon 2019-01-11 16:01:00 -08:00 committed by GitHub
commit 562a4878a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -71,7 +71,7 @@ float DHT::convertFtoC(float f) {
float DHT::readHumidity(bool force) { float DHT::readHumidity(bool force) {
float f = NAN; float f = NAN;
if (read()) { if (read(force)) {
switch (_type) { switch (_type) {
case DHT11: case DHT11:
f = data[0]; f = data[0];