diff --git a/nspanel_blueprint.yaml b/nspanel_blueprint.yaml index 335683e..19009be 100644 --- a/nspanel_blueprint.yaml +++ b/nspanel_blueprint.yaml @@ -575,15 +575,6 @@ blueprint: selector: entity: domain: climate - climate_optimistic: - name: Climate control optimistic mode - TRUE/FALSE (Optional) - default: true - description: > - *CLIMATE page* - - *Depends on your climate device and HA-Integration. If optimisitc mode is **OFF** then changes are made will wait for response from device to update temperature in the display. This can cause delays or jumping values. If **ON** the script update the display immediately but apply changes after closing climate-page* - selector: - boolean: hotwatercharge: name: Hot Water Charge Button - ENTITY (Optional) description: > @@ -3507,7 +3498,6 @@ trigger_variables: nextion_inited: 'binary_sensor.{{ nspanel_name }}_nextion_display' nspanelevent: 'sensor.{{ nspanel_name }}_nspanel_event' hotwatercharge: !input 'hotwatercharge' - display_target_temperature: 'sensor.{{ nspanel_name }}_display_target_temperature' relay01_entity: 'switch.{{ nspanel_name }}_relay_1' relay02_entity: 'switch.{{ nspanel_name }}_relay_2' nspaneltemp: 'sensor.{{ nspanel_name }}_temperature' @@ -3575,7 +3565,6 @@ variables: printf: 'esphome.{{ nspanel_name }}_send_command_printf' font_color: 'esphome.{{ nspanel_name }}_send_command_font_color' background_color: 'esphome.{{ nspanel_name }}_send_command_background_color' - #thermostat_cycle: 'esphome.{{ nspanel_name }}_send_thermostat_cycle_state' ## Deprecated on v3.3.1 notification_show: 'esphome.{{ nspanel_name }}_notification_show' notification_clear: 'esphome.{{ nspanel_name }}_notification_clear' play_rtttl: 'esphome.{{ nspanel_name }}_play_rtttl' @@ -5385,12 +5374,7 @@ variables: qrcode_enabled: !input 'qrcode_enabled' ###### SYNC SETTINGS ##### - #delay_boot: !input 'delay' # NOT IN USE delay_value: !input 'delay' - #delay_jump_page: !input 'delay' # NOT IN USE - #sync_slider_ha: !input 'sync_slider_ha' # NOT IN USE - #sync_value_ha: !input 'sync_value_ha' # NOT IN USE - climate_optimistic: !input 'climate_optimistic' ##### GENERAL ENTITYS ##### hotwatertemp: !input 'hotwatertemp' @@ -6228,27 +6212,6 @@ action: - alias: Page changed conditions: '{{ nspanel_event.component == "currentpage" }}' sequence: - - alias: old state - variables: - old_state: '{{ trigger.event.data.old_state.state }}' - ##### climate-page left - apply climate temperature if climate_optimistic ##### ## TODO - remove from here - - if: '{{ old_state.page == pages.climate and climate_optimistic }}' - then: - - variables: - display_target_temperature_state: > - {{ - states(display_target_temperature) | default("unavailable") - if display_target_temperature is string - else "unavailable" - }} - - condition: '{{ is_number(display_target_temperature_state) }}' - - *variables-settings_entity - - condition: '{{ settings_entity_domain == "climate" }}' - - service: climate.set_temperature - data: - entity_id: '{{ settings_entity_dict.entity }}' - temperature: '{{ display_target_temperature_state }}' - continue_on_error: true - choose: ## PAGE HOME ## - alias: Home page @@ -8814,10 +8777,6 @@ action: - condition: trigger id: climate_state - '{{ trigger.event.data.new_state.state not in ["unavailable", "unknown", "", None] }}' - # - condition: template - # value_template: '{{ nspanel_event.page == pages.climate }}' - # - condition: template - # value_template: '{{ climate_optimistic == false }}' sequence: - variables: heating_state: > @@ -8863,7 +8822,7 @@ action: data: cmd: heating_bt_pic.pic={{ heating_bt_pic }} continue_on_error: true - - if: '{{ trigger.event.data.new_state.state != "off" and is_number(target_temperature) }}' #### TODO AND->OR (not) not optimistic-mode + - if: '{{ trigger.event.data.new_state.state != "off" and is_number(target_temperature) }}' then: - service: '{{ nextion.commands.set_climate_target_temp }}' data: diff --git a/nspanel_esphome.yaml b/nspanel_esphome.yaml index 08d324f..3698831 100644 --- a/nspanel_esphome.yaml +++ b/nspanel_esphome.yaml @@ -311,32 +311,6 @@ api: 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 - deprecated on v3.3.1 #### - #- service: send_thermostat_cycle_state - # variables: - # value: float - # then: - # - wait_until: - # binary_sensor.is_on: nextion_init - # - lambda: |- - # //ESP_LOGD("nextion", "thermostat sendig value %f", value); - # int v = int(2 * std::min(std::max(value - 13.5, 0.0), 5.0)); - # int left = v + (v ? 19 : 16); // 16 is empty left. - # v = int(2 * std::min(std::max(value - 18.0, 0.0), 4.0)); - # int mid = v + (v ? 29 : 17); // 17 is empty mid. - # v = int(2 * std::min(std::max(value - 21.5, 0.0), 5.5)); - # int right = v + (v ? 37 : 18); // 18 is empty right. - # // sends the 3 images to the display - # //ESP_LOGD("nextion", "thermostat left %i", left); - # //ESP_LOGD("nextion", "thermostat mid %i", mid); - # //ESP_LOGD("nextion", "thermostat right %i", right); - # id(disp1).send_command_printf("climate_left.pic=%i", left); - # id(disp1).send_command_printf("climate_middle.pic=%i", mid); - # id(disp1).send_command_printf("climate_right.pic=%i", right); - # // send target-temp - # id(disp1).set_component_text_printf("target_temp", "%.1f", value); - # id(display_target_temp).publish_state(value); - #### Service to set climate target_temp #### - service: set_climate_target_temp variables: @@ -348,7 +322,6 @@ api: lambda: |- id(disp1).set_component_value("climate.climateslider", target_temp); id(disp1).set_component_text_printf("climate.target_temp", "%.1f", target_temp); - id(display_target_temp).publish_state(target_temp); #### Service to set climate state #### - service: set_climate @@ -403,6 +376,7 @@ api: } else { id(disp1).set_component_text_printf(btnbri.c_str(), " "); } + ##### SERVICE TO WAKE UP THE DISPLAY ##### - service: wake_up_display variables: @@ -645,13 +619,6 @@ sensor: # - lambda: id(disp1).set_component_text_printf("home.current_temp", "%.1f°", id(temp_nspanel).state); # onboard temp (thermostat temp) to home page. # - lambda: id(disp1).set_component_text_printf("climate.current_temp", "%.1f", id(temp_nspanel).state); - ##### current value of page-climate target_temp ##### - - name: ${device_name} Display Target Temperature - platform: template - id: display_target_temp - lambda: return {}; - update_interval: 10s - ###### Display Brightness GET VALUE FROM NSPanel SLIDER ##### - name: ${device_name} brightness Slider platform: nextion