Home Automation and Security System Using IOT

Home Automation and Security System Using IOT

Naralasetti VeeranjaneyuluGavini Srivalli Jyostna Devi Bodapati

Department of IT, Vignan’s Foundation for Science, Technology and Research, Vadlamudi, Guntur, AP, India

MCA student, Vignan’s Foundation for Science, Technology and Research, Vadlamudi, Guntur, AP, India

Department of CSE, Vignan’s Foundation for Science, Technology and Research, Vadlamudi, Guntur, AP, India

Corresponding Author Email: 
veeru2006n@gmail.com
Page: 
21-24
|
DOI: 
https://doi.org/10.18280/ria.330104
Received: 
12 October 2018
|
Revised: 
20 January 2019
|
Accepted: 
26 January 2019
|
Available online: 
1 May 2019
| Citation

OPEN ACCESS

Abstract: 

It is needless to say the importance of automation and security systems in the present era. In this paper we propose simple solutions for automation of electrical appliances and home security. We propose to control automatic turn on and turn off of electrical appliances like electric bulb, Air conditioner, electric fan etc.; with respect to the human motion detection rather than using manual switch on/off system. Another solution is controlling the Air conditioner temperature depending on the room temperature. We propose another function to provide security. In all these applications, the Arduino Uno processing unit is used, along with 3 different sensors. To detect the human presence PIR (Passive Infrared) Sensor is used, temperature sensor (LM35) is used to detect the room temperature and Ultrasonic (HC-SR04) sensor is used to detect the presence of objects. If there is any human movement it is detected by the PIR Sensor and the lights will turn on. If the room temperature is above the given temperature set, it is detected by the temperature sensor and the Air conditioner will turn on directly. If there is any object that is detected by the ultrasonic sensor it is detected by the sensor and a buzzer is set that starts emitting sound.

Keywords: 

Arduino Uno, PIR sensor, LM35 sensor, ultrasonic sensor, relay

1. Introduction

In India, it is very common to see manual operation of electrical equipment (lights, AC, fans, etc.) [1]. It is still common to use manual switching system to operate electric gadgets. It is very common for people to forget to switch off the gadgets after usage as people are so busy with many different works. After leaving home also people keep thinking about whether they switched off the gadgets properly or it. To help the people it is very much helpful if we can provide automation systems for these problems [2]. The only way to overcome these types of problems is to provide automatic systems and security systems [3]. In this paper we have proposed three different simple solutions to automate the system.

The first solution is to automatically switch on and switch off the electric gadgets according to human moment detection. Another solution to provide security by detecting an unknown object is moving in front of the sensor. When an unknown object is detected then the sound waves are generated and then buzzer starts emitting sound. Another simple solution is setting the cooling system of an air conditioner. This will allow the air conditioner to turn on according to the temperature.

To automate the above functions 3 different sensors are used [4]. A Passive Infrared Sensor is used to detect the human motion when the person enters to the room. This triggers the electric gadgets to turn on. These sensors are connected to fans, Air conditioners and electrical bulbs. A temperature sensor (LM35) is use to detect the room temperature and this makes the air conditioner to turn on when the room temperature exceeds 30 °C. Temperature Sensor is used to detect the temperature of the room [5]. The ultrasonic sensor detects the radiation when the person wants to enter the room alarm and when detects something unknown then buzzer starts emitting a sound.

2. Home Automation

Power is supplied to the Arduino processor. The sensors, Temperature Sensor, Ultrasonic sensor and PIR Sensor are given as Input to the Arduino and the result can be seen with the help of Output devices [6]. Light, Ac and Buzzer act as output devices. The source code is written in the Arduino IDE software will be dumped to the Arduino Software.  The temperature sensor helps to detect the room temperature and if the temperature is above the given temperature that is set then the air conditioner is turned on automatically otherwise the AC is in turn off mode [7]. PIR Sensor helps to detect the human movement and if there is any human movement then the Lights will be automatically turn on otherwise it is in turn off mode [8]. Ultrasonic sensor helps to detect unknown object movements and the sound waves then buzzer starts emitting a sound [9]. 

2.1 Arduino Uno processor

