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

Arduino-Controlled Fire Detection and GSM Notification System

View and Edit Project In Cirkit DesignerImage of Arduino-Controlled Fire Detection and GSM Notification System

Circuit Documentation

Summary

This circuit is designed to control multiple DC motors using an L298N DC motor driver, interfaced with an Arduino UNO microcontroller. The circuit includes power management components such as an 18650 Li-Ion battery and an LM296 DC-DC converter, as well as sensors like flame sensors and a smoke sensor for safety monitoring. A servo motor is included for additional actuation, and a Sim800l module is present for potential communication capabilities. A 5V mini water pump is controlled via a 1 Channel 5V Relay Module, which is also interfaced with the Arduino UNO.

Component List

Wiring Details

L298N DC Motor Driver

18650 Li-Ion Battery

Arduino UNO

DC Motors

Flame Sensors

Smoke Sensor

5V Mini Water Pump

Sim800l

LM296 DC-DC Converter

1 Channel 5V Relay Module

Servo

Documented Code

Arduino UNO Code

// Define L298N motor control pins
int enA = 5;  // Enable Pin A
int in1 = 9;  // Input Pin 1
int in2 = 10; // Input Pin 2

void setup() {
  // Set the motor control pins as outputs
  pinMode(enA, OUTPUT);
  pinMode(in1, OUTPUT);
  pinMode(in2, OUTPUT);
}

void loop() {
  // Motor Forward
  digitalWrite(in1, HIGH);
  digitalWrite(in2, LOW);
  analogWrite(enA, 200); // Set motor speed (0-255)

  delay(2000); // Run forward for 2 seconds

  // Motor Stop
  digitalWrite(in1, LOW);
  digitalWrite(in2, LOW);
  analogWrite(enA, 0); 

  delay(1000); // Stop for 1 second

  // Motor Reverse
  digitalWrite(in1, LOW);
  digitalWrite(in2, HIGH);
  analogWrite(enA, 200); // Set motor speed (0-255)

  delay(2000); // Run reverse for 2 seconds

  // Motor Stop
  digitalWrite(in1, LOW);
  digitalWrite(in2, LOW);
  analogWrite(enA, 0); 

  delay(1000); // Stop for 1 second
}

L298N DC Motor Driver Code

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

}

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

}

Note: The code for the L298N DC motor driver is not complete and does not contain any functional code. It is likely that the control code is intended to be placed on the Arduino UNO, which sends the control signals to the L298N.