-
-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathBoxPower.h
More file actions
41 lines (32 loc) · 757 Bytes
/
BoxPower.h
File metadata and controls
41 lines (32 loc) · 757 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#ifndef BoxPower_h
#define BoxPower_h
#include "BaseHeader.h"
#include <EnhancedThread.h>
class BoxPower : public EnhancedThread {
public:
enum class PowerEvent {
PRE_HIBERNATE,
PRE_RESET,
BOX_IDLE,
};
void
initPins(),
begin(),
loop();
void
feedSleepTimer(),
feedSleepTimerSilent(),
reset(),
hibernate();
void
setSdPower(bool power),
setOtherPower(bool power);
bool
getSdPower(),
getOtherPower();
private:
uint8_t _sleepMinutes;
uint32_t _lastFeed;
void _preparePowerDown();
};
#endif