tempcomp: print warning message on error

This commit is contained in:
Miroslav Lichvar
2014-03-20 13:47:08 +01:00
parent 0a56c0e8c1
commit 7a512ad9c3
2 changed files with 8 additions and 0 deletions

View File

@@ -67,7 +67,14 @@ read_timeout(void *arg)
LOG_FileWrite(logfileid, "%s %11.4e %11.4e",
UTI_TimeToLogForm(now.tv_sec), temp, comp);
}
} else {
LOG(LOGS_WARN, LOGF_TempComp,
"Temperature compensation of %.3f ppm exceeds sanity limit of %.1f",
comp, MAX_COMP);
}
} else {
LOG(LOGS_WARN, LOGF_TempComp, "Could not read temperature from %s",
filename);
}
if (f)