Skip to content

4.1.7. BME280 LCD Environmental Monitor

Description In this expert project, learners will combine the high-precision BME280 environmental sensor with an IIC 1602 Liquid Crystal Display (LCD) to build a standalone, real-time environmental monitoring station. The system continuously reads atmospheric temperature, relative humidity, and barometric pressure, displaying formatted readings directly on the LCD screen without needing a computer serial monitor connection.
Use case This project connects to real-world industrial and IoT applications such as: Multi-device I2C architecture enables compact, highly capable weather station builds.

Components (Things You will need)

Arduino Uno Arduino USB Cable Bread Board Jumper Wires BME Sensor LCD Display

Building the circuit

Things Needed:

  • Arduino Uno Board = 1
  • BME280 Sensor Module = 1
  • IIC 1602 LCD Module = 1
  • Breadboard = 1
  • Male to Female Jumper Wires
  • USB Cable = 1

Mounting the component on the breadboard and wiring the circuit

Step 1: Inventory the Components

Check the Required Components table and confirm that all listed modules and components are available.

Step 2: Connect the BME280 Power

Connect the VCC pin of the BME280 sensor to the 3.3V pin on the Arduino Uno board using a jumper wire. Then, connect the GND pin to a GND pin on the Arduino Uno board.

Step 3: Connect the BME280 I²C Pins

Connect the SDA pin of the BME280 sensor to A4 (SDA) on the Arduino Uno board using a jumper wire. Then, connect the SCL pin to A5 (SCL).

Step 4: Connect the I²C LCD Power

Connect the VCC pin of the I²C LCD display to the 5V pin on the Arduino Uno board using a jumper wire. Then, connect the GND pin to a GND pin on the Arduino Uno board.

Step 5: Connect the I²C LCD Pins

Connect the SDA pin of the I²C LCD display to A4 (SDA) and the SCL pin to A5 (SCL) on the Arduino Uno board using jumper wires. These connections allow the LCD display and BME280 sensor to share the I²C bus.

Step 6: Perform a Final Check

Double-check all power, signal, and ground connections against the Circuit Connections table and wiring diagram. Ensure that the BME280 is connected to 3.3V, the I²C LCD display is connected to 5V, and there are no loose wires or accidental short circuits.

Step 7: Connect the USB Cable

After verifying all signal, power, and ground connections, connect the USB cable to the Arduino Uno board and the computer to power the board and begin programming.

Components on breadboard

Make sure to connect the Arduino USB cable to the Arduino board.

PROGRAMMING

Step 1: Open your Arduino IDE. See how to set up here: Getting Started.

Step 2: Write the complete program implementing the system logic with appropriate pin definitions, setup configuration, and the main control loop.

// Project 62: BME280 LCD Environmental Monitor
#include <Wire.h>
#include <Adafruit_BME280.h>
#include <LiquidCrystal_I2C.h>

Adafruit_BME280 bme;
LiquidCrystal_I2C lcd(0x27, 16, 2);

unsigned long lastUpdate = 0;
const long interval = 2000;

void setup() {
  Wire.begin();
  lcd.init();
  lcd.backlight();
  lcd.setCursor(0, 0);
  lcd.print("BME280 Station");
  lcd.setCursor(0, 1);
  lcd.print("Initializing...");
  delay(1500);

  if (!bme.begin(0x76)) {
    lcd.clear();
    lcd.print("BME280 Error!");
    while (1);
  }
  lcd.clear();
}

void loop() {
  if (millis() - lastUpdate >= interval) {
    lastUpdate = millis();
    float temp = bme.readTemperature();
    float hum = bme.readHumidity();
    float pres = bme.readPressure() / 100.0F;

    lcd.setCursor(0, 0);
    lcd.print("T:"); lcd.print(temp, 1); lcd.print("C H:"); lcd.print(hum, 0); lcd.print("%");
    lcd.setCursor(0, 1);
    lcd.print("P:"); lcd.print(pres, 1); lcd.print(" hPa    ");
  }
}

Step 3: Save your code. See the Getting Started section

Step 4: Select the arduino board and port See the Getting Started section:Selecting Arduino Board Type and Uploading your code.

Step 5: Upload your code. See the Getting Started section:Selecting Arduino Board Type and Uploading your code

CONCLUSION

The screen shows initialization text for 1.5 seconds, then presents continuous live temperature, humidity, and atmospheric pressure.