You are on page 1of 6

Y. Zhao and Z.

Ye: A Low Cost GSM/GPRS Based Wireless Home Security System

567

A Low Cost GSM/GPRS Based Wireless Home Security System


Yanbo Zhao and Zhaohui Ye
Abstract Home security system is needed for occupants convenience and safety. In this paper, we present the design and implementation of a low cost, low power consumption, and GSM/GPRS (Global System for Mobile Communication /General Packet Radio Service) based wireless home security system. The system is a wireless home network which contains a GSM/GPRS gateway and three kinds of wireless security sensor nodes that are door security nodes, infrared security nodes and fire alarm nodes. The nodes are easy installing. The system can response rapidly to alarm incidents and has a friendly user interface including a LCD (Liquid Crystal Display) and a capacitive sensor keyboard. The wireless communication protocol between the gateway and the nodes is also suitable for other home appliances. Furthermore, some methods are taken to ensure the security of system information.
Index Terms Security, GSM/GPRS, Wireless
I.

INTRODUCTION

THERE is a growing interest in intelligent home network as a way to offer a comfortable, convenient and safe environment for occupants [1]. In order to enhance the occupants convenience and safety, home security system is indispensable in the field of intelligent home network. The requirements of a home security system include low cost, low power consumption, easy installation and rapid response to alarm incidents. According to connecting mode, home network can be divided into two kinds: wireless network and non-wireless network [2]. The wireless technology has some remarkable benefits comparing with non-wireless technology. For example, it makes the installation and maintenance easier and reduces the system cost. Bluetooth [3], ZigBee [4], [5], 802.11 [6] and wireless USB [7] are the most popular technologies in the field of home wireless network. [3] introduces a method to form a home network which provides flexible and dynamic services via Bluetooth. However, the system mentioned in [3] is high power consumption and high cost so that it is not convenient to use in security system. [4] and [5] present how to apply ZigBee/IEEE802.15.4 to establish a home network that is costeffective and low power consumption. However,
Yanbo Zhao is with the Department of Automation, Tsinghua University, Beijing, China (Email: zhao-yb06@mails.tsinghua.edu.cn). Zhaohui Ye is with the Department of Automation, Tsinghua University, Beijing, China (Email: yezhaohui@mail.tsinghua.edu.cn).

[4] and [5] dont present the implementation. Wireless home network based on the IEEE802.11 standard, also known as WiFi, provides a good solution for many home network needs such as transferring file and media date [6], but this standard is also high cost and high power consumption. [7] presents the design of a home network using a wireless USB controller that offers several benefits such as low cost, expandability and outstanding performance. Wireless USB can also be used in home security system. How to inform user in real time when alarm incidents occur has become a crucial feature of home security system. This can be done via internet or GSM/GPRS. GSM/GPRS is more convenient than internet. The main reason is that the GSM/GPRS network has wide spread coverage making the whole system available for almost all the time. Furthermore, GSM/GPRS network has high security infrastructure which makes sure that the information sent or received cannot be monitored [8]. The network examples mentioned in [3], [5], [6] and [7] send the information to remote users via internet. [8] and [9] are examples of home systems using GSM/GPRS network for remote controlling. However, [8] only illustrates that GSM is communication method between remote user and home network server but doesnt apply it to home security system. The system in [9] only applies GSM/GPRS technology to intrusion detecting and its communication is non-wireless. In this paper, a low cost GSM/GPRS based wireless home security system is presented. The system includes two parts: wireless security sensor nodes and a GSM/GPRS gateway. It has the following features: (1) Low cost. All the microprocessors used in the sensor nodes and the gateway are cheap 8-bit microprocessors, and all other devices are inexpensive. (2) Low power consumption. All security sensor nodes are powered by batteries. (3) Easy installing. Because the nodes communicate with the gateway by wireless, they can be installed anywhere inside the home. (4) Rapid response. The GSM/GPRS gateway will send SMS (Short Message Service) messages to inform remote PMP (Property Management Person) and users when alarm incidents occur. (5) Friendly user interface. The system has a friendly user interface including sixteen capacitive sensor keys and a LCD. Users can view the states of security sensor nodes, modify password of the gateway and change the mobile phone number for receiving the alarm messages. (6) Emergency alarm function. There is an emergency alarm key (SOS key) in the GSM/GPRS gateway which makes users at home to alarm in emergency situations.

