I used a Wemos Mini DHT22 Shield, a Wemos Dq Mini and male dupont cables. GND from IKEA goes to DHT22’s GND the pin next to the GND is not used by the shield so soldered GND and the next pin together. From that pin GND goes to the Wemos.
5V goes from IKEA to the Wemos.
REST goes from IKEA to the Wemos D2 pin.
Wemos D4 pin goes to DHT22 Data.
Wemos VCC (3V) goes to DHT22 VCC.
It is a bit too crowded inside. I placed everything above the pm1006 sensor but if you do not use dupont connectors, but wires only or maybe the solution above with the ESP01 and the 5V->3V converter and a single DHT22 under the fan, you might get a more reliable configuration without blocking any airflow.
Here is the config, I used at that time @Habbie’s repo as an external component, but now you should use @sermayoral’s repo as @Habbie’s code adds a new icon to ESPHome what cannot be picked up as an external component. (Read the GitHub PR from the OP for clarification.) The external component solution is needed until the new version of ESPHome releases the pm1006 component.
esphome:
name: cellar-air-quality
platform: ESP8266
board: d1_mini
# Enable logging
logger:
# Enable Home Assistant API
api:
ota:
password: "xxxx"
wifi:
ssid: "wifi"
password: "password"
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Cellar-Air-Quality"
password: "xxxx"
captive_portal:
external_components:
- source: github://Habbie/esphome@pm1006
components: [ pm1006 ]
uart:
rx_pin: D2
baud_rate: 9600
sensor:
- platform: dht
pin: D4
temperature:
name: "Cellar Temperature"
humidity:
name: "Cellar Humidity"
model: DHT22
update_interval: 10s
- platform: pm1006
pm_2_5:
name: "Cellar Air Quality"
switch:
- platform: restart
name: "Cellar Air Quality Sensor Restart"
If any issue drop me a message.