packaging: also support rpmbuild from Tizen:2.3
[contrib/mraa.git] / include / mraa_internal_types.h
index 844509f..1c76e33 100644 (file)
@@ -27,7 +27,6 @@
 
 #include "common.h"
 #include "mraa.h"
-#include "mraa_func.h"
 #include "mraa_adv_func.h"
 #include "iio.h"
 
@@ -137,11 +136,15 @@ struct _iio {
     int num; /**< IIO device number */
     char* name; /**< IIO device name */
     int fp; /**< IIO device in /dev */
+    int fp_event;  /**<  event file descriptor for IIO device */
     void (* isr)(char* data); /**< the interupt service request */
     void *isr_args; /**< args return when interupt service request triggered */
+    void (* isr_event)(struct iio_event_data* data, void* args); /**< the event interupt service request */
     int chan_num;
     pthread_t thread_id; /**< the isr handler thread id */
     mraa_iio_channel* channels;
+    int event_num;
+    mraa_iio_event* events;
     int datasize;
 };
 
@@ -285,9 +288,10 @@ typedef struct _board_t {
     mraa_pininfo_t* pins;     /**< Pointer to pin array */
     mraa_adv_func_t* adv_func;    /**< Pointer to advanced function disptach table */
     struct _board_t* sub_platform;     /**< Pointer to sub platform */
-    struct _iio* iio_devices; /**< Pointer to IIO devices */
-    uint8_t iio_device_count; /**< IIO device count */
     /*@}*/
 } mraa_board_t;
 
-
+typedef struct {
+    struct _iio* iio_devices; /**< Pointer to IIO devices */
+    uint8_t iio_device_count; /**< IIO device count */
+} mraa_iio_info_t;