Skip to content

Commit 32a5a8a

Browse files
authored
Merge pull request #25 from peterhinch/issues_23_24
Fix gyro scaling for degrees. Temperature is signed byte.
2 parents f2f1468 + 789293d commit 32a5a8a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

adafruit_bno055.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ class BNO055:
9191
Driver for the BNO055 9DOF IMU sensor.
9292
"""
9393

94-
temperature = _ReadOnlyUnaryStruct(0x34, 'B')
94+
temperature = _ReadOnlyUnaryStruct(0x34, 'b')
9595
"""Measures the temperature of the chip in degrees Celsius."""
9696
accelerometer = _ScaledReadOnlyStruct(0x08, '<hhh', 1/100)
9797
"""Gives the raw accelerometer readings, in m/s.
@@ -107,7 +107,7 @@ class BNO055:
107107
other drivers too."""
108108
magnetic = _ScaledReadOnlyStruct(0x0e, '<hhh', 1/16)
109109
"""Gives the raw magnetometer readings in microteslas."""
110-
gyroscope = _ScaledReadOnlyStruct(0x14, '<hhh', 1/900)
110+
gyroscope = _ScaledReadOnlyStruct(0x14, '<hhh', 1/16)
111111
"""Gives the raw gyroscope reading in degrees per second."""
112112
euler = _ScaledReadOnlyStruct(0x1a, '<hhh', 1/16)
113113
"""Gives the calculated orientation angles, in degrees."""

0 commit comments

Comments
 (0)