I have two Xbee shield mounted on my Arduinos...The TRANSMITTER xbee has a botton that, when pressed, sends a signal to the COORDINATOR xbee ( the receiver! ) -----> When the COORDINATOR receives the signal it turns a led on, and write a Serial.println command, that is read by Processing ----> Processing is listening to the port of the COORDINATOR (COM7), and as it receive a Serial.println message it trigger a file .WAV...a simple audio file.
So...the Sketches work fine, but the weird thing is that both the COORDINATOR and the RECEIVER just reset a few second after the button message!
Any idea WHY???? it should keep receiving signal....
P.S.
The COORDINATOR cannot start itself untill the receiver is trasmitting...so i have to turn it on wait a few second and then plug the other XBEE...here is the problem! when they both auto-reset, the COORDINATOR cannot start again because it is "disturbed" by the RECEIVER.....A good solution would be to avoid this strange reset! BUT HOW???
By the way i am not using any of the pins of the xbee but only the Arduino's digital pins, the 5V and GND. So i wonder how could the ATmega reset and the CTS pin eventually comunicate.
I' ll try to isolate the cts anyway and see what happens.
Also the weird thing is that i'm using a tutorial code that works just fine ( http://itp.nyu.edu/~raf275/meshnetworking/XBee/XBee_example.html ) ... it is a button connected to arduino+Xbee that sends a Serial.print read by the other arduino+Xbbe, which turns a led on...
I only added a Serial.println that is sent from the Xbee coordinator ( the one with the Led ) to Processing, in order to trigger an audio file...But the Xbees reset themselves alone...????