upd: simpify esp-conf
This commit is contained in:
256
esphome.yaml
256
esphome.yaml
@@ -23,31 +23,40 @@ substitutions:
|
||||
# nspanel_ha_climate_thermostat: climate.xxxxx
|
||||
###### END OF SECRETS BLOCK TO PASTE ####################################################################
|
||||
|
||||
###### Change ME ######
|
||||
node_name: "nspanel_NAME" # ändere Name zum Beispiel in den Raum wo das NSPanel verbaut wird
|
||||
device_name: § # ändere Name zum Beispiel Raum - ist der Name der in HA verwnedet wird
|
||||
wifi_ssid: "WLAN NAME" # Gib dein WLAN Name ein
|
||||
wifi_password: "WLAN PASSWORD" # Gib dein Passwort fürs WLAN ein
|
||||
ota_password: "OTA PASSWORD" # Gib ein Passwort ein - kann das selbe wie WLAN sein
|
||||
nextion_update_url: "http://10.0.0.200:8123/local/nspanel/nspanel.tft" # URL to tft file git or local
|
||||
##### Change ME #####
|
||||
|
||||
### advanced config activate only when you know what you do ###
|
||||
|
||||
# ## usage of secrets-file ## -> comment in ###### Change ME ######
|
||||
# wifi_ssid: !secret nspanel_wifi_ssid # add in your esphome secrets file.
|
||||
# wifi_password: !secret nspanel_wifi_password # add in your esphome secrets file.
|
||||
# ota_password: !secret nspanel_ota_password # add in your esphome secrets file.
|
||||
# nextion_update_url: !secret nspanel_update_url # add in your esphome secrets file.
|
||||
|
||||
# ## static ip config ##
|
||||
# ip: "10.0.0.7"
|
||||
# gw: "10.0.0.138"
|
||||
# subnet: "255.255.255.0"
|
||||
# dns: "10.0.0.138"
|
||||
# domain: ".local"
|
||||
|
||||
### end of advanced config
|
||||
|
||||
|
||||
node_name: !secret nspanel_node_name # $node_name
|
||||
device_name: !secret nspanel_device_name # $device_name
|
||||
ip: !secret nspanel_ip # static ip
|
||||
gw: !secret nspanel_gateway
|
||||
subnet: !secret nspanel_subnet
|
||||
dns: !secret nspanel_dns
|
||||
domain: !secret nspanel_domain
|
||||
|
||||
wifi_ssid: !secret nspanel_wifi_ssid # add in your esphome secrets file.
|
||||
wifi_password: !secret nspanel_wifi_password # add in your esphome secrets file.
|
||||
ota_password: !secret nspanel_ota_password # add in your esphome secrets file.
|
||||
nextion_update_url: !secret nspanel_update_url # add in your esphome secrets file.
|
||||
webserver_password: !secret nspanel_web_password
|
||||
###### EDIT THE BELOW ENTITIES FOR YOURS... #######################################################################
|
||||
|
||||
#ha_weekday: sensor.wochentag ##### Sensor Wochentag generiert in HA (custom_configuration -> nspanel) #####
|
||||
#ha_outdoor_temp: sensor.terrasse_garage_motion_sensor_temperature ##### Temperatur von Bewegungsmelder Outdoor (Zigbee2Mqtt) #####
|
||||
#ha_hotwater_temp: sensor.hotwater_temp ##### Buderus Heizung Warmwasser Temperatur (Integration) #####
|
||||
ha_hotwater_charge: !secret nspanel_hotwater_charge
|
||||
ha_heating_system_flame: !secret nspanel_ha_heating_system_flame ##### Buderus Heizung Flamen-Status (Integration) #####
|
||||
ha_climate_thermostat_target_temp: !secret nspanel_ha_climate_thermostat_target_temp ##### Climate Thermostat generiert in HA (custom_configuration -> nspanel) #####
|
||||
ha_climate_thermostat: !secret nspanel_ha_climate_thermostat ##### Climate Thermostat generiert in HA (custom_configuration -> nspanel) #####
|
||||
#ha_humidity: sensor.kinderzimmer_lea_temperatur_sensor_humidity
|
||||
###### EDIT THE BELOW ENTITIES FOR YOURS... depricated #######################################################################
|
||||
### - will be removed in future release - ignore it or set if exist ##################
|
||||
ha_hotwater_charge: switch.wwcharge
|
||||
ha_heating_system_flame: binary_sensor.flamestatus ##### Buderus Heizung Flamen-Status (Integration) #####
|
||||
ha_climate_thermostat_target_temp: sensor.nspanel_target_temp ##### Climate Thermostat generiert in HA (custom_configuration -> nspanel) #####
|
||||
ha_climate_thermostat: climate.nspanel_name ##### Climate Thermostat generiert in HA (custom_configuration -> nspanel) #####
|
||||
|
||||
#########################################
|
||||
#
|
||||
#
|
||||
@@ -88,12 +97,13 @@ wifi:
|
||||
ssid: ${wifi_ssid}
|
||||
password: ${wifi_password}
|
||||
power_save_mode: none
|
||||
manual_ip:
|
||||
static_ip: ${ip}
|
||||
gateway: ${gw}
|
||||
subnet: ${subnet}
|
||||
dns1: ${dns}
|
||||
domain: ${domain}
|
||||
### advanced config - uncomment to use static IP-Config ###
|
||||
# manual_ip:
|
||||
# static_ip: ${ip}
|
||||
# gateway: ${gw}
|
||||
# subnet: ${subnet}
|
||||
# dns1: ${dns}
|
||||
# domain: ${domain}
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
ssid: "${device_name}"
|
||||
@@ -105,7 +115,7 @@ web_server:
|
||||
port: 80
|
||||
auth:
|
||||
username: admin
|
||||
password: ${webserver_password}
|
||||
password: ${ota_password}
|
||||
|
||||
##### OTA (Over the air updates) password #####
|
||||
ota:
|
||||
@@ -139,23 +149,6 @@ uart:
|
||||
baud_rate: 115200
|
||||
id: tf_uart
|
||||
|
||||
##### INFO - Time component that fetches time from home Assistant and updates the display once a minute and when the display is ready at bootup (and time is available) #####
|
||||
#time:
|
||||
# - platform: homeassistant
|
||||
# id: homeassistant_time
|
||||
# on_time:
|
||||
# - seconds: 0
|
||||
# minutes: /1
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a01", "%02i:%02i", id(homeassistant_time).now().hour, id(homeassistant_time).now().minute);
|
||||
# on_time_sync:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a01", "%02i:%02i", id(homeassistant_time).now().hour, id(homeassistant_time).now().minute);
|
||||
|
||||
###### A reboot button is always useful #####
|
||||
button:
|
||||
- platform: restart
|
||||
@@ -412,58 +405,6 @@ binary_sensor:
|
||||
on_click:
|
||||
- switch.toggle: hvac_mode
|
||||
|
||||
##### Display Brightness - BUTTON DECREASES Brightness #####
|
||||
# - platform: nextion
|
||||
# name: $device_name Brightness DOWN
|
||||
# page_id: 7
|
||||
# component_id: 12
|
||||
# internal: true
|
||||
# on_click:
|
||||
# - number.set:
|
||||
# id: display_brightness
|
||||
# value: !lambda return id(display_brightness_global) - 1;
|
||||
# - lambda: id(disp1).set_component_text_printf("settings.a03", "%i", id(display_brightness_global));
|
||||
# - lambda: id(disp1).send_command_printf("settings.brightslider.val=%i", id(display_brightness_global));
|
||||
|
||||
##### Display Brightness - BUTTON INCREASES Brightness #####
|
||||
# - platform: nextion
|
||||
# name: $device_name Brightness UP
|
||||
# page_id: 7
|
||||
# component_id: 13
|
||||
# internal: true
|
||||
# on_click:
|
||||
# - number.set:
|
||||
# id: display_brightness
|
||||
# value: !lambda return id(display_brightness_global) + 1;
|
||||
# - lambda: id(disp1).set_component_text_printf("settings.a03", "%i", id(display_brightness_global));
|
||||
# - lambda: id(disp1).send_command_printf("settings.brightslider.val=%i", id(display_brightness_global));
|
||||
|
||||
##### Display DIM Brightness - BUTTON DECREASES Brightness #####
|
||||
# - platform: nextion
|
||||
# name: $device_name Brightness DIM DOWN
|
||||
# page_id: 7
|
||||
# component_id: 14
|
||||
# internal: true
|
||||
# on_click:
|
||||
# - number.set:
|
||||
# id: display_dim_brightness
|
||||
# value: !lambda return id(display_dim_brightness_global) - 1;
|
||||
# - lambda: id(disp1).set_component_text_printf("settings.a04", "%i", id(display_dim_brightness_global));
|
||||
# - lambda: id(disp1).send_command_printf("settings.dimslider.val=%i", id(display_dim_brightness_global));
|
||||
|
||||
##### Display DIM Brightness - BUTTON INCREASES Brightness #####
|
||||
# - platform: nextion
|
||||
# name: $device_name Brightness DIM UP
|
||||
# page_id: 7
|
||||
# component_id: 15
|
||||
# internal: true
|
||||
# on_click:
|
||||
# - number.set:
|
||||
# id: display_dim_brightness
|
||||
# value: !lambda return id(display_dim_brightness_global) + 1;
|
||||
# - lambda: id(disp1).set_component_text_printf("settings.a04", "%i", id(display_dim_brightness_global));
|
||||
# - lambda: id(disp1).send_command_printf("settings.dimslider.val=%i", id(display_dim_brightness_global));
|
||||
|
||||
##### Restart NSPanel Button #####
|
||||
- platform: nextion
|
||||
name: ${device_name} Restart
|
||||
@@ -554,39 +495,6 @@ sensor:
|
||||
switch.is_on: nextion_init
|
||||
- lambda: id(disp1).set_component_text_printf("home.a03", "%.1f°", id(temp_nspanel).state); # onboard temp (thermostat temp) to home page.
|
||||
- lambda: id(disp1).set_component_text_printf("thermostat.a04", "%.1f", id(temp_nspanel).state);
|
||||
|
||||
##### TEMPERATURE Outdoor FROM HA #####
|
||||
# - platform: homeassistant
|
||||
# id: temp_outdoor
|
||||
# entity_id: $ha_outdoor_temp
|
||||
# on_value:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a06", "%.0f°", id(temp_outdoor).state);
|
||||
# - lambda: id(disp1).set_component_text_printf("thermostat.a07", "%.0f°", id(temp_outdoor).state);
|
||||
|
||||
##### HUMIDITY Indoor FROM HA #####
|
||||
# - platform: homeassistant
|
||||
# id: humidity
|
||||
# entity_id: $ha_humidity
|
||||
# on_value:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a04", "%.0f°", id(humidity).state);
|
||||
|
||||
|
||||
##### THERMOSTAT HOT WATER TEMP FROM HA #####
|
||||
# - platform: homeassistant
|
||||
# id: temp_hotwater
|
||||
# entity_id: $ha_hotwater_temp
|
||||
# on_value:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a07", "%.1f°", id(temp_hotwater).state);
|
||||
# - lambda: id(disp1).set_component_text_printf("thermostat.a08", "%.1f°", id(temp_hotwater).state);
|
||||
|
||||
##### THERMOSTAT CLIMATE TARGET TEMPERATURE FROM HA #####
|
||||
- platform: homeassistant
|
||||
@@ -977,18 +885,6 @@ text_sensor:
|
||||
id: last_click_weathersettings
|
||||
value: !lambda return x;
|
||||
|
||||
|
||||
|
||||
##### Wochentag SENSOR FROM HA #####
|
||||
# - platform: homeassistant
|
||||
# id: weekday
|
||||
# entity_id: $ha_weekday
|
||||
# on_value:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: id(disp1).set_component_text_printf("home.a02", "%s", id(weekday).state.c_str());
|
||||
|
||||
##### HEATING System ICON #####
|
||||
- platform: homeassistant
|
||||
entity_id: ${ha_heating_system_flame}
|
||||
@@ -1021,58 +917,6 @@ text_sensor:
|
||||
} else {
|
||||
id(disp1).set_component_value("thermostat.a12",0);
|
||||
}
|
||||
# - lambda: |-
|
||||
# id(disp1).set_component_value("thermostat.a12",0);
|
||||
# if (id(hotwater_charge) == "on")
|
||||
# {
|
||||
# id(disp1).set_component_value("thermostat.a12",1);
|
||||
# }
|
||||
|
||||
##### WEATHER SYMBOL FROM HA WEATHER ENTITY #####
|
||||
# - platform: homeassistant
|
||||
# id: weather_symbol
|
||||
# entity_id: weather.home_wetter
|
||||
# on_value:
|
||||
# then:
|
||||
# - wait_until:
|
||||
# switch.is_on: nextion_init
|
||||
# - lambda: |-
|
||||
# int symbol=1; // 1 is a empty box.
|
||||
# if (id(weather_symbol).state == "sunny") {
|
||||
# symbol=2;
|
||||
# } else if (id(weather_symbol).state == "cloudy") {
|
||||
# symbol=3;
|
||||
# if (id(sun_sun).state == "below_horizon") {
|
||||
# symbol=3;
|
||||
# }
|
||||
# } else if (id(weather_symbol).state == "rainy") {
|
||||
# symbol=4;
|
||||
# } else if (id(weather_symbol).state == "pouring") {
|
||||
# symbol=5;
|
||||
# } else if (id(weather_symbol).state == "snowy") {
|
||||
# symbol=6;
|
||||
# } else if (id(weather_symbol).state == "hail" || id(weather_symbol).state == "snowy-rainy") {
|
||||
# symbol=7;
|
||||
# } else if (id(weather_symbol).state == "fog") {
|
||||
# symbol=8;
|
||||
# } else if (id(weather_symbol).state == "windy" || id(weather_symbol).state == "windy-variant") {
|
||||
# symbol=9;
|
||||
# } else if (id(weather_symbol).state == "lightning") {
|
||||
# symbol=10;
|
||||
# } else if (id(weather_symbol).state == "partlycloudy") {
|
||||
# symbol=11;
|
||||
# if (id(sun_sun).state == "below_horizon") {
|
||||
# symbol=12;
|
||||
# }
|
||||
# } else if (id(weather_symbol).state == "lightning-rainy" || id(weather_symbol).state == "exceptional") {
|
||||
# symbol=13;
|
||||
# if (id(sun_sun).state == "below_horizon") {
|
||||
# symbol=14;
|
||||
# }
|
||||
# } else if (id(weather_symbol).state == "clear-night") {
|
||||
# symbol=15;
|
||||
# }
|
||||
# id(disp1).send_command_printf("home.a05.pic=%i", symbol);
|
||||
|
||||
#########################################
|
||||
#
|
||||
@@ -1135,26 +979,6 @@ switch:
|
||||
id: relay_2
|
||||
pin:
|
||||
number: 19
|
||||
# on_turn_off:
|
||||
# - globals.set:
|
||||
# id: heating_room_global
|
||||
# value: '0'
|
||||
# - lambda: |-
|
||||
# if (id(hvac_mode_global) == 0)
|
||||
# {
|
||||
# id(disp1).send_command_printf("thermostat.a06.pic=49");
|
||||
# } else if (id(hvac_mode_global) == 1) {
|
||||
# id(disp1).send_command_printf("thermostat.a06.pic=50");
|
||||
# }
|
||||
# - lambda: id(disp1).send_command_printf("home.a52.pic=53");
|
||||
# - lambda: id(disp1).send_command_printf("thermostat.a52.pic=53");
|
||||
# on_turn_on:
|
||||
# - globals.set:
|
||||
# id: heating_room_global
|
||||
# value: '1'
|
||||
# - lambda: id(disp1).send_command_printf("thermostat.a06.pic=51");
|
||||
# - lambda: id(disp1).send_command_printf("home.a52.pic=66");
|
||||
# - lambda: id(disp1).send_command_printf("thermostat.a52.pic=66");
|
||||
|
||||
##### Switch Climate HVAC Mode #####
|
||||
- platform: template
|
||||
|
||||
1353
esphome_dhcp.yaml
1353
esphome_dhcp.yaml
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user