Skip to content

Commit

Permalink
waterCheckInterval variable name updated
Browse files Browse the repository at this point in the history
  • Loading branch information
genkigenki authored and fiendie committed Jan 8, 2024
1 parent 43c04c2 commit 751c016
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ int backflushState = 10; // counter for state machine
// Water sensor
boolean waterFull = true;
unsigned long lastWaterCheck;
const unsigned long WaterCheckInterval = 200; // Check water level every 200 ms
const unsigned long waterCheckInterval = 200; // Check water level every 200 ms
int waterCheckConsecutiveReads = 0; // Counter for consecutive readings of water sensor
const int waterCountsNeeded = 3; // Number of same readings to change water sensing

Expand Down Expand Up @@ -2474,7 +2474,7 @@ void loopLED() {
}

void loopWater() {
if ((millis() - lastWaterCheck) > WaterCheckInterval) {
if ((millis() - lastWaterCheck) > waterCheckInterval) {
lastWaterCheck = millis();

bool isWaterDetected = digitalRead(PIN_WATERSENSOR) == (WATER_SENS == 1 ? LOW : HIGH);
Expand Down

0 comments on commit 751c016

Please sign in to comment.