ESP32 External Sensor Project: BMP180 Sensor

Agung Ahsary
3 min readFeb 27, 2022

--

In this article you will learn how to use BMP180 sensor with ESP32. Basically, BMP180 is a barometric sensor that reads temperature, pressure, and altitude around it in which you will found at the end of this article.

Requirements:

  1. ESP32 board
  2. PC/Laptop
  3. Arduino IDE software
  4. Micro-USB to USB cable
  5. BMP180 sensor
  6. 4x Female-Female jumper wire

Steps:

  1. Open your Arduino IDE software on yout PC/laptop

2. Connect your ESP32 to your PC/laptop using your Micro-USB to USB cable.

3. Do an initial setup for your ESP32 board shown in this article (step 3 and step 4 only) https://agungahsary255.medium.com/how-to-make-esp32-built-in-led-blink-b16b7cb4c6fa.

4. Go to Sketch > Include Library > Manage Libraries and type “BMP085” in the search box and install “Adafruit BMP085 Library” (Don’t worry this BMP085 library will be compatible with BMP180 sensors).

5. Use your jumper wires to connect your ESP32 to your BMP180 sensor like shown in the picture below.

I’m using breadboard so it look a little bit different.

6. Now write the code like the picture below. To automatically write the code in your IDE go to Sketch > Include Library > Adafruit BMP085 Library.

7. Upload the sketch.

8. After done uploading, open Serial Monitor, set baud rate to 9600, and you should see outputs like this.

Aaand that’s it! Hope it works!

--

--

Agung Ahsary
Agung Ahsary

No responses yet