Blackymas / NSPanel_HA_Blueprint

This allows you to configure your complete NSPanel via Blueprint with UI and without changing anything in the code
1.26k stars 235 forks source link

`Bug` NSPanel invalid blueprint version - no version on panel - V 4.3.0 #1907

Closed Atlas192 closed 3 months ago

Atlas192 commented 3 months ago

TFT Version

4.3.0

ESPHome Version

4.3.0

Blueprint Version

4.3.0

Panel Model

EU

What is the bug?

Bildschirmfoto vom 2024-03-13 21-45-04

i followed this guide, but still no blueprint on the panel: https://github.com/Blackymas/NSPanel_HA_Blueprint/blob/main/docs/error_initializing.md#blueprint-is-not-detected

because i dont have the blueprint on the Panel i probably also see this error:

Bildschirmfoto vom 2024-03-13 22-33-18

Steps to Reproduce

Got a new NSPanel and flashed it accroding to this guide. https://github.com/Blackymas/NSPanel_HA_Blueprint/blob/main/docs/install.md

I run HomeAssistant in a docker container.

Your Panel's YAML

substitutions:
  # Settings - Editable values
  name: panel23042600007194
  friendly_name: panel23042600007194
  wifi_ssid: !secret wifi_ssid
  wifi_password: !secret wifi_password
  nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/blob/v4.3.0/nspanel_eu.tft"
  # Add-on configuration (if needed)
  # heater_relay: "1"  # Possible values: "1" or "2"

# Customization area
##### My customization - Start #####
api:
  encryption:
    key: "IYggTlS/9IRnD9xtAFeHldeVRQ8pIvgofvKHPIBxves="
##### My customization - End #####

# Core and optional configurations
packages:
  remote_package:
    url: https://github.com/Blackymas/NSPanel_HA_Blueprint
    ref: v4.3.0
    files:
      - nspanel_esphome.yaml # Basic package
      # Optional advanced and add-on configurations
      # - esphome/nspanel_esphome_advanced.yaml
      # - nspanel_esphome_addon_climate_cool.yaml
      # - nspanel_esphome_addon_climate_heat.yaml
      # - nspanel_esphome_addon_climate_dual.yaml
    refresh: 300s

esp32:
  framework:
    type: esp-idf

ESPHome Logs

Creating esp32 image... Successfully created esp32 image. esp32_create_combined_bin([".pioenvs/panel23042600007194/firmware.bin"], [".pioenvs/panel23042600007194/firmware.elf"]) Wrote 0x134850 bytes to file /config/.esphome/build/panel23042600007194/.pioenvs/panel23042600007194/firmware-factory.bin, ready to flash to offset 0x0 ======================== [SUCCESS] Took 316.14 seconds ======================== INFO Successfully compiled program. INFO Connecting to 192.168.178.130 INFO Uploading /config/.esphome/build/panel23042600007194/.pioenvs/panel23042600007194/firmware.bin (1198160 bytes) Uploading: [============================================================] 100% Done...

INFO Upload took 4.09 seconds, waiting for result... INFO OTA successful INFO Successfully uploaded program. INFO Starting log output from 192.168.178.130 using esphome API INFO Successfully connected to panel23042600007194 @ 192.168.178.130 in 7.159s INFO Successful handshake with panel23042600007194 @ 192.168.178.130 in 0.108s [21:38:36][I][app:102]: ESPHome version 2024.2.2 compiled on Mar 13 2024, 21:34:49

[21:38:36][C][wifi:409]: Local MAC: D4:8A:FC:98:BC:40 [21:38:36][C][wifi:414]: SSID: 'Vodafone-E84C'[redacted] [21:38:36][C][wifi:415]: IP Address: 192.168.178.130 [21:38:36][C][wifi:417]: BSSID: DC:15:C8:F2:E7:6E[redacted]

[21:38:36][C][wifi:420]: Signal strength: -57 dB ▂▄▆█ [21:38:36][C][wifi:424]: Channel: 13 [21:38:36][C][wifi:425]: Subnet: 255.255.255.0 [21:38:36][C][wifi:426]: Gateway: 192.168.178.1 [21:38:36][C][wifi:427]: DNS1: 192.168.178.1 [21:38:36][C][wifi:428]: DNS2: 0.0.0.0

