Merge pull request #2024 from MichaelHeimann/Blackymas-urls

Update prebuilt
This commit is contained in:
Edward Firmo
2024-04-07 18:53:15 +02:00
committed by GitHub
10 changed files with 153 additions and 55 deletions

View File

@@ -8,7 +8,6 @@
##### PLEASE only make changes if it is necessary and also the required knowledge is available. #####
##### For normal use with the Blueprint, no changes are necessary. #####
#####################################################################################################
---
substitutions:
device_name: nspanel
wifi_ssid: nspanel
@@ -38,8 +37,8 @@ api:
url: string
then:
- ota_http.flash:
url: !lambda return url.c_str();
verify_ssl: false
md5_url: !lambda return id(fw_url).state + ".md5";
url: !lambda return id(fw_url).state;
- lambda: |-
static const char *const TAG = "prebuilt.button.bt_firmware_update";
ESP_LOGE(TAG, "Firmware update failed!");
@@ -56,8 +55,8 @@ button:
on_press:
then:
- ota_http.flash:
url: !lambda return id(firmware_url).state;
verify_ssl: false
md5_url: !lambda return id(fw_url).state + ".md5";
url: !lambda return id(fw_url).state;
- lambda: |-
static const char *const TAG = "prebuilt.button.bt_firmware_update";
ESP_LOGE(TAG, "Firmware update failed!");
@@ -65,7 +64,7 @@ button:
captive_portal:
dashboard_import:
package_import_url: github://Blackymas/NSPanel_HA_Blueprint/prebuilt/nspanel_esphome_prebuilt.yaml@dev # Must be updated
package_import_url: github://Blackymas/NSPanel_HA_Blueprint/prebuilt/nspanel_esphome_prebuilt.yaml@main # Must be updated
import_full_config: false
esp32_improv:
@@ -79,9 +78,9 @@ esphome:
on_boot:
- priority: 602.0
then:
- text_sensor.template.publish:
id: firmware_url
state: https://raw.githubusercontent.com/Blackymas/NSPanel_HA_Blueprint/dev/prebuilt/nspanel_esphome_prebuilt.bin # Must be updated
- text.set:
id: fw_url
value: "https://raw.githubusercontent.com/Blackymas/NSPanel_HA_Blueprint/main/prebuilt/nspanel_esphome_prebuilt.bin"
improv_serial:
@@ -107,16 +106,16 @@ select:
- "NSPanel US (CJK languages)"
- "NSPanel US Landscape (CJK languages)"
text_sensor:
- id: firmware_url
name: Firmware update - URL
platform: template
update_interval: 60s
internal: true
text:
- platform: template
name: Firmware URL
id: fw_url
icon: mdi:cloud-download
mode: text
optimistic: true
# internal: true
wifi:
networks: !remove
ap: {}
power_save_mode: LIGHT # To make it compatible with BLE
...