bme280: fix integer handling for python3 in bme280.py (#5237)

Singed-off-by: Christopher Conroy <cbc02009@gmail.com>
This commit is contained in:
cbc02009 2022-02-06 12:15:35 -05:00 committed by GitHub
parent 0143199175
commit 54646c77dc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -437,7 +437,7 @@ class BME280:
else: else:
factor = 0 factor = 0
while duration_ms > 0x3F: while duration_ms > 0x3F:
duration_ms /= 4 duration_ms //= 4
factor += 1 factor += 1
duration_reg = duration_ms + (factor * 64) duration_reg = duration_ms + (factor * 64)