- test driving
This commit is contained in:
2023-10-10 17:06:30 +02:00
parent fd3155f49d
commit 692adf7e16
8 changed files with 38 additions and 31 deletions
+2 -2
View File
@@ -112,7 +112,7 @@ void TestMode::abortManeuver() {
}
uint8_t TestMode::getRemainingManeuverTime() const {
if (busy)
if (this->busy)
return (uint8_t) ((this->maneuverTime - (millis() - this->actionStart)) / 1000);
return 0;
}
@@ -120,7 +120,7 @@ uint8_t TestMode::getRemainingManeuverTime() const {
bool TestMode::engineInit(int16_t powerPercentage, int16_t seconds) {
if (this->busy)
return false;
if (powerPercentage >= 100 || powerPercentage <= -100)
if (powerPercentage > 100 || powerPercentage < -100)
return false;
if (seconds < 0)
return false;