The Arduino Uno is an open source microcontroller. The board consists of 14 Digital pins and 6 analog pins which can be used as pulse width modulation outputs [10]. In addition it also contains a 16 MHz ceramic resonator, an ICSP (In Circuit Serial Programming) header, a USB connection, a Power jack and a reset button. Each pin of the Arduino Uno is operated at 5V [11].

Figure 1. Arduino Uno 

Figure 1 Shows the processor used in the home automation system. It is the Arduino Uno processor. Figure 2 shows the block diagram of the home automation and security system. It shows the input, processing and output devices of the proposed system. Power supply is given to the processor unit.

Figure 2. Block diagram of Proposed system 

PIR Sensor: PIR Sensor is a Passive Infrared sensor which is also called as IR (infrared) motion sensor. The specialty of this PIR sensor is it is little, works with little power, affordable and easy to use. The actual detection range is between 5 m to 12 m. It can detect a human movement within distance from 10 m from the sensor. This sensor is used in many home automation applications. Figure 3 shows a snap of this PIR sensor.

LM35 Sensor: The LM35 are precision integrated circuit temperature devices. This sensor range is from -55 °C to 150 °C. That is it can detect temperatures with in the range of -55 °C to 150 °C. This sensor works better than a thermostat. Measures the temperature more accurately than a thermistor. The output varies by 10mv in response to every 1 °C rise and fall in temperature. Figure 4 shows a picture of this LM35 sensor.

Figure 3. PIR sensor

Figure 4. LM35 sensor

Ultrasonic Sensor (HC-SR04): Ultrasonic sensor iacts as a transmitter and a receiver. It is an instrument that measures the distance based on the time required. It works by emitting sound waves at a frequency too high for humans to hear.  Some sensors use a separate sound emitter and receiver, it is possible to combine these into one device. Figure 5 shows a clear picture of this sensor.

 

Figure 5. Ultrasonic sensor (HC-SR04)

Relay Module: A relay is an electrically operated switch that can be turned on or off. this device is used in power protection. This can be used for both AC and DC systems. This device is small, long time reliable, stable. It controls higher voltage. Figure 6 shows the relay module.

Figure 6. Relay module

Figure 7 shows the assembling of all the devices together to build the home automation and security system that is proposed.

Figure 7. Home automation and security kit

3. Assembling the Hardwares

In this work First, we implement the code for the required functionalities with the help of Arduino IDE. Arduino IDE is the basic environment to write Arduino integrated development environment. It supports different programming languages like JAVA, C and C++. Each program in the Arduino has two common functions that are used as mandatory. The first foremost function is setup() function and another one is loop() function. The setup() function contain the relay pins and digital pins of a program. The loop() function contain main process of the program and it is the heart of the program. The Arduino software helps to inbuild the program to the hardware. Below we describe how the different sensors are connected to the processors.

The PIR (Passive Infrared) sensor that contains three pins (Ground, Output, VCC) is connected with the help of jumper wire. The Ground of PIR Sensor is connected to the positive position of the power rail of the breadboard. Output pin is connected to the Arduino pin that we have given in the source code. VCC is connected to the negative of the power rail of the breadboard.

Temperature sensor is connected to the compound rail of breadboard. Relay Module contains three pins (Gnd, IN1, VCC). The Ground of the relay is connected to the positive part of breadboard. The IN1 is connected to the Arduino pin. VCC is connected to the compound rail.

Ultrasonic Sensor has four pins (VCC, Trig, Echo, Gnd). This sensor is used as a distance sensor. The VCC of the ultrasonic sensor is connected to 5V pin of the Arduino. The Trig pin of the ultrasonic sensor is connected to the Arduino pin. The Echo pin of the ultrasonic sensor is connected to the Arduino pin. The Ground of the ultrasonic sensor pin is connected to the Arduino Ground pin.

Buzzer has two pins. Buzzer positive pin is connected to the Arduino pin buzzer negative pin is connected to the negative channel of the breadboard.

After completion of all the above steps the source code will be dumped to the Arduino Uno hardware with the help Arduino software through USB cable.

4. Experimental Results

Automation of electric bulb operation: We can check the result with the help of serial monitor by giving a motion in front of PIR Sensor if there is a motion the light will turn on automatically if there is no motion then the light will be turned off.

Automation of AC operation based on human motion and preset temperature: If there is any human motion is detected and if the temperature is more than the preset temperature, then the AC will be automatically turned on. If the temperature is less than the preset temperature then the AC will be turned off.

