Problem solved Comunication Mega 2560 - Processing- serial port


hi there!!!  7 hours trying set comunication  between processing 2.0b8 , mega 2560, after reviewing forums on web , looking information everywhere, solve problem ... problem consist in when try communicate processing , arduino, if processing starts send information , mega locked (the led on pin 13 turn on , resetting card wont work while board receiving data). solved follows:

need reset card after establishing comunicasion, before starts send information (before rx led starts turn on), achieve this, need put delay in processing code,just few seconds, right after setting port, during time need press reset button reset card before starts receiving data, , there no problems transmission of data, did follows:


  port = new serial (this, serial.list () [1], 9600);

  while (a < 3000) {         / / cycle of 3 seconds duration, during time
  = millis ();}              / / need press reset buton.

***********************************************************************************************************************************************************************
***********************************************************************************************************************************************************************

que tal? estuve cerca de 7 horas tratando de establecer comunicación entre mi processing 2.0b8 y mi mega 2560, después de revisar foros por toda la web y buscar información por doquier, logre resolver el problema... en si el problema consiste en que cuando intentas comunicar processing y arduino mega, si processing envía información en cuanto arranca, la mega se traba (el led del pin 13 se prende y ni reseteando la tarjeta funciona bien). la forma en que se soluciona es la siguiente:

simplemente necesitas resetear la tarjeta después de que se establece la comunicación, pero antes de que se empiece enviar la información (antes de que el led rx se prenda), para lograr hacer esto necesitaremos poner un retraso en el código de prossesing de algunos segundos, justo después de establecer el puerto, durante este tiempo necesitaras presionar el botón reset de la tarjeta para reiniciarla y que no haya problemas con la transmisión de los datos, yo lo hice de la siguiente manera:

println(serial.list());
port = new serial(this, serial.list()[1], 9600);

while( < 3000){               //ciclo de 3 segundos de duracion durante este tiempo
a=millis();}                      //  necesitaras precionar el boton reset de tu tarjeta



Arduino Forum > Using Arduino > Installation & Troubleshooting > Problem solved Comunication Mega 2560 - Processing- serial port


arduino

Comments

Popular posts from this blog

Convierte tu Raspberry en un NAS. Firmware fvdw-sl 15.3 - Raspberry Pi Forums

How to format a Get Request

avrdude: verification error, first mismatch at byte 0x0000 0x0c != 0x62