Post the complete error message.
This was the complete error message:
error: no matching function for call to 'HardwareSerial::print(uint8_t&, uint8_t&, uint8_t&)'
** Serial.print(xy[0],xy[1],xy[2]);**
xbee.readPacket(500);
Serial.println("Packet Detected");
Serial.print("count: ");
Serial.println(count);
if(xbee.getResponse().isAvailable())
{
Serial.println("Packet Arrived");
Serial.print("count: ");
Serial.println(count);
//Serial.println(xbee.getResponse().getApiId());
if(xbee.getResponse().getApiId() == ZB_RX_RESPONSE)
{
xbee.getResponse().getZBRxResponse(rx);
Serial.print("Data Received: ");
for(int i=0; i<rx.getDataLength(); i++)
{
//sample+= (char)rx.getData(i);
Serial.print(rx.getData(i),DEC);
}
//Serial.println(sample);
count++;
Serial.print("count: ");
Serial.println(count);
}
}
else if(xbee.getResponse().isError())
{
Serial.print("Error Reading Packet. Error Code: ");
Serial.println(xbee.getResponse().getErrorCode());
}
delay(1000);
On the receiving side there will also be an array with 3 elements
As you see in the code, we are getting the received data by using (rx.getData(i), DEC). I guess, but not sure if it is getting data bit by bit or it taking data as a packet. So, can you suggest a way of getting a data packet in form of an array with three elements?