An Intelligent Home Security System Using Gsm Computer Science Essay


Abstract- It is an intelligent Home security system using GSM. The system is developed keeping in mind the safety of the house from fire and theft irrespective of the presence of the host. This system will take the remedy action in case of fire and attempt of theft. It will also be able to switch on and off the electrical appliances from remote location. System can send preformatted SMS depending upon sensor feedback. It can also interpret the SMS send by user for controlling the electrical appliances.

System is based on an application that allows local and remote monitoring of a home environment. It explores ways of employing an embedded operating system to implement an inexpensive home monitoring system consisting of an array of sensors. This system consists of host mobile phone, GSM modem and a controller board incorporating an ARM 9 microcontroller. The mobile phone serves as a remote control through which a user can interact with home automation system. The controller board interface with array of sensors and relays reside at home and work as a home server, which carries out the task of controlling and monitoring home appliances with many sensors. This application is developed using real time operating system, MicroC/OS II .

Keywords: SMS, RTOS, MicroC/OS II, GSM Modem


Lady using a tablet
Lady using a tablet


Essay Writers

Lady Using Tablet

Get your grade
or your money back

using our Essay Writing Service!

Essay Writing Service

Home automation has been an important issue throughout the last two decades. Many solutions have been reported and implemented [1]. Other systems used conventional phone line for controlling home appliances. Most recently, Internet and wireless communications have been utilized in home automations [2]. With the recent development in mobile computing devices and mobile networks, new and better solutions can be developed to make home automation more convenient and accessible on the base of 24/7 from anywhere at anytime.

This project gives design of a stand-alone embedded system that can control home appliances remotely,. The system allows the homeowner to control his house appliances via his mobile phone set by sending commands in the form of SMS messages and receives the messages of misshapen like attempt of theft, gas leakage or fire.

System is implemented using two modules. In the first module, remotely the system allows the host to control his home appliances via mobile phone by sending commands in the form of SMS. SMS is the medium via which the host and the home server can communicate. SMS consist of predefined command to control the home appliances. For example suppose the host wants hot water before reaching home, he can send SMS of electrical geyser switch on from his mobile. This SMS is received by system mobile (GSM modem). Once the GSM modem receives the message, it will send the message to the controller. The controller will interpret the SMS and take the action accordingly. Figure 1 shows the block diagram of module 1.

Figure 1: Block Diagram of module 1

Second module of the project provides the security of the home in case of gas leakage, theft and fire and by using various sensors. These sensors are monitoring any misshapen condition. If such condition is found system send preformatted SMS to the host mobile. For example if suppose gas leakage sensor detects gas leakage, it will give signal to the controller and then controller sends SMS of 'GAS leakage is detected' to the host mobile. Also it will give alarm for security guard so that fast controlling action can be taken. As per each sensors output preformatted SMS will be send to the host. Following Figure 2 shows the block diagram of module 2.

Figure 2: Block Diagram of module

System Requirement

This system consists of host mobile phone, GSM modem and a controller board incorporating an ARM 9 microcontroller. The mobile phone serves as a remote control through which a user can interact with home automation system. The controller board interface with array of sensors and relays reside at home and work as a home server, which carries out the task of controlling and monitoring home appliances with many sensors. This application is developed using real time operating system, MicroC/OS II.

This system is designed for performing mainly two functions:

Remotely on/off of electrical appliances.

Monitoring of the home by using some sensors.

Lady using a tablet
Lady using a tablet


Writing Services

Lady Using Tablet

Always on Time

Marked to Standard

Order Now

System is having following device

1) Home Server

2) Communication Media (GSM modem)

3) Host mobile Phone

Home server consists of controller with some sensor.

2.1 Home server requirement:

A) H/W Requirement

ARM 9 ATMEL AT91SAM9260 processor

16x2 LCD display

PS2 keyboard

Temperature sensor -LM-35

LPG leakage sensor -MQ 6

PIR Sensor


B) S/W Requirement:

Real Time Operating System (Micro C/OS II)

ARM 9 (AT91SAM 9260) Processor:

This is the heart of the system and it interprets the data sent from the GSM module and executes the different security tasks accordingly. The AT91SAM9260 is based on the integration of an ARM926EJ-S processor with fast ROM and RAM memories and a wide range of peripherals.

