File tree 2 files changed +7
-2
lines changed
2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -108,7 +108,12 @@ class BNO055:
108
108
magnetic = _ScaledReadOnlyStruct (0x0e , '<hhh' , 1 / 16 )
109
109
"""Gives the raw magnetometer readings in microteslas."""
110
110
gyroscope = _ScaledReadOnlyStruct (0x14 , '<hhh' , 1 / 16 )
111
- """Gives the raw gyroscope reading in degrees per second."""
111
+ """Gives the raw gyroscope reading in degrees per second.
112
+
113
+ .. warning:: This is deprecated. Use ``gyro`` instead. It'll work with
114
+ other drivers too."""
115
+ gyro = _ScaledReadOnlyStruct (0x14 , '<hhh' , 0.001090830782496456 )
116
+ """Gives the raw gyroscope reading in radians per second."""
112
117
euler = _ScaledReadOnlyStruct (0x1a , '<hhh' , 1 / 16 )
113
118
"""Gives the calculated orientation angles, in degrees."""
114
119
quaternion = _ScaledReadOnlyStruct (0x20 , '<hhhh' , 1 / (1 << 14 ))
Original file line number Diff line number Diff line change 10
10
print ('Temperature: {} degrees C' .format (sensor .temperature ))
11
11
print ('Accelerometer (m/s^2): {}' .format (sensor .accelerometer ))
12
12
print ('Magnetometer (microteslas): {}' .format (sensor .magnetometer ))
13
- print ('Gyroscope (deg /sec): {}' .format (sensor .gyroscope ))
13
+ print ('Gyroscope (rad /sec): {}' .format (sensor .gyro ))
14
14
print ('Euler angle: {}' .format (sensor .euler ))
15
15
print ('Quaternion: {}' .format (sensor .quaternion ))
16
16
print ('Linear acceleration (m/s^2): {}' .format (sensor .linear_acceleration ))
You can’t perform that action at this time.
0 commit comments