paper title (use style: paper title)ijrar.org/papers/ijrar_223624.docx  · web...

10
SMARTECT SECURITY AND AUTOMATION USING IoT & IMAGE PROCESSING Mr. Kumar R Dept. of ISE MVJ College of Engineering Bangalore,India [email protected] Krishan Jangir Dept. of ISE MVJ College of Engineering Bangalore,India krishanjangir031998@gmail. com Deepak Jangir Dept. of ISE MVJ College of Engineering Bangalore,India [email protected] Yezdan R Dept. of ISE MVJ College of Engineering Bangalore,India [email protected] H S Rakshak Dept. of ISE MVJ College of Engineering Bangalore,India [email protected] Abstract - The Smartect Security and Automation system is aimed at providing smart security solutions to the average consumer. It becomes very tedious and sometimes impossible to prevent certain security mishaps such as trespassing, attempts of robbery and fire safety. Also, certain monotonous tasks such as opening and closing of gates, turning off of appliances, etc. can be automated to provide ease of access in our daily lives. Thus, Smartect aims at providing solutions to all of these through the use of technology such as the Arduino mega, Machine Learning concepts such as - Image Recognition, Deep Learning and Natural Language Processing. The system will be fed with photos of the home owner providing a biometric feature for access control and to detect trespassing, deep learning algorithms would be used to differentiate between trespassing humans and animals. Cryptographic Techniques such as block- chaining and hashing would also be used to secure this data and the IOT server as well. With time, the system would also be able to predict the building owner’s day to day pattern and hence further upgrading the system’s safety. Thus, Smartect aims at providing the complete package for all safety, security and ease of access needs. Keywords - Smartect, Arduino Mega, Application and camera. 1 INTRODUCTION In urbanization you think big, because you think decades ahead‖-Kushal Pal Singh. Consider this, over half of the world’s population lives in urban areas, it is expected by 2050 that this coefficient will grow to 66 per cent. Research tells us that on an average, people spend a high percentage of their lives inside buildings i.e. offices, schools and homes. Our entire lives revolve around these buildings and infrastructure. Buildings also represent one of the largest capital expenses for businesses, probably next only to the CTC‘s being paid to employees. The beginning of the industrial revolution signalled the beginning of a new era to the Homo sapiens with rapid development, a population explosion and increasing longevity in lives due to the development of science and technology. This trend continues in the modern area with the IOT and Artificial intelligence sparking a revolution this time around.

Upload: others

Post on 21-Sep-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

SMARTECT SECURITY AND AUTOMATION USING IoT & IMAGE PROCESSING

Mr. Kumar RDept. of ISE

MVJ College of EngineeringBangalore,India

[email protected]

Krishan JangirDept. of ISE

MVJ College of EngineeringBangalore,India

[email protected]

Deepak JangirDept. of ISE

MVJ College of EngineeringBangalore,India

[email protected]

Yezdan RDept. of ISE

MVJ College of EngineeringBangalore,India

[email protected]

H S RakshakDept. of ISE

MVJ College of EngineeringBangalore,India

[email protected]

Abstract - The Smartect Security and Automation system is aimed at providing smart security solutions to the average consumer. It becomes very tedious and sometimes impossible to prevent certain security mishaps such as trespassing, attempts of robbery and fire safety. Also, certain monotonous tasks such as opening and closing of gates, turning off of appliances, etc. can be automated to provide ease of access in our daily lives. Thus, Smartect aims at providing solutions to all of these through the use of technology such as the Arduino mega, Machine Learning concepts such as - Image Recognition, Deep Learning and Natural Language Processing. The system will be fed with photos of the home owner providing a biometric feature for access control and to detect trespassing, deep learning algorithms would be used to differentiate between trespassing humans and animals. Cryptographic Techniques such as block-chaining and hashing would also be used to secure this data and the IOT server as well. With time, the system would also be able to predict the building owner’s day to day pattern and hence further upgrading the system’s safety. Thus, Smartect aims at providing the complete package for all safety, security and ease of access needs.Keywords - Smartect, Arduino Mega, Application and camera.

