FAQ
TL;DR: “Send page 1
and it must work” [Elektroda, Slawek K., #17619813]. A single page
command 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.
Quick Facts
• 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].
How do I change pages from Arduino?
Send a plain text command: 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., #17619813].
The command `0x66 0x02` did nothing—why?
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].
Why does my Dual-State Button reset after switching pages?
Local (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]
How can I read which page is currently displayed?
Issue 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].
My text flashes and returns `0x1A` errors—what’s wrong?
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]
Can I store multiple integers in EEPROM?
Yes—each 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]
What’s the safest way to update a value only when it changes?
- Read the new value into
valNew
.
- If
valNew != valPrev
, send it with pageX.obj.val=valNew
.
- Set
valPrev = valNew
.
This cuts serial traffic by ~50 % in logging tests [Elektroda, Slawek K., #18690561].
Why does my Nano freeze after adding 30 objects?
Every declared Nextion object consumes SRAM. A user hit 89 % global RAM (1 592 B) with 35 objects, causing instability [Elektroda, darlin, post #18453905] Shorten object names and send raw serial strings instead of creating Nex*
instances to cut memory use by up to 40 % [Elektroda, Slawek K., #18454973].
How do I invert a Progress Bar (countdown style)?
Set the bar value to 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]
Is it possible to overwrite the bootloader or font chip via SD?
No. The SD or UART uploader only writes the external SPI flash (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]