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

Arduino UNO Water Level Monitoring System with GSM Notification

View and Edit Project In Cirkit DesignerImage of Arduino UNO Water Level Monitoring System with GSM Notification

Circuit Documentation

Summary

This circuit is designed to monitor water levels using a water level sensor and an Arduino UNO. When the water level exceeds a certain threshold, an LED will light up. Additionally, the circuit includes a GSM SIM900 module for potential communication capabilities.

Component List

  1. Water Level Sensor

    • Description: Measures the water level and outputs an analog signal.
    • Pins: SIG, VCC, GND
  2. Arduino UNO

    • Description: Microcontroller board used to read sensor data and control the LED.
    • Pins: UNUSED, IOREF, Reset, 3.3V, 5V, GND, Vin, A0, A1, A2, A3, A4, A5, SCL, SDA, AREF, D13, D12, D11, D10, D9, D8, D7, D6, D5, D4, D3, D2, D1, D0
  3. Resistor

    • Description: Limits the current flowing through the LED.
    • Pins: pin1, pin2
    • Properties:
      • Resistance: 220 Ohms
  4. LED: Two Pin (red)

    • Description: Lights up when the water level exceeds the threshold.
    • Pins: cathode, anode
  5. GSM SIM900

    • Description: Module for GSM communication.
    • Pins: A5, A4, A3, A2, A1, A0, 5V, GND, 3.3V, RESET, D0, D1, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11, D12, D13, AREF

Wiring Details

Water Level Sensor

Arduino UNO

Resistor

LED: Two Pin (red)

GSM SIM900

Documented Code

// Define the pins
int waterSensorPin = A0;  // Water level sensor connected to analog pin A0
int ledPin = 13;          // LED connected to digital pin 13

void setup() {
  // Initialize serial communication at 9600 bits per second
  Serial.begin(9600);
  // Initialize the LED pin as an output
  pinMode(ledPin, OUTPUT);
}

void loop() {
  // Read the input on analog pin 0
  int sensorValue = analogRead(waterSensorPin);

  // Print out the value you read
  Serial.print("Water Level: ");
  Serial.println(sensorValue);

  // Check if the water level is above a threshold
  if (sensorValue > 300) {  // Adjust the threshold as necessary
    digitalWrite(ledPin, HIGH);  // Turn the LED on
  } else {
    digitalWrite(ledPin, LOW);   // Turn the LED off
  }

  // Wait for a second before taking the next reading
  delay(1000);
}

This code initializes the Arduino UNO to read the water level sensor's analog input and control the LED based on the sensor's readings. The LED will turn on if the water level exceeds a specified threshold.