avr-fw-modules/core/src/event_pull.c

21 lines
270 B
C
Executable File

#include <hwo/events.h>
#include <sys/atomic.h>
#include <hwo/threads.h>
#include <stdlib.h>
/*! \brief Wartet auf einen Event und liefert ihn zurück.
*
*/
EVENT* event_pull(void)
{
EVENT *e;
do
{
e = event_wait( 100 );
if (e)
return e;
} while (1);
};