35 #include "osapi/osapi_dll.h"
40 #ifndef osapi_thread_h
63 #define OSAPI_TIMER_PERIODIC (0x1)
68 #define OSAPI_TIMER_ONE_SHOT (0x0)
75 OSAPI_TIMEOUT_OP_AUTOMATIC = 1,
76 OSAPI_TIMEOUT_OP_MANUAL
88 struct OSAPI_TimerEntry;
89 struct OSAPI_TimeoutHandle
92 struct OSAPI_TimerEntry *_entry;
98 typedef struct OSAPI_TimeoutHandle OSAPI_TimeoutHandle_T;
100 #define OSAPI_TimeoutHandle_INITIALIZER \
114 RTI_INT32 max_entries;
124 struct OSAPI_ThreadProperty thread;
130 #define OSAPI_TimerProperty_INITIALIZER \
135 OSAPI_THREAD_USE_OSDEFAULT_STACKSIZE,\
136 OSAPI_THREAD_PRIORITY_NORMAL,\
137 OSAPI_THREAD_DEFAULT_OPTIONS,\
142 typedef struct OSAPI_Timer *OSAPI_Timer_T;
144 FUNCTION_MUST_TYPEDEF(
150 (*OSAPI_TimerTickHandlerFunction)(OSAPI_Timer_T timer);
174 MUST_CHECK_RETURN OSAPIDllExport OSAPI_Timer_T
203 SHOULD_CHECK_RETURN OSAPIDllExport
RTI_BOOL
250 MUST_CHECK_RETURN OSAPIDllExport
RTI_BOOL
252 OSAPI_TimeoutHandle_T *out_handle,
253 RTI_INT32 timeout_sec,
254 RTI_INT32 timeout_nsec,
256 OSAPI_TimeoutFunction_T timeout_handler,
291 MUST_CHECK_RETURN OSAPIDllExport
RTI_BOOL
293 OSAPI_TimeoutHandle_T *out_handle,
294 RTI_INT32 timeout_sec,
295 RTI_INT32 timeout_nsec);
327 SHOULD_CHECK_RETURN OSAPIDllExport
RTI_BOOL
357 MUST_CHECK_RETURN OSAPIDllExport
RTI_BOOL
359 OSAPI_TimeoutHandle_T *handle);