MPU6050 library using i2c interface on LPC1768 - Complementary filter is added. Now program can calculate pitch and roll angles.

Fork of MPU6050 by Baser Kandehir

Revision:
7:e4e02c9c1381
Parent:
5:5bff0edcdff8
--- a/MPU6050.h	Wed Aug 05 13:15:07 2015 +0000
+++ b/MPU6050.h	Thu Nov 03 17:14:54 2016 +0000
@@ -30,8 +30,8 @@
 #include "math.h"
 #include "MPU6050RegDef.h"
 
-#define PI 3.14159265359    // This value will be used when calculating angles
-#define dt 0.005            // 200 Hz sampling period
+#define PI 3.141592   // This value will be used when calculating angles
+#define dt 0.01            
 
 extern float aRes, gRes;