Open rodneyosodo opened 3 years ago
Hi not sure what you'd like me to do here? 🤔
@0x6f736f646f this line tries to explain: https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L14
Do you know of a different way to discard the first reading, or obtain reliable results through the first read?
Then it might be a library issue. This can be improved by using a filter. Yes, you would be trading the raw values but you would achieve better results.
This is from BME official docs.
calibration_params = bme280.load_calibration_params(bus, address)
# the sample method will take a single reading and return a compensated_reading object
data = bme280.sample(bus, address, calibration_params)
For a data-logger like application, periodically call bme2.sample(bus, address, calibration_params) to get time-based readings.
@alexellis are you currently sampling the readings? If not we can probably use this approach and see if clears the issue.
Work something up and let's have a look at how it might change the approach. I'm interested as I take the second reading over on rgee0/seeds2 too.
These lines are redefined
https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L15 is redefined here https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L20
https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L16 is redefined here https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L21
https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L17 is redefined here https://github.com/alexellis/growlab/blob/d1e65558d864b112bfd98871bae1c83bbdc7ff46/bme280-logger/sender/sensors.py#L22