Manuscript received December 6, 2007

0098 3063/08/$20.00 2008 IEEE

568

IEEE Transactions on Consumer Electronics, Vol. 54, No. 2, MAY 2008

(7) Information security method. In order to ensure the security of system information, some security methods are taken, such as a password for gateway to prevent unauthorized person to access the system, and a pseudo security key for data encryption and decryption to ensure security wireless communication. The paper is organized as follows. Section II presents the general structure of the proposed system, as well as its main features and components. Section III shows the design of GSM/GPRS gateway and Section IV shows the design of security sensor nodes. Section V discusses the communication between the gateway and the security sensor nodes. In Section VI, the preliminary experimental functions of the system are shown and, finally, in Section VII, conclusions are presented, referring perspectives for future work. II. THE HOME SECURITY SYSTEM The general structure of the home security system is shown in Fig. 1. The system includes two parts: wireless security sensor nodes and a GSM/GPRS gateway. There are three kinds of sensor nodes in this system: door security nodes, infrared security nodes and fire alarm nodes. The GSM/GPRS module is the interface between the gateway and the GSM/GPRS network.

PSoC device which reduces the design complexity of capacitive sensor keyboard in the system. The wireless data transfer between gateway and sensor nodes is implemented with a wireless transceiver module. The module operates in the unlicensed worldwide 2.4GHz ISM (Industrial, Scientific and Medical) band and has many excellent features: (1) low power consumption, 21mA operating current and sleep current less than 1A; (2) DSSS (Direct Sequence Spread Spectrum) data rates up to 250kbps, GFSK (Gaussian Frequency Shift Keying) data rate of 1 Mbps; (3) Operating range is 10m plus; (4) 4 MHz SPI (Serial Peripheral Interface) microcontroller interface. III. THE GSM/GPRS GATEWAY A. Hardware of GSM/GPRS Gateway The diagram of the hardware of GSM/GPRS gateway is shown in Fig. 2. The GSM/GPRS gateway contains six major components: (1) Microprocessors, including I and II; (2) Wireless transceiver module; (3) LCD; (4) LEDs (Light Emitting Diodes) and a buzzer; (5) Capacitive sensor keyboard; (6) GSM/GPRS module.

GSM/GPRS gateway

UART interface

Security nodes

SMS GSM/GPRS module The mobile phone of remote user Fig. 2. The diagram of GSM/GPRS gateway

Fig. 1. The structure of home security system

The microprocessor used in this system is 8-bit PSoC (Programmable System on Chip) device. There are three reasons to use this device. Firstly, it makes the design easier and reduces system cost. It has configurable analog and digital blocks, as well as programmable interconnects logic. This architecture allows users to create customized peripherals such as filters, amplifiers, analog to digital converters, communication interfaces and so on. Secondly, this device has a sleep timer and SMP (Switch Mode Pump) circuit, which are useful to reduce power consumption. Thirdly, there is a special

Microprocessor I is the central device of the gateway. It receives the information coming from nodes and sends out alarm messages to remote users via GSM/GPRS module. Microprocessor II deals with the keys signals and sends the signals to microprocessor I through its SPI interface. In this system, the communications between the GSM/GPRS module and Microprocessor I are implemented in the form of AT (Attention) commands. The implementation of GSM/GPRS gateway is shown in Fig. 3.

Y. Zhao and Z. Ye: A Low Cost GSM/GPRS Based Wireless Home Security System

569

Fig. 3. The implementation of GSM/GPRS gateway

