File tree Expand file tree Collapse file tree 1 file changed +0
-6
lines changed Expand file tree Collapse file tree 1 file changed +0
-6
lines changed Original file line number Diff line number Diff line change @@ -143,8 +143,6 @@ def _read_temperature(self):
143
143
while self ._get_status () & 0x08 :
144
144
sleep (0.002 )
145
145
raw_temperature = self ._read24 (_BME280_REGISTER_TEMPDATA ) / 16 # lowest 4 bits get dropped
146
- if raw_temperature == 0x80000 : #0x80000 means the measurment was skipped
147
- return
148
146
#print("raw temp: ", UT)
149
147
var1 = (raw_temperature / 16384.0 - self ._temp_calib [0 ] / 1024.0 ) * self ._temp_calib [1 ]
150
148
#print(var1)
@@ -319,8 +317,6 @@ def pressure(self):
319
317
# Algorithm from the BME280 driver
320
318
# https://github.com/BoschSensortec/BME280_driver/blob/master/bme280.c
321
319
adc = self ._read24 (_BME280_REGISTER_PRESSUREDATA ) / 16 # lowest 4 bits get dropped
322
- if adc == 0x80000 : #0x80000 means the measurement was skipped
323
- return None
324
320
var1 = float (self ._t_fine ) / 2.0 - 64000.0
325
321
var2 = var1 * var1 * self ._pressure_calib [5 ] / 32768.0
326
322
var2 = var2 + var1 * self ._pressure_calib [4 ] * 2.0
@@ -354,8 +350,6 @@ def humidity(self):
354
350
"""
355
351
self ._read_temperature ()
356
352
hum = self ._read_register (_BME280_REGISTER_HUMIDDATA , 2 )
357
- if hum == 0x8000 : #0x8000 means the reading was skipped
358
- return None
359
353
#print("Humidity data: ", hum)
360
354
adc = float (hum [0 ] << 8 | hum [1 ])
361
355
#print("adc:", adc)
You can’t perform that action at this time.
0 commit comments