aaa

Revision:
1:a823f3d5217c
Parent:
0:98a0cccbc509
--- a/MPU9250.cpp	Tue Jul 05 07:09:43 2016 +0000
+++ b/MPU9250.cpp	Mon Nov 16 10:41:58 2020 +0000
@@ -3,6 +3,8 @@
 #define Kp 2.0f * 5.0f // these are the free parameters in the Mahony filter and fusion scheme, Kp for proportional feedback, Ki for integral
 #define Ki 0.0f
 
+
+
 //******************************************************************************
 MPU9250::MPU9250(PinName sda, PinName scl)
 {
@@ -197,6 +199,7 @@
  
  // Set gyroscope full scale range
  // Range selects FS_SEL and AFS_SEL are 0 - 3, so 2-bit values are left-shifted into positions 4:3
+  Gscale = GFS_500DPS;
   uint8_t c =  readByte(MPU9250_ADDRESS, GYRO_CONFIG);
   writeByte(MPU9250_ADDRESS, GYRO_CONFIG, c & ~0xE0); // Clear self-test bits [7:5] 
   writeByte(MPU9250_ADDRESS, GYRO_CONFIG, c & ~0x18); // Clear AFS bits [4:3]