B. Software Design of GSM/GPRS gateway The working procedure of gateway is as follows: (1) The wireless transceiver module receives the states information of security sensor nodes and sends the information to microprocessor II through its SPI interface. (2) LCD displays the information of sensor nodes. When alarm incidents happen, LCD will display alarm information. LEDs and the buzzer will warn the users at home. At the same time, the gateway will send alarm SMS messages to remote PMP and users through the GSM/GPRS module. (3) Sixteen capacitive sensor keys including an emergency alarm key (SOS key) are designed to modify password and mobile phone number for receiving the alarm messages. Whats more, the SOS key is used to startup emergency alarm. The function of microprocessor II is receiving keyboards information and sending it to microprocessor I through SPI interface. Its procedure workflow is to scan keyboard in turns and to send out signals corresponding to the keys which are touched by fingers of user. The flowchart of main program of microprocessor I is shown in Fig. 4. (1) Initializes system. (2) Receives information of sensor nodes and keyboard. (3) If any node alarms, the program calls alarm subprogram to display alarm message on the LCD and sends corresponding SMS messages to remote PMP and users. (4) If user at home presses the SOS key, it means he/she wants to alarm immediately. Then, the system will send the SOS message to remote PMP and users at once. (5) If user wants to use the menu function of gateway, he/she need to press the Menu key. Then, the program calls menu subprogram.

Fig. 4. The flowchart of main program of microprocessor I

Fig. 5 shows the flowchart of the menu subprogram. (1) Check up password. (2) If the password is right, the menu appears on LCD, otherwise the sub program ends at once. (3) Press 1 to 4 corresponds to the four functions of the menu: 1 for initializing password and the SOS number, 2 for changing password, 3 for changing the SOS number and 4 for quit. These functions are discussed in Section IV in detail.

Fig. 5. The flowchart of menu subprogram

570

IEEE Transactions on Consumer Electronics, Vol. 54, No. 2, MAY 2008

IV. WIRELESS SECURITY SENSOR NODES A. The General Structure of the Sensor Nodes The general diagram of wireless security sensor nodes is shown in Fig. 6. Every sensor node has a wireless transceiver module and a microprocessor. The microprocessor receives and analyses the sensors signals to detect the state of node.

Fig. 8. The implementation of a door security node

Fig. 6. The general diagram of nodes

Two methods are taken to reduce power consumption of nodes: (1) SMP circuit. It can be used to generate typical operating supply voltages off a single battery using only a few external components. As long as external voltage is more than one volt, the microprocessor would work normally, so the node can work steadily for a long time. (2) By configuring the sleep timer, the microprocessor can go into sleep mode periodically, which reduces average power consumption. B. The Door Security Node Door security node adopts magnetic sensor. The sensor doesnt need external power supply and has an ON/OFF signal output according to the distance from magnet to dry spring. The distance threshold is 16 mm. As the sensor is normally in ON state, the circuit in Fig. 7 is designed to use a 1M resistor R1 to limit the circuit current so as to reduce power consumption. The implementation of a door security node is shown in Fig. 8.
VCC

C. The Infrared Security Node The infrared security node adopts a pyroelectric infrared sensor (PIR). PIR sensor responds to the infrared radiation of human body whose radiation is strongest at wavelength between 9.4 m and 10.4 m [10]. The sensor can be placed in the entrances of rooms or other areas. When an intruder enters these areas, the sensor will detect the infrared radiation generated by the intruder and output a signal whose range is about 1mV and frequency is about 1Hz, as shown in Fig. 9.

Fig. 9. Output signal of PIR sensor

Magnetic sensor

R2 330 R1 1M
Microprocessor

Fig. 7. Circuit of door security node

Since the output signal of PIR sensor is very small, signal processing circuit must be designed. The common method is using a special amplifier to process the signal [11]. The circuit has a stable output and a quick response. However, it is complex, high power consumption and high cost. Since microprocessor contains configurable analog and digital blocks which can be configured as filters, amplifiers and analog to digital converters, the other simpler method is to use these configured filter, amplifier and ADC (Analog to Digital Converter) to process the signal, as shown in Fig.10. The output signal of PIR sensor is wired to microprocessor

