From 0a396c4c716eaa6980f01ceecf37ede17cc96649 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=2E=20=C3=81rkosi=20R=C3=B3bert?= Date: Mon, 13 Nov 2023 14:08:44 +0100 Subject: [PATCH 1/3] Update for recent ESPHome releases - change switch restore_state to restore_mode as the former configuration option is not supported anymore - change `onboard_led` to be a status_led light platform, so it can be double purposed as both ESPHome Status LED and heating indicator - add some entity icons, device class --- esphome/esphome_smarttherm.yaml | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/esphome/esphome_smarttherm.yaml b/esphome/esphome_smarttherm.yaml index 5914d74..c5513de 100644 --- a/esphome/esphome_smarttherm.yaml +++ b/esphome/esphome_smarttherm.yaml @@ -54,25 +54,28 @@ output: id: pwm_output switch: - - platform: gpio - pin: D4 - id: onboard_led - inverted: True - internal: True - - platform: template name: ${unit_name}_heating id: heating entity_category: config - restore_state: True + restore_mode: RESTORE_DEFAULT_OFF + icon: "mdi:water-boiler" optimistic: True turn_on_action: - - switch.turn_on: onboard_led + - light.turn_on: onboard_led - script.execute: set_pwm_level_from_slider turn_off_action: - - switch.turn_off: onboard_led + - light.turn_off: onboard_led - script.execute: set_pwm_low_level +light: + - platform: status_led + id: onboard_led + internal: True + pin: + number: D4 + inverted: true + script: - id: set_pwm_level_from_slider then: @@ -106,6 +109,7 @@ number: mode: slider optimistic: True entity_category: config + icon: "mdi:gas-burner" on_value: then: - sensor.template.publish: @@ -175,6 +179,7 @@ binary_sensor: pullup: True name: ${unit_name}_active id: power_active + device_class: power filters: # debounce - delayed_on: 5s - delayed_off: 5s From 31cb9e9e71e8ed4ee459758f9713583edbdf9c03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=2E=20=C3=81rkosi=20R=C3=B3bert?= Date: Mon, 13 Nov 2023 14:26:09 +0100 Subject: [PATCH 2/3] Update api config options - API password is not supported anymore, it needs encryption --- esphome/esphome_smarttherm.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/esphome/esphome_smarttherm.yaml b/esphome/esphome_smarttherm.yaml index c5513de..b0318e7 100644 --- a/esphome/esphome_smarttherm.yaml +++ b/esphome/esphome_smarttherm.yaml @@ -20,7 +20,9 @@ ota: # native api of ESPHome #api: -# password: !secret api_password +# reboot_timeout: 60min +# encryption: +# key: !secret encryption_key # or mqtt (my choice) mqtt: From 5c76fc2030c84c54919c27d15c79f5915c050b4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=2E=20=C3=81rkosi=20R=C3=B3bert?= Date: Wed, 29 May 2024 16:39:47 +0200 Subject: [PATCH 3/3] Update esphome_smarttherm.yaml remove api/ota/etc as these are standard ESPHome config options to be seen in the doc. ota will soon change a bit, so no need to update this doc again, for something otherwise unrelated directly to this project --- esphome/esphome_smarttherm.yaml | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/esphome/esphome_smarttherm.yaml b/esphome/esphome_smarttherm.yaml index b0318e7..8f5f8d5 100644 --- a/esphome/esphome_smarttherm.yaml +++ b/esphome/esphome_smarttherm.yaml @@ -3,21 +3,6 @@ substitutions: unit_name: "smarttherm" -wifi: - ssid: !secret wifi_ssid - password: !secret wifi_password - fast_connect: true - reboot_timeout: 0s - - ap: - ssid: ${unit_name} Fallback Hotspot - password: !secret fallback_password - -captive_portal: - -ota: - password: !secret ota_password - # native api of ESPHome #api: # reboot_timeout: 60min