BMP280 Temperature+Pressure Sensor

The bmp280 sensor platform allows you to use your BMP280 (datasheet, Adafruit) temperature and pressure sensors with ESPHome. The I²C or SPI is required to be set up in your configuration for this sensor to work.

../../_images/bmp280-full.jpg

BMP280 Temperature and Pressure Sensor.

# Example configuration entry I2C
sensor:
  - platform: bmp280_i2c
    temperature:
      name: "Outside Temperature"
      oversampling: 16x
    pressure:
      name: "Outside Pressure"
    address: 0x77
    update_interval: 60s

# Example configuration entry SPI
sensor:
  - platform: bmp280_spi
    temperature:
      name: "Outside Temperature"
      oversampling: 16x
    pressure:
      name: "Outside Pressure"
    cs_pin: GPIO5
    update_interval: 60s

Configuration variables:

  • temperature (Optional): The information for the temperature. sensor

    • oversampling (Optional): The oversampling parameter for the temperature sensor. See Oversampling Options.

    • All other options from Sensor.

  • pressure (Optional): The information for the pressure sensor.

    • oversampling (Optional): The oversampling parameter for the pressure sensor. See Oversampling Options.

    • All other options from Sensor.

  • iir_filter (Optional): Set up an Infinite Impulse Response filter to increase accuracy. One of OFF, 2x, 4x, 16x. Defaults to OFF.

  • update_interval (Optional, Time): The interval to check the sensor. Defaults to 60s.

I²C Configuration variables:

  • address (Optional, int): Manually specify the I²C address of the sensor. Defaults to 0x77. Another address can be 0x76.

SPI Configuration variables:

  • cs_pin (Optional, Pin Schema): The CS pin of the BMP280 sensor.

../../_images/bmp280-full.jpg

Pins on the BMP280. Only VCC, GND, SCL, and SDA need to be connected.

Oversampling Options

By default, the BMP280 sensor measures each value 16 times when requesting a new value. You can, however, configure this amount. Possible oversampling values:

  • NONE (value is skipped)

  • 1x

  • 2x

  • 4x

  • 8x

  • 16x (default)

See Also