It's a alert system which will provide real-time alert on fire or LPG gas Leak in your house and it will monitor the house temperature and Methane ppm concentration in air via a Web portal. If the sensor records more than 60 degree temperature or 1000 ppm (you can modify on script) of methane concentration then it would send directly sms alert to the registered mobile number.
- Raspberry Pi
- ADC121C_MQ4 (Measure Methane Concentration in PPM)
- DHT-11 (Measure Temperature)
- GSM module (To send SMS)
First raspbian os needs to be installed on SD card then run the following codes
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install python-pip
sudo apt-get install build-essential libi2c-dev i2c-tools python-dev libffi-dev
sudo python -m pip install --upgrade pip setuptools wheel
sudo pip install cffi
sudo pip install smbus-cffi
sudo pip install Adafruit_DHT
git clone https://github.com/sakearzoo/Smart_Alert_System.git && cd Smart_Alert_System
chmod +x fire.py
chmod +x gas.py
chmod +x main.py
After then you need to modify the connect.php
file with proper credentials, Add your phone number to fire.py
and gas.py
and finally update the main.py
with proper website address.
To run the script you need to enter th following code:
Sudo ./main.py
or
sudo python main.py