adafruit / Adafruit_BME280_Library

Arduino Library for BME280 sensors
Other
333 stars 304 forks source link

Reset on begin and read coefficients only after calibration #20

Closed frankleonrose closed 7 years ago

frankleonrose commented 7 years ago

We added a soft reset on begin() in order to put the sensor in a known state. Following reset, it is necessary to wait for calibration to complete. Thankfully, the chip offers a status bit to read to detect when it is performing calibration.

In Adafruit_BME280::begin(addr)

In class Adafruit_BME280

Limitations: No known limitations. All code uses existing hardware comms layer and standard library calls (eg delay). Testing: Library examples run as usual.

ladyada commented 7 years ago

can you verify you've compiled and tested with an arduino using IDE 1.8.1 (or thereabouts :)

frankleonrose commented 7 years ago

@ladyada Just installed 1.8.1 and rebuilt. Runs fine - 20℃ right here & now.

(I use PlatformIO normally and hadn't updated ArduinoIDE since 1.6.12. Thanks for the prompt.)

ladyada commented 7 years ago

ok!