Blackymas / NSPanel_HA_Blueprint

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

US_land.tft Touch miss calibrated`Bug` #2124

Closed Nmebowen closed 4 months ago

Nmebowen commented 4 months ago

TFT Version

4.3.7

ESPHome Version

4.3.7

Blueprint Version

4.3.7

Panel Model

US (Landscape)

What is the bug?

The touch seems to be unsuable i have 2 US panels in landscape both have the same issue and one EU panel thats working fine all with the same firmware just different tft uploads, im only using the core.yaml with no addons the only exception being an alteration to the wifi settings.

Steps to Reproduce

No response

Your Panel's YAML

No response

ESPHome Logs

No response

Home Assistant Logs

No response

edwardtfn commented 4 months ago

Mmmmm I use the US landscaped myself without any issue, so it might be something on your side. Could you please share the logs from ESPHome (specially the dump messages after a reboot and a few seconds after that)? Please hide any sensitive info before sharing.

Nmebowen commented 4 months ago

Sorry in advance for the spam....

[17:35:32][I][app:132]: Rebooting safely... [17:35:32][D][binary_sensor:036]: 'Nextion display': Sending state OFF INFO Processing expected disconnect from ESPHome API for kitchen-nspanel @ O.O WARNING Disconnected from API INFO Successfully connected to kitchen-nspanel @ 0.0 in 1.050s INFO Successful handshake with kitchen-nspanel @ 0.0 in 0.029s [17:35:39][D][sensor:094]: 'ntc_source': Sending state 1.21850 V with 2 decimals of accuracy [17:35:39][D][resistance:039]: 'resistance_sensor' - Resistance 6556.4Ω [17:35:39][D][sensor:094]: 'resistance_sensor': Sending state 6556.42578 Ω with 1 decimals of accuracy [17:35:39][D][ntc:026]: 'Temperature' - Temperature: 34.8°C [17:35:39][D][sensor:094]: 'Temperature': Sending state 34.81277 °C with 1 decimals of accuracy

[17:35:43][D][script.boot_progress:2070]: Progress: 25%

[17:35:43][D][script.boot_progress:2070]: Progress: 30%

[17:35:43][D][script.boot_progress:2070]: Progress: 35%

[17:35:43][D][script.boot_progress:2070]: Progress: 40% [17:35:43][W][component:237]: Component script took a long time for an operation (72 ms). [17:35:43][W][component:238]: Components should block for at most 30 ms. WARNING kitchen-nspanel @ 0.0: Connection error occurred: [Errno 104] Connection reset by peer INFO Processing unexpected disconnect from ESPHome API for kitchen-nspanel @ 0.0 WARNING Disconnected from API INFO Successfully connected to kitchen-nspanel @ 0.0 in 0.005s INFO Successful handshake with kitchen-nspanel @ 0.0 in 0.022s [17:36:19][D][sensor:094]: 'ntc_source': Sending state 1.22083 V with 2 decimals of accuracy [17:36:19][D][resistance:039]: 'resistance_sensor' - Resistance 6576.4Ω [17:36:19][D][sensor:094]: 'resistance_sensor': Sending state 6576.35303 Ω with 1 decimals of accuracy [17:36:19][D][ntc:026]: 'Temperature' - Temperature: 34.7°C [17:36:19][D][sensor:094]: 'Temperature': Sending state 34.73993 °C with 1 decimals of accuracy [17:36:21][D][text_sensor:064]: 'Device Name': Sending state 'kitchen_nspanel' [17:36:27][D][sensor:094]: 'RSSI': Sending state -61.00000 dBm with 0 decimals of accuracy [17:36:29][C][nspanel_ha_blueprint:2196]: Wi-Fi: Fair (-61 dBm) [17:36:29][C][nspanel_ha_blueprint:2207]: API: Connected

[17:36:29][W][nspanel_ha_blueprint:2220]: Init steps: 0 (0.0%) [17:36:29][W][nspanel_ha_blueprint:2221]: State: Pending [17:36:29][C][nspanel_ha_blueprint:2222]: Requesting blueprint settings

[17:36:29][C][nspanel_ha_blueprint:2228]: Version: 4.3.7 [17:36:29][C][nspanel_ha_blueprint:2229]: Compiler: 2024.5.3 [17:36:29][C][nspanel_ha_blueprint:2234]: Framework: ESP-IDF [17:36:29][C][nspanel_ha_blueprint:2239]: Free heap: [17:36:29][C][nspanel_ha_blueprint:2243]: Internal: 213344 bytes (60.9%) [17:36:29][C][nspanel_ha_blueprint:2253]: PSRAM: 2011171 bytes (96.5%)