The AT91SAM9260 embeds an Ethernet MAC, one USB Device Port, and a USB Host controller. It also integrates several standard peripherals, such as the USART, SPI, TWI, Timer Counters, and Synchronous Serial Controller, ADC and Multimedia Card Interface and image sensor interface. It has three 32 bit parallel I/O ports, so maximum 96 I/O devices can be connected to the processor. It also support for real time operating system.


This project is developed using real time operating system. Here Micro C/OS II is used as RTOS. MicroC/OS II is a very small operating system, making it suitable for small applications on small platforms.

MicroC/OS-II (commonly termed µC/OS-II or uC/OS-II), is a low-cost priority-based pre-emptive real time multitasking operating system kernel for microcontroller, written mainly in the C programming language. It is highly portable and has been ported to many different platforms. Its strength is its small size and manage up to 64 tasks.

2.2 Communication Media:

GSM technology is used for communication between home server and host.GSM is most popular network because of following advantages.

Advantages of GSM:

GSM network is very vast. Not only nationally but even internationally, GSM is a most popular network for voice and data communication.

GSM network is familiar to most of the people, reason being that it is very user friendly.

GSM handset responds to AT commands. These AT commands can easily decoded by microcontroller.

GSM network offers a respectable level of privacy and security. Unless the correct GSM number is known to the caller, conversation is not possible.

GSM offers international roaming facility.

Home server becomes compatible with GSM modem using AT commands. AT commands are instruction used to control the GSM modem. Few of the AT commands are listed below.

Table 1: AT Commands

AT command



Send message


Send message from storage


Write message to memory


Delete message


Send command


More messages to send


Read SMS messages

System Design

3.1 Hardware Design

For this system implementation two boards are designed, one is controller board and other is peripheral board. Controller board is having ARM 9 controller with SDRAM and NAND flash and reset circuit. All the sensors, relays and LCD and keyboard are placed on peripheral board. These two boards are connected with 50 pin FRC connector or I/O connector.

Following figure 3 shows block diagram of interfacing of system board and peripheral board.

Figure 3: Block Diagram of the system

A) Processor Board:

It has ARM 9 AT91SAM9260 processor with two crystals. Main crystal is of 18MHz and other crystal is of 32 KHz.

It interface with SDRAM which has 64 Mbyte 32 bit wide.

Two UART for interfacing with Com port and for interfacing with GSM modem.

It has RESET pushbutton.

It has JTAG interface for debugging.

It has 50 pin extended general purpose I/O connector for interfacing sensors, relays, LCD and keyboard

It is two layer PCB with all SMD components.

Three different power supply unit is required.

5V : For GPIO

3.3 V: For MCU, Memory and ADC

1.8 V: For MCU core

B)Peripheral board:

Lady using a tablet
Lady using a tablet

This Essay is

a Student's Work

Lady Using Tablet

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.

Examples of our work

Peripheral board consist of sensors with signal conditioning circuit

Selection of sensors:

LPG Gas sensor: MQ 6 gas sensor is used for detection of LPG gas. It has a high sensitivity to propane, methane, and ISO-butane, making it ideal for LPG monitoring. It has simple drive circuit. It operates on 5V DC supply.

Motion Sensor: Motion sensor is a PIR sensor. It is passive infrared sensor in which black body phenomenon is used. When any motion is detected, it gives pulse of 5V. Detection range of this sensor is 5 meters.

Fire sensor: LM 35 is used as temperature sensor for detection of fire. O/P is calibrated directly in Celsius. It has linear 10mv/0C scale factor. It operates from 4 to 30 V.

Features of Peripheral Board:

LM35 - PC0 pin

PIR sensor - PB9 pin

MQ6 sensor- PB8 pin

4 Relays- PB16-PB19

16*2 LCD

PS2 Keyboard

3.2 Software Design

Functionality of the System:

System has following features:

Password protection is provided.

Two modes of operation are provided.

a) SET mode b) VIEW mode

System has different SET modes as per the condition of host.

No restriction on number of host.

