Skip to content

Commit dd0b9e7

Browse files
committed
Linted
1 parent 21b930c commit dd0b9e7

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

adafruit_bno055.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -189,10 +189,10 @@ def mode(self):
189189
legend: x=on, -=off (see Table 3-3 in datasheet)
190190
191191
+------------------+-------+---------+------+----------+----------+
192-
| Mode | Accel | Compass | Gyro | Fusion | Fusion |
193-
| | | (Mag) | | Absolute | Relative |
192+
| Mode | Accel | Compass | Gyro | Fusion | Fusion |
193+
| | | (Mag) | | Absolute | Relative |
194194
+==================+=======+=========+======+==========+==========+
195-
| CONFIG_MODE | - | - | - | - | - |
195+
| CONFIG_MODE | - | - | - | - | - |
196196
+------------------+-------+---------+------+----------+----------+
197197
| ACCONLY_MODE | X | - | - | - | - |
198198
+------------------+-------+---------+------+----------+----------+
@@ -212,7 +212,7 @@ def mode(self):
212212
+------------------+-------+---------+------+----------+----------+
213213
| COMPASS_MODE | X | X | - | X | - |
214214
+------------------+-------+---------+------+----------+----------+
215-
| M4G_MODE | X | X | - | - | X |
215+
| M4G_MODE | X | X | - | - | X |
216216
+------------------+-------+---------+------+----------+----------+
217217
| NDOF_FMC_OFF_MODE| X | X | X | X | - |
218218
+------------------+-------+---------+------+----------+----------+
@@ -363,7 +363,7 @@ def magnetic(self):
363363
"""Gives the raw magnetometer readings in microteslas.
364364
Returns an empty tuple of length 3 when this property has been disabled by the current mode.
365365
"""
366-
if self.mode not in [0x00, 0X01, 0x03, 0x05, 0x08]:
366+
if self.mode not in [0x00, 0x01, 0x03, 0x05, 0x08]:
367367
return self._magnetic
368368
return (None, None, None)
369369

@@ -714,37 +714,37 @@ def _temperature(self):
714714
@property
715715
def _acceleration(self):
716716
resp = struct.unpack("<hhh", self._read_register(0x08, 6))
717-
return tuple([x / 100 for x in resp])
717+
return tuple(x / 100 for x in resp)
718718

719719
@property
720720
def _magnetic(self):
721721
resp = struct.unpack("<hhh", self._read_register(0x0E, 6))
722-
return tuple([x / 16 for x in resp])
722+
return tuple(x / 16 for x in resp)
723723

724724
@property
725725
def _gyro(self):
726726
resp = struct.unpack("<hhh", self._read_register(0x14, 6))
727-
return tuple([x * 0.001090830782496456 for x in resp])
727+
return tuple(x * 0.001090830782496456 for x in resp)
728728

729729
@property
730730
def _euler(self):
731731
resp = struct.unpack("<hhh", self._read_register(0x1A, 6))
732-
return tuple([x / 16 for x in resp])
732+
return tuple(x / 16 for x in resp)
733733

734734
@property
735735
def _quaternion(self):
736736
resp = struct.unpack("<hhhh", self._read_register(0x20, 8))
737-
return tuple([x / (1 << 14) for x in resp])
737+
return tuple(x / (1 << 14) for x in resp)
738738

739739
@property
740740
def _linear_acceleration(self):
741741
resp = struct.unpack("<hhh", self._read_register(0x28, 6))
742-
return tuple([x / 100 for x in resp])
742+
return tuple(x / 100 for x in resp)
743743

744744
@property
745745
def _gravity(self):
746746
resp = struct.unpack("<hhh", self._read_register(0x2E, 6))
747-
return tuple([x / 100 for x in resp])
747+
return tuple(x / 100 for x in resp)
748748

749749
@property
750750
def offsets_accelerometer(self):

0 commit comments

Comments
 (0)