Ashwini kumar sinha
Published © CC BY

Smart Fire and Flammable Gas Safety Valve

A smart valve that automatically stops the flammable gas supply when gas leakage takes place or fire occurs for protection.

IntermediateWork in progress10 hours1,542
Smart Fire and Flammable Gas Safety Valve

Things used in this project

Hardware components

Arduino UNO
Arduino UNO
×1
solenoid valve
×1
Grove - Gas Sensor(MQ2)
Seeed Grove - Gas Sensor(MQ2)
×1
CoolMOS C7 Gold SJ MOSFET
Infineon CoolMOS C7 Gold SJ MOSFET
×1

Software apps and online services

Arduino IDLE

Story

Read more

Schematics

untitled_sketch_bb_J9RuuoyMLg.jpg

Code

infinion.ino

Arduino
int gassensor=9;
int Mosfet=7;

void setup(){

pinMode(gassensor,INPUT);
pinMode(Mosfet,OUTPUT);
}

void loop(){

  if (digitalRead(gassensor==LOW)){

  digitalWrite(Mosfet,1);//for on
    
  }
  if (digitalRead(gassensor==HIGH)){

  digitalWrite(Mosfet,0);//for off to save
    
  }
  
}

Credits

Ashwini kumar sinha

Ashwini kumar sinha

23 projects • 47 followers
Ashwini kumar sinha a Robotic lover and electronics hobbyist. Works at EFY-I

Comments

Add projectSign up / Login