Home
About Us
Achievement
Home
Raspberry-Pi Projects
_Raspberry Pi 4 Complete Guide
Arduino Project
_All Projects
Esp8266 Project
_All Projects
Esp32 Project
_Automation-with-feedback
GAS Leakage Detector Using Arduino
Just Do Electronics
September 26, 2021
Circuit Diagram :-
Code :-
//Prateek //www.prateeks.in #include
LiquidCrystal lcd(7, 8, 9, 10, 11, 12); #include
SoftwareSerial mySerial(2, 3); int gasValue = A0; int data = 0; int buzzer = 4; int G_led = 5; int R_led = 6; void setup() { pinMode(buzzer, OUTPUT); pinMode(R_led, OUTPUT); pinMode(G_led, OUTPUT); randomSeed(analogRead(0)); mySerial.begin(9600); Serial.begin(9600); lcd.begin(16, 2); pinMode(gasValue, INPUT); lcd.print (" Gas Leakage "); lcd.setCursor(0, 1); lcd.print (" Detector Alarm "); delay(3000); lcd.clear(); } void loop() { data = analogRead(gasValue); Serial.print("Gas Level: "); Serial.println(data); lcd.print ("Gas Scan is ON"); lcd.setCursor(0, 1); lcd.print("Gas Level: "); lcd.print(data); delay(1000); if ( data > 90) // { digitalWrite(buzzer, HIGH); digitalWrite(R_led, HIGH); digitalWrite(G_led, LOW); SendMessage(); Serial.print("Gas detect alarm"); lcd.clear(); lcd.setCursor(0, 0); lcd.print("Gas Level Exceed"); lcd.setCursor(0, 1); lcd.print("SMS Sent"); delay(1000); } else { digitalWrite(buzzer, LOW); digitalWrite(R_led, LOW); digitalWrite(G_led, HIGH); Serial.print("Gas Level Low"); lcd.clear(); lcd.setCursor(0, 0); lcd.print("Gas Level Normal"); delay(1000); } lcd.clear(); } void SendMessage() { Serial.println("www.prateeks.in"); mySerial.println("AT+CMGF=1"); delay(1000); mySerial.println("AT+CMGS=\"+918830584864\"\r"); delay(1000); mySerial.println("Excess Gas Detected."); mySerial.println(data); delay(100); mySerial.println((char)26); delay(1000); }
Video :-
0 Comments
Newer
Older
IoT Based Fingerprint Biometric Attendance System Using NodeMCU (Esp8266)
Build Your Own Gps Tracking System using Arduino
Ultrasonic Sensor as a Counter with Arduino
OTP Based Door Lock Using Arduino And SIM800L
How To Make RFID & Keypad Based Door Lock
IoT Based Patient Health Monitoring System Using Blynk App
Arduino Based Ventilator
IoT Weight Scale using Load Cell HX711 & ESP8266
Esp32 Cam Based Face Unlock
ESP32 Led Blink With Push Button
YouTube
Like on Facebook
Follow on Twitter
Follow on Google+
Follow on Instagram
Subscribe on Youtube
Hi WelCome To My Website If you have a creative mind and want to learn Electronics even without studying it then FRIENDS this Website And Youtube Channel is for you, I am crazy creators who love making Electronics things. I have a bunch of more than 130 Tutorial Videos on My YouTube Channel and I upload a new Tutorial every Sunday.
Tags
Arduino Project
Esp32 Project
Esp8266 Project
0 Comments