watchdog handling finished
This commit is contained in:
@ -15,9 +15,11 @@ public:
|
||||
|
||||
enum class LoopResult {
|
||||
OK,
|
||||
SUSPEND_RQ,
|
||||
CANCEL_RQ,
|
||||
RESTART_RQ,
|
||||
TIMEOUT
|
||||
TIMEOUT,
|
||||
FAULT
|
||||
};
|
||||
|
||||
WatchdogTask();
|
||||
@ -28,10 +30,17 @@ public:
|
||||
private:
|
||||
int fd = 0;
|
||||
|
||||
bool obswRunning = false;
|
||||
bool watchdogRunning = false;
|
||||
std::array<uint8_t, 64> buf;
|
||||
States state = States::NOT_STARTED;
|
||||
|
||||
LoopResult watchdogLoop();
|
||||
LoopResult pollEvent(struct pollfd& waiter);
|
||||
LoopResult parseCommandByte(ssize_t readLen);
|
||||
|
||||
int performRunningOperation();
|
||||
int performTimeoutOperation();
|
||||
};
|
||||
|
||||
#endif /* WATCHDOG_WATCHDOG_H_ */
|
||||
|
Reference in New Issue
Block a user