@@ -279,6 +279,12 @@ The goal was to create a version that allows everyone to use the NSpanel fully l
|
||||
default: []
|
||||
selector:
|
||||
text: {}
|
||||
relay_1_local_fallback:
|
||||
name: Activate Relay 1 local Fallback (Optional)
|
||||
default: false
|
||||
description: '* *activate this to use left button to toggle relay 1 if display is offline* '
|
||||
selector:
|
||||
boolean:
|
||||
right_button_entity:
|
||||
name: Right Button (Optional)
|
||||
description: '* *Right Hardware Button - Select the entity that should be switched*'
|
||||
@@ -302,6 +308,12 @@ The goal was to create a version that allows everyone to use the NSpanel fully l
|
||||
default: []
|
||||
selector:
|
||||
text: {}
|
||||
relay_2_local_fallback:
|
||||
name: Activate Relay 2 local Fallback (Optional)
|
||||
default: false
|
||||
description: '* *activate this to use right button to toggle relay 2 if display is offline* '
|
||||
selector:
|
||||
boolean:
|
||||
|
||||
##### BUTTON Page Labels #####
|
||||
button_page01_label:
|
||||
@@ -1410,6 +1422,8 @@ variables:
|
||||
qrcode_label: !input "qrcode_label"
|
||||
qrcode_value: !input "qrcode_value"
|
||||
qrcode_state: !input "qrcode_state"
|
||||
relay_1_local_fallback: !input "relay_1_local_fallback"
|
||||
relay_2_local_fallback: !input "relay_2_local_fallback"
|
||||
|
||||
#### HARDWARE BUTTONS #####
|
||||
left_button_entity: !input "left_button_entity"
|
||||
@@ -2830,6 +2844,30 @@ action:
|
||||
data:
|
||||
song_str: "two short:d=4,o=5,b=100:16e6,16e6"
|
||||
|
||||
###### Set local fallback ######
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ relay_1_local_fallback }}'
|
||||
then:
|
||||
- service: switch.turn_on
|
||||
data:
|
||||
entity_id: 'switch.{{ nspanel_name }}_relay_1_local_fallback'
|
||||
else:
|
||||
- service: switch.turn_off
|
||||
data:
|
||||
entity_id: 'switch.{{ nspanel_name }}_relay_1_local_fallback'
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ relay_2_local_fallback }}'
|
||||
then:
|
||||
- service: switch.turn_on
|
||||
data:
|
||||
entity_id: 'switch.{{ nspanel_name }}_relay_2_local_fallback'
|
||||
else:
|
||||
- service: switch.turn_off
|
||||
data:
|
||||
entity_id: 'switch.{{ nspanel_name }}_relay_2_local_fallback'
|
||||
|
||||
##### NSPanel boot init finished and jump to Home Page#####
|
||||
- delay:
|
||||
milliseconds: "{{ delay_value }}"
|
||||
@@ -2884,10 +2922,26 @@ action:
|
||||
id: open_qrcode_page
|
||||
- condition: template
|
||||
value_template: '{{ qrcode_state == true }}'
|
||||
- condition: template
|
||||
value_template: '{{ qrcode_value |length > 0 }}'
|
||||
sequence:
|
||||
- service: "{{ command_printf }}"
|
||||
data:
|
||||
cmd: "page {{ page_qrcode }}"
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ qrcode_label |length > 0 }}'
|
||||
then:
|
||||
- service: "{{ command_text_printf }}"
|
||||
data:
|
||||
component: "qrcode_label"
|
||||
message: "{{ qrcode_label }}"
|
||||
- delay:
|
||||
milliseconds: "{{ delay_value }}"
|
||||
- service: "{{ command_text_printf }}"
|
||||
data:
|
||||
component: "qrcode_value"
|
||||
message: "{{ qrcode_value }}"
|
||||
|
||||
##### Button Notification clear #####
|
||||
- conditions:
|
||||
@@ -5940,22 +5994,6 @@ action:
|
||||
## PAGE QR Code ##
|
||||
- conditions: '{{ trigger.event.data.new_state.state == page_qrcode }}'
|
||||
sequence:
|
||||
##### QR Code Page Label #####
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ qrcode_label |length > 0 }}'
|
||||
then:
|
||||
- service: "{{ command_text_printf }}"
|
||||
data:
|
||||
component: "qrcode_label"
|
||||
message: "{{ qrcode_label }}"
|
||||
- delay:
|
||||
milliseconds: "{{ delay_value }}"
|
||||
|
||||
- service: "{{ command_text_printf }}"
|
||||
data:
|
||||
component: "qrcode_value"
|
||||
message: "{{ qrcode_value }}"
|
||||
|
||||
##### Open Climate Settings #####
|
||||
- conditions:
|
||||
|
||||
@@ -246,6 +246,7 @@ api:
|
||||
- wait_until:
|
||||
switch.is_on: nextion_init
|
||||
- lambda: |-
|
||||
id(disp1).send_command_printf("page qrcode");
|
||||
id(disp1).set_component_text_printf("qrcode.qrcode_value", "%s", qrdata.c_str());
|
||||
|
||||
#### Service to send thermostat cycle state ####
|
||||
|
||||
Reference in New Issue
Block a user