Maker Pro
Maker Pro

Soil Moisture sensor , Zigbee project

In a project I am doing, I have to send analog readings of a soil moisture sensor through zigbee. I have connected the sensor Vcc to 5v and ground; the zigbee Vcc to 3.3v and ground. The analog pin of sensor to Txx pin of adapter on which the zigbee is mounter. On the coordinator zigbee, i/o packets are being recieved..but it is always giving value of "020a" or "020b" irrespective of the data from sensor. I have also fed the analog data of sensor through voltage divider to keep it within 1.2v range..can you suggest what I am doing wrong??
 

Harald Kapp

Moderator
Moderator
The Txx pin of the Zigbee adapter very probably requires a digital signal (a data stream), not an analog input.
Also make sure the two GNDs of 3.3V and 5V are connected.

Which sensor and which Zigbee module do you use? Post links to the datasheets.
 

Harald Kapp

Moderator
Moderator
... means you have to connect the analog signal to pin # 20 (D0). The datasheet does not mention a Txx pin which you refer to in your post #1. Make sure your analog signal is connected to the correct pin.
The analog input signal shall be within the ADC range of 0V...Vddad (+-0.3V max.) As Vddad is connected to Vcc, this means 3.3V. 1.2V should give workeable readings, however at 0...3,3V you'll get better resolution.

This page shows at least a schematic of the sensor's design. The "analog output" is directly connected to the sensor. Connecting this pin to the ADC input of the Zigbee module may overload the sensor resulting in 0V output. You may have to insert a buffer amplifier (simple non-inverting opamp, use rail-to-rail type!) to decouple the sensor from the ADC.

As for the AT-commands required to setup the Zigbee module I'm afraid I do not have the time to analyze these for correctness.
 
Top