From bdebed62c62d7b6b7e544ba1f96aa747cd708ca2 Mon Sep 17 00:00:00 2001 From: Blackymas <41958506+Blackymas@users.noreply.github.com> Date: Tue, 25 Oct 2022 08:53:38 +0200 Subject: [PATCH] Update BETA_blueprint.yaml --- BETA Version/BETA_blueprint.yaml | 36 +++++++++++++++++++++++++------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/BETA Version/BETA_blueprint.yaml b/BETA Version/BETA_blueprint.yaml index 81fed53..d5479e2 100644 --- a/BETA Version/BETA_blueprint.yaml +++ b/BETA Version/BETA_blueprint.yaml @@ -677,7 +677,6 @@ variables: command_background_color: "esphome.{{ nspanel_name }}_send_command_background_color" tft_upload: "esphome.{{ nspanel_name }}_upload_tft" tft_path: !input "tft_path" - delay_jump_page: !input "delay_jump_page" humidity: !input "humidity" hotwatertemp: !input "hotwatertemp" outdoortemp: !input "outdoortemp" @@ -686,10 +685,12 @@ variables: language: !input "language" left_button_entity: !input "left_button_entity" right_button_entity: !input "right_button_entity" + delay_jump_page: !input "delay_jump_page" # Icons Mapping cover_pic_closed: "106" cover_pic_open: "107" + battery_icon: "108" # color for buttons button_light_off: "90" @@ -1758,29 +1759,29 @@ action: data: cmd: page coversettings - delay: - milliseconds: "{{ delay_jump_page }}" + milliseconds: 2 - service: "{{ command_value }}" data: component: coversettings.coverslider message: '{{ (state_attr(entity_long, "current_position") | int ) |round(0) }}' + - delay: + milliseconds: 4 - service: "{{ command_text_printf }}" data: component: coversettings.cover_value message: '{{ (state_attr(entity_long, "current_position") | int ) |round(0) }} %' + - delay: + milliseconds: 6 - service: "{{ command_text_printf }}" data: component: coversettings.cover_name message: '{{ entity_long_name }}' - - service: "{{ command_text_printf }}" - data: - component: coversettings.battery_value - message: '{{ (state_attr(entity_long, "battery") | int ) |round(0) }} %' - if: - condition: template value_template: '{{ states(entity_long) == "open" }}' then: - delay: - milliseconds: "{{ delay_jump_page }}" + milliseconds: 8 - service: "{{ command_printf }}" data: cmd: coversettings.cover_status.pic={{ cover_pic_open }} @@ -1789,10 +1790,29 @@ action: value_template: '{{ states(entity_long) == "closed" }}' then: - delay: - milliseconds: "{{ delay_jump_page }}" + milliseconds: 10 - service: "{{ command_printf }}" data: cmd: coversettings.cover_status.pic={{ cover_pic_closed }} + - if: + - condition: template + value_template: "{{ state_attr(entity_long, 'battery') != none }}" + then: + - delay: + milliseconds: 12 + - service: "{{ command_text_printf }}" + data: + component: coversettings.battery_value + message: '{{ (state_attr(entity_long, "battery") | int ) |round(0) }} %' + - service: "{{ command_printf }}" + data: + cmd: coversettings.battery_icon.pic={{ battery_icon }} + + + + + + ##### Page Coversettings - Changed from HA ##### - choose: