|
|
@ -172,9 +172,13 @@ void thermostatCheck(){
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void readSensor() {
|
|
|
|
void readSensor() {
|
|
|
|
|
|
|
|
float tempC = sensor.getTempCByIndex(0);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(tempC != DEVICE_DISCONNECTED_C){
|
|
|
|
// read the actual temperature after it's been converted
|
|
|
|
// read the actual temperature after it's been converted
|
|
|
|
temperature = sensor.getTempCByIndex(0) + CORRECTION;
|
|
|
|
temperature = tempC + CORRECTION;
|
|
|
|
// do what you need with the temperature here
|
|
|
|
// do what you need with the temperature here
|
|
|
|
|
|
|
|
}
|
|
|
|
metrics = "temp ";
|
|
|
|
metrics = "temp ";
|
|
|
|
metrics += temperature;
|
|
|
|
metrics += temperature;
|
|
|
|
}
|
|
|
|
}
|
|
|
|