bme280
Reads a BME280 or BMP280 temperature, humidity and pressure sensor at a fixed interval. Supported hardware lists the chips.
Properties
- I2C bus — the bus the sensor is wired to. Required. See I2C bus.
- address —
0x76(SDO to ground, most boards) or0x77(SDO to VCC). Default0x76. In the flow file, a plain number:118or119. - interval (ms) — how often to read. Default 5000. Must be 100 or more.
Wiring
Input — none. bme280 is a source.
Output — one reading per interval, with topic an empty string:
msg['payload'] == {'temperature': 21.43, 'humidity': 48.2, 'pressure': 1012.6}
Temperature is in °C, humidity in %, pressure in hPa, each to 2 decimal places. On a BMP280, humidity is None.
To use one value, pick it out in a function node: msg['payload'] = msg['payload']['temperature'].
Behavior
The first reading goes out when the flow starts. The status dot shows which chip answered, BME280 or BMP280. A failed read sends nothing; the node tries again at the next interval, so a sensor connected after the flow starts is picked up.
Errors
- Nothing answers. The dot shows disconnected,
no reply at 0x76 on I2C bus 0. Check the wiring, pins and address; see I2C device not answering. - A different chip at the address. The dot shows error,
no BME280/BMP280 at 0x76 (chip id 0x..). - No I2C bus. Deploy stops with
bme280 has no I2C bus. Pick one, or add one with +.