AHRS

Dependencies:   Eigen

Dependents:   IndNav_QK3_T265

Revision:
4:3c21fb0c9e84
Child:
8:51062bb877f0
diff -r 6811c0ce95f6 -r 3c21fb0c9e84 ekf.h
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ekf.h	Fri May 03 13:46:40 2019 +0000
@@ -0,0 +1,41 @@
+
+#ifndef EKF_H_
+#define EKF_H_
+
+#include <mbed.h>
+#include "matrix.h"
+
+class ekf
+{
+public:
+
+    ekf(float);
+    virtual ~ekf();
+    float get_est_state(uint8_t);
+    void loop(matrix *);
+    void display_matrix(char);
+    float getRoll(){
+        return x.a[1][1];
+        }
+    float getPitch(){
+        return x.a[2][1];
+        }
+    float getYaw(void){
+        return 0;
+        }
+private:
+    matrix x;
+    matrix x_km;
+    matrix P;
+    matrix Q;
+    matrix R;
+    matrix F;
+    matrix H;
+    matrix K;
+    matrix E;
+    float g,tau_g,m,itau_g,k1,kdm;
+    float Ts;
+    void dgl(matrix *);
+};
+
+#endif
\ No newline at end of file