Ahmad RIzqi Nanda Baihaqi, Baianjaay
Published

Plant watering system based on IoT (Internet of Things)

This project is useful for people who forget to water their plants properly.

BeginnerProtip14
Plant watering system based on IoT (Internet of Things)

Things used in this project

Hardware components

ESP32
Espressif ESP32
×1
Relay (generic)
×1
SparkFun Soil Moisture Sensor (with Screw Terminals)
SparkFun Soil Moisture Sensor (with Screw Terminals)
×1
Jumper wires (generic)
Jumper wires (generic)
×1
PHPoC Bread Board
PHPoC Bread Board
×1

Software apps and online services

Arduino IDE
Arduino IDE
Blynk
Blynk

Hand tools and fabrication machines

Multitool, Screwdriver
Multitool, Screwdriver
Plier, Cutting
Plier, Cutting

Story

Read more

Code

project ariznbai.ino

C/C++
#define BLYNK_PRINT Serial
#include <WiFi.h>
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>

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

// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "Ariznbai";
char pass[] = "syndicate";

int sensorPin = 2;   // Input pin for the Flame Sensor
int sensorValue = 0;  // Variable to store the value coming from the flame sensor
int relay1       = 23;
void setup()
{
  // Debug console
  pinMode(relay1, OUTPUT);
  pinMode(relay1, HIGH);
  Serial.begin(9600);
  Blynk.begin(auth, ssid, pass, "blynk-cloud.com",8080);
  pinMode(2, INPUT);
}

void loop()
{
  Blynk.run();
  sensorValue = digitalRead(sensorPin);
  if (sensorValue == 1) {
    Blynk.notify("I need water..");
  }

}

Credits

Ahmad RIzqi Nanda Baihaqi, Baianjaay

Ahmad RIzqi Nanda Baihaqi, Baianjaay

0 projects • 0 followers

Comments

Add projectSign up / Login