[17:36:29][C][nspanel_ha_blueprint:2261]: Baud rate: 115200 bps [17:36:29][C][nspanel_ha_blueprint:2262]: Queue size: 0

[17:36:29][C][nspanel_ha_blueprint:2267]: Queue size: 0 [17:36:29][C][nspanel_ha_blueprint:2269]: Is setup: True [17:36:29][C][nspanel_ha_blueprint:2276]: Init: True [17:36:29][C][nspanel_ha_blueprint:2282]: TFT: 4.3.7

[17:36:29][C][nspanel_ha_blueprint:2285]: - Core [17:36:29][D][sensor:094]: 'Display Current brightness': Sending state 35.00000 % with 0 decimals of accuracy [17:36:29][D][sensor:094]: 'ntc_source': Sending state 1.22383 V with 2 decimals of accuracy [17:36:29][D][resistance:039]: 'resistance_sensor' - Resistance 6602.0Ω [17:36:29][D][sensor:094]: 'resistance_sensor': Sending state 6602.03955 Ω with 1 decimals of accuracy [17:36:29][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:36:29][D][sensor:094]: 'Temperature': Sending state 34.64640 °C with 1 decimals of accuracy [17:36:34][D][script.set_timezone:3110]: Setting timezone: <+07>-7 [17:36:34][C][homeassistant.time:010]: Home Assistant Time:

[17:36:34][D][sensor:094]: 'Blueprint': Sending state 3.22581 % with 1 decimals of accuracy [17:36:34][D][time:051]: Synchronized time: 2024-05-27 17:36:34 [17:36:34][D][time.on_time_sync:218]: System clock synchronized [17:36:34][D][time.on_time_sync:219]: Timezone: <+07>-7 [17:36:34][W][component:237]: Component api took a long time for an operation (80 ms). [17:36:34][W][component:238]: Components should block for at most 30 ms. [17:36:34][D][time:051]: Synchronized time: 2024-05-27 17:36:34 [17:36:34][D][time.on_time_sync:218]: System clock synchronized [17:36:34][D][time.on_time_sync:219]: Timezone: <+07>-7 [17:36:34][D][sensor:094]: 'Blueprint': Sending state 9.67742 % with 1 decimals of accuracy [17:36:34][D][sensor:094]: 'Blueprint': Sending state 22.58064 % with 1 decimals of accuracy [17:36:34][D][sensor:094]: 'Blueprint': Sending state 48.38710 % with 1 decimals of accuracy [17:36:34][D][text_sensor:064]: 'Version Blueprint': Sending state '4.3.7'

[17:36:34][D][script.check_versions:2104]: ESPHome: 4.3.7 [17:36:34][D][script.check_versions:2105]: TFT: 4.3.7 [17:36:34][D][script.check_versions:2108]: Blueprint: 4.3.7

[17:36:34][D][script.check_versions:2104]: ESPHome: 4.3.7 [17:36:34][D][script.check_versions:2105]: TFT: 4.3.7 [17:36:34][D][script.check_versions:2108]: Blueprint: 4.3.7 [17:36:34][D][script.page_changed:2601]: New page: home [17:36:34][D][text_sensor:064]: 'Detailed Entity': Sending state '' [17:36:34][D][script.timer_dim:3223]: Waking up on page: home

[17:36:34][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:34][W][component:237]: Component api took a long time for an operation (64 ms). [17:36:34][W][component:238]: Components should block for at most 30 ms. [17:36:34][D][sensor:094]: 'Display Current brightness': Sending state 100.00000 % with 0 decimals of accuracy [17:36:39][D][sensor:094]: 'ntc_source': Sending state 1.22250 V with 2 decimals of accuracy [17:36:39][D][resistance:039]: 'resistance_sensor' - Resistance 6590.6Ω [17:36:39][D][sensor:094]: 'resistance_sensor': Sending state 6590.61426 Ω with 1 decimals of accuracy [17:36:39][D][ntc:026]: 'Temperature' - Temperature: 34.7°C [17:36:39][D][sensor:094]: 'Temperature': Sending state 34.68795 °C with 1 decimals of accuracy [17:36:44][D][script.set_timezone:3110]: Setting timezone: <+07>-7 [17:36:44][C][homeassistant.time:010]: Home Assistant Time:

