mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-18 12:52:44 +01:00
event_periodic_callback: add getter for user context
This commit is contained in:
parent
2039a10e71
commit
e20b966109
@ -40,6 +40,17 @@ typedef struct {
|
||||
event_callback_t event; /**< callback event portion */
|
||||
} event_periodic_callback_t;
|
||||
|
||||
/**
|
||||
* @brief Get user context from Periodic Callback Event
|
||||
*
|
||||
* @param[in] event event_periodic_callback object to initialize
|
||||
* @return User supplied argument to the event
|
||||
*/
|
||||
static inline void *event_periodic_callback_get_arg(event_periodic_callback_t *event)
|
||||
{
|
||||
return event->event.arg;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Initialize a periodic callback event
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user