1 INTRODUCTION

In urbanization you think big, because you think decades ahead‖-Kushal Pal Singh. Consider this, over half of the world’s population lives in urban areas, it is expected by 2050 that this coefficient will grow to 66 per cent. Research tells us that on an average, people spend a high percentage of their lives inside buildings i.e. offices, schools and homes. Our entire lives revolve around these buildings and infrastructure. Buildings also represent one of the largest capital expenses for businesses, probably next only to the CTC‘s being paid to employees. The beginning of the industrial revolution signalled the beginning of a new era to the Homo sapiens with rapid development, a population

explosion and increasing longevity in lives due to the development of science and technology. This trend continues in the modern area with the IOT and Artificial intelligence sparking a revolution this time around.

The coming decades will bring about a significant shift in the way buildings are developed and used. Land shortage will lead to a tendency to construct taller buildings and dig for space underground. Such type of buildings will give rise to new kinds of problems, one that challenges the safety and security of the people. It is to address these sorts of problems that modern technology must be used.The Internet of Things offers innovative solutions to meet these goals. Smart buildings harness IoT connectivity, sensors and the cloud storage to remotely monitor and control a range of building systems, right from HVAC systems to lighting and security systems. The ultimate aim is to get all the components of the buildings communicating with each other so that there is improved performance, ease of access and an overall feeling of safety. Why go smart? The future belongs to those who can continuingly use the available limited energy resources to the optimum, and saving on energy means saving on the expenses and bills. Lastly, the security of the human resource inside the building is better guarded through this wonderful new piece of technology.

Consider a situation where you are the last person to leave office, you suddenly realize that you have not locked your door or that you forgot to turn off the lights. To prevent you from getting the boot the next morning technology comes to your rescue. The smart door lock system kicks in and automatically locks he door once the last the resident is out of the building. Or supposing a burglar has intruded into your building space, it would prove to be a meal to find him, unless your compound safety mechanism kicks in and has eyes on him from the word go. Not only do you save time with these tactics but also make the entire process so very efficient. This is where IOT based smart buildings can really turn into a savior of sorts.

Page 2: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

Image recognition based on Deep Learning also enhances the access control mechanisms. Thus, it would further enhance the proposition that to maintain high levels of security, human intervention is no longer required. The security guard might easily be overpowered or undergo deception. But it is next to impossible to cheat the algorithms.

2 OBJECTIVE

The main objective of the proposed system is to develop a security module that can be implemented in a large-scale due to its economic feasibility, ease of access and a sense of reliability in the field of automated security.

3 RELATED WORK

Different steps for implementing Smartect Security and Automation system are presented below In “Design and Implementation of Security System [1] Facial Recognition using Open CV–Open Source Computer Vision is a library of programming functions mainly aimed at real-time computer vision. Its main functionality is to Read and write images. Facial Detection and detecting other key features of the face. Detection of shapes such as circles, rectangles etc. in images, to name a few. Data Gathering- This step involves extraction of unique features of a person’s face that can be used to differentiate him from another person. Trainer- The data from the dataset is taken and is used to train the open CV module. This is done with the help of a specific training module. Recognition-Here a face is captured on the camera and if this face was already captured before, the recognizer returns a “prediction” marking the face with an id and also marking the accuracy of the match.

In “Smartect Security and Automation system”, [2] Motion Sensor – OpenCV is again used for motion detection. The basic principle behind motion detection in cameras is to differentiate between the foreground and background.i.e.to discern between small lighting changes and actual motion. we plan to implement is a camera that turns on only when it detects motion and click pictures when any sort of motion is detected. Training of the system will first be only the background. Subsequently it would be trained with other objects in the image to improve accuracy of detection. Also integrated is a drop-box account which would store the photos taken. All of these steps are done to improve storage efficiency of our system.