[17:36:44][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:44][D][time:051]: Synchronized time: 2024-05-27 17:36:44 [17:36:44][D][time.on_time_sync:218]: System clock synchronized [17:36:44][D][time.on_time_sync:219]: Timezone: <+07>-7 [17:36:44][W][component:237]: Component api took a long time for an operation (79 ms). [17:36:44][W][component:238]: Components should block for at most 30 ms. [17:36:44][D][time:051]: Synchronized time: 2024-05-27 17:36:44 [17:36:44][D][time.on_time_sync:218]: System clock synchronized [17:36:44][D][time.on_time_sync:219]: Timezone: <+07>-7 [17:36:44][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:44][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:44][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:44][D][text_sensor:064]: 'Version Blueprint': Sending state '4.3.7'

[17:36:44][D][script.check_versions:2104]: ESPHome: 4.3.7 [17:36:44][D][script.check_versions:2105]: TFT: 4.3.7 [17:36:44][D][script.check_versions:2108]: Blueprint: 4.3.7

[17:36:44][D][script.check_versions:2104]: ESPHome: 4.3.7 [17:36:44][D][script.check_versions:2105]: TFT: 4.3.7 [17:36:44][D][script.check_versions:2108]: Blueprint: 4.3.7 [17:36:44][D][script.page_changed:2601]: New page: home [17:36:44][D][text_sensor:064]: 'Detailed Entity': Sending state ''

