Skip to content
A

Pressure & Altitude

Interfacing BMP180 Pressure & Altitude with Arduino Uno

What is the BMP180?

An earlier-generation barometric pressure sensor, still widely used in altimeter and weather-station projects thanks to abundant library support. The BMP180 measures atmospheric pressure and temperature over I2C, and because pressure decreases predictably with altitude, its readings can be converted into a fairly accurate relative-altitude estimate — a long-standing staple for DIY weather stations, altitude-hold drone code, and any project needing a simple 'how high up am I' or 'is the weather changing' reading.

Specifications

Sensor typeBosch BMP180 barometric pressure and temperature sensor
Operating voltage1.8V–3.6V DC (breakout boards regulate from 3.3-5V input)
Operating current~5 µA at 1 sample/second in standard mode
Pressure range300 hPa to 1100 hPa (equivalent to roughly 9000m below to 500m above sea level)
Pressure resolution0.01 hPa in ultra-high-resolution mode (roughly ~0.1m altitude resolution)
Temperature accuracy±2°C typical
InterfaceI2C, up to 3.4MHz
I2C address0x77 (fixed)

BMP180 Pinout

PinNameDescription
1VINPower, 3.3–5V DC depending on breakout regulator
2GNDGround
3SCLI2C clock line
4SDAI2C data line

Add standard 4.7kΩ pull-up resistors on SDA/SCL if not already present on the breakout board. Because altitude is calculated from relative pressure, calibrate against a known local sea-level pressure reading (or a recent baseline reading at a known altitude) for meaningful absolute altitude results, since raw pressure alone only gives relative changes.

Setting Up BMP180 with Arduino Uno

Library

Adafruit BMP085 Library by Adafruit

Search "Adafruit BMP085" in Library Manager (Sketch > Include Library > Manage Libraries) — despite the name, it also supports the BMP180

Wiring

Component pinArduino Uno pinNote
VIN5V (breakout regulates down) or 3.3V
GNDGND
SCLA5 (SCL)
SDAA4 (SDA)

Example code

C++

readAltitude() assumes sea-level pressure of 1013.25 hPa by default — pass your local sea-level pressure to bmp.readAltitude(seaLevelPressure) for an accurate absolute altitude, otherwise treat it as a relative measurement.

Related Guides & Projects