In “Smartect Security and Automation system”, [3] Fire Safety Mechanism –This system is equipped with smoke and flame sensor. When a fire is sensed, this system automatically unlocks the door and opens the windows to remove the excess smoke. The system would reduce and limit the building’s electric supply to only emergency lights to reduce further damages. The nearest fire station would be contacted automatically for assistance. This system has two-fold mechanisms for fire detection, thus preventing any false

positive alarms. The flame sensor will generate certain output on detection of flame. Measured input from the Sensor is then fed to the amplifier. Amplifier then sends analog data to the analog output pin of the module. In this, we are going to interface LED using the Flame Sensor Module KY-026 in Raspberry Pi.

In “Smart Security and Automation system”, [4] Human Detection – Digital image processing by using the package and features of OpenCV library and coded with one of the high-level languages like Python and is booted with the help of a Raspberry Pi microcontroller. This is fitted with a RaspiCam to capture the motion images of objects passing through it. The model utilizes image samples in top-view or even over-view and predefined models containing to great numbers motion variations are set, which helps in identification of humans entering the surroundings. A set of Passive Infra-Red (PIR) sensors are installed to instruct the system to capture images of a person or an object that crosses it (passes around it). This system of human detection is combined with sensor feedback mechanism which is being used along with the capability to send data to local servers via Bluetooth signals.

In “Smart Security and Automation system”, [5] Encryption module –We Using the python library called “cryptography” and a packet named “fornet”, we encrypt the needed files. The files we would be encrypting here are the photos of the user. The module generates a 32-bit hash key, which is stored in a file in storage and retrieved when necessary. Thus, keeping in mind with privacy laws all over the world.

In “IoT Application Development: Home Security System” [6], The proposed solution makes use of USB Webcam as an image capturing unit, Electric Door Strike as an actuator and Telegram which has an amazing feature as Telegram Bot which provide APIs to build solutions which is compatible with Raspberry Pi IoT infrastructure.

In "Web-based online embedded door access control and home security system based on face recognition," [7] The paper describes about the implementation and deployment of wireless control system and accessibility in to a home environment for authenticated people only. A wireless network technique, ZigBee and image processing technique PCA based, dedicatedly make the security system alive as per the request.

In “Smart Home Automation using Arduino UNO Microcontroller”, it describes he design and prototype implementation of Smart Home Automation System is proposed. The system incorporates microcontroller and Bluetooth module to provide automation capability to various household activities. A microcontroller offers high performance and flexibility.

In” Embodiment of IOT based Smart Home Security System” [9], paper reflects on the IoT base Smart Home System as well as home security System. built is low-cost smart home operated by Android application wirelessly inside the home and also from anywhere in the world using GSM system. Smart electrical monitoring system where

Page 3: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

user can operate wirelessly their light, fan, TV, freeze etc. smart Security system where user can maintain the security system using application even, he/she can get any type security alert living anywhere in the world Smart gardening system using android application and GSM system has been developed.

4 METHODOLOGY

In this section we will discuss the methodology that we are using to avoid accidents block diagram of the proposed system is shown below

Fig 4.1 Block Diagram of Face Recognition/Pedestrian System

4.1 Block Diagram DescriptionThis project mainly contains two modules

4.1.1 Arduino Mega: The Arduino Mega is mainly based on microcontroller board of ATmega2560. In this proposed system, the Arduino mega connects all the sensors and the body of the robot which helps the microcontroller control the movement and the functionalities of the robot.

4.1.2 Arduino Uno:The Arduino Uno is an open-source microcontroller board based on the Microchip ATmega328P microcontroller and developed by Arduino.cc. The board is equipped with sets of digital and analog input/output pins that may be interfaced to various expansion boards and other circuits.

