software:firmware
MakAir Firmware
rpi_watchdog.h
Go to the documentation of this file.
1 
8 #pragma once
9 #include "../includes/parameters.h"
10 
12 #define COUNTDOWN_IN_S 60
13 
15 class RpiWatchdog {
16  public:
18  RpiWatchdog();
19 
21  void update();
22 
24  void resetCountDown();
25 
27  void disable();
28 
29  private:
30  int32_t m_countDown;
36  DISABLED
37  };
39 };
40 
Watchdog for the Raspberry PI.
Definition: rpi_watchdog.h:15
int32_t m_countDown
Definition: rpi_watchdog.h:30
RpiWatchdogStep m_rpiWatchdogStep
Definition: rpi_watchdog.h:38
@ SWITCH_ON_RASPBERRY
Definition: rpi_watchdog.h:34
@ WAIT_FOR_FIRST_HEARTBEAT
Definition: rpi_watchdog.h:35
@ SWITCH_OFF_RASPBERRY
Definition: rpi_watchdog.h:33
RpiWatchdog()
Default constructor.
void update()
This should be called by the main state machine every 1s.
void disable()
Disable countdown mode (used for debug)
void resetCountDown()
When the UI software on the Raspberry PI sends a heartbeat, reset countdown.
RpiWatchdog rpiWatchdog