ICRS Eurobot 2013

Dependencies:   mbed mbed-rtos Servo QEI

Revision:
20:70d651156779
Parent:
19:4b993a9a156e
--- a/Processes/Kalman/Kalman.h	Sun Apr 07 19:26:07 2013 +0000
+++ b/Processes/Kalman/Kalman.h	Tue Apr 09 15:33:36 2013 +0000
@@ -2,23 +2,25 @@
 #define KALMAN_H
 
 //#include "globals.h"
+#include "rtos.h"
 
 namespace Kalman
 {
 
-typedef struct state {
+typedef struct State {
     float x;
     float y;
     float theta;
-} state ;
+} State ;
 
 //Accessor function to get the state as one consistent struct
-state getState();
+State getState();
 
 //Main loops (to be attached as a thread in main)
-void predictloop(void* dummy);
-void updateloop(void* dummy);
+void predictloop(void const *dummy);
+void updateloop(void const *dummy);
 
+void start_predict_ticker(Thread* predict_thread_ptr_in);
 
 enum measurement_t {SONAR0 = 0, SONAR1, SONAR2, IR0, IR1, IR2};
 const measurement_t maxmeasure = IR2;
@@ -29,13 +31,11 @@
 extern float RawReadings[maxmeasure+1];
 extern float IRpahseOffset;
 
-extern bool Kalman_init;
+extern bool Kalman_inited;
 
 //Initialises the kalman filter
 void KalmanInit();
 
-// reset kalman states
-void KalmanReset();
 }
 
 #endif //KALMAN_H
\ No newline at end of file