The VERBOSE logs for my ESPhome relay node doesn’t give a clue:
INFO Trying to connect to mvrelay @ 10.0.30.44 in the background
INFO Successfully connected to mvrelay @ 10.0.30.44 in 0.017s
INFO Successful handshake with mvrelay @ 10.0.30.44 in 0.112s
[22:23:06][I][app:102]: ESPHome version 2023.12.5 compiled on Jan 13 2024, 22:21:36
[22:23:06][C][status_led:065]: Status Led Light:
[22:23:06][C][status_led:066]: Pin: GPIO13
[22:23:06][C][wifi:573]: WiFi:
[22:23:06][C][wifi:405]: Local MAC: [redacted]
[22:23:06][C][wifi:410]: SSID: [redacted]
[22:23:06][C][wifi:411]: IP Address: 10.0.30.44
[22:23:06][C][wifi:413]: BSSID: [redacted]
[22:23:06][C][wifi:414]: Hostname: 'mvrelay'
[22:23:06][C][wifi:416]: Signal strength: -59 dB ▂▄▆█
[22:23:06][V][wifi:418]: Priority: 0.0
[22:23:06][C][wifi:420]: Channel: 1
[22:23:06][C][wifi:421]: Subnet: 255.255.255.0
[22:23:06][C][wifi:422]: Gateway: 10.0.30.1
[22:23:06][C][wifi:423]: DNS1: 10.0.30.1
[22:23:06][C][wifi:424]: DNS2: 0.0.0.0
[22:23:06][C][logger:443]: Logger:
[22:23:06][C][logger:444]: Level: VERBOSE
[22:23:06][C][logger:445]: Log Baud Rate: 115200
[22:23:06][C][logger:447]: Hardware UART: UART0
[22:23:06][C][uart.arduino_esp32:137]: UART Bus 1:
[22:23:06][C][uart.arduino_esp32:138]: TX Pin: GPIO25
[22:23:06][C][uart.arduino_esp32:139]: RX Pin: GPIO26
[22:23:06][C][uart.arduino_esp32:141]: RX Buffer Size: 256
[22:23:06][C][uart.arduino_esp32:143]: Baud Rate: 4800 baud
[22:23:06][C][uart.arduino_esp32:144]: Data Bits: 8
[22:23:06][C][uart.arduino_esp32:145]: Parity: NONE
[22:23:06][C][uart.arduino_esp32:146]: Stop bits: 2
[22:23:06][C][uptime.sensor:031]: Uptime Sensor 'Uptime'
[22:23:06][C][uptime.sensor:031]: Device Class: 'duration'
[22:23:06][C][uptime.sensor:031]: State Class: 'total_increasing'
[22:23:06][C][uptime.sensor:031]: Unit of Measurement: 's'
[22:23:06][C][uptime.sensor:031]: Accuracy Decimals: 0
[22:23:06][C][uptime.sensor:031]: Icon: 'mdi:timer-outline'
[22:23:06][V][uptime.sensor:031]: Unique ID: 'a842e350ed40-uptime'
[22:23:06][C][template.select:065]: Template Select 'MechanischeVentilatieSelect'
[22:23:06][C][template.select:066]: Update Interval: 60.0s
[22:23:06][C][template.select:069]: Optimistic: YES
[22:23:06][C][template.select:070]: Initial Option: Low
[22:23:06][C][template.select:071]: Restore Value: NO
[22:23:06][C][switch.gpio:068]: GPIO Switch 'mvrelay Relay Medium'
[22:23:06][C][switch.gpio:070]: Icon: 'mdi:electric-switch'
[22:23:06][C][switch.gpio:091]: Restore Mode: always OFF
[22:23:06][C][switch.gpio:031]: Pin: GPIO27
[22:23:06][C][switch.gpio:033]: Interlocks:
[22:23:06][C][switch.gpio:037]: mvrelay Relay High
[22:23:06][C][switch.gpio:068]: GPIO Switch 'mvrelay Relay High'
[22:23:06][C][switch.gpio:070]: Icon: 'mdi:electric-switch'
[22:23:06][C][switch.gpio:091]: Restore Mode: always OFF
[22:23:06][C][switch.gpio:031]: Pin: GPIO14
[22:23:06][C][switch.gpio:033]: Interlocks:
[22:23:06][C][switch.gpio:037]: mvrelay Relay Medium
[22:23:06][C][gpio.binary_sensor:015]: GPIO Binary Sensor 'mvrelay Switch Medium'
[22:23:06][C][gpio.binary_sensor:016]: Pin: GPIO32
[22:23:06][C][gpio.binary_sensor:015]: GPIO Binary Sensor 'mvrelay Switch High'
[22:23:06][C][gpio.binary_sensor:016]: Pin: GPIO33
[22:23:06][C][light:103]: Light 'LED'
[22:23:06][C][bl0939:130]: BL0939:
[22:23:06][C][bl0939:131]: Voltage 'mvrelay Voltage'
[22:23:06][C][bl0939:131]: Device Class: 'voltage'
[22:23:06][C][bl0939:131]: State Class: 'measurement'
[22:23:06][C][bl0939:131]: Unit of Measurement: 'V'
[22:23:06][C][bl0939:131]: Accuracy Decimals: 1
[22:23:06][C][bl0939:132]: Current 1 'mvrelay Current 1'
[22:23:06][C][bl0939:132]: Device Class: 'current'
[22:23:06][C][bl0939:132]: State Class: 'measurement'
[22:23:06][C][bl0939:132]: Unit of Measurement: 'A'
[22:23:06][C][bl0939:132]: Accuracy Decimals: 2
[22:23:06][C][bl0939:133]: Current 2 'mvrelay Current 2'
[22:23:06][C][bl0939:133]: Device Class: 'current'
[22:23:06][C][bl0939:133]: State Class: 'measurement'
[22:23:06][C][bl0939:133]: Unit of Measurement: 'A'
[22:23:06][C][bl0939:133]: Accuracy Decimals: 2
[22:23:06][C][bl0939:134]: Power 1 'mvrelay Power 1'
[22:23:06][C][bl0939:134]: Device Class: 'power'
[22:23:06][C][bl0939:134]: State Class: 'measurement'
[22:23:06][C][bl0939:134]: Unit of Measurement: 'W'
[22:23:06][C][bl0939:134]: Accuracy Decimals: 0
[22:23:06][C][bl0939:135]: Power 2 'mvrelay Power 2'
[22:23:06][C][bl0939:135]: Device Class: 'power'
[22:23:06][C][bl0939:135]: State Class: 'measurement'
[22:23:06][C][bl0939:135]: Unit of Measurement: 'W'
[22:23:06][C][bl0939:135]: Accuracy Decimals: 0
[22:23:06][C][bl0939:136]: Energy 1 'mvrelay Energy 1'
[22:23:06][C][bl0939:136]: Device Class: 'energy'
[22:23:06][C][bl0939:136]: State Class: 'total_increasing'
[22:23:06][C][bl0939:136]: Unit of Measurement: 'kWh'
[22:23:06][C][bl0939:136]: Accuracy Decimals: 3
[22:23:06][C][bl0939:137]: Energy 2 'mvrelay Energy 2'
[22:23:06][C][bl0939:137]: Device Class: 'energy'
[22:23:06][C][bl0939:137]: State Class: 'total_increasing'
[22:23:06][C][bl0939:137]: Unit of Measurement: 'kWh'
[22:23:06][C][bl0939:137]: Accuracy Decimals: 3
[22:23:06][C][bl0939:138]: Energy sum 'mvrelay Energy Total'
[22:23:06][C][bl0939:138]: Device Class: 'energy'
[22:23:06][C][bl0939:138]: State Class: 'total_increasing'
[22:23:06][C][bl0939:138]: Unit of Measurement: 'kWh'
[22:23:06][C][bl0939:138]: Accuracy Decimals: 3
[22:23:06][C][restart.button:017]: Restart Button 'Restart'
[22:23:06][C][mdns:115]: mDNS:
[22:23:06][C][mdns:116]: Hostname: mvrelay
[22:23:06][V][mdns:117]: Services:
[22:23:06][V][mdns:119]: - _esphomelib, _tcp, 6053
[22:23:06][V][mdns:121]: TXT: friendly_name = MVrelay
[22:23:06][V][mdns:121]: TXT: version = 2023.12.5
[22:23:06][V][mdns:121]: TXT: mac = a842e350ed40
[22:23:06][V][mdns:121]: TXT: platform = ESP32
[22:23:06][V][mdns:121]: TXT: board = esp32dev
[22:23:06][V][mdns:121]: TXT: network = wifi
[22:23:06][V][mdns:121]: TXT: api_encryption = Noise_NNpsk0_25519_ChaChaPoly_SHA256
[22:23:06][C][ota:097]: Over-The-Air Updates:
[22:23:06][C][ota:098]: Address: mvrelay.local:3232
[22:23:06][C][ota:101]: Using Password.
[22:23:06][C][api:139]: API Server:
[22:23:06][C][api:140]: Address: mvrelay.local:6053
[22:23:06][C][api:142]: Using noise encryption: YES
[22:23:06][C][wifi_signal.sensor:009]: WiFi Signal 'RSSI'
[22:23:06][C][wifi_signal.sensor:009]: Device Class: 'signal_strength'
[22:23:06][C][wifi_signal.sensor:009]: State Class: 'measurement'
[22:23:06][C][wifi_signal.sensor:009]: Unit of Measurement: 'dBm'
[22:23:06][C][wifi_signal.sensor:009]: Accuracy Decimals: 0
[22:23:06][V][wifi_signal.sensor:009]: Unique ID: 'a842e350ed40-wifisignal'
Here is my node config:
substitutions:
devicename: mvrelay
max_temp: "85.0"
esphome:
name: ${devicename}
friendly_name: MVrelay
# Ensures that, after a reboot, the ventilation will go to the state reflected by the physical knob. Since the relais go off first during the boot, the default value is already "Low" and does not need to be defined anymore.
on_boot:
if:
condition:
binary_sensor.is_on: switch_medium
then:
- select.set:
id: mvselect
option: "Medium"
else:
if:
condition:
binary_sensor.is_on: switch_high
then:
- select.set:
id: mvselect
option: "High"
# Enable logging
logger:
level: INFO
# Enable Home Assistant API
api:
encryption:
key: !secret mvrelay_api_key
ota:
password: !secret ota_secret
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
esp32:
board: esp32dev
sensor:
- platform: wifi_signal
name: "RSSI"
id: sensor_rssi
update_interval: 90s
entity_category: "diagnostic"
- platform: uptime
name: "Uptime"
id: sensor_uptime
update_interval: 300s
entity_category: "diagnostic"
- platform: bl0939
update_interval: 60s
voltage:
name: ${devicename} Voltage
current_1:
name: ${devicename} Current 1
disabled_by_default: True
current_2:
name: ${devicename} Current 2
disabled_by_default: True
active_power_1:
name: ${devicename} Power 1
active_power_2:
name: ${devicename} Power 2
energy_1:
name: ${devicename} Energy 1
energy_2:
name: ${devicename} Energy 2
energy_total:
name: ${devicename} Energy Total
light:
- platform: status_led
name: "LED"
id: led_status
pin:
number: GPIO13
inverted: True
internal: True
button:
- platform: restart
name: "Restart"
id: button_restart
uart:
tx_pin: GPIO25
rx_pin: GPIO26
baud_rate: 4800
parity: NONE
stop_bits: 2
switch:
- platform: gpio
id: Relay_Medium
name: ${devicename} Relay Medium
pin: GPIO27
icon: "mdi:electric-switch"
restore_mode: always_off
# Ensure only one switch at a time is on (https://esphome.io/components/switch/gpio.html#interlocking)
interlock: &interlock_group [Relay_Medium, Relay_High]
on_turn_on:
then:
- select.set:
id: mvselect
option: "Medium"
on_turn_off:
then:
- select.set:
id: mvselect
option: "Low"
- platform: gpio
id: Relay_High
name: ${devicename} Relay High
pin: GPIO14
icon: "mdi:electric-switch"
restore_mode: always_off
interlock: *interlock_group
on_turn_on:
then:
- select.set:
id: mvselect
option: "High"
on_turn_off:
then:
- select.set:
id: mvselect
option: "Low"
binary_sensor:
- platform: gpio
name: ${devicename} Switch Medium
id: switch_medium
pin:
number: GPIO32
mode:
input: True
pullup: True
inverted: True
filters:
- delayed_on_off: 50ms
publish_initial_state: false
on_press:
then:
- select.set:
id: mvselect
option: "Medium"
on_release:
then:
- select.set:
id: mvselect
option: "Low"
- platform: gpio
name: ${devicename} Switch High
id: switch_high
pin:
number: GPIO33
mode:
input: True
pullup: True
inverted: True
filters:
- delayed_on_off: 50ms
publish_initial_state: false
on_press:
then:
- select.set:
id: mvselect
option: "High"
on_release:
then:
- select.set:
id: mvselect
option: "Low"
select:
- platform: template
name: MechanischeVentilatieSelect
id: mvselect
options:
- "Low"
- "Medium"
- "High"
restore_value: false
optimistic: true
on_value:
then:
- lambda: |-
if (id(mvselect).state == "Low") {
id(Relay_Medium).turn_off();
id(Relay_High).turn_off();
} else if (id(mvselect).state == "Medium") {
id(Relay_Medium).turn_on();
} else if (id(mvselect).state == "High") {
id(Relay_High).turn_on();
}
If you find anything wrong with this config, please let me know
I also checked the ESPhome add-on config and it actually has a setting called
Home Assistant Dashboard Integration
which is disabled by default (at least in my case). Enabling it does nothing different. Here are the logs since the most recent restart of the ESPhome add-on:
s6-rc: info: service fix-attrs: starting
s6-rc: info: service base-addon-timezone: starting
s6-rc: info: service base-addon-log-level: starting
s6-rc: info: service fix-attrs successfully started
[21:46:28] INFO: Configuring timezone (Europe/Amsterdam)...
s6-rc: info: service base-addon-log-level successfully started
s6-rc: info: service base-addon-timezone successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service init-nginx: starting
s6-rc: info: service esphome: starting
s6-rc: info: service esphome successfully started
s6-rc: info: service init-nginx successfully started
s6-rc: info: service nginx: starting
s6-rc: info: service nginx successfully started
s6-rc: info: service discovery: starting
[21:46:31] INFO: Waiting for ESPHome dashboard to come up...
[21:46:31] INFO: Starting ESPHome dashboard...
2024-01-13 21:46:32,469 INFO Starting dashboard web server on unix socket /var/run/esphome.sock and configuration dir /config/esphome...
[21:46:32] INFO: Starting NGINX...
2024-01-13 21:46:33,536 INFO 304 GET / (0.0.0.0) 15.29ms
2024-01-13 21:46:33,610 INFO 304 GET /devices (0.0.0.0) 4.07ms
[21:46:33] INFO: Successfully send discovery information to Home Assistant.
s6-rc: info: service discovery successfully started
s6-rc: info: service legacy-services: starting
s6-rc: info: service legacy-services successfully started
2024-01-13 21:46:38,615 INFO 304 GET /devices (0.0.0.0) 4.03ms
[repeating]
2024-01-13 21:47:44,033 INFO 304 GET /devices (0.0.0.0) 2.96ms
2024-01-13 21:48:37,061 INFO 304 GET / (0.0.0.0) 2.80ms
2024-01-13 21:48:37,174 INFO 304 GET /devices (0.0.0.0) 4.14ms
2024-01-13 21:48:39,696 INFO 200 GET /static/js/esphome/c.VPeQYmPp.js (0.0.0.0) 33.61ms
2024-01-13 21:48:39,743 INFO 200 GET /static/js/esphome/c.nIEdC0BA.js (0.0.0.0) 3.97ms
2024-01-13 21:48:39,749 INFO 200 GET /static/js/esphome/c.bcXJSIrw.js (0.0.0.0) 3.13ms
2024-01-13 21:48:39,754 INFO 200 GET /static/js/esphome/c.KwoaAax2.js (0.0.0.0) 2.69ms
2024-01-13 21:48:39,836 INFO 200 GET /static/js/esphome/c.g39gNE03.js (0.0.0.0) 3.92ms
2024-01-13 21:48:39,867 INFO 101 GET /logs (0.0.0.0) 1.65ms
2024-01-13 21:48:39,871 INFO Running command 'esphome --dashboard logs /config/esphome/mvrelay.yaml --device 10.0.30.44'
2024-01-13 21:48:42,168 INFO 304 GET /devices (0.0.0.0) 3.13ms
[repeating]
2024-01-13 21:49:37,253 INFO 304 GET /devices (0.0.0.0) 2.99ms
2024-01-13 21:49:42,143 INFO 200 GET /static/js/esphome/c.JK_Zc7F3.js (0.0.0.0) 11.83ms
2024-01-13 21:49:42,259 INFO 304 GET /devices (0.0.0.0) 3.04ms
2024-01-13 21:49:43,226 INFO 101 GET /validate (0.0.0.0) 1.07ms
2024-01-13 21:49:43,229 INFO Running command 'esphome --dashboard config /config/esphome/mvrelay.yaml --show-secrets'
2024-01-13 21:49:44,611 INFO Process exited with return code 0
2024-01-13 21:49:47,259 INFO 304 GET /devices (0.0.0.0) 2.72ms
2024-01-13 21:49:52,214 INFO 101 GET /logs (0.0.0.0) 1.29ms
2024-01-13 21:49:52,217 INFO Running command 'esphome --dashboard logs /config/esphome/mvrelay.yaml --device 10.0.30.44'
2024-01-13 21:49:52,262 INFO 304 GET /devices (0.0.0.0) 2.06ms
2024-01-13 21:49:57,265 INFO 304 GET /devices (0.0.0.0) 2.65ms
2024-01-13 21:50:19,020 INFO 304 GET / (0.0.0.0) 1.65ms
2024-01-13 21:50:19,074 INFO 304 GET /devices (0.0.0.0) 2.70ms
2024-01-13 21:54:00,399 INFO 304 GET / (0.0.0.0) 1.71ms
2024-01-13 21:54:00,482 INFO 304 GET /devices (0.0.0.0) 3.68ms
2024-01-13 21:54:05,454 INFO 304 GET /devices (0.0.0.0) 2.57ms
2024-01-13 21:57:30,227 INFO 304 GET / (0.0.0.0) 2.72ms
2024-01-13 21:57:30,283 INFO 304 GET /devices (0.0.0.0) 4.40ms
2024-01-13 21:57:33,097 INFO 101 GET /logs (0.0.0.0) 1.11ms
2024-01-13 21:57:33,613 INFO Running command 'esphome --dashboard logs /config/esphome/mvrelay.yaml --device 10.0.30.44'
2024-01-13 21:57:35,296 INFO 304 GET /devices (0.0.0.0) 2.11ms
[repeating]
2024-01-13 21:58:51,340 INFO 304 GET /devices (0.0.0.0) 2.70ms
2024-01-13 21:58:56,299 INFO 200 GET /static/js/esphome/c.L2HzI1eb.js (0.0.0.0) 11.33ms
2024-01-13 21:58:56,306 INFO 200 GET /edit?configuration=mvrelay.yaml (0.0.0.0) 2.79ms
2024-01-13 21:58:56,326 INFO 200 GET /static/js/esphome/monaco-editor/esm/vs/editor/editor.worker.js (0.0.0.0) 3.97ms
2024-01-13 21:58:57,054 INFO 200 GET /static/fonts/codicon.ttf (0.0.0.0) 12.42ms
2024-01-13 21:58:57,387 INFO 101 GET /ace (0.0.0.0) 1.39ms
2024-01-13 21:58:57,390 INFO Running command 'esphome --dashboard -q vscode --ace /config/esphome'
Not sure if that helps, though.