Re: Xbee problem!!!

Im trying to send two analog values through an xbee. so far I've tryed to use a sync character like this:

The transmitter prints the value 255 then x value BYTE then value 254 then y value BYTE.

so for the reciever i did this:

incomingByte = Serial.read();

if (incomingByte == 255){
x = Serial.read();
}
if (incomingByte == 254){
y = Serial.read();
}

Thank you in advance.

You will need to elaborate a little more. What version XBee's are you sending serial data back and forth or are you reading the analog pins directly.

Im reading the analog pins with the arduino and sending them with a Serial.print. Im using series 1 xbee.