ESP8266 Temp Multi-Sensor
I built a WiFi sensor for my attic to monitor temperature, humidity, and pressure for less than $10 using
and with the home automation software Home Assistant with the EspHome plugin.
Here is my attic sensor’s display in Home Assistant:
Hardware
NOTICE: The GND pin of the sensor is NOT connected to pin D8 which is why the second pin has been removed from the header assembly. I used a wire to connect ground from accross the board.
Case
As always I have to find another reason to justify the purchase of my 3D printer. So I searched Thingiverse and found where “Spiritdude” had already created a nice case for the D1 Mini board, but the sensor location created problems for the left side mouting location, so I imported the STL file into SketchUp and moved the leg more to the top of the case.
Here is my modified version of Spiritdude’s case if you want to print your own.
Software
Here is my “Home Assistant ESP-Home” yaml config file for the Multi-Sensor.
esphome:
name: attic_multisensor_01
platform: ESP8266
board: d1_mini
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_pass
captive_portal:
# Enable logging
logger:
# Enable Home Assistant API
api:
# Enable Over The Air updates
ota:
# Create BME Sensor on I2C
i2c:
sda: D6
scl: D7
# Scan I2C address to look for sensors
scan: True
sensor:
- platform: bme280
# Default address 0x77
address: 0x76
temperature:
name: "Attic Temperature"
id: attic_bme280_temperature
filters:
- lambda: return x * (9.0/5.0) + 32.0;
unit_of_measurement: "°F"
pressure:
name: "Attic Pressure"
id: attic_bme280_pressure
humidity:
name: "Attic Humidity"
id: attic_bme280_humidity
filters:
- calibrate_linear:
# Map 0.0 (from sensor) to 0.0 (true value)
- 0.0 -> 0.0
- 32.7 -> 55.7
update_interval: 15s