Skip to content

Commit 7a88e4b

Browse files
authored
Merge pull request #3 from MkLHX/master
allow to change i2c address
2 parents c87e618 + 6bbb0ad commit 7a88e4b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

adafruit_sht4x.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,8 @@ class SHT4x:
9090
9191
"""
9292

93-
def __init__(self, i2c_bus):
94-
self.i2c_device = i2c_device.I2CDevice(i2c_bus, _SHT4X_DEFAULT_ADDR)
93+
def __init__(self, i2c_bus, address=_SHT4X_DEFAULT_ADDR):
94+
self.i2c_device = i2c_device.I2CDevice(i2c_bus, address)
9595
self._buffer = bytearray(6)
9696
self.reset()
9797
self._mode = Mode.NOHEAT_HIGHPRECISION # pylint: disable=no-member

0 commit comments

Comments
 (0)