[21:38:36][C][logger:448]: Level: DEBUG [21:38:36][C][logger:449]: Log Baud Rate: 0 [21:38:36][C][logger:451]: Hardware UART: UART0 [21:38:36][C][uart.idf:139]: UART Bus 0: [21:38:36][C][uart.idf:140]: TX Pin: GPIO16 [21:38:36][C][uart.idf:141]: RX Pin: GPIO17 [21:38:36][C][uart.idf:143]: RX Buffer Size: 256 [21:38:36][C][uart.idf:145]: Baud Rate: 115200 baud [21:38:36][C][uart.idf:146]: Data Bits: 8 [21:38:36][C][uart.idf:147]: Parity: NONE [21:38:36][C][uart.idf:148]: Stop bits: 1 [21:38:36][C][ledc.output:164]: LEDC Output: [21:38:36][C][ledc.output:165]: Pin GPIO21 [21:38:36][C][ledc.output:166]: LEDC Channel: 0 [21:38:36][C][ledc.output:167]: PWM Frequency: 1000.0 Hz [21:38:36][C][ledc.output:168]: Bit depth: 16 [21:38:36][C][template.binary_sensor:028]: Template Binary Sensor 'Nextion display' [21:38:36][C][template.binary_sensor:028]: Device Class: 'connectivity' [21:38:36][C][template.number:050]: Template Number 'Display Brightness' [21:38:36][C][template.number:050]: Unit of Measurement: '%' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Display Brightness Dimdown' [21:38:36][C][template.number:050]: Unit of Measurement: '%' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Display Brightness Sleep' [21:38:36][C][template.number:050]: Unit of Measurement: '%' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Temperature Correction' [21:38:36][C][template.number:050]: Unit of Measurement: '°C' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Timeout Page'

[21:38:36][C][template.number:050]: Unit of Measurement: 's' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Timeout Dimming'

[21:38:36][C][template.number:050]: Unit of Measurement: 's' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.number:050]: Template Number 'Timeout Sleep'

[21:38:36][C][template.number:050]: Unit of Measurement: 's' [21:38:36][C][template.number:051]: Optimistic: YES [21:38:36][C][template.number:052]: Update Interval: 60.0s [21:38:36][C][template.select:065]: Template Select 'Baud rate'

[21:38:36][C][template.select:066]: Update Interval: 60.0s [21:38:36][C][template.select:069]: Optimistic: YES [21:38:36][C][template.select:070]: Initial Option: 115200 [21:38:36][C][template.select:071]: Restore Value: YES

[21:38:36][W][component:214]: Component script took a long time for an operation (0.05 s). [21:38:36][W][component:215]: Components should block for at most 20-30ms. [21:38:36][D][sensor:094]: 'Display Current brightness': Sending state 100.00000 % with 0 decimals of accuracy [21:38:36][C][template.select:065]: Template Select 'Wake-up page'

[21:38:36][C][template.select:066]: Update Interval: 60.0s [21:38:36][C][template.select:069]: Optimistic: YES [21:38:36][C][template.select:070]: Initial Option: home [21:38:36][C][template.select:071]: Restore Value: YES [21:38:36][C][template.select:065]: Template Select 'Update TFT display - Model'

[21:38:36][C][template.select:066]: Update Interval: 60.0s [21:38:36][C][template.select:069]: Optimistic: YES [21:38:36][C][template.select:070]: Initial Option: NSPanel EU [21:38:36][C][template.select:071]: Restore Value: YES [21:38:36][C][template.select:065]: Template Select 'Update TFT display - Baud rate'

[21:38:36][C][template.select:066]: Update Interval: 60.0s [21:38:36][C][template.select:069]: Optimistic: YES [21:38:36][C][template.select:070]: Initial Option: 921600 [21:38:36][C][template.select:071]: Restore Value: YES [21:38:36][C][template.sensor:022]: Template Sensor 'Blueprint' [21:38:36][C][template.sensor:022]: State Class: '' [21:38:36][C][template.sensor:022]: Unit of Measurement: '%' [21:38:36][C][template.sensor:022]: Accuracy Decimals: 1