If there is any detection of human motion and the room temperature is less than the preset temperature then the AC will be in the turn off mode. If temperature exceeds the preset temperature and if there is no human motion detected then also AC is in turn off mode.

Simple Security system: The Ultrasonic Sensor emits the presence of any object in front of the door. The ultrasonic sensor consists of transmitter and receiver. The maximum distance is measured by it is set to 4 meters. If any unknown person comes within 2 meters of the door then the buzzer should ring. One is used to transmit the ultrasonic wave and other one receives it. Anyone comes in the range of ultrasonic sensor, Arduino detects the distance from object to the sensor. If the object is within the range it sends the signals to buzzer and buzzer starts beeping. Arduino timestamp set the time for sensor with in the given time. By using the Arduino timestamp we can set the time for sensor, when the sensor detects object then it sends the indication. The sensor detects the objects within the range and sends the indication. If there is no object is moving within the range the sensor it can’t recognize sound waves, then the buzzer is not ringing.

Note: If the relay is on then the power is supplied. and if the relay is off then there is no power supply.

5. Conclusion

This paper proposes the design and construction of home automation and security system using temperature sensor, PIR sensor and Ultrasonic Sensor. The temperature sensor measures the room temperature when the person enters the room temperature. If the temperature exceeds the preset temperature then the air conditioner will be turned on automatically. PIR Sensor detects the presence of human. Ultrasonic Sensor senses the ultrasonic waves in the range of the sensor. If there is any object that is detected in the given time then the buzzer beeps. The object is not detected by the sensor the buzzer will not ring.  The Arduino is successfully programmed in C/C++.

  References

[1] Mahalakshmi, G, Vigneswaran, M. (2017). IOT based home automation using Arduino. International Journal of Engineering and Advanced Research Technology (IJEART), 3(8): 7-11.

[2] John, S.N., Ndujiuba, C., Oluwaseyi, O.I., Onyinye, I.C. (2012). Design and implementation of a microprocessor-based temperature controller with real time display. In Proceedings of International Conference Comp. Energy, Net., Robotics and Telecom, pp. 14-18.

[3] Hitu, B., Mathew, L., Gupta, A. (2015). Controlling of temperature and humidity for an infant incubator using microcontroller. International Journal of Advanced Research in Electrical and Electronics and Instrumental Engineering, 4(6): 4975-4982. https://doi.org/10.592310.15662/ijareeie.2015.0406012

[4] Amoo, A.L., Guda, H.A., Sambo, H.A., Soh, T.L.G. (2014). Design and implementation of a room temperature control system: Microcontroller based. In Proceedings of IEEE Student Conference on Research and Development. https://doi.org/10.1109/SCORED.2014.7072989

[5] Prince, N.N., Theophilus, A., Daniel, A.O., Vincent, N. (2014). Design and implementation of microcontroller based automatic fan speed regulator. International Journal of Engineering Research and Management, 1(5): 202-208. 

[6] Javale, D., Mohsin, M., Nandanwar, S., Shingate, M. (21013). Home automation and security system using android ADK. International Journal of Electronics Communication and Computer Technology, 3(2): 411-440.

[7] Sasikala, V. (2012). Design and implementation of smart house control using Lab view. International Journal of Soft Computing and Engineering, 1(6): 2231-2307.

[8] Chan, M., Campo, E., Estève, D., Fourniols, J.Y. (2009). Smart homes current features and future perspectives. The European Menopause Journal, 64(2): 90-97. https://doi.org/10.1016 /j.maturitas.2009.07.014

[9] Kaur, I. (2011). Microcontroller based home automation system with security. International Journal of Advanced Computer Science and Applications, 1(6). https://doi.org/10.14569/IJACSA.2010.010610

[10] Natarajan, A.P. (2011). Home automation and security for mobile devices. International Conference on Electrical, Instrumentation & Communication Engineering Recent Trends and Research Issues ICE2- RTRI 2015, At Department of Electrical Sciences, Sri Krishna Institutions, Coimbatore, 141-146.

[11] Piyare, R. (2013). Internet of things: Ubiquitous home control and monitoring system using android based smart phone. International Journal of Internet of Things, 2(1): 5-11. https://doi.org/10.5923/j.ijit.20130201.02