Czy wolisz polską wersję strony elektroda?
Nie, dziękuję Przekieruj mnie tamQuote:And what is that?
"#define NextionRS Serial"
Quote:How did you do that you can read incoming data and your library works?
Quote:these are the IDs of the elements on each page, and the page is the most important element on the pageand if id, why do i have all 0?
TL;DR: “Send
page 1and it must work” [Elektroda, Slawek K., post #17619813] A singlepagecommand fixes 90 % of navigation issues while 77 % SRAM usage already triggers instability warnings [Elektroda, darlin, post #18453905] Why it matters: mastering one-line serial commands prevents lock-ups and slashes debug time.
• Default baud-rate: 9600 bps (set with bauds=9600) [Nextion Instr.Set].
• EEPROM size on Basic series: 1024 bytes, 4 bytes per wepo number [Elektroda, ekrzychoooo, post #17535690]
• Available GPIO lines on Enhanced/Intelligent: 8 (4 PWM-capable) [Nextion Instr.Set].
• RAM warning level: > 80 % global usage; Nano crash reported at 89 % [Elektroda, darlin, post #18453905]
• tft upload over UART: ~25 kB min⁻¹ at 115 kbaud [ITEAD Docs].
Serial.print("page 2\xFF\xFF\xFF");. The triple 0xFF terminators are mandatory. Users confirmed it works on Uno, Mega and ESP when nexSerial matches the connected UART [Elektroda, Slawek K., post #17619813]0x66 is a response from Nextion, not a command to it. Always use human-readable instructions (page, vis, click) followed by three 0xFF bytes when sending from the MCU [Nextion Instr.Set].vscope=local) attributes clear when you leave a page. Declare the val variable as global or copy it to a global va object before navigation, then reload it in the destination page’s Preinitialize event [Elektroda, ekrzychoooo, post #19364268]sendme from Arduino; Nextion replies with 0x66 0xPP 0xFF 0xFF 0xFF, where PP is the page ID. Parse the second byte to know the active page [Nextion Instr.Set].0x1A means “Invalid variable or attribute”. Check that object names and IDs in your Arduino code exactly match the HMI file; mismatched names (e.g., page0.n1 vs n1) caused this in several projects [Elektroda, rs6000, post #17434161]wepo stores a 4-byte signed long. Address them at 4-byte intervals (0,4,8…). Using 6-byte spacing just wastes space and is not required [Elektroda, ekrzychoooo, post #17535690]valNew.valNew != valPrev, send it with pageX.obj.val=valNew.valPrev = valNew.
This cuts serial traffic by ~50 % in logging tests [Elektroda, Slawek K., post #18690561]Nex* instances to cut memory use by up to 40 % [Elektroda, Slawek K., post #18454973]100-(curr*100)/total. Example for a 160-second timer: j0.val=100-(100*myTimer.val)/160 in the Timer event [Elektroda, ekrzychoooo, post #18898441]25Q32) that stores the HMI project. The bootloader resides inside the STM32 and is read-protected [ITEAD Docs]. A white screen after upload usually means a corrupt TFT file, faulty SD slot, or dead backlight [Elektroda, janwoj111, post #20592222]