Project showcase
Rain Warning Display on Mobile for your Home Garden

Rain Warning Display on Mobile for your Home Garden © GPL3+

A system that warns for unexpected rains to help out your garden. The system displays real time values on mobile.

  • 6,804 views
  • 6 comments
  • 30 respects

Components and supplies

Apps and online services

About this project

Recently I bought a rain sensor for hooking it up to my arduino. I have a home garden and watering it in my area is troublesome. I live in an area where we get unexpected rains. So I wanted to make a system that would check for rain on all times and alert me whenever it rains. The system notifies me on my mobile and shows the intensity of rain on my screen.

Rain sensors are used in the detection of water beyond what a humidity sensor can detect.

How it works:

The rain sensor detects water that completes the circuits on its sensor boards' printed leads. The sensor board acts as a variable resistor that will change from 100k ohms when wet to 2M ohms when dry. In short, the wetter the board the more current that will be conducted.

Pins:

A0.......... Analog output

D0......... Digital output

GND..... Ground

VCC...... Positive voltage (input: 5v for analog 3.3v for Digital.)

Loop Pins:

+ .......... Sensor board hookup A

- .......... Sensor board hookup B

Happy Hacking :)

Code

Smart GardenArduino
#define BLYNK_PRINT Serial
#include <SPI.h>
#include <Ethernet.h>
#include <BlynkSimpleEthernet.h>
#include <SimpleTimer.h>

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "";


WidgetLCD lcd(V1);   // LCD Widget
int nRainIn = A1;
int nRainDigitalIn = 2;
int nRainVal;
boolean bIsRaining = false;
String strRaining;


void setup() {
  Serial.begin(9600);
  Blynk.begin(auth);      // Start Blynk server
  pinMode(2,INPUT);
  while (Blynk.connect() == false) {
    // Wait until connected
  }
}
void loop() {
   Blynk.run();
  
  nRainVal = analogRead(nRainIn);
  bIsRaining = !(digitalRead(nRainDigitalIn));
  
  if(bIsRaining){
    strRaining = "YES";
  }
  else{
    strRaining = "NO";
  }
  
  Serial.print("Raining?: ");
  Serial.print(strRaining);  
  Serial.print("\t Moisture Level: ");
  Serial.println(nRainVal);
  Blynk.virtualWrite(3, nRainVal);
  lcd.clear();
  if (nRainVal< 550)
  {
       lcd.clear(); //Use it to clear the LCD Widget
  lcd.print(4, 0, "Raining"); // use: (position X: 0-15, position Y: 0-1, "Message you want to print")
  lcd.print(4, 1, "Heavily!"); }
  if (nRainVal> 700 && nRainVal < 900)
  {
      lcd.clear(); //Use it to clear the LCD Widget
  lcd.print(4, 0, "Rain"); // use: (position X: 0-15, position Y: 0-1, "Message you want to print")
  lcd.print(4, 1, "Warning!"); } 
   
  delay(200);

}

Schematics

Rain sensor
Rain sensor module arduino hookup

Comments

Similar projects you might like

Room temperature sensor with display on Mobile

Project showcase by Kaustubh Agarwal

  • 23,926 views
  • 8 comments
  • 54 respects

Smart Doorbell

Project showcase by Kaustubh Agarwal

  • 50,791 views
  • 20 comments
  • 108 respects

Control Lights with your Phone from Anywhere in the World!

Project showcase by Kaustubh Agarwal

  • 15,047 views
  • 4 comments
  • 36 respects

College Faculty DashBoard

Project showcase by Kaustubh Agarwal

  • 4,275 views
  • 4 comments
  • 27 respects

Lights On/Off using Twitter

Project showcase by Kaustubh Agarwal

  • 3,939 views
  • 0 comments
  • 14 respects

Smart Garden

Project showcase by patel Dipen

  • 22,485 views
  • 15 comments
  • 59 respects
Add projectSign up / Login