This commit is contained in:
Matthew Kennedy 2020-12-11 16:50:06 -08:00
parent 5c9acd4c66
commit 770283accd
1 changed files with 1 additions and 1 deletions

View File

@ -94,7 +94,7 @@ static float GetDutyForState(HeaterState state, float heaterEsr)
return rampDuty; return rampDuty;
case HeaterState::ClosedLoop: case HeaterState::ClosedLoop:
// Negated because lower resistance -> hotter // Negated because lower resistance -> hotter
return heaterPid.GetOutput(-HEATER_TARGET_ESR, -heaterEsr); return -heaterPid.GetOutput(HEATER_TARGET_ESR, heaterEsr);
case HeaterState::Stopped: case HeaterState::Stopped:
// Something has gone wrong, return 0. // Something has gone wrong, return 0.
return 0; return 0;