Introduction: Fire Detection Using Arduino and Flame Sensor

Flame sensor is interfaced to arduino to detect Flame. Led and buzzer are interfaced to arduino to indicate the flame.

Hard ware components required:-

1) Flame sensor (Analogue Output)

2)Arduino

3)Bread board

4)LED

5)Buzzer

6)Connecting wires

Step 1: Hard Ware Connections

Flame sensor interfacing to Arduino

Flame sensor to Arduino

vcc -> vcc

gnd -> gnd

A0 -> A0

Led interfacing to Arduino

LED +ve is connected to 9th pin of Arduino

LED -ve is connected to gnd pin of arduino

For detailded description regarding led interfacing refer the below link

https://www.instructables.com/id/LED-blinking-using-Arduino/

Buzzer interfacing to Arduino

Buzzer +ve is connected to 12th pin of Arduino

Buzzer -ve is connected to GND pin of Arduino

Step 2: Programming

#include<SoftwareSerial.h>

int sensorPin = A0; // select the input pin for the LDR

int sensorValue = 0; // variable to store the value coming from the sensor

int led = 9; // Output pin for LED

int buzzer = 12; // Output pin for Buzzer

void setup() {

// declare the ledPin and buzzer as an OUTPUT:

pinMode(led, OUTPUT);

pinMode(buzzer,OUTPUT);

Serial.begin(9600);

}

void loop()

{

Serial.println("Welcome to TechPonder Flame Sensor Tutorial");

sensorValue = analogRead(sensorPin);

Serial.println(sensorValue);

if (sensorValue < 100)

{

Serial.println("Fire Detected");

Serial.println("LED on");

digitalWrite(led,HIGH);

digitalWrite(buzzer,HIGH);

delay(1000);

}

digitalWrite(led,LOW);

digitalWrite(buzzer,LOW);

delay(sensorValue);

}

Copy and paste the above code in Arduino ide and upload to Arduino UNO.
Thanks,

TechPonder.

Step 3: Results

Results are displayed on the serial window.

When there is Flame the LED and Buzzer automatically ON and when there is no flame amount Arduino automatically turns off LED and Buzzer.

Here based on our room condition the threshold value we took was 100 for the Flame sensor.

When we place a Flame Near Flame Sensor Arduino automatically turns on the LED and Buzzer. When we remove Flame from the flame sensor Arduino automatically Turns Off LED and buzeer.

Thanks,
TechPonder.

Comments

author
ahamed0081 (author)2017-08-10

Hi,

I'm trying to make a prototype which can detect fire using flame sensor and send an sms to a allocated mobile number.
Experts on coding please advice me to make the programme

author
arduinomaster (author)2017-05-05

//you need to include this to make a piezo run that does not buzz by itself.

// the 100 means the Arduino reads the value between 0 and 1024 or 5 to 0 volt.

// if (sensorValue < 100) if sensor reads less then 100 then do {tone(12,300,500); delay(600);}

// 12=pin 300 sound note ,600 minus (500 sound time) makes a delay of 100 milliseconds.

int piezoPin =12;

int sensorValue = 0;

void setup() {

// put your setup code here, to run once:

}

void loop() {

// put your main code here, to run repeatedly:

if (sensorValue < 100){

tone(12,300,500);

delay(1000);

}

else if (piezoPin = LOW);

}

//this sketch compiles

author
VaibhavB50 (author)2017-04-29

Buzzer is not working when connected in 12th pin and gnd....

author
andrer119 (author)2017-03-11

Hi, What is "100"... Celsius or Fahrenheit? and why does it go down? what is the measurement unit?

author
F16d made it! (author)2017-02-04

I had a good time learning with this my first Arduino project. I'm hoping to intergrate this into a machine tool and open the E-stop circuit in the event of a flash fire. Hopefully as an added level of protection.

IMG_2780.JPGIMG_2775 (1).MOVIMG_2777.MP4
author
alihashmi385 (author)2016-12-15

Why threshold is kept 100. What if it is kept to 200 and so?

author
MuhammadF231 (author)2016-10-20

Good Post....

author
FebrianS1 (author)2016-08-23

How to adjust the distance of fire detection range?

author
sai harshathm (author)2016-07-15

how much ohm resitor is used in fire alarm project

author
Mer (author)sai harshathm2016-08-01

I used a 330 ohm and it worked fine.

author
kode1303 (author)2015-08-18

Maybe this could be used to control a diy pellet burner. Hmmm ...

About This Instructable

30,432views

49favorites

License:

More by TechPonder:how to interface LCD (16X2) to arduinoHow to Interface Ultrasonic Sensor (HCSR04) to arduino unoFire  detection  using Arduino and flame sensor
Add instructable to: