removed '*' copy error.

This commit is contained in:
Simon IJskes 2019-02-11 12:33:06 +01:00
parent 57fe95c1be
commit 8b9624479e

View File

@ -41,7 +41,7 @@ float DHT::readTemperature(bool S, bool force) {
case DHT11:
f = data[2];
if (data[3] & 0x80) {
f *= -1 -f ;
f = -1 - f ;
}
f += (data[3] & 0x0f) * 0.1;
if(S) {
@ -164,11 +164,11 @@ bool DHT::read(bool force) {
pinMode(_pin, OUTPUT);
digitalWrite(_pin, LOW);
switch(_type) {
case DHT22:
case DHT21:
case DHT22:
case DHT21:
delayMicroseconds(1100); // data sheet says "at least 1ms"
break;
case DHT11:
case DHT11:
default:
delay(20); //data sheet says at least 18ms, 20ms just to be safe
break;