[21:38:36][C][template.sensor:023]: Update Interval: 60.0s [21:38:36][C][switch.gpio:068]: GPIO Switch 'Nextion display - Power' [21:38:36][C][switch.gpio:091]: Restore Mode: always ON [21:38:36][C][switch.gpio:031]: Pin: GPIO4 [21:38:36][C][template.text_sensor:020]: Template Sensor 'Device Name'

[21:38:36][C][template.text_sensor:020]: Template Sensor 'Detailed Entity'

[21:38:36][C][template.text_sensor:020]: Template Sensor 'Current Page'

[21:38:36][C][template.text_sensor:020]: Template Sensor 'Notification Label' [21:38:36][C][template.text_sensor:020]: Template Sensor 'Notification Text' [21:38:37][C][switch.gpio:068]: GPIO Switch 'Relay 1' [21:38:37][C][switch.gpio:091]: Restore Mode: restore defaults to OFF [21:38:37][C][switch.gpio:031]: Pin: GPIO22 [21:38:37][C][switch.gpio:068]: GPIO Switch 'Relay 2' [21:38:37][C][switch.gpio:091]: Restore Mode: restore defaults to OFF [21:38:37][C][switch.gpio:031]: Pin: GPIO19 [21:38:37][C][gpio.binary_sensor:015]: GPIO Binary Sensor 'Left Button' [21:38:37][C][gpio.binary_sensor:016]: Pin: GPIO14 [21:38:37][C][gpio.binary_sensor:015]: GPIO Binary Sensor 'Right Button' [21:38:37][C][gpio.binary_sensor:016]: Pin: GPIO27 [21:38:37][C][template.switch:068]: Template Switch 'Notification unread' [21:38:37][C][template.switch:091]: Restore Mode: always OFF [21:38:37][C][template.switch:057]: Optimistic: YES [21:38:37][C][template.switch:068]: Template Switch 'Notification sound' [21:38:37][C][template.switch:091]: Restore Mode: restore defaults to OFF [21:38:37][C][template.switch:057]: Optimistic: YES

[21:38:37][C][nextion:129]: Device Model: NX4832F035_011C [21:38:37][C][nextion:130]: Firmware Version: 72 [21:38:37][C][nextion:131]: Serial Number: D9B334015A548056 [21:38:37][C][nextion:132]: Flash Size: 16777216 [21:38:37][C][nextion:133]: Wake On Touch: YES [21:38:37][C][nextion:134]: Exit reparse: YES [21:38:37][C][factory_reset.button:011]: Factory Reset Button 'Factory reset'

[21:38:37][C][restart.button:017]: Restart Button 'Restart' [21:38:37][C][adc:097]: ADC Sensor 'ntc_source' [21:38:37][C][adc:097]: Device Class: 'voltage' [21:38:37][C][adc:097]: State Class: 'measurement' [21:38:37][C][adc:097]: Unit of Measurement: 'V' [21:38:37][C][adc:097]: Accuracy Decimals: 2 [21:38:37][C][adc:107]: Pin: GPIO38 [21:38:37][C][adc:122]: Attenuation: 11db [21:38:37][C][adc:142]: Update Interval: 60.0s [21:38:38][C][resistance:010]: Resistance Sensor 'resistance_sensor' [21:38:38][C][resistance:010]: State Class: 'measurement' [21:38:38][C][resistance:010]: Unit of Measurement: 'Ω' [21:38:38][C][resistance:010]: Accuracy Decimals: 1

[21:38:38][C][resistance:011]: Configuration: DOWNSTREAM [21:38:38][C][resistance:012]: Resistor: 11200.00Ω [21:38:38][C][resistance:013]: Reference Voltage: 3.3V [21:38:38][C][ntc:014]: NTC Sensor 'Temperature' [21:38:38][C][ntc:014]: Device Class: 'temperature' [21:38:38][C][ntc:014]: State Class: 'measurement' [21:38:38][C][ntc:014]: Unit of Measurement: '°C' [21:38:38][C][ntc:014]: Accuracy Decimals: 1 [21:38:38][C][homeassistant.time:010]: Home Assistant Time:

[21:38:39][C][mdns:116]: Hostname: panel23042600007194 [21:38:39][C][ota:096]: Over-The-Air Updates: [21:38:39][C][ota:097]: Address: panel23042600007194.local:3232 [21:38:39][C][ota:100]: Using Password. [21:38:39][C][ota:103]: OTA version: 2. [21:38:39][C][api:139]: API Server: [21:38:39][C][api:140]: Address: panel23042600007194.local:6053 [21:38:39][C][api:142]: Using noise encryption: YES [21:38:39][C][wifi_signal.sensor:009]: WiFi Signal 'RSSI' [21:38:39][C][wifi_signal.sensor:009]: Device Class: 'signal_strength' [21:38:39][C][wifi_signal.sensor:009]: State Class: 'measurement' [21:38:39][C][wifi_signal.sensor:009]: Unit of Measurement: 'dBm' [21:38:39][C][wifi_signal.sensor:009]: Accuracy Decimals: 0

[21:38:41][D][sensor:094]: 'Display Current brightness': Sending state 100.00000 % with 0 decimals of accuracy [21:38:46][D][main:2735]: Nextion setup sequence finished! [21:38:46][D][nextion:464]: Got new page: 6 [21:38:46][D][text_sensor:064]: 'Current Page': Sending state 'climate' [21:38:46][D][script.page_changed:2148]: New page: climate

[21:38:46][D][nextion:464]: Got new page: 0 [21:38:46][D][text_sensor:064]: 'Current Page': Sending state 'home'

[21:38:46][D][text_sensor:064]: 'Detailed Entity': Sending state '' [21:38:46][D][script.page_changed:2148]: New page: home

[21:38:47][D][sensor:094]: 'Page Id': Sending state 0.00000 with 0 decimals of accuracy [21:38:47][D][sensor:094]: 'Page Id': Sending state 0.00000 with 0 decimals of accuracy [21:39:16][D][sensor:094]: 'ntc_source': Sending state 1.71700 V with 2 decimals of accuracy [21:39:16][D][resistance:039]: 'resistance_sensor' - Resistance 12148.1Ω [21:39:16][D][sensor:094]: 'resistance_sensor': Sending state 12148.07422 Ω with 1 decimals of accuracy [21:39:16][D][ntc:026]: 'Temperature' - Temperature: 20.7°C [21:39:16][D][sensor:094]: 'Temperature': Sending state 20.68430 °C with 1 decimals of accuracy [21:39:16][D][sensor:094]: 'Display Current brightness': Sending state 25.00000 % with 0 decimals of accuracy [21:39:21][D][sensor:094]: 'Display Current brightness': Sending state 25.00000 % with 0 decimals of accuracy

[21:39:29][D][script.check_versions:1846]: ESPHome: 4.3.0 [21:39:29][D][script.check_versions:1847]: TFT: 4.3.0

[21:39:29][E][script.check_versions:1852]: Blueprint version mismatch! [21:39:33][D][sensor:094]: 'RSSI': Sending state -60.00000 dBm with 0 decimals of accuracy [21:39:46][D][script.timer_sleep:2881]: Going to sleep from page home [21:39:46][D][nextion:464]: Got new page: 9 [21:39:46][D][text_sensor:064]: 'Current Page': Sending state 'screensaver' [21:39:46][D][text_sensor:064]: 'Detailed Entity': Sending state '' [21:39:46][D][script.page_changed:2148]: New page: screensaver [21:39:46][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:39:46][D][sensor:094]: 'Page Id': Sending state 9.00000 with 0 decimals of accuracy [21:39:46][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:39:51][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:40:16][D][sensor:094]: 'ntc_source': Sending state 1.71100 V with 2 decimals of accuracy [21:40:16][D][resistance:039]: 'resistance_sensor' - Resistance 12059.9Ω [21:40:16][D][sensor:094]: 'resistance_sensor': Sending state 12059.91113 Ω with 1 decimals of accuracy [21:40:16][D][ntc:026]: 'Temperature' - Temperature: 20.8°C [21:40:16][D][sensor:094]: 'Temperature': Sending state 20.84360 °C with 1 decimals of accuracy [21:40:17][D][nextion:446]: Got touch event: [21:40:17][D][nextion:447]: page_id: 9 [21:40:17][D][nextion:448]: component_id: 0 [21:40:17][D][nextion:449]: event type: PRESS [21:40:17][D][nextion:446]: Got touch event: [21:40:17][D][nextion:447]: page_id: 9 [21:40:17][D][nextion:448]: component_id: 0 [21:40:17][D][nextion:449]: event type: RELEASE

