Calibration program for my port of FreeIMU library. Use it with the FreeIMU Cube program or the python calibration program.

Dependencies:   FreeIMU mbed-rtos mbed

Revision:
4:145d1eb8a15d
Parent:
3:cc1415081d36
Child:
5:d21e84d6f5a1
--- a/main.cpp	Fri Jan 10 05:52:20 2014 +0000
+++ b/main.cpp	Wed Mar 28 21:07:33 2018 +0000
@@ -67,14 +67,18 @@
 }
 
 //if the Processing program cannot accept serial inputs, uncomment this to send quaternion information automatically
-//#define AUTO_OUTPUT
+// #define AUTO_OUTPUT
 
 int main()
 {
+    RtosTimer IMUTimer(getIMUdata, osTimerPeriodic, (void *)0);
     pc.baud(115200);
+    // pc.printf("123456789012345678901234567890123456789012345678901234567890\r\n");
     imu.init(true);
+    // pc.printf("fresfgsdgfsgdfgsdg123456789012345fdsgsdgd678901234567890123456789012345678901234567890\r\n");
     pc.baud(115200);
-    RtosTimer IMUTimer(getIMUdata, osTimerPeriodic, (void *)0);
+    
+    // start data collection
     IMUTimer.start(5);
 
     while(true) {
@@ -133,7 +137,7 @@
                 writeArr(raw_values, 6, sizeof(int16_t)); // writes accelerometer and gyro values
 
                 imu.magn->getValues(&raw_values[0], &raw_values[1], &raw_values[2]);
-                writeArr(raw_values, 3, sizeof(int16_t));
+                writeArr(raw_values, 3, sizeof(int16_t)); // write magnetometer values
 
                 pc.printf("\r\n");
                 Thread::wait(4);