Skip to content

Commit

Permalink
Merge pull request #77 from savannahcofer/bugfix/script_timeout
Browse files Browse the repository at this point in the history
Fix timeout error in adafruit_bme680.py
  • Loading branch information
FoamyGuy authored Nov 18, 2024
2 parents 4c14417 + 42cfd8d commit 6e6555b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion adafruit_bme680.py
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ def _perform_reading(self) -> None:
data = self._read(_BME680_REG_MEAS_STATUS, 17)
new_data = data[0] & 0x80 != 0
time.sleep(0.005)
if start_time >= time.monotonic() - 3.0:
if time.monotonic() - start_time >= 3.0:
raise RuntimeError("Timeout while reading sensor data")
self._last_reading = time.monotonic()

Expand Down

0 comments on commit 6e6555b

Please sign in to comment.