Minor changes

This commit is contained in:
dario
2023-09-28 12:32:47 +02:00
parent 73bf55a0b4
commit 8086b2d8e5
4 changed files with 6 additions and 4 deletions

View File

@@ -31,5 +31,6 @@
// Settings for TACOS
#define STA_TACOS_MANAGER_PRIORITY osPriorityNormal
#define STA_TACOS_NUM_STATES 4
#define STA_TACOS_INITIAL_STATE 0
#endif /* INC_STA_CONFIG_HPP_ */

View File

@@ -29,15 +29,16 @@ namespace sta
lockoutTimer_.setCallback([](void *) { STA_DEBUG_PRINTLN("[LOCKOUT TIMEOUT]"); }, nullptr);
lockoutTimer_.start(5000);
failsafeTimer_.setCallback([](void *) { STA_DEBUG_PRINTLN("[FAILSAFE TIMEOUT]"); }, nullptr);
failsafeTimer_.setCallback([](void * arg) { STA_DEBUG_PRINTLN("[FAILSAFE TIMEOUT]"); }, nullptr);
failsafeTimer_.start(10000);
}
void Statemachine::func()
{
STA_DEBUG_PRINTLN("LOOPY LOOP IN STATEMACHINE.");
STA_DEBUG_PRINTLN(lockoutTimer_.isRunning() ? "LOCKOUT RUNNING!" : "LOCKOUT STOPPED!");
osDelay(3000);
osDelay(500);
}
uint16_t Statemachine::getCurrentState() const