Y. Zhao and Z. Ye: A Low Cost GSM/GPRS Based Wireless Home Security System

571

after a RC (resistor-capacitor) filter. The signal processes inside the microprocessor include amplifying, further filtering, analog to digital conversion and comparing with the alarm threshold determined by experiments. This method greatly simplifies circuit and reduces the power consumption. The implementation of infrared security node is shown in Fig. 11.
VCC
Fig. 12. The implementation of a fire alarm node

6.8M

V. THE WIRELESS COMMUNICATION When alarm incidents occur, the nodes will send alarm information to the GSM/GPRS gateway immediately. If there is no alarm incident, the gateway and sensor nodes use a query-reply communication mode. When a node is queried, it returns its state to the gateway. The communication packet format between the gateway and node is given in Fig. 13. The packet consists of Preamble (P), Start of Packet (SOP), Packet Length (PL), Payload Data (PD) and the CRC16 bits. Payload data have two bytes. The first byte represents the identity of security node, the second byte represents the state of node (0x00000001: Open State; 0x00000010: Close State; 0x00000100: Alarm State) or query command (0x00001111) from gateway. Before the payload data is transferred, it is encrypted with a pseudo security key. The payload data is decrypted with the same pseudo security key after received. The security key is generated by GSM/GPRS gateway and is sent to each node when installing.

47u 6.8M 0.01u 20K

Fig. 10. Circuit of PIR sensor with a RC filter

Fig. 13. The communication packet format Fig. 11. The implementation of an infrared security node

VI. THE SYSTEM FUNCTION A. Alarm Function The home security system discussed above has two kinds of alarms: abnormal alarms issued from three sensor nodes and emergency alarm started by users when they touch SOS key. Table I presents messages on LCD and SMS messages sent to user when alarms take place.
TABLE I ALARM FUNCTIONS OF SYSTEM Alarm Type door security nodes alarm infrared security nodes alarm fire alarm emergency alarm LCD Door Alarm MESSAGE SENT Stealing Alarm MESSAGE SENT Fire Alarm MEDSSAGE SENT SOS!!! MESSAGE SENT SMS Door Alarm Stealing Alarm Fire Alarm HELP!!!

D. The Fire Alarm Node There are many fire-detection techniques. The common methods are based on temperature sampling, relative humidity sampling, smoke analysis, in addition to ultraviolet and infrared sampling. [12] presents a fire-alarming method based on video process. Although the method mentioned in [12] can provide additional information about the process of burning, it is too expensive to be used in home security system. In this system, each fire alarm node adopts a temperature sensor and an infrared receiver. The temperature sensor monitors environment temperature and infrared receiver monitors heat and flames. If temperature or infrared of environment exceed defined thresholds, the node sends out alarm signal. The implementation of a fire alarm node is shown in Fig. 12. It is simple design, low cost and suitable to use in home.

572

IEEE Transactions on Consumer Electronics, Vol. 54, No. 2, MAY 2008

The Menu Function Menu key should be touched in order to use functions of menu. User is requested to enter password firstly. If the input password is correct, the system menu will show on the LCD. (1) Initialization Press 1, the system password is changed to 222333 and mobile phone number for help is changed to 00000000000. (2) Change password Press 2, the system requests user to enter new password. When completed, the system asks user to input again to verify. If two inputs are same, the password will be changed to the new one. During the process, you can use Cancel key to delete what you have entered. (3) Change mobile number Press 3, the system displays the existing mobile number and prompts user to enter new number. When finish inputting mobile phone number, press Set key to complete the amendment. (4) Quit Press 4, the system quits the menu. VII. CONCLUSION This paper presents the design and the implementation of a wireless home security system. PSoC devices and wireless transceiver modules are adopted. The system has a friendly user interface and employs some methods to reduce the power consumption. Communication of the system is complete wireless, which makes the system easy to install and use. The system is low cost, low power consumption and easily operable. In addition, the wireless transceiver modules enable the system to transfer other information such as voice and picture rather than just alarm signals. As a result, the system can lightly be expanded to other applications. The system is secured with a login password. As a future work, we are currently working to establish a more secure system by researching a proper wireless security protocol. ACKNOWLEDGMENT The author would like to thank Lucan Lin, Xiaolong Chen for their contribution to the design and implementation of the system. REFERENCES
[1] [2] [3] K. C. Lee, Network-based fire-detection system via controller area network for smart home automation, IEEE Trans. Consumer Electron., vol. 50, no. 4, pp. 1093-1100, Nov. 2004. A. Z. Alkar, An internet based wireless home automation system for multifunctional devices, IEEE Trans. Consumer Electron., vol. 51, no. 4, pp. 1169-1174, Nov. 2005. Y. Tajika, T. Saito K. Termoto, N. Oosaka and M. Isshiki, Networked home appliance system using bluetooth technology integrating appliance control/monitoring with internet service, IEEE Trans. Consumer Electron., vol. 49, no. 4, pp. 1043-1048, Nov. 2003.

