Hello guys, I’m Natanael Prado. And I’m having a poblem running some pages that I made with the nextion editor in the arduino sketch. I’m trying to run some pages in the arduino sketch to create somr animation to my nextion display, each page has a time to appear that i putted in the nextion editor, but when I try to run this pages in the nextion display through Arduino, a blank image appear between each page and the animation doesn’t run the way I want, it only happens when I try to run pages. I will put a gif here
#include <SoftwareSerial.h> //Include the library
SoftwareSerial mySerial(17, 16); // RX, TXvoid bomdiacriador();
void setup() {
Serial.begin(57600); //open the serial port
while (!Serial) { // wait for serial port to connect. Needed for native USB port only
;
}
Serial.println(“Serial On”); //Print this messages when the serial port is connected
mySerial.begin(9600); // set the data rate for the SoftwareSerial port
}
void loop () {bomdiacriador();
}
void bomdiacriador() {
mySerial.print(“page 0”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 1”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 2”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 3”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 4”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 5”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 0”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 1”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 6”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 3”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 4”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 5”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 7”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 8”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 9”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 10”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 11”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 12”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 13”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 14”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 15”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 16”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 17”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
mySerial.print(“page 18”);
mySerial.write(0xff); //Send this three lines after each command sent to the nextion display.
mySerial.write(0xff);
mySerial.write(0xff);
}
That’s the code that I made in Arduino, Anyone knows how I can solve this??