Blynk Fire Alarm
Hey There, Welcome back to another interesting article based on NodeMCU. Today in this article we'll not only use NodeMCU but also link it with the BLYNK App which can easily be downloaded from PlayStore and App Store. This project uses constant Wi-Fi connection to deliver fire notification to the respected device. The main components used in this project is NodeMCU, Flame sensor & BLYNK App.
Whenever there is fire there is emission of Infrared spectrum which can be detected by any infrared cameras and detectors. But these seem to be very costly, to lesser the cost we use IR receiver led or photo diode to receive the infrared spectrum emitted by fire. Photo diode is not very effecting as other imaging devices. But it can be used for this purpose.
For more information related to this project visit its original posts and also bookmark website for more such article in future before they appear on Instructables.
Material Required
- NodeMCU (ESP8266 MOD)
- Flame sensor
- Jumper wires
- Breadboard
- Phone with Wi-Fi connection
Circuit Diagram
Code
//TECHATRONIC.COM // BLYNK LIBRARY // https://github.com/blynkkk/blynk-library // ESP8266 LIBRARY // https://github.com/ekstrand/ESP8266wifi #define BLYNK_PRINT Serial #include <ESP8266WiFi.h> #include <BlynkSimpleEsp8266.h> BlynkTimer timer; char auth[] = "your-auth-code"; //Auth code sent via Email char ssid[] = "your-wifi-ssid"; //Wifi name char pass[] = "your-wifi-password"; //Wifi Password int flag=0; void notifyOnFire() { int isButtonPressed = digitalRead(D1); if (isButtonPressed==1 && flag==0) { Serial.println("Fire DETECTED"); Blynk.notify("Alert : Fire detected"); flag=1; } else if (isButtonPressed==0) { flag=0; } } void setup() { Serial.begin(9600); Blynk.begin(auth, ssid, pass); pinMode(D1,INPUT_PULLUP); timer.setInterval(1000L,notifyOnFire); } void loop() { Blynk.run(); timer.run(); }
For further reading about installing and setting up BLYNK App also for code explanation visit its original post also for any issue either comment down below or on the original website.