Skip to content

Commit 367dab4

Browse files
authored
Merge pull request #19 from adafruit/dhct_dhcx
fixing "DHCT" typo
2 parents 2ffd1a0 + d8f652c commit 367dab4

6 files changed

+15
-15
lines changed

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Introduction
1414
:target: https://github.com/adafruit/Adafruit_CircuitPython_LSM6DS/actions
1515
:alt: Build Status
1616

17-
CircuitPython library for the ST LSM6DSOX, LSM6DS33, and ISM330DHCT 6-dof Accelerometer and Gyros
17+
CircuitPython library for the ST LSM6DSOX, LSM6DS33, and ISM330DHCX 6-dof Accelerometer and Gyros
1818

1919

2020
Dependencies

adafruit_lsm6ds.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
_LSM6DS_DEFAULT_ADDRESS = const(0x6A)
6464

6565
_LSM6DS_CHIP_ID = const(0x6C)
66-
_ISM330DHCT_CHIP_ID = const(0x6B)
66+
_ISM330DHCX_CHIP_ID = const(0x6B)
6767
_LSM6DS33_CHIP_ID = const(0x69)
6868

6969
_LSM6DS_FUNC_CFG_ACCESS = const(0x1)
@@ -294,15 +294,15 @@ def accelerometer_range(self, value):
294294
def gyro_range(self):
295295
"""Adjusts the range of values that the sensor can measure, from 125 Degrees/second to 4000
296296
degrees/s. Note that larger ranges will be less accurate. Must be a `GyroRange`. 4000 DPS
297-
is only available for the ISM330DHCT"""
297+
is only available for the ISM330DHCX"""
298298
return self._cached_gyro_range
299299

300300
@gyro_range.setter
301301
def gyro_range(self, value):
302302
if not GyroRange.is_valid(value):
303303
raise AttributeError("range must be a `GyroRange`")
304-
if value is GyroRange.RANGE_4000_DPS and not isinstance(self, ISM330DHCT):
305-
raise AttributeError("4000 DPS is only available for ISM330DHCT")
304+
if value is GyroRange.RANGE_4000_DPS and not isinstance(self, ISM330DHCX):
305+
raise AttributeError("4000 DPS is only available for ISM330DHCX")
306306

307307
if value is GyroRange.RANGE_125_DPS:
308308
self._gyro_range_125dps = True
@@ -398,7 +398,7 @@ class LSM6DS33(LSM6DS): # pylint: disable=too-many-instance-attributes
398398
CHIP_ID = _LSM6DS33_CHIP_ID
399399

400400

401-
class ISM330DHCT(LSM6DS): # pylint: disable=too-many-instance-attributes
401+
class ISM330DHCX(LSM6DS): # pylint: disable=too-many-instance-attributes
402402

403403
"""Driver for the LSM6DS33 6-axis accelerometer and gyroscope.
404404
@@ -407,7 +407,7 @@ class ISM330DHCT(LSM6DS): # pylint: disable=too-many-instance-attributes
407407
408408
"""
409409

410-
CHIP_ID = _ISM330DHCT_CHIP_ID
410+
CHIP_ID = _ISM330DHCX_CHIP_ID
411411

412412
def __init__(self, i2c_bus, address=_LSM6DS_DEFAULT_ADDRESS):
413413
super().__init__(i2c_bus, address)

examples/lsm6ds_full_test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
import busio
44

55
# pylint:disable=no-member,unused-import
6-
from adafruit_lsm6ds import LSM6DS33, LSM6DSOX, ISM330DHCT, Rate, AccelRange, GyroRange
6+
from adafruit_lsm6ds import LSM6DS33, LSM6DSOX, ISM330DHCX, Rate, AccelRange, GyroRange
77

88
i2c = busio.I2C(board.SCL, board.SDA)
99

1010
sensor = LSM6DS33(i2c)
1111
# sensor = LSM6DSOX(i2c)
12-
# sensor = ISM330DHCT(i2c)
12+
# sensor = ISM330DHCX(i2c)
1313

1414
sensor.accelerometer_range = AccelRange.RANGE_8G
1515
print(

examples/lsm6ds_ism330dhct_simpletest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import time
22
import board
33
import busio
4-
from adafruit_lsm6ds import ISM330DHCT
4+
from adafruit_lsm6ds import ISM330DHCX
55

66
i2c = busio.I2C(board.SCL, board.SDA)
77

8-
sensor = ISM330DHCT(i2c)
8+
sensor = ISM330DHCX(i2c)
99

1010
while True:
1111
print("Acceleration: X:%.2f, Y: %.2f, Z: %.2f m/s^2" % (sensor.acceleration))

examples/lsm6ds_rate_test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
import busio
33

44
# pylint:disable=no-member,unused-import
5-
from adafruit_lsm6ds import LSM6DS33, LSM6DSOX, ISM330DHCT, Rate
5+
from adafruit_lsm6ds import LSM6DS33, LSM6DSOX, ISM330DHCX, Rate
66

77
i2c = busio.I2C(board.SCL, board.SDA)
88

99
sensor = LSM6DS33(i2c)
1010
# sensor = LSM6DSOX(i2c)
11-
# sensor = ISM330DHCT(i2c)
11+
# sensor = ISM330DHCX(i2c)
1212

1313
while True:
1414
sensor.accelerometer_data_rate = Rate.RATE_12_5_HZ

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
name="adafruit-circuitpython-lsm6ds",
2222
use_scm_version=True,
2323
setup_requires=["setuptools_scm"],
24-
description="CircuitPython library for the ST LSM6DSOX, LSM6DS33, and ISM330DHCT 6-DOF Accelerometer and Gyros",
24+
description="CircuitPython library for the ST LSM6DSOX, LSM6DS33, and ISM330DHCX 6-DOF Accelerometer and Gyros",
2525
long_description=long_description,
2626
long_description_content_type="text/x-rst",
2727
# The project's main homepage.
@@ -48,7 +48,7 @@
4848
"Programming Language :: Python :: 3.5",
4949
],
5050
# What does your project relate to?
51-
keywords="adafruit blinka circuitpython micropython lsm6ds lsm6dsox lsm6ds33 icm330dhct imu gyro gyroscope inemo"
51+
keywords="adafruit blinka circuitpython micropython lsm6ds lsm6dsox lsm6ds33 icm330dhcx imu gyro gyroscope inemo"
5252
"accelerometer",
5353
# You can just specify the packages manually here if your project is
5454
# simple. Or you can use find_packages().

0 commit comments

Comments
 (0)