summaryrefslogtreecommitdiffstats
path: root/ctl-lib/ctl-timer.h
diff options
context:
space:
mode:
authorfulup <fulup.arfoll@iot.bzh>2017-10-18 11:31:33 +0200
committerfulup <fulup.arfoll@iot.bzh>2017-10-18 11:31:33 +0200
commit17a6011775e8c6d1536994f8b9cd4fa2f99791f7 (patch)
tree262f653a0369d080e2368bddd840e3c0fa089b29 /ctl-lib/ctl-timer.h
parent29d0c8e83b1ac766395d2d5bee4d83cb0148a7ec (diff)
1st V2/pre-V3 version
Diffstat (limited to 'ctl-lib/ctl-timer.h')
-rw-r--r--ctl-lib/ctl-timer.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/ctl-lib/ctl-timer.h b/ctl-lib/ctl-timer.h
index b08299f..ced0417 100644
--- a/ctl-lib/ctl-timer.h
+++ b/ctl-lib/ctl-timer.h
@@ -26,17 +26,19 @@
typedef int (*timerCallbackT)(void *context);
typedef struct TimerHandleS {
+ int magic;
int count;
int delay;
const char*label;
void *context;
timerCallbackT callback;
sd_event_source *evtSource;
+ AFB_ApiT api;
+ timerCallbackT freeCB;
} TimerHandleT;
-PUBLIC int TimerEvtInit (void);
-PUBLIC afb_event TimerEvtGet(void);
-PUBLIC void TimerEvtStart(TimerHandleT *timerHandle, timerCallbackT callback, void *context);
+PUBLIC int TimerEvtInit (AFB_ApiT apiHandle);
+PUBLIC void TimerEvtStart(AFB_ApiT apiHandle, TimerHandleT *timerHandle, timerCallbackT callback, void *context);
PUBLIC void TimerEvtStop(TimerHandleT *timerHandle);
#endif // CTL_TIMER_INCLUDE