From be64fe8fc7286960b9dc9f7cd229999f73e52d81 Mon Sep 17 00:00:00 2001 From: Alexander Klein Date: Tue, 1 Aug 2023 23:44:56 +0200 Subject: [PATCH] First try to fix pre error moves to ok --- lib/Pump/pump.cpp | 2 +- lib/Pump/pump.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/Pump/pump.cpp b/lib/Pump/pump.cpp index 229f735..c0b665b 100644 --- a/lib/Pump/pump.cpp +++ b/lib/Pump/pump.cpp @@ -115,7 +115,7 @@ void Pump::readSensorValues() { bool Pump::checkSensorsValues() { if (millis() - this->lastMillisCheckSensor < Pump::delayCheckSensor) - return true; + return false; this->lastMillisCheckSensor = millis(); if (this->flow > 1) { diff --git a/lib/Pump/pump.h b/lib/Pump/pump.h index 78973d6..d04e601 100644 --- a/lib/Pump/pump.h +++ b/lib/Pump/pump.h @@ -35,13 +35,13 @@ class Pump { private: static const uint8_t delayCheckSensor = 100; static const uint8_t delayReadPressure = 33; - static const uint8_t minPressure = 200; + static const uint8_t minPressure = 400; static const uint16_t restartPressure = 250; static const uint16_t blinkTime = 1000; static const uint16_t delayReadFlow = 1000; static const uint16_t maxPressure = 620; static const uint16_t maxMaxPressureTime = 10000; - static const uint16_t maxPreErrorTime = 30000; + static const uint16_t maxPreErrorTime = 40000; void readSensorValues(); bool checkSensorsValues();