5. SYSTEM HARDWARE AND SOFTWARE CONFIGURATION

5.1 Hardware Components

5.1.1 Arduino Mega 2560 REV3

Fig 5.1 Arduino Mega 2560 REV3

The Arduino Mega 2560 is a Board based on the ATmega2560 microcontroller. It has 54 digital input / output pins (of which 15 could be used as PWM outputs), 16 analog inputs, four UARTs (hardware serial ports), a 16 MHz crystal oscillator, a USB link, a power jack, an ICSP header and a reset button. It comprises everything you need to help the microcontroller; just connect it to a computer using a USB cable or power it with AC to DC Adapter or a battery

5.1.2 Arduino Uno REV3

Fig 5.2 Arduino Uno REV3

Arduino Uno is a board based on the ATmega328P (datasheet) Microcontroller. It has 14 digital input / output pins (of which 6 can be used as PWM outputs), 6 analog inputs, a 16 MHz ceramic resonator (CSTCE16M0V53-R0), a USB interface, a power jack, an ICSP header and a reset button. It contains all the requirements to support the microcontroller; just connect it to a computer with a USB cable or power it with AC to DC Adapter or with a Battery.

5.1.3 MQ2 Gas Sensor

Gas sensor module (MQ2) is useful for detecting gas leakage (in home and industry). Combustible gas and smoke can be observed. The Gas sensor output voltage increases as gas concentrations rise. Rotating the potentiometer will change the sensitivity.

Page 4: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

Fig 5.3 MQ2 Gas Sensor

5.1.4 Flame Sensor

Fig 5.4 Flame Sensor

Flame Sensor can be used in the range of 760 nm- 1100 nm to detect fire source or other wave length light sources. It is based on the YG1006 sensor which is a high speed NPN silicone phototransistor with high sensitivity. The sensor is sensitive to infrared radiation due to its black epoxy. Sensor can be a great addition to locating the source of fire in a fire fighting system, it can be used as a system eye. The Signal LED will light up when the sensor detects flame and the D0 pin goes LOW.

5.1.5 PIR Sensor

Fig 5.5 PIR SensorPIR sensors allow you to sense motion, which is almost often used to detect whether a person has moved inside or beyond the range of sensors. They're small, inexpensive, low-powered, easy to use and don't wear out. They are most commonly used in appliances and gadgets which are used in homes or businesses. They are also called PIR, "Passive Infrared," "Pyroelectric," or "IR Motion" Sensors.

5.1.6 Fire Extinguisher

Fig 5.6 Fire Extinguisher

A fire extinguisher is an external fire safety system used, often in emergencies, to extinguish or prevent small fires. This is not intended for use on an out - of -control fire, such as one that has reached the ceiling, endangering the user or otherwise needing a fire brigade's expertise.

5.1.7 16x2 LCD Display

Fig 5.7 16x2 LCD Display

An LCD is a flat-panel screen or other electronically modulated optical device that uses the light-modulating properties of liquid crystals in conjunction with polarizers. Liquid crystals do not specifically emit light; rather, they use a backlight or reflector to create colored or monochrome images.

5.1.8 CCTV

Fig 5.8 CCTVClosed-circuit television, also known as video surveillance, is the use of video cameras to relay a signal over a small range of monitors to a particular location.

Page 5: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

5.1.9 SG90 Servo Motor

Fig 5.9 SG90 Servo MotorA servo motor is an electric device that can precisely move or rotate an object. When you want to rotate and object at a certain angle or distance, then you use a servo motor. It consists of a basic motor running via the servo mechanism.

5.1.10 MFRC-522 RC522 RFID

Fig 5.10 RC522 RFID