[21:40:18][D][nextion:464]: Got new page: 6 [21:40:18][D][text_sensor:064]: 'Current Page': Sending state 'climate' [21:40:18][D][script.page_changed:2148]: New page: climate

[21:40:18][D][script.timer_dim:2848]: Waking up on page: climate [21:40:18][D][nextion:464]: Got new page: 0 [21:40:18][D][text_sensor:064]: 'Current Page': Sending state 'home'

[21:40:18][D][text_sensor:064]: 'Detailed Entity': Sending state '' [21:40:18][D][script.page_changed:2148]: New page: home

[21:40:18][D][script.timer_dim:2848]: Waking up on page: home

[21:40:18][W][component:214]: Component display took a long time for an operation (0.05 s). [21:40:18][W][component:215]: Components should block for at most 20-30ms. [21:40:18][D][sensor:094]: 'Page Id': Sending state 0.00000 with 0 decimals of accuracy [21:40:18][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:40:18][D][sensor:094]: 'Page Id': Sending state 0.00000 with 0 decimals of accuracy [21:40:18][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:40:23][D][sensor:094]: 'Display Current brightness': Sending state 100.00000 % with 0 decimals of accuracy [21:40:33][D][sensor:094]: 'RSSI': Sending state -59.00000 dBm with 0 decimals of accuracy [21:40:48][D][sensor:094]: 'Display Current brightness': Sending state 25.00000 % with 0 decimals of accuracy [21:40:53][D][sensor:094]: 'Display Current brightness': Sending state 25.00000 % with 0 decimals of accuracy [21:41:16][D][sensor:094]: 'ntc_source': Sending state 1.70400 V with 2 decimals of accuracy [21:41:16][D][resistance:039]: 'resistance_sensor' - Resistance 11957.9Ω [21:41:16][D][sensor:094]: 'resistance_sensor': Sending state 11957.89453 Ω with 1 decimals of accuracy [21:41:16][D][ntc:026]: 'Temperature' - Temperature: 21.0°C [21:41:16][D][sensor:094]: 'Temperature': Sending state 21.02960 °C with 1 decimals of accuracy [21:41:18][D][script.timer_sleep:2881]: Going to sleep from page home [21:41:18][D][nextion:464]: Got new page: 9 [21:41:18][D][text_sensor:064]: 'Current Page': Sending state 'screensaver' [21:41:18][D][text_sensor:064]: 'Detailed Entity': Sending state '' [21:41:18][D][script.page_changed:2148]: New page: screensaver [21:41:18][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:41:18][D][sensor:094]: 'Page Id': Sending state 9.00000 with 0 decimals of accuracy [21:41:18][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:41:23][D][sensor:094]: 'Display Current brightness': Sending state 0.00000 % with 0 decimals of accuracy [21:41:28][I][ota:117]: Boot seems successful, resetting boot loop counter. [21:41:28][D][esp32.preferences:114]: Saving 1 preferences to flash... [21:41:28][D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed [21:41:33][D][sensor:094]: 'RSSI': Sending state -59.00000 dBm with 0 decimals of accuracy [21:41:47][D][api.connection:197]: Home Assistant 2024.3.0 (192.168.178.240) requested disconnected [21:42:06][D][api:102]: Accepted 192.168.178.240 [21:42:06][W][api.connection:092]: : Socket operation failed: BAD_INDICATOR errno=11 [21:42:06][D][api:102]: Accepted 192.168.178.240 [21:42:06][W][api.connection:092]: : Socket operation failed: HANDSHAKESTATE_READ_FAILED errno=11 [21:42:16][D][sensor:094]: 'ntc_source': Sending state 1.72100 V with 2 decimals of accuracy [21:42:16][D][resistance:039]: 'resistance_sensor' - Resistance 12207.2Ω [21:42:16][D][sensor:094]: 'resistance_sensor': Sending state 12207.21973 Ω with 1 decimals of accuracy [21:42:16][D][ntc:026]: 'Temperature' - Temperature: 20.6°C [21:42:16][D][sensor:094]: 'Temperature': Sending state 20.57818 °C with 1 decimals of accuracy [21:42:33][D][sensor:094]: 'RSSI': Sending state -59.00000 dBm with 0 decimals of accuracy

Home Assistant Logs

2024-03-13 22:04:32.868 ERROR (MainThread) [homeassistant.helpers.template] Template variable error: No first item, sequence was empty. when rendering '{%- if nspanel_entities | count > 0 %} {{ (nspanel_entities | selectattr(None, "search", "_nextion_display") | list | first).split(".")[1].split("_nextion_display")[0] }} {%- elif nspanel_deviceid is string %} {{ nspanel_deviceid | regexreplace("[^a-zA-Z0-9]", "") | regexreplace("+", "_") | lower }} {%- endif %}' 2024-03-13 22:04:32.871 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] Error rendering trigger variables: UndefinedError: No first item, sequence was empty. 2024-03-13 22:04:45.503 WARNING (MainThread) [aioesphomeapi.connection] 192.168.178.130: Connection error occurred: 192.168.178.130: Connection requires encryption 2024-03-13 22:04:45.529 WARNING (MainThread) [aioesphomeapi.connection] 192.168.178.130: Connection error occurred: 192.168.178.130: Invalid encryption key: received_name=panel23042600007194 2024-03-13 22:13:10.945 WARNING (MainThread) [aioesphomeapi.connection] panel23042600007194 @ 192.168.178.130: Connection error occurred: [Errno 104] Connection reset by peer 2024-03-13 22:31:04.470 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Automation reloaded: If at step 3: Error executing script. Service not found for call_service at pos 3: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:04.471 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Automation reloaded: Error executing script. Service not found for if at pos 3: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:04.476 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:24.675 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Automation reloaded: If at step 3: Error executing script. Service not found for call_service at pos 3: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:24.676 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Automation reloaded: Error executing script. Service not found for if at pos 3: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:24.681 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_init_page_home not found. 2024-03-13 22:31:52.499 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Hardware button - State: Error executing script. Service not found for call_service at pos 2: Service esphome.nspanel_hw_button_state not found. 2024-03-13 22:31:52.500 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_hw_button_state not found. 2024-03-13 22:31:54.899 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Hardware button - State: Error executing script. Service not found for call_service at pos 2: Service esphome.nspanel_hw_button_state not found. 2024-03-13 22:31:54.901 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_hw_button_state not found. 2024-03-13 22:31:56.261 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: NSPanel event: Choose at step 2: Page changed: Choose at step 1: Home page: Error executing script. Service not found for call_service at pos 1: Service esphome.nspanel_command not found. 2024-03-13 22:31:56.263 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: NSPanel event: Choose at step 2: Page changed: Error executing script. Service not found for choose at pos 1: Service esphome.nspanel_command not found. 2024-03-13 22:31:56.267 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: NSPanel event: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_command not found. 2024-03-13 22:31:56.268 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Error executing script. Service not found for choose at pos 2: Service esphome.nspanel_command not found.

