Hey,
I am relatively new to ESPHome and HA, but I have recently been trying to setup my system.
I went for MQTT way, i.e. my ESP8266s do not have API tag in their config. I managed to setup ESP8266 and MQTT explorer shows the device and messages coming in. I also see retained configuration messages of homeassistant with its prefix topic. This is my device config.
esphome:
name: esp8266-1
friendly_name: scd4x-air-quality-1
esp8266:
board: esp01_1m
# Enable logging
logger:
# Enable Home Assistant API
#api:
sensor:
- platform: scd4x
co2:
name: "co2"
temperature:
name: "temp"
humidity:
name: "humidity"
i2c_id: bus_a
i2c:
sda: 2
scl: 14
scan: true
id: bus_a
mqtt:
broker: IP
username: user
password: user
ota:
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: ""
password: ""
captive_portal:
One problem I saw right away is that no entities were created in homeassistant although retained config messages are seen in MQTT explorer.
Do I need additional setup for HA to see this device and somehow to autodetect it and add entities? Do I have to modify configuration.yaml to do that only? What is the typical workflow for MQTT ESPHome devices/entities to appear? I have reviewed manual several times, but it is really hard to read and understand sometimes, because it mostly works as a reference only…
Moreover, I recently reinstalled homeassistant machine and thus all of my devices are gone now. But I do not understand, how can I readd my devices to ESPHome dashboard that are based on MQTT integration only? They do not have API integration. At the moment, HA does not add them via devices section (with an IP) and states that “it does not have API tag”. Also, there is no option to readd on ESPHome section. I am simply lost, I do not want to reflash all my devices incase I reinstall homeassistant OS…
Thank you.