The Code:
int incomingByte = 0; // for incoming serial data
void setup() {
Serial.begin(9600); // opens serial port, sets data rate to 9600 bps
}
void loop() {
// send data only when you receive data:
if (Serial.available() > 10) {
// read the incoming byte:
incomingByte = Serial.read();
// say what you got:
Serial.print(incomingByte, HEX);
Serial.print(" ");
}
}
The Output:
7E 0 12 92 0 13 A200 40 A9 05 69 FF FE C1 1 0 0 1 3 FF 9F
What it should be outputting
7E 00 12 92 00 13 A2 00 40 A9 05 69 FF FE C1 01 00 00 01 03 FF 9F
My question is that why is the output deciding to drop some zeroes?
I'm reading a frame from an XBee wireless communication module. The XBee TX pin is connected to the RX pin of the MSP430G2553 launchpad.