SOIL MOISTURE SENSOR

TINKS030

  1. This sensor can be used to test the moisture of soil when the soil is having water shortage, the module output is at high level, and else the output is at low level.
  2. Module triple output mode, digital output is simple, analog output more accurate, serial output with exact readings.
Features:-
  1. Sensitivity adjustable.
  2. Threshold level can be configured.
  3. Module triple output mode, digital output is simple, analog output more
  4. Accurate, serial output with exact readings.
  5. Operating Voltage +5v dc regulated
Applications:-
  1. Agriculture
  2. Landscape irrigation
  3. Automatically water the flower plant

    

int sensorPin=A0;

void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
Serial.println("taking the senor input");
delay(2000);
}

void loop() {
int output_value;
// put your main code here, to run repeatedly:
output_value=analogRead(sensorPin);
output_value=map(output_value,550,0,0,100);
Serial.print("moisture");
Serial.print(output_value);
Serial.println("%");
delay(1000);
}