Aviso

El foro está en modo de sólo lectura.

Arduino UNO and Nextion

Más
6 años 5 meses antes #807 por Jose Luis
Respuesta de Jose Luis sobre el tema Arduino UNO and Nextion
You can delete these libraries and install the itead ones.
But you can not have both.
Today I uploaded an example for itead libraries,
You can try to see if it works.
The code is in cambatronics, descargas
Más
6 años 5 meses antes #808 por Jose Luis
Respuesta de Jose Luis sobre el tema Arduino UNO and Nextion
You can also make an example without libraries.

Narduino code :
void setup() {
Serial.begin(9600);                                                                 // Inicializa com por hardware.
}

void loop() {
 
for (int i=0; i <= 255; i++){
    
    Serial.print("n0.val=");
    Serial.print(i);
    ff();

    Serial.print("t0.txt="\");
    Serial.print(i);
    Serial.print("\"");
    ff();
      delay(1000);
   } 
}

// · 0xff
void ff(){
 Serial.write(0xff);
 Serial.write(0xff);
 Serial.write(0xff);
}

In the nextion editor create a label component and a numeric component call t0 and n0.

  When you run the program you had to count both labels up to 100.
Más
6 años 5 meses antes #809 por Jose Luis
Respuesta de Jose Luis sobre el tema Arduino UNO and Nextion
the nextion connected on the Rx and Tx pins of the arduino. (rx nextion to tx anduino, tx nextion to rx arduino)
Más
6 años 5 meses antes #810 por gvardal
Respuesta de gvardal sobre el tema Arduino UNO and Nextion
I format my computer today and install ide just now
I tried all off thing we discuss again and i will write the results
thx
Más
6 años 5 meses antes #811 por gvardal
Respuesta de gvardal sobre el tema Arduino UNO and Nextion
I have this error message

Arduino:1.8.5 (Windows 7), Kart:"Arduino/Genuino Uno"

sketch_nov20a:13: error: stray '\' in program

D:\Arduino Dosyaları\sketch_nov20a\sketch_nov20a.ino:13:28: warning: missing terminating " character

sketch_nov20a:13: error: missing terminating " character

D:\Arduino Dosyaları\sketch_nov20a\sketch_nov20a.ino: In function 'void loop()':

sketch_nov20a:14: error: expected ')' before 'Serial'

exit status 1
stray '\' in program

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Más
6 años 5 meses antes #812 por Jose Luis
Respuesta de Jose Luis sobre el tema Arduino UNO and Nextion
Yes,If this line is wrong: Serial.print("t0.txt="\");
is Serial.print("t0.txt=\"");

void setup() {
Serial.begin(9600);                                                                 // Inicializa com por hardware.
}

void loop() {
 
for (int i=0; i <= 255; i++){
    
    Serial.print("n0.val=");
    Serial.print(i);
    ff();

    Serial.print("t0.txt=\"");
    Serial.print(i);
    Serial.print("\"");
    ff();
      delay(1000);
   } 
}

// · 0xff
void ff(){
 Serial.write(0xff);
 Serial.write(0xff);
 Serial.write(0xff);
}

Tiempo de carga de la página: 0.126 segundos
Gracias a Foro Kunena