The unified diff between revisions [cc8258a6..] and [23a3e9a5..] is displayed below. It can also be downloaded as a raw diff.
This diff has been restricted to the following files: 'event.h'
# # old_revision [cc8258a6c3643514892e84cf24fed008bc6f9660] # new_revision [23a3e9a50b4034343e3bd217d2c225dcaec064dd] # # add_file "event.h" # content [6ae28929ff160f4c112bac5954c1fbfa282b6756] # ============================================================ --- /dev/null +++ event.h 6ae28929ff160f4c112bac5954c1fbfa282b6756 @@ -0,0 +1,20 @@ +#ifndef __EVENT_H +#define __EVENT_H + +#include "types.h" + +#define EVENT_TIMER 0 +#define EVENT_I2C_COMPLETE 1 +#define EVENT_UART_INPUT 2 + +#define EVENT_MAX 2 + +typedef void event_handler(void); + +void event_set(unsigned int event); +bool event_get(unsigned int *event); +void event_clear(unsigned int event); +void event_dispatch(void); +void event_register(unsigned int event, event_handler *handler); + +#endif /* __EVENT_H */