J. A. Gutierrez, M. Naeve, E. Callaway, M. Bourgeois, V. Mitter, and B. Heile, IEEE 802.15.4: a developing standard for low-power low-cost wireless personal area networks, IEEE Network, vol. 15, no. 5, pp. 1219, Sept-Oct. 2001. [5] Y. P. Tsou, J. W. Hsieh, C. T. Lin, and C. Y. Chen, Buliding a remote supervisory control network system for smart home applications, IEEE International Conf. on System, Man and Cybernetics, pp. 1826-1830, Oct. 2006. [6] L. Ophir, 802.11 Over Coax A Hybrid Coax Wireless Home Network Using 802.11 Technology, Consumer Communications and Networking Conference, pp. 13-18, Jan. 2004. [7] H. S. Kim, and C. G. Lee, Wireless USB based home security system on the OSGi service platform, International conf. on Consumer Electron., pp. 1-2, Jan. 2007. [8] B. Yusekkaya, A. A. Kayalar, M. B. Tosun, M. K. Ozcan, and A. Z. Alkar, A GSM, internet and speech controlled wireless interactive home automation system, IEEE Trans. Consumer Electron., vol. 52, no. 3, pp. 837-843, Aug. 2006. [9] A. Alheraish, Design and implementation of home automation system, IEEE Trans. Consumer Electron., vol. 50, no. 4, pp. 10871092, Nov. 2004. [10] S. Lee, K. N. Ha, and K. C. Lee, A pyroelectric infrared sensor-based indoor location-aware system for the smart home, IEEE Trans. Consumer Electron., vol. 52, no. 4, pp. 1311-1317, Nov. 2006. [11] B. Li, B. Jiang, and B.Q. Wang, Application of BISS0001 on heatreleased infrared switch, Application Science and Technology, vol. 33, no. 2, pp. 31-33, Feb. 2006. [12] P. H. Huang, J. Y. Su, Z. M. Lu, J. S. Pan, A fire-alarming method based on video processing, Intelligent Conf. on Intelligent Information Hiding and Multimedia Signal Processing, pp. 359-364, Dec. 2006. Yanbo Zhao was born in Shijiazhuang, China on July 18, 1984. He received the B.S degree from Harbin Institute of Technology, Harbin, China, in 2006. He is currently pursuing his M.S degree at Tsinghua University, Beijing, China. His main research interests are home automation network, home network security and electronic technology applications. Zhaohui Ye was born in Hunan Province, China on December 14, 1968. She received her B.S, M.S., and Ph.D degrees in Industry Automation Instrument, Reactor PHOTO Engineering and Reactor Security, and Control Science and Engineering from Tsinghua University, Beijing, China, in 1992, 1994, and 2004, respectively. She has been working in Automation Department at Tsinghua University, Beijing, China since 1994, and now she is an associate professor. From September, 2002 to March, 2003, she studied as a Visiting Scholar in Extension and Teaching Development Center at University of California, at San Diego, USA. Her main research interests are home automation network, electronic technology application, and analog integrated circuit design.

[4]

You might also like