Edit esp-loungebookshelfleds.yaml
This commit is contained in:
@@ -6,6 +6,7 @@
|
|||||||
# https://home.fox.co.nz/gitea/zorruno/zorruno-homeassistant/src/branch/master/esphome/esp-loungebookshelfleds.yaml
|
# https://home.fox.co.nz/gitea/zorruno/zorruno-homeassistant/src/branch/master/esphome/esp-loungebookshelfleds.yaml
|
||||||
#:########################################################################################:#
|
#:########################################################################################:#
|
||||||
# VERSIONS:
|
# VERSIONS:
|
||||||
|
# V2.2 2026-07-20 Simplified local MQTT command and status topics to the device root
|
||||||
# V2.1 2026-03-11 Updated yaml to zorruno layout V1.1
|
# V2.1 2026-03-11 Updated yaml to zorruno layout V1.1
|
||||||
# V2.0 2025-09-15 A bunch of fixes and made it more standard across my devices
|
# V2.0 2025-09-15 A bunch of fixes and made it more standard across my devices
|
||||||
# V1.0 2025-08-17 First setup (and replacement of Tasmota)
|
# V1.0 2025-08-17 First setup (and replacement of Tasmota)
|
||||||
@@ -48,10 +49,10 @@
|
|||||||
# - Maximum ON time before automatic fade-down (1-48 h, 0 = no limit)
|
# - Maximum ON time before automatic fade-down (1-48 h, 0 = no limit)
|
||||||
#
|
#
|
||||||
# MQTT COMMANDS:
|
# MQTT COMMANDS:
|
||||||
# - ${mqtt_local_command_topic}/light/set = ON
|
# - ${mqtt_local_command_topic} = ON
|
||||||
# - ${mqtt_local_command_topic}/light/set = OFF
|
# - ${mqtt_local_command_topic} = OFF
|
||||||
# - State publishes to:
|
# - State publishes to:
|
||||||
# - ${mqtt_local_status_topic}/light/state
|
# - ${mqtt_local_status_topic}
|
||||||
#:########################################################################################:#
|
#:########################################################################################:#
|
||||||
# OFFLINE NOTES:
|
# OFFLINE NOTES:
|
||||||
# a) Home Assistant offline (network and MQTT online):
|
# a) Home Assistant offline (network and MQTT online):
|
||||||
@@ -84,7 +85,7 @@ substitutions:
|
|||||||
|
|
||||||
# Project Naming
|
# Project Naming
|
||||||
project_name: "Magichome Single Colour V1.1 LED Controller.Generic ESP8266" # Project details. Manufacturer before the dot, device after the dot.
|
project_name: "Magichome Single Colour V1.1 LED Controller.Generic ESP8266" # Project details. Manufacturer before the dot, device after the dot.
|
||||||
project_version: "v2.1" # Project version denotes release of the YAML file, allowing checking of deployed vs latest version
|
project_version: "v2.2" # Project version denotes release of the YAML file, allowing checking of deployed vs latest version
|
||||||
|
|
||||||
# Passwords & Secrets (Unfortunately, you can't use substitutions inside secret names)
|
# Passwords & Secrets (Unfortunately, you can't use substitutions inside secret names)
|
||||||
api_key: !secret esp-api_key # If using HA API
|
api_key: !secret esp-api_key # If using HA API
|
||||||
@@ -132,8 +133,7 @@ packages:
|
|||||||
local_ota_pass: "${ota_pass}"
|
local_ota_pass: "${ota_pass}"
|
||||||
|
|
||||||
#### HOME ASSISTANT API (choose encryption or no encryption options) ####
|
#### HOME ASSISTANT API (choose encryption or no encryption options) ####
|
||||||
common_api: !include
|
common_api: !include #file: common/api_common.yaml
|
||||||
#file: common/api_common.yaml
|
|
||||||
file: common/api_common_noencryption.yaml
|
file: common/api_common_noencryption.yaml
|
||||||
vars:
|
vars:
|
||||||
local_api_key: "${api_key}"
|
local_api_key: "${api_key}"
|
||||||
@@ -351,12 +351,12 @@ status_led:
|
|||||||
mqtt:
|
mqtt:
|
||||||
on_message:
|
on_message:
|
||||||
# Light control to ramp up
|
# Light control to ramp up
|
||||||
- topic: "${mqtt_local_command_topic}/light/set"
|
- topic: "${mqtt_local_command_topic}"
|
||||||
payload: "${mqtt_local_device_command_ON}"
|
payload: "${mqtt_local_device_command_ON}"
|
||||||
then:
|
then:
|
||||||
- switch.turn_on: mosfet_ramp_switch
|
- switch.turn_on: mosfet_ramp_switch
|
||||||
# Light control to ramp down
|
# Light control to ramp down
|
||||||
- topic: "${mqtt_local_command_topic}/light/set"
|
- topic: "${mqtt_local_command_topic}"
|
||||||
payload: "${mqtt_local_device_command_OFF}"
|
payload: "${mqtt_local_device_command_OFF}"
|
||||||
then:
|
then:
|
||||||
- switch.turn_off: mosfet_ramp_switch
|
- switch.turn_off: mosfet_ramp_switch
|
||||||
@@ -593,7 +593,7 @@ light:
|
|||||||
on_turn_on:
|
on_turn_on:
|
||||||
- output.turn_on: green_led_out
|
- output.turn_on: green_led_out
|
||||||
- mqtt.publish:
|
- mqtt.publish:
|
||||||
topic: "${mqtt_local_status_topic}/light/state"
|
topic: "${mqtt_local_status_topic}"
|
||||||
payload: "${mqtt_local_device_command_ON}"
|
payload: "${mqtt_local_device_command_ON}"
|
||||||
retain: true
|
retain: true
|
||||||
- lambda: |-
|
- lambda: |-
|
||||||
@@ -617,7 +617,7 @@ light:
|
|||||||
lambda: "return !id(booting);"
|
lambda: "return !id(booting);"
|
||||||
then:
|
then:
|
||||||
- mqtt.publish:
|
- mqtt.publish:
|
||||||
topic: "${mqtt_local_status_topic}/light/state"
|
topic: "${mqtt_local_status_topic}"
|
||||||
payload: "${mqtt_local_device_command_OFF}"
|
payload: "${mqtt_local_device_command_OFF}"
|
||||||
retain: true
|
retain: true
|
||||||
- lambda: "id(ramp_switch_target_on) = false;"
|
- lambda: "id(ramp_switch_target_on) = false;"
|
||||||
|
|||||||
Reference in New Issue
Block a user