The MFRC522 is a highly integrated reader or writer IC that supports ISO / IEC 14443 A / MIFARE mode for contactless communication at 13.56 MHz The MFRC522 reader. Without additional active circuitry, the internal transmitter of the MFRC522 can drive a reader or writer antenna designed to communicate with ISO / IEC 14443 A / MIFARE cards and transponders. The receiver module provides reliable and efficient implementation for ISO / IEC 14443 A / MIFARE compatible cards and transponders to demodulate and decode the signals. The digital module administers the full functionality of ISO / IEC 14443 A framing and error detection (parity and CRC).

5.1.11 LEDs

Fig 5.11 LED

A light-emitting diode is a light source with a semiconductor that emits light as the current flows through it. In the semiconductor, electrons recombine with holes in the nucleus, releasing energy in the form of photons.

5.1.11 Breadboard

Fig 5.12 Breadboard

A breadboard is a plastic rectangular board with a set of tiny holes inside it. These holes allow you to easily insert electronic components to prototype (meaning building and testing an early prototype of) an electronic circuit, such as this one with a battery, switch, resistor, and LED (light-emitting diode).

5.1.12 Jumper Cables

Fig 5.13 Jumper Cables

Jumper wires are simply wires with connector pins at either end, so that they can be used to connect two points without soldering each other. Usually, jumper wires are used with breadboards and other prototyping devices to make adjustments to a circuit as needed simple.

6 EXPERIMENTAL RESULTS6.1 Snapshot 1: Overall Project Snapshot

Page 6: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

Fig 6.1 Overall Project Snapshot

6.2 Snapshot 2: Smoke Sensor & Flame Sensor – Fire Safety Module

Fig 6.2 Working of Smoke SensorThe smoke and flame sensors are placed in the room where there is a high chance of fire for example kitchens, laboratories, indoor fireplaces etc. The smoke and flame sensors keep sensing for smoke, gas leakage & fire 24/7. The sensors are triggered when they sense smoke or fire (flame). Also, to prevent false positives in case of smoke produced due to Incense Sticks or any other reason, we have implemented an image recognition module that detects the incoming video frame and converts it to frames. It then converts the video into HSV colour space which is closer to how humans perceive colour and then takes it takes an upper and lower range of orange colour and shows pixels detected in that range. Once smoke or fire is sensed, the data is sent to the Arduino Mega 2560 REV3 for processing and the Arduino is automated to take further actions. The Arduino is programmed to limit the power supply of the building to prevent further damages. Emergency LEDs are used as they consume less power. The windows of the building are automatically opened

to remove excess smoke. An exhaust fan is also switched on to remove excess smoke from the building

6.3 Snapshot 3: Automated Fire Extinguisher

Fig 6.3 Shows the Woking of the Automated Fire

Extinguisher and Displays Messages

6.4 Snapshot 4: Face Recognition & RFID

Fig 6.7 Shows the Working of Face Recognition &

RFID ModuleA camera (mobile phone/webcam) is placed at the entrance. This immediately captures a photo when the user clicks on the capture button in the GUI. To protect the privacy of the individual and according to the GDPR, the photo is also encrypted and stored in the database. The photo is then sent to the OpenCV module used for image recognition. An RFID is also setup as an alternative.

6.5 Snapshot 5: Human Recognition

Fig 6.5 Shows the Working of Human/Pedestrian Recognition Module

To prevent unauthorized entry of people, cameras are placed near the compounds. These cameras are activated when motion is detected by the motion sensors, and clicks several photos of the intruder as soon as an alert is sounded. All the images are stored in a folder and the and folder undergoes extraction of positive and negative images. This model is done using OpenCV2. The model is trained in such a way as to detect for people in the given photographs. It makes a box around the figures detected in the image and writes

Page 7: Paper Title (use style: paper title)ijrar.org/papers/IJRAR_223624.docx  · Web viewBangalore,Indiakrishanjangir031998@ ... The model utilizes image samples in top-view or even over-view

output frames to disk. Background subtraction is done in the image and compared with the original image. It finally alerts the user if intrusion (humans) are detected and hence if animals/birds are not detected.

