Below is the file 'event.h' from this revision. You can also download the file.
#ifndef __EVENT_H #define __EVENT_H #include "types.h" #define EVENT_TIMER 0 #define EVENT_MPU6050_I2C_COMPLETE 1 #define EVENT_HMC5883L_I2C_COMPLETE 2 #define EVENT_MPL3115A2_I2C_COMPLETE 3 #define EVENT_UART_INPUT 4 #define EVENT_SDCARD 5 #define EVENT_MAX 5 #define EVENT_NONE 0xffff typedef void event_handler(void); void event_set(unsigned int event); bool event_get(unsigned int *event); void event_clear(unsigned int event); bool event_dispatch(void); void event_register(unsigned int event, event_handler *handler); #endif /* __EVENT_H */