diff Small_CPU/Src/compass.c @ 115:3834b6272ee5 FlipDisplay

Merge with 68181cd61f2069d061621c2cd2a6afddb7486f5e
author Ideenmodellierer
date Thu, 03 Jan 2019 19:59:36 +0100
parents 22a1094545f3
children 14e4c83a7559
line wrap: on
line diff
--- a/Small_CPU/Src/compass.c	Thu Jan 03 18:35:11 2019 +0100
+++ b/Small_CPU/Src/compass.c	Thu Jan 03 19:59:36 2019 +0100
@@ -1853,7 +1853,6 @@
     while((ticks) < 60 * 1000)
     {
 				compass_read();
-
 				acceleration_read();
 				compass_calc_roll_pitch_only();
 			
@@ -1873,15 +1872,16 @@
 				}
 
 				copyCompassDataDuringCalibration(compass_DX_f,compass_DY_f,compass_DZ_f);
-        compass_add_calibration(&g);
+				compass_add_calibration(&g);
 				HAL_Delay(1);
 				lasttick = HAL_GetTick();
 				if(lasttick == 0)
 				{
 					 tickstart = -ticks;
 				}	
+				HAL_Delay(1);
 				ticks = lasttick - tickstart;
-		}
+    }
         
     compass_solve_calibration(&g);