We are using XB24-B and need to connect gas sensor output to the Xbee’s ADC input, since this pin accepts up to 1.2V and the output from the gas sensor is up to 5V, we drop this voltage whit an Operational Amplifier on inverter attenuator mode reaching -1.3V then we send this voltage to other OPAM in inverter mode only reaching 1.3V. This output, is sent to Xbee’s pin 20 (AD0) configured as ZNET 2.5 ROUTER / END DEVICE API (ED) mode with all inputs disabled except AD0. Another Xbee module is configured as ZNET 2.5 COORDINATOR API. At ED radio, IR command was set as 0x1388ms (5000ms) and after this value is written, the COORDINATOR begins to get values from ED, this values vary between 0x0 and 0x03FF (0 - 1.2V) at terminal tab in the X-CTU application, we get wrong values from ED because although we have stable lectures near to 0.3V at the multimeter, in terminal tab, appears values that could be bouncing from 0x0000 or 0x03FF without any variation on the output value from de sensor. We replace the sensor element whit a potentiometer to have more control whit the input values to the attenuator but it still doing the same. Another thing that I did since it could has noise, was connect a 10uF filter between GND XBee and AD0 and a load resistor at the output from the inverter. We had change IR values (up and down) too but it doesn’t have changes.
My question is, what do I need to do to get the correct values at the terminal tab?
I would recommend you retest with newer firmware. Znet 2.5 is almost 5 years old and hasn’t been updated. in XCTU go to -> ‘modem configuration’ -> modem: XBEE: XB24-ZB -> function set: zigbee coordinator API -> version: 21a0. then do ‘show defaults’ and write the firmware. make sure to have ‘pc settings’ tab baud at 9600 and ‘enable API’ radio box unchecked. This will reflash the firmware.
Not saying this is your problem, but if you mix IC and IR, then it is possible that some of the data you receive at your coordinator LACKS the AD0 value, which means you software might incorrectly be saying ‘0x0000’, when in truth there was no AD0 value in the sample.
Another common problem, if more than 1 ED is sending data (perhaps even a node on someone else’s system but jointed to you!), make sure that you validate the correct MAC/address is being parsed, discarding other nodes. For example, I once helped a customer with a problem when the analog value semmed to cycle between ‘correct’ and zero/0. The problem was they had a 2nd unexpected node sending valid IR/IS data, but their software code was NOT correctly detecting that it only wanted every-other packet.
I just weld my circuit in a pcb, and it works now, I don’t know what happened but it works with the same configuration that i had, XB24-B firmware and ZNET 2.5 COORDINATOR/ED funtion set. Are there any diference betwen XB24-B and XB24-ZB i’ll configure with this other one to make tests.