I’ve purchased this set of ESP-01 with DHT11 temperature and humidity sensor.
https://www.aliexpress.com/item/ESP8266-ESP-01-ESP-01S-Wifi-DHT11-Temperature-Humidity-Sensor-Meter-Module-Wireless-Thermometer-for-NodeMCU/32967287653.html?spm=a2g0s.9042311.0.0.27424c4doegzX9
I’ve uplodaded the folowing code from esphome:
esphome:
name: esp01
platform: ESP8266
board: nodemcu
wifi:
ssid: '*****'
password: '******'
# Enable logging
logger:
# Enable Home Assistant API
api:
ota:
web_server:
port: 80
sensor:
- platform: dht
pin: 2
temperature:
name: "Living Room Temperature"
humidity:
name: "Living Room Humidity"
update_interval: 60s
The firmware upload went fine. the web server is running, both temperature and humidity sensors are registered. I can also see the esp01 integration with both sensors in my Home Assistant. However, no temperature or humidity values are shown. I suspect it may have something to do with invalid pin number, but I’ve tried different values and none work. What pin number should be used on ESP-01?