Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed
Fork of ICE by
Diff: src/ConfigurationHandler/Controls/TimerControl.h
- Revision:
- 156:44f87c5a83ae
- Parent:
- 136:6ad7ba157b70
- Child:
- 157:0d79678ed00f
diff -r 62d9a1c5c25a -r 44f87c5a83ae src/ConfigurationHandler/Controls/TimerControl.h
--- a/src/ConfigurationHandler/Controls/TimerControl.h Fri Sep 30 12:27:14 2016 +0000
+++ b/src/ConfigurationHandler/Controls/TimerControl.h Fri Sep 30 13:37:47 2016 +0000
@@ -17,6 +17,10 @@
std::string controlFile;
std::string id;
std::string output;
+ unsigned int priority;
+ unsigned long startTime;
+ unsigned int duration;
+ unsigned long actualStartTime;
enum State {
STATE_OFF,
@@ -24,16 +28,6 @@
STATE_DISABLED
};
State currentState;
-
- typedef struct {
- unsigned int priority; // uniqueness to each timer element
- unsigned long startTime; // epoch time
- unsigned int duration; // in seconds
- unsigned long actualStarTime;
- } Schedule_t;
-
- std::vector<Schedule_t> schedule;
- unsigned long actualStartTime;
public:
TimerControl() {};
@@ -45,9 +39,17 @@
void display(void);
- std::string getControlFile(void) {
+ std::string getControlFile(void) const {
return controlFile;
}
+
+ std::string getOutput(void) const {
+ return output;
+ }
+
+ unsigned long getStartTime() const {
+ return startTime;
+ }
bool timerStart(void);
bool timerStop(void);
@@ -58,6 +60,8 @@
void start(void);
void update(void);
+ void cleanup(void);
+
// unregister the control with the output task
void unregisterControl(void);
