From 02407e1d01e16d5eb313a8d0570946513a2820c0 Mon Sep 17 00:00:00 2001 From: lowflyerUK Date: Sun, 3 Dec 2017 21:49:32 +0000 Subject: [PATCH] Updated mask operation in constants.py to correct gas resistance --- library/bme680/constants.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/bme680/constants.py b/library/bme680/constants.py index 8452da7..5cc0840 100644 --- a/library/bme680/constants.py +++ b/library/bme680/constants.py @@ -325,7 +325,7 @@ class CalibrationData: def set_other(self, heat_range, heat_value, sw_error): self.res_heat_range = (heat_range & RHRANGE_MSK) // 16 self.res_heat_val = heat_value - self.range_sw_err = (sw_error * RSERROR_MSK) // 16 + self.range_sw_err = (sw_error & RSERROR_MSK) // 16 # BME680 sensor settings structure which comprises of ODR, # over-sampling and filter settings.