25 #ifndef UTILS_TIMEOUT_H_ 26 #define UTILS_TIMEOUT_H_ 64 void (*handler)(
struct timeout *, uint8_t,
void *);
75 void (*handler)(
struct timeout *, uint8_t,
void *),
void *handler_opaque);
92 uint32_t util_timeout_next(
struct timeout_manager *mgr, uint32_t cur_ts);
102 uint32_t us, uint8_t type);
108 uint32_t us, uint8_t type, uint32_t cur_ts);
119 #endif // ndef UTILS_TIMEOUT_H_ struct timeout * timeouts_first
uint32_t timeout_type
Time and type. Type is stored in the 4 most significant bits, and the time in the 28 least significan...
uint32_t util_timeout_time_us(void)
struct timeout * timeouts_last
struct timeout * due_last
struct timeout * due_first
int util_timeout_init(struct timeout_manager *mgr, void(*handler)(struct timeout *, uint8_t, void *), void *handler_opaque)
void util_timeout_poll(struct timeout_manager *mgr)
void util_timeout_disarm(struct timeout_manager *mgr, struct timeout *to)
void util_timeout_poll_ts(struct timeout_manager *mgr, uint32_t cur_ts)
void util_timeout_arm_ts(struct timeout_manager *mgr, struct timeout *to, uint32_t us, uint8_t type, uint32_t cur_ts)
void util_timeout_arm(struct timeout_manager *mgr, struct timeout *to, uint32_t us, uint8_t type)