#16 Exact Measurement of Altitude with BME280 sensor

Поделиться
HTML-код
  • Опубликовано: 28 ноя 2024

Комментарии • 109

  • @HildebrandJohnson
    @HildebrandJohnson 7 лет назад +10

    If one doesn't need the humidity measurement, the BMP280 is a little less expensive than the BME280. The only difference is the hygrometer.

  • @JerryEricsson
    @JerryEricsson 4 года назад

    Cool review. I picked up the mini stackable ESP8266 with the BMP180 shield and an OLED Sheild.When the drivers are properlly loaded she gives a nice display that pretty much matches the airport listed altitude to a few feet, it jumps around quite a lot, plus gives temp and BMP readings.

    • @AndreasSpiess
      @AndreasSpiess  4 года назад

      It should even show you the weather (pressure changes) if you once calibrate it to your altitude.

  • @hoggif
    @hoggif 5 лет назад +1

    Thanks for interesting video. BTW, some cycling meters (like new garmins) have a neat feature: you can store gps point(s) with known altitude. When you drive by one point, device calibrates itself.
    I used to have points near home, work and some other locations I may be stopped for long. I found out than weather patterns usually agreed to 2-4m between points at flat terrain separated by about 10-15km. Sometimes altimeter measured even 30m difference when there was eg. a low pressure zone approaching.

    • @AndreasSpiess
      @AndreasSpiess  5 лет назад

      I did not know about that feature. Very good concept!

  • @rbode9218
    @rbode9218 6 лет назад +1

    Dear Andreas, can you tell us if there will be a next episode on the altitude measurement?
    I'm very interested in building a device with the accuracy as shown in the first video.

  • @k1mgy
    @k1mgy 9 лет назад

    Fantastic device with temperature, humidity and pressure in such a small package! Your testing against a GPS will be interesting, but I wonder if GPS resolution is perhaps insufficient to come to a conclusion about accuracy and linearity. Did you use the over-sampling and normal modes during the indoor tests per the data sheet?

    • @AndreasSpiess
      @AndreasSpiess  9 лет назад

      +k1mgy If I remember right I used the "indoors" profile which uses 16x oversampling for pressure. I did not test it without oversampling because I wanted precision and had no issue with speed.
      You find the video about GPS precision in my channel. It shows, that the precisions are different: GPS is very good in absolute altitude, but much weaker than pressure sensors in small altitude differences. For my power meter I need precision for small altitude differences. This is why I use pressure sensors for that (in addition to a GPS for speed)

  • @albertsjoberg1200
    @albertsjoberg1200 6 лет назад +1

    Very late to this party. I found the BMP180 very sensitive to light. I also note that the light conditions on each floor in your house is different.
    Try covering the hole in the can with a blackout material or sponge. You may find that that will also remove some of the large deviations in your initial spreadsheet data.

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      Thanks for bringing this up. I did not know it.

    • @brianh21858
      @brianh21858 5 лет назад

      If the hole is sealed, then it will not measure the change in pressure, so care must be taken not to hermetically seal the hole. Sponge would work so long as it doesn't block the hole.

  • @DougHanchard
    @DougHanchard 6 лет назад

    Prior to modern electronic altimeters being used in aviation, the use of aneroid barometers was extremely accurate because they could be calibrated, relative to ground based measuring device only. You are correct stating altimeters used in aviation are calibrated for differential - but they cannot check or verify local conditions, only measure based on the first calibrated input. It should be noted for clarification, Aircraft altimeters are only *indicators* of barometric pressure, not an actual measuring sensor. Early Electronic models often had reference calibration issues. It was one reason radar altimeters were believed to be their replacement.
    Unfortunately, the size, cost and electric power required for precision measurements has turned out to be problematic.
    For all of the reasons described above, all aircraft flying *above* 18,000' - set the barometric pressure to 29.92" for all types of altimeters, digital or aneroid for the reason you explain.
    Below this altitude, pilots call air traffic control of each sector flown, for their airspace barometric pressure reading to input into the aircraft altimeter - analog or digital. It is not unusual to have up to 1.5" differential between two adjacent sectors, which drastically changes indicated altitude.
    This may explain your sensors inaccuracies. If you have a known valid barometric pressure reading and precise altitude to enter as part of your calibration starting point, perhaps your accuracy will improve. The use of a GPS altitude measurements can be inaccurate up to 3 meters and thus cannot replace true known ASL elevation.
    Even so, I believe these Bosch devices are not measuring sensors that can self calibrate without an reference index point and have the same potential inaccuracies as their aviation cousins....

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      Thank you for your explanations. As a former hobby pilot, I am aware of some of the facts you mention. The Bosh sensors have to be calibrated as any other pressure sensor I know if you want to measure height.

  • @JerryEricsson
    @JerryEricsson 6 лет назад

    I have been playing around with the 180, I have two of them, one on a shield for the Wemos ESP8266 and have the other hooked to a Wemos D1 ESP8266 (arduino look-a-like) Both are off, depending on the day, of course from 20 feet to (today) over 200 feet above sea level. I live in a town that is at around 2550 Feet above sea level. I have considered tacking on a -200 or what ever but it changes so greatly that there is really no good subtraction that would give me a valid reading. I guess I will just have to go with the flow, I am working at building a unit to put in my RV for when we are on the road. Our usual route in the spring and fall take us up over passes that are from 7000 feet to the highest at around 9000 feet when crossing the Rocky Mountains, and down to around 20 feet where we park for the winter in the Mojave Desert of Arizona, just a stones throw from both Nevada and California.

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      These devices are quite precise if the pressure in an area stays the same and you calibrated them on a known altitude. For traveling they are probably not accurate because you change the area quite often. Pilots have to adjust their sensors always before landing to the relevant airport.

  • @myozone
    @myozone 7 лет назад +1

    As a 'rule of thumb' I use 0.12 meters per millibar which is good over a range of about 3000 meters

  • @imadeddinerabia9541
    @imadeddinerabia9541 Год назад

    Did you compare the altitude reading from bme280 to gps reading? Actually sometimes there's big difference in altitude especially when the sea level presuure is far away from 1013.25hpa lower or greater

    • @AndreasSpiess
      @AndreasSpiess  Год назад

      The BME never displays a absolute altitude. It always have to be calibrated to the current air pressure

    • @imadeddinerabia9541
      @imadeddinerabia9541 Год назад

      @@AndreasSpiess
      Yeah exactly,
      The air pressure maybe accurate with bme sensors but altitude never be because of the 1013.25 average at sea lvl

  • @juansolo1617
    @juansolo1617 4 года назад

    Perhaps you should attempt the test again, but this time open all the windows. I'm not sure if the windows being closed would affect the pressure readings while indoors. Perhaps the air system inside could be throwing the reading off.

  • @einars899
    @einars899 7 лет назад

    You should not expect sub-meter resolution. Just opening/closing a door or a window will throw the mesurements off scale. Even a slight wind outside will do the same. Even some wind let out by yourself could influence the result, so don't. ;-)
    The comparison of the different sensors should however be valid if those parameters were not throwing the results off.

    • @AndreasSpiess
      @AndreasSpiess  7 лет назад

      I think you are right. But with a little averaging, you might be able to eliminate some of the mentioned effects. Of course, the speed is reduced then.

  • @norm1124
    @norm1124 9 лет назад

    Danke für den Vergleich. Insbesondere die Gegenüberstellung der Größe.

  • @schabanow
    @schabanow 9 лет назад

    Andreas, thank you very much for useful info. Have you finished any of your gadgets? I mean constructively, structurally finished (boxed) as a handhold or desktop boxes that contains (among the other things) bme_280 the environmental sensor? If yes, then have you apply any protective screens, or meshes or maybe labyrinth to prevent the water drop from getting into your device through that tiny pinhole?
    I construct pocket weather station that utilises bme_280 and am concerned about issues just described...

    • @AndreasSpiess
      @AndreasSpiess  9 лет назад +1

      +schabanow No, I did not finish my power meter for my bike (where the BME280 will be part of). Here in Switzerland it is winter now and I was not able to finish the project before it got cold. So, I have now plenty of time till next spring ;-)
      To your question: I do not forsee to use the device in heavy rain. So , I will not have a big problem with water. Just my thougts: Because pressure is quite universal you can place the air inflow hole away from your electronics. It is not necessary to have the air inflow close to the sensor. And if you place the air inflow hole at the bottom of your device (if this exist), it shoudl be ok. I think also, that the air inflow hole can be very small, because the amount of air is very small. A labyrinth for shoure would help in addition if neccessary.

    • @schabanow
      @schabanow 9 лет назад +1

      Thanks for kind response, Andreas! Besides air pressure my device is intended to measure air humidity (and wind speed as well - DIY impeller is applied), so the manufacturer's DS suggests the possible minimum air volume between the bme_280 sensor and the open air (the less air buffer volume, the less time of sensor's reaction). My box is supposed to run in quite hard conditions (hunters, fishermen), so it should withstand to immersion in water up to 10 cm deep or so. )) So I'm gonna try quite thin brass mesh plug-washers coated with water-repellant mixture, like Aquapel, etc (just try "water repellant" in YT's search string - there are a lot of spectacular videos on the sbj). Thanks again, and say hello to Alpine Milka Cow! )) We haven't winter this year here yet...

    • @schabanow
      @schabanow 9 лет назад

      Andreas you just stop chatting so I wanna apologize for my clumsy (possible clumsy) joke about Alpine Cow... The matter is they show here on TV that advertisement video with Milky Way' lilac cow with a big bell on its neck. )) So here we have just steady mental association between Switzerland and Alpine Lilac Cow for me ukrainian man. )) Please forgive me if I've disturbed you in some clumsy way. Have a great day! Alex.

    • @AndreasSpiess
      @AndreasSpiess  9 лет назад

      +schabanow No, not at all. I have to apologize, I did not stop chatting on purpose, I just had nothing to reply. Absolutely no problem! As I wrote you, for the moment, I do not have a problem with water and this is why I did not answer anymore. We can keep in touch, Andreas

    • @pepper669
      @pepper669 7 лет назад

      schabanow You might try Gore-Tex or a similar fabric, since these are said to repeal water while letting through water vapour (and I would guess air, too) trough microscopic holes.

  • @vipinpnair
    @vipinpnair 8 лет назад

    +Andreas Spiess , Does accuracy of altitude measurement can be increased by using multiple BME280 by averaging the output data?

    • @AndreasSpiess
      @AndreasSpiess  8 лет назад +1

      Probably, but I think, not a lot. You can also average the reading of one over time to get a similar result, but of course, slower. A basic averaging function is already built in into the chip.

  • @therealfox
    @therealfox 8 лет назад +1

    Is it possible to read the BME280 with a much smaller uC like a Attiny85 e.g. ?

    • @AndreasSpiess
      @AndreasSpiess  8 лет назад

      +therealfox Since the BME280 uses I2C it shoud be possible. Use TinyWireM (master) library and keep me posted if it works...

    • @therealfox
      @therealfox 8 лет назад

      +Andreas Spiess I try to measure the altitude of an rc model to see in which altitude i am flying an try to read it after the flight. But i dont know if its worth to order the whole electronic parts if i am could not sure that it work. It should be more accuracy then gps, but it only need 1 logfile entry every 5 seconds or so. I'am really unsure if the tiny can handle it. Maybe i need to search for an already build project for this.

    • @AndreasSpiess
      @AndreasSpiess  8 лет назад

      Where do you want to store the data? On an SD card? Then, the Attiny is definitively too small

  • @baykus790
    @baykus790 3 года назад

    Love your intro watermarks..

  • @viisteist1363
    @viisteist1363 7 лет назад +1

    cool. would it be possible to check the Hpa pressure automatically also tho, like the esptime?:e

  • @henrycheung6960
    @henrycheung6960 4 года назад

    Great video, do you by any chance has a video of your home made bike computer? Would love to watch that...

    • @AndreasSpiess
      @AndreasSpiess  4 года назад

      I never finished this project :-(

    • @henrycheung6960
      @henrycheung6960 4 года назад

      @@AndreasSpiess I'm doing my researching to build one, and came across your video and the great works done by this guy karman.cc/blog/archives/746

  • @mikebrown7366
    @mikebrown7366 5 лет назад +1

    I assume your house is warmer on 2nd floor, compared to first floor and warmer still on third floor. Perhaps you need temperature compensation? Also, some of these sensors are sensitive to light. I don't know if BMP280 has same problem.

    • @AndreasSpiess
      @AndreasSpiess  5 лет назад

      I think the difference is below 1 degree C. So not very important.

    • @RichardEiger
      @RichardEiger 3 года назад

      The deviation not only depends on the temperature but also on pressure altitude in combination with temperature. For every 1000 ft (ca. 300m) it would be 4 times the difference between ISO standard temperature (at given altitude) and measured temperature. For relatively small changes in altitude this should not have a big impact. At least as long as temperature does not differ very much from ISO standard and/or for very high altitudes.

  • @SuperManyl
    @SuperManyl Год назад

    Thank you for the video.
    I wanted to check the code but the rep on GitHub doesn't exist anymore 😢

    • @AndreasSpiess
      @AndreasSpiess  Год назад

      This is an old video. But I am sure you find example files in the Arduino IDE to start with.

  • @dominikheinz2297
    @dominikheinz2297 6 лет назад

    @Andreas Spiess I consider sending up a weather ballon and I wanna attach a ESP8266 to it to log the height. Do you think this sensor is suitable for that? If not what would you recommend?

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад +1

      The ESP is no sensor. And it’s reach is quite small. I would go for a LoRa Module. On a balloon it reached up to 700km

    • @dominikheinz2297
      @dominikheinz2297 6 лет назад

      @@AndreasSpiess There is no need for transfer. I plan on attaching the sensor and log data. I can obtain the data when the balloon has landed. I was just wondering if the sensor shown in this video will do the job, which means logging the altitude. Considering influences such as low temperatures, possible humidity, ~50km of height

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      I do not know. Maybe you consult the data sheet and check which sensors were used for other projects. I would not trust you get your balloon back. But I am not an expert.

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад +1

      Check also the batteries. Lopo are not good when it is cold

  • @Watermodels
    @Watermodels 5 лет назад +1

    Thanks for the interesting comparison.
    First one addition:
    there are different oversampling-modes available for the pressure-readings, which increase precision a bit but make response-time slower (internal averaging). For the SFE_BMP180.h library this is done via: pressure.startPressure(3)
    values from int 0-3, higher = more accurate. See also the manual for BMP180/280
    Doing so and with averaging over 6 values in my code, the old BMP180 is accurate enough for my homebuild variometer inside my rc-glider. Transfer to ground via 433 Mhz radio-module, tone-output of arduino feeds signal-input of module. Output from receiver goes via amplifier to headphones = only one arduino needed.
    I Agree with Mr. Tucker that GPS-measurements are very imprecise if not RTK-compensatet via reference-station(s) - see
    www.swisstopo.admin.ch/en/knowledge-facts/surveying-geodesy/permanent-networks.html
    Even with correction an undisturbed view to the horizon is needed for good altitude measurements, which is often difficult in mountainous areas like in switzerland.

  • @JDI4DAVID
    @JDI4DAVID 6 лет назад

    I also have a couple of these sensors but have found that the noise is much greater than the declared 0.2 Pa. Even if this can be overcome there is the ±1.5 Pa/K temperature coefficient to deal with. Would you not say that it is almost unusable for altitude measurement? I also wonder if you can get true altitude from a GPS. How did you get on with it on your bicycle?

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      If I remember right they included the temp sensor to compensate the issue with temperature and in the datasheet they even have a formula. I am no more sure because this is a quite old video.

    • @JDI4DAVID
      @JDI4DAVID 6 лет назад

      Andreas Spiess Thank you Andreas.

    • @cmblcdoe6669
      @cmblcdoe6669 3 года назад

      @@JDI4DAVID I know I'm replying to a 2 year old message, but I've found by using the formulas given in the datasheet, I'm getting incredible accuracy from the MBE280. As an experiment, I put my build in my car at work, zeroing that altitude and seeing then monitoring my relative altitude to my start position at work. My trip home is about 5 miles, and varies about 250 ft in elevation. Arriving home, it showed my altitude at -12 ft. from my starting position. I double checked those figures on a topographic map and they checked out nicely. The next morning I zeroed the altimeter at my starting position at home, and traveled back to work and it showed work as being +15 ft difference from my home driveway. So the altitude seems to me to be accurate to within 3 ft. I just haven't quite figured out the formulas to use to get my calculated altitude based on reported pressure readings. And that is because the more I think about it, the less I understand about what exactly the reported air pressure really means. And I should know better. I used to be a pilot back in the 1970's.

    • @saliholoji
      @saliholoji Час назад

      @@cmblcdoe6669 I'm sorry I'm being stupid for replying to a three year old message, what is the code/formula you are talking about?

  • @EldadWasserman
    @EldadWasserman 7 лет назад

    hi
    maybe you can help me... I am trying to connect the bmp280 to my stm32f103c8 with Arduino IDE. I don't know what library to use for the i2c communication ... and I am searching for code example for reading data from this bmp280 what pins to connect the sensor

    • @AndreasSpiess
      @AndreasSpiess  7 лет назад

      In arduino, we use the wire library. It should exist also for your microcontroller. The pins are defined by this library. Otherwise, it will not be easy. Roger Clark knows a lot about ST and Arduino IDE ( ruclips.net/user/synergie8 )

    • @EldadWasserman
      @EldadWasserman 7 лет назад

      Thanks for your fast reply !!!!!!!!!!!!!!!!!!

  • @uribass7733
    @uribass7733 4 года назад

    Hello,
    According the MCU specification, can I use the ESP-32-D ?

    • @AndreasSpiess
      @AndreasSpiess  4 года назад +1

      If you find a library for the ESP32 it should be ok. Check if your sensors work with 3.3 volts

    • @uribass7733
      @uribass7733 4 года назад

      @@AndreasSpiess OK, I used the Lolin32, with BME280, and its work with the Adafruit bme280 lib. thank you very much!!

  • @TheNamelessOne12357
    @TheNamelessOne12357 8 лет назад

    Hi! Did you experience strange spikes with this sensor in normal mode? All my BMP280 sensors randomly show incorrect data, about 150 hPa less for 0.1-0.5 seconds and then goes back to normal. Tried different I2C speeds, capacitors on VCC lines, different oversampling settings, nothing solves this issue.

    • @AndreasSpiess
      @AndreasSpiess  8 лет назад

      No, I do not remember having these problems.

    • @FreeEditsForYou
      @FreeEditsForYou Месяц назад

      I have the bmp280. Seems to work good with a Arduino Nano. As I type this I realize this comment was made 8 years ago omfg. Time flies

    • @TheNamelessOne12357
      @TheNamelessOne12357 Месяц назад

      @@FreeEditsForYou Yep, and the issue was not solved. I decided not to use pressure sensor in that project.

  • @tomnutt209
    @tomnutt209 7 лет назад

    Ace! The altitude accuracy is excellent.
    I've tried to implement the altitude formula in my python code using the BME280 chip
    [ Altitude = 44330.0 * (1.0 - pow((pressure * 1000) / 101325, (1.0 / 5.255))) ]
    but the results can vary +/- 20m :/
    Can you help?

    • @AndreasSpiess
      @AndreasSpiess  7 лет назад

      As you see in the video, my measurements were much more precise. So you either have a wrong chip or something else is wrong. But I can not do a remote diagnostics.

    • @tomnutt209
      @tomnutt209 7 лет назад +2

      Thanks Andreas, I was being stupid! Its because I compared results taken on different days and the sea level pressure has changed!

    • @AndreasSpiess
      @AndreasSpiess  7 лет назад

      :-)

    • @maneaflorin1
      @maneaflorin1 3 года назад +1

      @@tomnutt209 But how can we measure absolute altitude with this sensor? I wanna go into mountains and check the peak heights, without knowing the sea level pressure.

  • @testchannel1834
    @testchannel1834 6 лет назад

    Hello can you do another video with the New Bosch BMP388

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      I did not see a cheap Chinese module yet. So I will wait.

  • @cirelefebure5485
    @cirelefebure5485 7 лет назад +1

    Really interesting, thank you sir.

  • @izzyblackout1090
    @izzyblackout1090 6 лет назад

    Did you apply filters for the reading?

    • @AndreasSpiess
      @AndreasSpiess  6 лет назад

      No, but if I remember right there are built-in filters. Maybe you look at the datasheet

  • @mikegranberryii
    @mikegranberryii 5 месяцев назад

    What about the 6th floor?

    • @AndreasSpiess
      @AndreasSpiess  5 месяцев назад

      I do not know. And I am happy I did not have one. Would have been exhasting ;-)

  • @thomasblock3117
    @thomasblock3117 9 лет назад +3

    very informative, but BME280 should be cheaper now

    • @AndreasSpiess
      @AndreasSpiess  9 лет назад +1

      +Thomas Block Thank you for your comment! I just checked on Aliexpress. The modules are still around 8$. But as I said, it is worth the money if you need precision.

    • @thomasblock3117
      @thomasblock3117 9 лет назад

      +Andreas Spiess Please send me your contact details. I want to discuss some new projects thomas.block@bosch-sensortec.com

    • @daijoubu4529
      @daijoubu4529 7 лет назад

      One of the reason it's more expensive is that they all have a level shifters and a LDO, perhaps they are not as 5V tolerant as the BMP180 which can be found with neither or only a LDO, they should make a low power BMP280 bare board for 3.3V use only

    • @daijoubu4529
      @daijoubu4529 7 лет назад

      One year later and I just bought one for USD$4.5, so price are indeed dropping :)

  • @internetwurmm
    @internetwurmm 6 лет назад +1

    Hello girls/guys, it is strongly depending how the library is "made" for good measurement. Also most floating values could be stopped by beeing displayed instantly when measurement and other things are changed a bit. The recommended settings from Bosch for the different scenarios working good for me now. github.com/BoschSensortec/BME280_driver The library i am using now is github.com/bolderflight/BME280. Gave me best results so far from testing also others. Best practice for me would be to use the given stuff from Basch itself. But i am missing skills to make it work so far. Even the part is more expensive then other i still buy them for the quality of results i get from them. Thanks for the videos Andres ;-)

  • @MusashiSound
    @MusashiSound 9 лет назад +1

    Great video

    • @AndreasSpiess
      @AndreasSpiess  9 лет назад +1

      +MusashiSound Thank you very much for your nice comment!

  • @Olavotemrazaodenovo
    @Olavotemrazaodenovo 4 года назад +1

    Excelente

  • @BooperNova
    @BooperNova 3 года назад

    There's a bme680 now

  • @prajyotkamble5560
    @prajyotkamble5560 3 года назад

    Could you plzzz share the code?

    • @AndreasSpiess
      @AndreasSpiess  3 года назад

      This is an old video and if I did not share the code I do not have it anymore :-(

  • @sebase1161
    @sebase1161 2 года назад

    i love this guy

  • @lalarvirus
    @lalarvirus 7 лет назад

    Thx u sir