mirror of https://github.com/arendst/Tasmota.git
v5.12.0e - Better fix MAX31850 higher temperatures
5.12.0e * Fix MAX31850 higher temperatures (#1269)
This commit is contained in:
parent
9a421ab6a2
commit
846f4d0178
|
@ -336,11 +336,7 @@ boolean Ds18x20Read(uint8_t sensor, float &t)
|
|||
break;
|
||||
case MAX31850_CHIPID:
|
||||
temp14 = (data[1] << 8) + (data[0] & 0xFC);
|
||||
if (temp14 < 0) {
|
||||
temp14 = (~temp14) +1;
|
||||
sign = -1;
|
||||
}
|
||||
t = ConvertTemp(sign * temp14 * 0.0625); // Divide by 16
|
||||
t = ConvertTemp(temp14 * 0.0625); // Divide by 16
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -140,12 +140,8 @@ boolean Ds18x20Read(uint8_t sensor, float &t)
|
|||
t = ConvertTemp(sign * temp12 * 0.0625); // Divide by 16
|
||||
break;
|
||||
case MAX31850_CHIPID:
|
||||
temp14 = (data[1] << 8) + (data[0] & 0xFC);
|
||||
if (temp14 < 0) {
|
||||
temp14 = (~temp14) +1;
|
||||
sign = -1;
|
||||
}
|
||||
t = ConvertTemp(sign * temp14 * 0.0625); // Divide by 16
|
||||
temp14 = (data[1] << 8) + (data[0] & 0xFC);
|
||||
t = ConvertTemp(temp14 * 0.0625); // Divide by 16
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue