Better AC dashboard

This commit is contained in:
2020-06-27 18:34:36 +03:00
parent 15e71f1419
commit 28e278216d
4 changed files with 40 additions and 10 deletions
@@ -101,6 +101,7 @@
name: Radiator
- entity: climate.toshiba_ac
name: AC
- entity: input_number.toshiba_cool_temp
- type: vertical-stack
cards:
@@ -174,6 +174,22 @@
- type: horizontal-stack
cards:
- type: custom:button-card
template: default
entity: climate.toshiba_ac
name: AC
state:
- value: 'off'
operator: '!='
styles:
card:
- background-color: var(--primary-color)
- color: black
icon:
- color: black
tap_action:
action: call-service
service: script.toshiba_ac_toggle_cool
- type: custom:button-card
template: default
entity: switch.camera
@@ -26,7 +26,27 @@ climate:
supported_swing_list:
- "off"
input_number:
toshiba_cool_temp:
name: AC cool temp
unit_of_measurement: "ºC"
min: 18
max: 21
step: 1
icon: mdi:air-conditioner
script:
toshiba_ac_toggle_cool:
sequence:
- service_template: >-
{% if is_state('climate.toshiba_ac', 'off') %}
script.toshiba_ac_on_cool
{% else %}
climate.turn_off
{% endif %}
data_template:
entity_id: "{% if not is_state('climate.toshiba_ac', 'off') %}climate.toshiba_ac{%endif%}"
toshiba_ac_on_cool:
sequence:
- service: climate.turn_on
@@ -43,8 +63,8 @@ script:
- delay: "00:00:01"
- service: climate.set_temperature
entity_id: climate.toshiba_ac
data:
temperature: 19
data_template:
temperature: "{{ states('input_number.toshiba_cool_temp') | default(19) }}"
- service: logbook.log
data:
name: "💨 Climate Module · "
@@ -104,14 +104,7 @@ automation:
scene_id: 4
scene_data: 0
action:
- service_template: >-
{% if is_state('climate.toshiba_ac', 'off') %}
script.toshiba_ac_on_cool
{% else %}
climate.turn_off
{% endif %}
data_template:
entity_id: "{% if not is_state('climate.toshiba_ac', 'off') %}climate.toshiba_ac{%endif%}"
- service: script.toshiba_ac_toggle_cool
- alias: Wallmote · Living room · 4 · Hold · Toggle Titanium
trigger: