Los Putacos / Mbed OS WearableDevice_Nucleo_New

Dependencies:   MPU9250_SPI

Fork of WearableDevice_Nucleo by Los Putacos

Revision:
26:4bc56ce08d15
Parent:
25:86137c182a17
Child:
27:c4b2ce6fa5b8
--- a/event.h	Fri Oct 27 23:49:44 2017 +0000
+++ b/event.h	Wed Nov 08 10:59:01 2017 +0000
@@ -7,33 +7,54 @@
 *       Date: 12-Oct-2017
 *    Version: V0.1
 */
-#include "pin.h"
+//-----------------------------------------------------------------
+
+//-----------------------------------------------------------------
+#include "mbed.h"
+
+#include "XBeeLib.h"
+#include "SDFileSystem.h"
 #include "MPU9250.h"
-#include "XBeeLib.h"
+//-----------------------------------------------------------------
 
 //-----------------------------------------------------------------
 #ifndef EVENT_H_
 #define EVENT_H_
-
-// void print_stinrg(void);
-// void print_event(void);
-// void blink_event(void);
+#define BufferSize 40000
+#define BufferSize_MIC 10000
 
-// void readIMU(void);
-// void readMicrophone(void);
-// void storeIMU(void);
-// void storeMicrophone(void);
-// void sendData(void);
-// void gayEvent(void);
-void CheckInputBuffer(void);
-void ReadIMUData(void);
-
+// Declarations
 extern XBeeLib::XBeeZB XBee;
-extern Timer time_stamp;
+extern Timer TimeStamp;
 extern mpu9250_spi imu;
 extern AnalogIn micro;
 extern Serial PC;
-extern FILE *fp;
-    
+
+// Read & Writepointers
+extern volatile uint16_t readPointer;
+extern volatile uint16_t readPointer_MIC;
+extern volatile uint16_t writePointer;
+extern volatile uint16_t writePointer_MIC;
+
+// Data Storage Buffers
+extern int16_t Data_Storage[BufferSize];
+extern uint16_t Data_Storage_MIC[BufferSize_MIC];
+
+// Flag Declaration
+extern uint8_t ReadIMU_Flag;
+
+// Time Buffer Declaration
+extern uint16_t Time_Data;
+extern uint8_t Requested_Time;
+
+// Ticker Declaration
+extern Ticker Ticker_IMU;
+
+// Function Declarations
+void ReadIMU(void);
+void ReceiveXBee(void);
+
 #endif // EVENT_H_
+//-----------------------------------------------------------------
+
 //-----------------------------------------------------------------
\ No newline at end of file