SparkFun_BME280_Arduino_Library icon indicating copy to clipboard operation
SparkFun_BME280_Arduino_Library copied to clipboard

firstly read temperature for avoiding wrong calculation

Open emre-h opened this issue 4 years ago • 2 comments

I have used the library and it was giving wrong altitude values because of not calling the readTempC() before calling readFloatAltitudeMeters(). Then I have called it and it has been fixed.

emre-h avatar Aug 03 '21 22:08 emre-h

Thanks for the PR!

Does this method come from the datasheet? Why do you readFloatPressure twice?

Hmm, it looks like t_fine gets set in readTempC and is used in readFloatPressure.

nseidle avatar Aug 04 '21 14:08 nseidle

It has fixed the wrong calculation. You can try it with or without my two-line containing commit. (it will probably give the wrong meter calculation without this commit)

emre-h avatar Aug 13 '21 18:08 emre-h