edwardtfn commented 3 months ago

Please take a look at this: Panel startup issues - Blueprint is not detected

Atlas192 commented 3 months ago

i did go through this multiple times. Sadly it still dosn't work for me.

Blueprint version, creation and panel selection: image

Reconnect the panels device: i deleted the device, restarted the ha docker container and then reconnected.

I also had a look on this issue: https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1677 but this does not apply to me, since i have the entity and the bug is also allready fixed.

FYI: i had the panel flashed with another name first (included a "-") and had the same issue. I then recreated the ESPHome entry reflashed the esp, reloaded the TFT panel and recreated the HA blueprint.

Any other ideas?

edwardtfn commented 3 months ago

Please go to Developer Tools, tab Services, and type upload_tft. Please take note of the full name of the service and share it here:

image

Then go to Settings > Devices & Services > ESPHome, open the device's page and look for the sensor "Device Name" under Diagnostics and please let me know how is that name.

Also, while you are on the Diagnostic area, please open details of the sensor "Nextion display" and let me know it's entity_id.

It's always a challenge for the blueprint to "calculate" the service names based on the information from those sensors, and probably this is where the issue is.

edwardtfn commented 3 months ago

Your Home Assistant log shows some different things:

Error "calculating the name":

2024-03-13 22:04:32.868 ERROR (MainThread) [homeassistant.helpers.template] Template variable error: No first item, sequence was empty. when rendering '{%- if nspanel_entities | count > 0 %}
{{ (nspanel_entities | selectattr(None, "search", "nextion_display") | list | first).split(".")[1].split("nextion_display")[0] }}
{%- elif nspanel_deviceid is string %}
{{ nspanel_deviceid | regex_replace("[^a-zA-Z0-9]", "") | regex_replace("+", "_") | lower }}
{%- endif %}'
2024-03-13 22:04:32.871 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] Error rendering trigger variables: UndefinedError: No first item, sequence was empty.

