37#ifndef EVENT_TIMEOUT_H
38#define EVENT_TIMEOUT_H
68#if IS_USED(MODULE_EVENT_TIMEOUT) || DOXYGEN
118 if (event_timeout->
clock == NULL || event_timeout->
queue == NULL ||
119 event_timeout->
event == NULL) {
void event_timeout_set(event_timeout_t *event_timeout, uint32_t timeout)
Set a timeout.
static bool event_timeout_is_pending(const event_timeout_t *event_timeout)
Check if a timeout event is scheduled to be executed in the future.
void event_timeout_init(event_timeout_t *event_timeout, event_queue_t *queue, event_t *event)
Initialize timeout event object.
void event_timeout_ztimer_init(event_timeout_t *event_timeout, ztimer_clock_t *clock, event_queue_t *queue, event_t *event)
Initialize timeout event object.
void event_timeout_clear(event_timeout_t *event_timeout)
Clear a timeout event.
bool event_is_queued(const event_queue_t *queue, const event_t *event)
Check if an event is already queued.
unsigned ztimer_is_set(const ztimer_clock_t *clock, const ztimer_t *timer)
Check if a timer is currently active.
ztimer_t timer
ztimer object used for timeout
event_t * event
event to post after timeout
event_queue_t * queue
event queue to post event to
ztimer_clock_t * clock
ztimer clock to use