diff --git a/MicroPython_BUILD/components/micropython/esp32/modules/ak8963.py b/MicroPython_BUILD/components/micropython/esp32/modules/ak8963.py index 7eb3af70..8b99e0b1 100644 --- a/MicroPython_BUILD/components/micropython/esp32/modules/ak8963.py +++ b/MicroPython_BUILD/components/micropython/esp32/modules/ak8963.py @@ -64,7 +64,7 @@ def __init__( if 0x48 != self.whoami: raise RuntimeError("AK8963 not found in I2C bus.") - # Sensitivity adjustement values + # Sensitivity adjustment values self._register_char(_CNTL1, _MODE_FUSE_ROM_ACCESS) asax = self._register_char(_ASAX) asay = self._register_char(_ASAY) @@ -72,7 +72,7 @@ def __init__( self._register_char(_CNTL1, _MODE_POWER_DOWN) # Should wait atleast 100us before next mode - self._adjustement = ( + self._adjustment = ( (0.5 * (asax - 128)) / 128 + 1, (0.5 * (asay - 128)) / 128 + 1, (0.5 * (asaz - 128)) / 128 + 1 @@ -94,10 +94,10 @@ def magnetic(self): xyz = list(self._register_three_shorts(_HXL)) self._register_char(_ST2) # Enable updating readings again - # Apply factory axial sensitivy adjustements - xyz[0] *= self._adjustement[0] - xyz[1] *= self._adjustement[1] - xyz[2] *= self._adjustement[2] + # Apply factory axial sensitivy adjustments + xyz[0] *= self._adjustment[0] + xyz[1] *= self._adjustment[1] + xyz[2] *= self._adjustment[2] # Apply output scale determined in constructor so = self._so @@ -118,8 +118,8 @@ def magnetic(self): return tuple(xyz) @property - def adjustement(self): - return self._adjustement + def adjustment(self): + return self._adjustment @property def whoami(self): diff --git a/MicroPython_BUILD/components/micropython/esp32/modules/mpu6500.py b/MicroPython_BUILD/components/micropython/esp32/modules/mpu6500.py index 59e66665..7953a790 100644 --- a/MicroPython_BUILD/components/micropython/esp32/modules/mpu6500.py +++ b/MicroPython_BUILD/components/micropython/esp32/modules/mpu6500.py @@ -30,7 +30,7 @@ _ACCEL_YOUT_H = const(0x3d) _ACCEL_YOUT_L = const(0x3e) _ACCEL_ZOUT_H = const(0x3f) -_ACCEL_ZOUT_L= const(0x40) +_ACCEL_ZOUT_L = const(0x40) _TEMP_OUT_H = const(0x41) _TEMP_OUT_L = const(0x42) _GYRO_XOUT_H = const(0x43) @@ -59,7 +59,7 @@ GYRO_FS_SEL_2000DPS = const(0b00011000) _GYRO_SO_250DPS = 131 -_GYRO_SO_500DPS = 62.5 +_GYRO_SO_500DPS = 65.5 _GYRO_SO_1000DPS = 32.8 _GYRO_SO_2000DPS = 16.4 @@ -71,7 +71,7 @@ SF_G = 1 SF_M_S2 = 9.80665 # 1 g = 9.80665 m/s2 ie. standard gravity SF_DEG_S = 1 -SF_RAD_S = 57.295779578552 # 1 rad/s is 57.295779578552 deg/s +SF_RAD_S = 57.295779513082 # 1 rad/s is 57.295779513082 deg/s class MPU6500: """Class which provides interface to MPU6500 6-axis motion tracking device.""" diff --git a/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/ak8963.py b/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/ak8963.py index 7eb3af70..8b99e0b1 100644 --- a/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/ak8963.py +++ b/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/ak8963.py @@ -64,7 +64,7 @@ def __init__( if 0x48 != self.whoami: raise RuntimeError("AK8963 not found in I2C bus.") - # Sensitivity adjustement values + # Sensitivity adjustment values self._register_char(_CNTL1, _MODE_FUSE_ROM_ACCESS) asax = self._register_char(_ASAX) asay = self._register_char(_ASAY) @@ -72,7 +72,7 @@ def __init__( self._register_char(_CNTL1, _MODE_POWER_DOWN) # Should wait atleast 100us before next mode - self._adjustement = ( + self._adjustment = ( (0.5 * (asax - 128)) / 128 + 1, (0.5 * (asay - 128)) / 128 + 1, (0.5 * (asaz - 128)) / 128 + 1 @@ -94,10 +94,10 @@ def magnetic(self): xyz = list(self._register_three_shorts(_HXL)) self._register_char(_ST2) # Enable updating readings again - # Apply factory axial sensitivy adjustements - xyz[0] *= self._adjustement[0] - xyz[1] *= self._adjustement[1] - xyz[2] *= self._adjustement[2] + # Apply factory axial sensitivy adjustments + xyz[0] *= self._adjustment[0] + xyz[1] *= self._adjustment[1] + xyz[2] *= self._adjustment[2] # Apply output scale determined in constructor so = self._so @@ -118,8 +118,8 @@ def magnetic(self): return tuple(xyz) @property - def adjustement(self): - return self._adjustement + def adjustment(self): + return self._adjustment @property def whoami(self): diff --git a/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/mpu6500.py b/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/mpu6500.py index 59e66665..7953a790 100644 --- a/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/mpu6500.py +++ b/MicroPython_BUILD/components/micropython/esp32/modules_examples/drivers/mpu6500.py @@ -30,7 +30,7 @@ _ACCEL_YOUT_H = const(0x3d) _ACCEL_YOUT_L = const(0x3e) _ACCEL_ZOUT_H = const(0x3f) -_ACCEL_ZOUT_L= const(0x40) +_ACCEL_ZOUT_L = const(0x40) _TEMP_OUT_H = const(0x41) _TEMP_OUT_L = const(0x42) _GYRO_XOUT_H = const(0x43) @@ -59,7 +59,7 @@ GYRO_FS_SEL_2000DPS = const(0b00011000) _GYRO_SO_250DPS = 131 -_GYRO_SO_500DPS = 62.5 +_GYRO_SO_500DPS = 65.5 _GYRO_SO_1000DPS = 32.8 _GYRO_SO_2000DPS = 16.4 @@ -71,7 +71,7 @@ SF_G = 1 SF_M_S2 = 9.80665 # 1 g = 9.80665 m/s2 ie. standard gravity SF_DEG_S = 1 -SF_RAD_S = 57.295779578552 # 1 rad/s is 57.295779578552 deg/s +SF_RAD_S = 57.295779513082 # 1 rad/s is 57.295779513082 deg/s class MPU6500: """Class which provides interface to MPU6500 6-axis motion tracking device."""