i am using two XBees and one Arduino and trying to send analog data over XBEE AND DISPALY ON SERIAL MONITOR

I have connected coordinator(XBee 1) to Arduino and Router(XBee 2) to the Soil moisture Sensor and want to send the analog sensor data to Coordinator from Router and then want it to display on Serial Monitor from Coordinator. I can see the Sensor analog data over Coordinator correctly but the Arduino code to display on serial monitor is not satisfactory. I am getting constant output on serial monitor . the value displayed is 16 16 16 16 …

I am sharing the code. Can any one please help me with this project of mine?


void setup() {
// put your setup code here, to run once:

void loop() {
// put your main code here, to run repeatedly:
if (Serial.available() >= 21){
if(Serial.read() == 0x7E){
for (int i = 1; i<19; i++){
byte discardByte = Serial.read();
int analogMSB = Serial.read();
int analogLSB = Serial.read();
int analogReading = (analogLSB + (analogMSB * 256));