Skip to content

Commit

Permalink
Merge pull request #1481 from discip/patch-1
Browse files Browse the repository at this point in the history
fixed CJC calibration condition
  • Loading branch information
Ralim authored Nov 24, 2022
2 parents 30f1840 + c55ecbf commit f031b31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/Core/Threads/GUIThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ void performCJCC() {
// Calibrate Cold Junction Compensation directly at boot, before internal components get warm.
OLED::refresh();
osDelay(50);
if (!isTipDisconnected() && (TipThermoModel::getTipInC() - getHandleTemperature(0) / 10) < 10) {
if (!isTipDisconnected() && abs( int(TipThermoModel::getTipInC() - getHandleTemperature(0) / 10)) < 10) {
uint16_t setoffset = 0;
// If the thermo-couple at the end of the tip, and the handle are at
// equilibrium, then the output should be zero, as there is no temperature
Expand Down Expand Up @@ -1231,4 +1231,4 @@ void startGUITask(void const *argument) {
GUIDelay();
}
}
}
}

0 comments on commit f031b31

Please sign in to comment.