I will wait for info asked in the previous message to be able to investigate this better.

Some encryption error on the API

2024-03-13 22:04:45.503 WARNING (MainThread) [aioesphomeapi.connection] 192.168.178.130: Connection error occurred: 192.168.178.130: Connection requires encryption
2024-03-13 22:04:45.529 WARNING (MainThread) [aioesphomeapi.connection] 192.168.178.130: Connection error occurred: 192.168.178.130: Invalid encryption key: received_name=panel23042600007194
2024-03-13 22:13:10.945 WARNING (MainThread) [aioesphomeapi.connection] panel23042600007194 @ 192.168.178.130: Connection error occurred: [Errno 104] Connection reset by peer

This is somehow related to that API key you have on your customizations. Maybe you can try to remove the API encryption just to troubleshoot until other things are solved, then you add encryption again.

Invalid service name:

2024-03-13 22:31:04.470 ERROR (MainThread) [homeassistant.components.automation.xpanelconfig] xPanelConfig: Main choices: Automation reloaded: If at step 3: Error executing script. Service not found for call_service at pos 3: Service esphome.nspanel_init_page_home not found.

This is probably related to the first one. For some reason your system is calculating the panel's name as "nspanel", while it's defined in the panel's yaml to be "panel23042600007194", so let's focus on this naming issue.

Mauricewillemstein commented 3 months ago

Hi, I had the same problem with my second display i bought 2 days ago. After trying all things i made a new install, clean buildfiles and no capital letters in the name. For me that fixed the blueprint isseu

edwardtfn commented 3 months ago

Capital letters shouldn't be an issue.

Atlas192 commented 3 months ago

Hi, thanks for the quick replies so far. Here is the information you requested.

Full name of the Service: image Device Name Diagnostic: image or the entityID? image Nexton Display image sorry here is the EntityID image

In the mean time I will update the ESPHome.yaml without the encription. I will let you know if there is any change. Still I think your onto something with the naming issue.

Sorry i missread again... here is the state: image

image

image

edwardtfn commented 3 months ago

Thanks for the additional info.

Just this one isn't the sensor I've asked for. This looks like a device_tracker added by your router.

Device Name Diagnostic: image

What I'm looking for is the state of sensor.panel23042600007194_device_name.

Atlas192 commented 3 months ago

yes i noticed. I updated my comment. image The Device Name actually changes for some reason?

still the same issue after the esp update: image

Atlas192 commented 3 months ago

ok i set the device state: image

I no longer recive the service.name issue.

The Page on the HMI does update. Still haf the RED HomeAssistant icon though. After an update of the Automation, the RED HomeAssistant icon is gone.

Thanks very much for your help.

edwardtfn commented 3 months ago

image The Device Name actually changes for some reason?

This is what is causing the issue. I will do some investigation here for all the calls changing this value and come back soon.

Atlas192 commented 3 months ago

When the device does a power cycle the issue is pressent again.

edwardtfn commented 3 months ago

Could you please add this customization to your panel's yaml and let me know the results so I can implement it for the next release?

edwardtfn commented 3 months ago

~Sorry, this is the right one:~

edwardtfn commented 3 months ago

Just add this line to your substitutions:

  device_name: panel23042600007194
edwardtfn commented 3 months ago

I've applied a fix to dev and will be included in the next release. Meanwhile, adding this substitution may fix the issue in your case.

Atlas192 commented 3 months ago

Yes, adding the "device_name" entry solved the issue. The Blueprint version is also pressent at startup.

Thanks again for your support.

adamengineering commented 3 months ago

I have the same problem as @Atlas192 had, just with the latest release 4.3.1

nspanelpro

I tried the steps described above with no luck. Anything else I'm missing?

edwardtfn commented 3 months ago

Could you please report it in a new issue and share your panel's yaml? In your case the panel's name is missing in the notification, so it is something different.