[17:36:44][D][sensor:094]: 'Blueprint': Sending state 100.00000 % with 1 decimals of accuracy [17:36:44][W][component:237]: Component api took a long time for an operation (62 ms). [17:36:44][W][component:238]: Components should block for at most 30 ms. [17:36:49][D][sensor:094]: 'ntc_source': Sending state 1.22333 V with 2 decimals of accuracy [17:36:49][D][resistance:039]: 'resistance_sensor' - Resistance 6597.8Ω [17:36:49][D][sensor:094]: 'resistance_sensor': Sending state 6597.75293 Ω with 1 decimals of accuracy [17:36:49][D][ntc:026]: 'Temperature' - Temperature: 34.7°C [17:36:49][D][sensor:094]: 'Temperature': Sending state 34.66198 °C with 1 decimals of accuracy [17:36:59][D][sensor:094]: 'ntc_source': Sending state 1.22350 V with 2 decimals of accuracy [17:36:59][D][resistance:039]: 'resistance_sensor' - Resistance 6599.2Ω [17:36:59][D][sensor:094]: 'resistance_sensor': Sending state 6599.18115 Ω with 1 decimals of accuracy [17:36:59][D][ntc:026]: 'Temperature' - Temperature: 34.7°C [17:36:59][D][sensor:094]: 'Temperature': Sending state 34.65678 °C with 1 decimals of accuracy [17:37:09][D][sensor:094]: 'ntc_source': Sending state 1.22317 V with 2 decimals of accuracy [17:37:09][D][resistance:039]: 'resistance_sensor' - Resistance 6596.3Ω [17:37:09][D][sensor:094]: 'resistance_sensor': Sending state 6596.32471 Ω with 1 decimals of accuracy [17:37:09][D][ntc:026]: 'Temperature' - Temperature: 34.7°C [17:37:09][D][sensor:094]: 'Temperature': Sending state 34.66717 °C with 1 decimals of accuracy [17:37:14][D][sensor:094]: 'Display Current brightness': Sending state 35.00000 % with 0 decimals of accuracy [17:37:19][D][sensor:094]: 'ntc_source': Sending state 1.22433 V with 2 decimals of accuracy [17:37:19][D][resistance:039]: 'resistance_sensor' - Resistance 6606.3Ω [17:37:19][D][sensor:094]: 'resistance_sensor': Sending state 6606.32666 Ω with 1 decimals of accuracy [17:37:19][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:37:19][D][sensor:094]: 'Temperature': Sending state 34.63083 °C with 1 decimals of accuracy [17:37:21][D][text_sensor:064]: 'Device Name': Sending state 'kitchen_nspanel' [17:37:27][D][sensor:094]: 'RSSI': Sending state -60.00000 dBm with 0 decimals of accuracy [17:37:29][D][sensor:094]: 'ntc_source': Sending state 1.22417 V with 2 decimals of accuracy [17:37:29][D][resistance:039]: 'resistance_sensor' - Resistance 6604.9Ω [17:37:29][D][sensor:094]: 'resistance_sensor': Sending state 6604.89795 Ω with 1 decimals of accuracy [17:37:29][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:37:29][D][sensor:094]: 'Temperature': Sending state 34.63602 °C with 1 decimals of accuracy [17:37:39][D][sensor:094]: 'ntc_source': Sending state 1.22417 V with 2 decimals of accuracy [17:37:39][D][resistance:039]: 'resistance_sensor' - Resistance 6604.9Ω [17:37:39][D][sensor:094]: 'resistance_sensor': Sending state 6604.89795 Ω with 1 decimals of accuracy [17:37:39][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:37:39][D][sensor:094]: 'Temperature': Sending state 34.63602 °C with 1 decimals of accuracy [17:37:44][D][script.timer_sleep:3250]: Going to sleep from page home [17:37:44][D][text_sensor:064]: 'Current Page': Sending state 'screensaver' [17:37:44][D][script.page_changed:2601]: New page: screensaver [17:37:44][D][text_sensor:064]: 'Detailed Entity': Sending state '' [17:37:44][D][nextion_textsensor:014]: Processed text_sensor "current_page" state "screensaver" [17:37:44][D][sensor:094]: 'Display Current brightness': Sending state 71.00000 % with 0 decimals of accuracy [17:37:44][D][sensor:094]: 'Display Current brightness': Sending state 71.00000 % with 0 decimals of accuracy [17:37:49][D][sensor:094]: 'ntc_source': Sending state 1.22400 V with 2 decimals of accuracy [17:37:49][D][resistance:039]: 'resistance_sensor' - Resistance 6603.5Ω [17:37:49][D][sensor:094]: 'resistance_sensor': Sending state 6603.46973 Ω with 1 decimals of accuracy [17:37:49][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:37:49][D][sensor:094]: 'Temperature': Sending state 34.64120 °C with 1 decimals of accuracy [17:37:59][D][sensor:094]: 'ntc_source': Sending state 1.22383 V with 2 decimals of accuracy [17:37:59][D][resistance:039]: 'resistance_sensor' - Resistance 6602.0Ω [17:37:59][D][sensor:094]: 'resistance_sensor': Sending state 6602.03906 Ω with 1 decimals of accuracy [17:37:59][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:37:59][D][sensor:094]: 'Temperature': Sending state 34.64640 °C with 1 decimals of accuracy [17:38:09][D][sensor:094]: 'ntc_source': Sending state 1.22417 V with 2 decimals of accuracy [17:38:09][D][resistance:039]: 'resistance_sensor' - Resistance 6604.9Ω [17:38:09][D][sensor:094]: 'resistance_sensor': Sending state 6604.89795 Ω with 1 decimals of accuracy [17:38:09][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:09][D][sensor:094]: 'Temperature': Sending state 34.63602 °C with 1 decimals of accuracy [17:38:19][D][sensor:094]: 'ntc_source': Sending state 1.22400 V with 2 decimals of accuracy [17:38:19][D][resistance:039]: 'resistance_sensor' - Resistance 6603.5Ω [17:38:19][D][sensor:094]: 'resistance_sensor': Sending state 6603.46826 Ω with 1 decimals of accuracy [17:38:19][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:19][D][sensor:094]: 'Temperature': Sending state 34.64121 °C with 1 decimals of accuracy [17:38:21][D][text_sensor:064]: 'Device Name': Sending state 'kitchen_nspanel' [17:38:27][D][sensor:094]: 'RSSI': Sending state -60.00000 dBm with 0 decimals of accuracy [17:38:29][D][sensor:094]: 'ntc_source': Sending state 1.22400 V with 2 decimals of accuracy [17:38:29][D][resistance:039]: 'resistance_sensor' - Resistance 6603.5Ω [17:38:29][D][sensor:094]: 'resistance_sensor': Sending state 6603.46826 Ω with 1 decimals of accuracy [17:38:29][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:29][D][sensor:094]: 'Temperature': Sending state 34.64121 °C with 1 decimals of accuracy [17:38:34][I][ota:117]: Boot seems successful, resetting boot loop counter. [17:38:34][D][esp32.preferences:114]: Saving 1 preferences to flash... [17:38:34][D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed [17:38:39][D][sensor:094]: 'ntc_source': Sending state 1.22400 V with 2 decimals of accuracy [17:38:39][D][resistance:039]: 'resistance_sensor' - Resistance 6603.5Ω [17:38:39][D][sensor:094]: 'resistance_sensor': Sending state 6603.46826 Ω with 1 decimals of accuracy [17:38:39][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:39][D][sensor:094]: 'Temperature': Sending state 34.64121 °C with 1 decimals of accuracy [17:38:49][D][sensor:094]: 'ntc_source': Sending state 1.22417 V with 2 decimals of accuracy [17:38:49][D][resistance:039]: 'resistance_sensor' - Resistance 6604.9Ω [17:38:49][D][sensor:094]: 'resistance_sensor': Sending state 6604.89697 Ω with 1 decimals of accuracy [17:38:49][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:49][D][sensor:094]: 'Temperature': Sending state 34.63602 °C with 1 decimals of accuracy [17:38:59][D][sensor:094]: 'ntc_source': Sending state 1.22400 V with 2 decimals of accuracy [17:38:59][D][resistance:039]: 'resistance_sensor' - Resistance 6603.5Ω [17:38:59][D][sensor:094]: 'resistance_sensor': Sending state 6603.46680 Ω with 1 decimals of accuracy [17:38:59][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:38:59][D][sensor:094]: 'Temperature': Sending state 34.64121 °C with 1 decimals of accuracy [17:39:09][D][sensor:094]: 'ntc_source': Sending state 1.22467 V with 2 decimals of accuracy [17:39:09][D][resistance:039]: 'resistance_sensor' - Resistance 6609.2Ω [17:39:09][D][sensor:094]: 'resistance_sensor': Sending state 6609.18652 Ω with 1 decimals of accuracy [17:39:09][D][ntc:026]: 'Temperature' - Temperature: 34.6°C [17:39:09][D][sensor:094]: 'Temperature': Sending state 34.62045 °C with 1 decimals of accuracy

Could it just be an issue with the api due to lag? The touch seems to respond weirdly maybe the input is being read after the page timeout? thats one diffence between the US panels and the EU one is distance to the WAP ive also seen something like

Component script took a long time for an operation (64 ms). Components should block for at most 30 ms. but i havent seen it since looking earlier

Ill have a play about with the access point now and see if thats a solution.

edwardtfn commented 4 months ago

Under the device's page (Settings > Devices & Services> ESPHome), on the Diagnostic area, there is a sensor related to Display mode. Which value you have there? What about Update TFT display - Model on the Configuration area? What is selected?

edwardtfn commented 4 months ago

Could it just be an issue with the api due to lag? The touch seems to respond weirdly maybe the input is being read after the page timeout? thats one diffence between the US panels and the EU one is distance to the WAP ive also seen something like

I don't think so. My first suspect (and this is the reason of my previous questions) is that you could be using the TFT for EU model. That one have an offset, as the display is not fully visible. If that TFT is used with an US model in landscape mode you will see exactly the behavior you reported originally. Display mode should answer that. It is 1 for EU model, 2 for US portrait and 3 for US landscape. Maybe I should change that sensor to show the names instead.

Nmebowen commented 4 months ago

It's set to US land as I did it manually by adding both tft files to my local www folder. From playing with my WiFi it's definitely the API causing lag when it takes too long to respond, without WiFi all of them are snappy and responsive I've moved the Access point closer to the one in my kitchen and it seems to work much better... Sadly the Access point has to be moved back as it's external and connects to my devices all over the farm so I'm looking at adding another one just to connect to devices within the house. I was using 3.4 something untill this morning which was old but had no issues now upgrading I imagine the complexity has put a far greater dependency on the API.

Nmebowen commented 4 months ago

Could it just be an issue with the api due to lag? The touch seems to respond weirdly maybe the input is being read after the page timeout? thats one diffence between the US panels and the EU one is distance to the WAP ive also seen something like

I don't think so. My first suspect (and this is the reason of my previous questions) is that you could be using the TFT for EU model. That one have an offset, as the display is not fully visible. If that TFT is used with an US model in landscape mode you will see exactly the behavior you reported originally. Display mode should answer that. It is 1 for EU model, 2 for US portrait and 3 for US landscape. Maybe I should change that sensor to show the names instead.

There used to be a button to "reparse tft' I think it was called that cleared any previous data from the nextion unit but I can't see that included any longer is it still somewhere in any of the yaml's I could try that if I could find it.

Nmebowen commented 4 months ago

Yes it seems to be a data packet problem with the API due to poor quality WiFi signal will close the issue, thanks for the concern edward