Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

Arduino Mega 2560-Based Smart Irrigation System with LoRa Connectivity

View and Edit Project In Cirkit DesignerImage of Arduino Mega 2560-Based Smart Irrigation System with LoRa Connectivity

Circuit Documentation

Summary

This document provides a detailed overview of a circuit that includes various sensors and a LoRa module connected to an Arduino Mega 2560. The circuit is designed to collect environmental data such as temperature, humidity, soil moisture, and rain levels, and transmit this data using the LoRa module.

Component List

  1. DHT 11

    • Description: Temperature and Humidity Sensor
    • Pins: VCC, GND, DATA
  2. Soil Moisture Sensor

    • Description: Measures the moisture level in the soil
    • Pins: VCC, GND, SIG
  3. Arduino Mega 2560

    • Description: Microcontroller board based on the ATmega2560
    • Pins: IOREF, RESET, 3V3, 5V, GND, VIN, A0-A15, D0-D53, AREF, SDA, SCL
  4. YF-S201 Water Flow Meter

    • Description: Measures the rate of water flow
    • Pins: SIG, GND, VCC
  5. RAIN SENSOR

    • Description: Detects the presence of rain
    • Pins: AO, DO, GRD, VCC
  6. LoRa Ra-02 SX1278

    • Description: Long Range (LoRa) transceiver module
    • Pins: GND, NSS, MOSI, MISO, SCK, D105, DI04, 3.3V, RST, DI00, DI01, D102, DI03

Wiring Details

DHT 11

Soil Moisture Sensor (1)

Soil Moisture Sensor (2)

Arduino Mega 2560

YF-S201 Water Flow Meter (1)

YF-S201 Water Flow Meter (2)

RAIN SENSOR

LoRa Ra-02 SX1278

Documented Code

Arduino Mega 2560 Code

void setup() {
  // put your setup code here, to run once:

}

void loop() {
  // put your main code here, to run repeatedly:

}

This code is a basic template for the Arduino Mega 2560. The setup function is used to initialize any settings or configurations, and the loop function contains the main code that runs repeatedly.