try swapping one end of the tx & rx around maybe. masto mentioned that the sometimes the screen printing on the boards can be backwards.
It gives me an error when I load the panel from home-assistant.
It starts to go slow until it is hell. Does somebody knows why it could be
when i finish it i upload it
it could be anything. maybe you can upload your hmi somewhere and later i can take a look. it’s sometimes wrong image sizes compared to your picture component or screen size, but as i say it could be a manner of things.
Using ‘COM7’ as serial port.
Connecting…………………_____
Unexpected error: ESP Chip Auto-Detection failed: Failed to connect to Espressif device: Timed out waiting for packet header
The same when i switch rx and tx.
Is there maybe a locked bootloader or some other method to prevent flashing?
does the serial device matter?
I have a ch340, pl2303 and cp2102x
edit: apparantly it does matter, the last one, cp2102x worked
how do i add text and symbols to the nspanel light switches?
i used this yaml and tft, but i have no text and symbols
what do you mean by add text and symbols. do you mean images for switch states? and text… what text???. do you have the nextion editor installed? or are you just wanting to use the provided tft from that project.
Do I need to add text into the TFT file myself then?
I have no idea yet.
All buttons are working, but no symbols or text on them
please post your yaml file somewhere so I can take a look. I’m sure it will just be your light entities that are not the same as the project you are using.
i am using the tft and yaml from this github:
just edited the entities
yes but i would like to see if you missed anything with the entity’s. i can’t really help unless I see the actual code you are using.
Has anyone managed to send multiline text to a text area?
I have a text area with setting isbr true, and I send from ESP-Home:
id(disp1).set_component_text_printf("Home.Text", "%s", "Foo\rBar");
As far as I have understood from googling it’s \r that ends the lines on nextion displays.
Anyone have a suggestion?
It kind of works.
I forgot about the max length of the text field, with that changed it does work with multiline.
But it doesn’t set the new line where I want it.
I get:
Foo B
ar
Hello, i have a problem with my NSPanel:
since yesterday, when i change the YAML-file and upload wireless, the display blinks and most of time it goes offline in HA, so i have to flash it again via usb. I have to use the last working Yaml version (without the new 5 lines). Everything i changed is added 2 more sensor values from HA to the display:
sensor:
- platform: homeassistant
id: kwh_mon
entity_id: sensor.energie_spower_kwh_this_month
on_value:
then:
- lambda: ‘id(disp1).set_component_text_printf(“StromWasser.kwhmon”, “%.2f “”\xb0”, x);’
this lines are correct in my opinion because they work with another entitys and all the lines above.
All other sensor and functions work in the same way…
I also tried to add another binary sensor and results the same problem.
Maybe my file becomes too long? (round about 800 lines)??? Or there is a maximum number of sensors at all?
When i delete some lines the flash works without hanging up the display…
Anybody can help?
when you compile it you will see a percentage used just before it flashes. is it above 68.4% ??
@wunni
you mean 64,8%? → Here is the log from the upload with the error
INFO Reading configuration /config/esphome/sonoff-nspanel.yaml…
INFO Detected timezone ‘Europe/Berlin’
WARNING GPIO4 is a Strapping PIN and should be avoided.
Attaching external pullup/down resistors to strapping pins can cause unexpected failures.
See Frequently Asked Questions — ESPHome
INFO Generating C++ source…
INFO Compiling app…
Processing sonoff-nspanel (board: esp32dev; framework: arduino; platform: platformio/espressif32 @ 3.5.0)
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
LDF: Library Dependency Finder → Library Dependency Finder (LDF) — PlatformIO latest documentation
Dependency Graph
|-- 1.0
|-- 1.0
|-- 1.0
|-- 1.0
|-- 1.2
Compiling /data/sonoff-nspanel/.pioenvs/sonoff-nspanel/src/main.cpp.o
Linking /data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware.elf
RAM: [= ] 13.1% (used 43012 bytes from 327680 bytes)
Flash: [====== ] 64.8% (used 1189440 bytes from 1835008 bytes)
Building /data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware.bin
esp32_create_combined_bin(["/data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware.bin"], ["/data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware.elf"])
Wrote 0x1326b0 bytes to file /data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware-factory.bin, ready to flash to offset 0x0
========================= [SUCCESS] Took 73.97 seconds =========================
INFO Successfully compiled program.
INFO Resolving IP address of sonoff-nspanel.local
INFO → 192.168.86.78
INFO Uploading /data/sonoff-nspanel/.pioenvs/sonoff-nspanel/firmware.bin (1189552 bytes)
Uploading: [============================================================] 100% Done…
INFO Waiting for result…
INFO OTA successful
INFO Successfully uploaded program.
INFO Starting log output from sonoff-nspanel.local using esphome API
WARNING Can’t connect to ESPHome API for sonoff-nspanel.local: Error resolving IP address: [Errno -2] Name or service not known
INFO Trying to reconnect to sonoff-nspanel.local in the background
no, 68.4 is my max size before it won’t connect after flashing. at 64.8 you should be fine. i do have the odd time when it just fails and keeps failing to connect. i normally do the clean build files button in esphome, reboot router and pc and it starts working again
I’ve never gotten to the bottom of why. but every time I go over 68.4% it’s guaranteed to happen.
ok will try it. but already tried with clean build files. Will restart the router and the raspberry and the mac.
the max size means the TFT File or the yam-file?
Strangely it works with one sensor less (approx. 5 lines) when i add one more device (no matter what kind) in the yaml it breaks…
size is the yaml. i think the tft can be upto 16mb. I’m hoping i got 68.4% right now you say that, I’m not in front of my pc yet. but thats the exact behaviour i get if i add 1 more component… I’ll check my size in 15 mins when I’m back.
after restart the same behaviour…
so that means i have to shorten my yaml?