Skip to content

Commit

Permalink
Only send compensation in atlas sensors when needed
Browse files Browse the repository at this point in the history
  • Loading branch information
oscgonfer committed May 17, 2024
1 parent 049ba1d commit 281ef89
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions sam/src/SckAux.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1694,7 +1694,7 @@ bool Atlas::sendCommand(char* command)
}
bool Atlas::tempCompensation()
{
// Temperature comepnsation for PH, EC, and DO
// Temperature compensation for PH, EC, and DO
float temperature;

if (!ORP) {
Expand All @@ -1711,11 +1711,12 @@ bool Atlas::tempCompensation()

temperature = atlasTEMP.newReading[0];
}
}

char data[10];
sprintf(data,"T,%.2f",temperature);
if (!sendCommand(data)) return false;
char data[10];
sprintf(data,"T,%.2f",temperature);
if (!sendCommand(data)) return false;

}

// Salinity compensation only for DO
if (DO && atlasEC.detected) {
Expand Down

0 comments on commit 281ef89

Please sign in to comment.