# nikhilsp780/-smart-irrigation-system-esp32 architecture

> Architecture diagram of the GitHub repository nikhilsp780/-smart-irrigation-system-esp32, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/nikhilsp780/-smart-irrigation-system-esp32
- Repository: https://github.com/nikhilsp780/-smart-irrigation-system-esp32

## Overview

This ESP32 project automates irrigation using soil moisture and rain detection, with pump control and water-flow measurement; it also exposes readings and controls through Blynk and retrieves weather information from OpenWeather. The tree contains one sketch, so runtime responsibilities share its path. No source excerpts were available; relationships shown are limited to those stated in the README.

Main entry points: [`IrrigationSystem_Final.ino`](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino) (Sensor Monitoring)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_sensing["Sensing"]
  node_sensor_reading["Sensor Monitoring"]
  node_flow_measurement["Water Measurement"]
end

subgraph group_irrigation["Irrigation Control"]
  node_irrigation_logic["Irrigation Logic"]
  node_pump["Pump and Relay"]
end

subgraph group_connectivity["Connectivity"]
  node_blynk_interface["Blynk Interface"]
  node_weather_integration["Weather Integration"]
end

node_environment{{"Environmental Sensors"}}
node_flow_sensor{{"Flow Sensor"}}
node_blynk{{"Blynk App"}}
node_weather_api{{"OpenWeather API"}}

node_environment -->|"provides readings"| node_sensor_reading
node_sensor_reading -->|"informs control"| node_irrigation_logic
node_irrigation_logic -->|"controls pump"| node_pump
node_environment -->|"provides flow pulses"| node_flow_measurement
node_flow_measurement -->|"reports volume"| node_blynk_interface
node_sensor_reading -->|"sends readings"| node_blynk_interface
node_blynk -->|"provides controls"| node_blynk_interface
node_weather_api -->|"provides weather"| node_weather_integration

click node_sensor_reading "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"
click node_irrigation_logic "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"
click node_pump "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"
click node_flow_measurement "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"
click node_blynk_interface "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"
click node_weather_integration "https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_sensor_reading,node_flow_measurement toneBlue
class node_irrigation_logic,node_pump toneAmber
class node_blynk_interface,node_weather_integration,node_weather_api toneMint
class node_environment,node_flow_sensor,node_blynk toneIndigo
```

## Components

### Sensing

- [Sensor Monitoring](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`
- [Water Measurement](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`

### Irrigation Control

- [Irrigation Logic](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`
- [Pump and Relay](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`

### Connectivity

- [Blynk Interface](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`
- [Weather Integration](https://github.com/nikhilsp780/-smart-irrigation-system-esp32/blob/main/IrrigationSystem_Final.ino): `IrrigationSystem_Final.ino`

### Other components

- **Environmental Sensors**
- **Flow Sensor**
- **Blynk App**
- **OpenWeather API**

## Connections

- Environmental Sensors → Sensor Monitoring: provides readings (evidence: `README.md`)
- Sensor Monitoring → Irrigation Logic: informs control (evidence: `README.md`)
- Irrigation Logic → Pump and Relay: controls pump (evidence: `README.md`)
- Environmental Sensors → Water Measurement: provides flow pulses (evidence: `README.md`)
- Water Measurement → Blynk Interface: reports volume (evidence: `README.md`)
- Sensor Monitoring → Blynk Interface: sends readings (evidence: `README.md`)
- Blynk App → Blynk Interface: provides controls (evidence: `README.md`)
- OpenWeather API → Weather Integration: provides weather (evidence: `README.md`)