To make this system as user friendly there is mode selection facility provide on LCD display. When this system is initialized, it will display SET mode and VIEW mode on LCD display. In SET mode host can select mode of operation. In view mode host can see

only mode of operation as well as host mobile no.

System is also working in presence of host. Only as per the condition of host, system functionality gets changed. So mode selection is required. In this project three conditions of host are considered. These conditions are:

In presence of host at day time

In presence of host at night time

In absence of host

In presence of host , functionality of the system:

Table 2: Functionality of the System

Day Time Condition

Night time condition

Gas Leakage sensor: ON

Required Actions: Alarm is on.

Gas Leakage sensor: ON

Required Actions: Alarm is on.

Fire Sensor: ON

Required Actions: Alarm is on.

Fire Sensor: ON

Required Actions: Alarm is on.

PIR sensor: OFF

PIR sensor : ON

Required actions: Alarm is on.

In absence of host, functionality of the system:

All the sensors are ON.

Required actions: It gives SMS and alarm in case of any misshapen.

Implementation and Testing

In programming, system is implemented in three modules.

In Module-1 setting mode operation of the System is described. Setting mode is used by the host to customize the system. As this system is designed for security in presence of host or in absence of host, so mode selection is required for this system. The functionality of each mode is different. Different mobile no. Of host can be entered in this module.

The security for the home is covered under Module-2. Several sensors as mentioned above are connected to I/O port of the controller. When any misshapen event occurs, particular sensor is activated. This event is recognized by the I/O port of the controller. All the sensors are in polling mode. As per the sensor activation, preformatted SMS is send to the host and generate the alarm for local control.

Module-3 deals with the controlling of the electric appliances remotely by sending message in terms of SMS. Host sends SMS to GSM modem. When the SMS is received by modem, it will generate interrupt to the controller. The controller reads and interprets the SMS by using AT commands. The controller performs the operation of relay switch on/off as per the message.

4.1 Flow Charts

Flow Chart for Module 1: Mode Setting for the System

Figure 4: Flow chart Module 1

Flow chart for module 2: Sensor Event

Figure 5: Flow Chart Module 2

Flow Chart for Module 3: Electrical Appliances on/off

Figure 6: Flow chart for module 3

Test Description

Host Action

Controller Action

SET/VIEW operation

or V pressed

Compare with S / V

S-SET menu

V-VIEW menu

SET menu

M or H


Compare with M or H

M- Mode Selection H- Host mobile entry

Mode selection menu

1 or 2 pressed

Compare with 1 or 2

Host Present

Absent Mode

Host mobile no. Entry

Enter host mobile no.

Store host mobile no.

VIEW mode

1 0r 2 is pressed

Selected mode Display

Host mobile no. Display4.2 Test Cases:

Test Module 1: Setting Operation

Table 2: Test case for module 1

Test Module 2: Appliances On/Off

Tabl e 2: Test case for module 2

Test Description

Host Action

Controller Action

Electrical Appliances on/Off

Send SMS

for relay On/Off

Read the SMS.

Compare with 0 and 1.

0-Off 1-On

Test Module 3: Sensor Event

Test Module 3: Sensor Event

Table 3: test case for module 3

Test Description

Controller Action

Host Action

Gas leakage is detected

Read Port PB8 pin,

If port pin is high, send Preformatted SMS and alarm is on.

Received the SMS

Intruder detection

Read port PB9 pin,

If port pin is high, send preformatted SMS and alarm is on.

Received SMS

Fire Detection

Read PC0 pin, if temperature >50oC,

Send preformatted SMS and alarm is on

Received SMS


5.1 Screen Shots of Output

Following are the some screen shots of the working model of the system

Display of Setting Operation of the System Module 1

Figure 7: Screen shot of module 1

After initialization of the system, it displays mode selection on LCD. If S is pressed, host can enter in settings mode and if V is pressed, host can enter into view mode.

Figure 8: Screen shot of set mode

B) Received SMS on Host Mobile of System Module 2

Figure 9: Screen shot Fire detection


This project gives the design and implementation of an intelligent home system. It provides complete home automation. It is user friendly system. For ARM 9 processor, large no. of GPIO are available, so future expansion is easily possible. This system is not restricted for home, but it can be used for any infrastructure such as buildings, offices and industries.