Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1246

Python • Re: BMP280 library

$
0
0
I just finished a combined driver for BMP280, BMP390, BMP581, BMP585. I needed this for my personal altimeter project.

You can find it here: https://github.com/bradcar/MicroPython_BMPxxx

This I2C driver allows you to get pressure, temperature, and altitude.
  • You can also set the known sea level pressure for accurate altitude. I use the nearest airport which tend to update this hourly. For example: https://www.weather.gov/wrh/timeseries?site=KPDX
  • You can also set altitude at a location and it will adjust the sea level pressure so you can more accurately track altitudes from that point forward.
  • For the altitude calculation I found NSF's NCAR formula which is the one recommended for aircraft (better than the simple one used in most drivers, or wikipedia's): https://ncar.github.io/aircraft_Process ... titude.pdf
Having played with all of the sensors, I highly recommend the latest from Bosch (BMP581 or BMP585) as they can track centimeter changes! Near as I can find, here are the Bosch sensor release dates:
  • BMP585, MEMS-based barometric pressure sensor, perf similar to BMP581, released 2023.
  • BMP581, capacitive-based barometric pressure sensor similar accuracy to BMP585, released 2022.
  • BMP390, previous generation, released 2021.
  • BMP280, old generation, released 2015.
The BMP585 is also waterproof. On my GitHub readme, at the end, I have a pointer to the Bosch video where you can see it tracking changes as it is moved in a fish tank (wow). Maybe that will inspire some projects... To be clear the sensor is waterproof but I don't know if anyone has it mounted on a waterproof board.

Statistics: Posted by bradcar — Sun Nov 24, 2024 4:04 am



Viewing all articles
Browse latest Browse all 1246

Trending Articles