6.6 Snapshot 6: Encryption/Decryption Key

Encryption is the process of encoding a message or information in such a way that only authorized parties can access it and those who are not authorized cannot. Encryption does not itself prevent interference but denies the intelligible content to a would-be interceptor. Using the python library called “cryptography” and a packet named “fornet”, we encrypt the needed files.

6.7 Snapshot 7: Application GUI

Fig 6.7 Shows the GUI Application & Controller

Tcl/Tk has long been an integral part of Python. It provides a robust and platform independent windowing toolkit, that is available to Python programmers using the Tkinter package, and its extension, the Tkinter.tix and the Tkinter.ttk modules.

7 CONCLUSION

In this project, we investigate the problem of Smart buildings using IOT. Existing solutions are either limited to a specific setting of the problem, or incur expensive, redundant computations. Hence, we propose novel and efficient solutions.

In the future, we plan to develop a much more efficient smart building system, with fewer expenses while continuingly emphasizing on the Do It Yourself (DIY) trend. We also plan to be more tech savvy and implement more futuristic systems in the future.

8 REFERENCES

[1] Sourav Roy, Md Nasir Uddin, Md Zahirul Haque, Md Jahidul Kabir, Ohsung Doh, Ilkyu Ha. Smart Door Lock System with Face Recognition Method. Nanjing University of Posts and Telecommunications, China (December 2018). In, Kyungil University, Gyeongsan, Gamasil-gil 50, 712-701, Republic of Korea

[2] Narasimha Prasad, L V Shankar Murthy P, Kishor Kumar Reddy C. Analysis of Magnitude for Earthquake Detection using Primary Waves and Secondary Waves. In, International Conference on Human Computer Interactions (ICHCI) in September 2014, IEEE.

[3] AJAYI Olasupo Opeyemi, OLAIFA Oluwaseun. Detecting Intrusion in Large Farm Lands and Plantations in Nigeria Using Virtual Fences. In, University of Lagos, Nigeria, 2016

[4] R. Angeline, Adithya S, Abishek Narayanan. Fire Alarm System Using IOT. In, International Journal of Innovative Technology and Exploring Engineering (IJITEE), Volume-8, Issue-6S3, April 2019.

[5] Md. Wahidur Rahman, Md. Harun-Ar-RashidRahabul Islam, Dr. Mohammad Motiur Rahman. Embodiment of IOT based Smart Home Security System. In, International Journal for Research in Applied Science & Engineering Technology (IJRASET) ISSN: 2321-9653; IC Value: 45.98; SJ Impact Factor: 6.887; Volume 6 Issue IX, Sep 2018.

[6] Shafana A.R.F, Aridharshan A. Android based Automation and Security System for Smart Homes. International Journal of Computer Science and Information Technology Research ISSN 2348-1196; Vol. 5, Issue 3, pp: (26-30), Month: July - September 2017.

[7] Neetu Anand, Piyush Mankad. Smart Home Automation using Arduino UNO Microcontroller. In, International Journal of Scientific Research in Computer Science, Engineering and Information Technology © 2017 IJSRCSEIT | Volume 2 | Issue 6 | ISSN: 2456-3307).

[8] Ali Dorri, Salil S. Kanhere, Raja Jurdak and Praveen Gauravaram. Blockchain for IoT Security and Privacy. In, The University of New South Wales Sydney, Australia & CSIRO, March 2017.

[9] Mrutyunjaya Sahani, Chiranjiv Nanda, Abhijeet Kumar Sahu and Biswajeet Pattnaik. Web-Based Online Embedded Door Access Control and Home Security System Based on Face Recognition. In, International Conference On Circuit, Power and Computing [ICCPCT], 2015.

[10] Dr. Rajeshwari M Banakar, Raj G Anvekar. IoT Application Development: Home Security System. In, IEEE Technological Innovations in ICT for agricultural and Rural Development(TIAR), 2017.