We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aeaaf4b commit 96e97cfCopy full SHA for 96e97cf
adafruit_ads1x15/ads1x15.py
@@ -152,6 +152,7 @@ def _read(self, pin):
152
"""Perform an ADC read. Returns the signed integer result of the read."""
153
fast = True
154
if self._last_pin_read != pin:
155
+ self._last_pin_read = pin
156
fast = False
157
config = _ADS1X15_CONFIG_OS_SINGLE
158
config |= (pin & 0x07) << _ADS1X15_CONFIG_MUX_OFFSET
@@ -165,7 +166,6 @@ def _read(self, pin):
165
166
while not self._conversion_complete():
167
pass
168
- self._last_pin_read = pin
169
return self._conversion_value(self.get_last_result(fast))
170
171
def _conversion_complete(self):
0 commit comments