0% found this document useful (0 votes)
24 views

Home Automation Using Android Applicatio

This document describes a home automation system that uses an Android application and Bluetooth technology. The system allows users to control home appliances like lights, fans, and bulbs from their smartphone. An Android app is developed to send control signals to a microcontroller via Bluetooth. The microcontroller is connected to the appliances and relays to switch the appliances on and off remotely. The system aims to make home automation more affordable and accessible for users.

Uploaded by

pra09deep
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views

Home Automation Using Android Applicatio

This document describes a home automation system that uses an Android application and Bluetooth technology. The system allows users to control home appliances like lights, fans, and bulbs from their smartphone. An Android app is developed to send control signals to a microcontroller via Bluetooth. The microcontroller is connected to the appliances and relays to switch the appliances on and off remotely. The system aims to make home automation more affordable and accessible for users.

Uploaded by

pra09deep
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

International Journal on Recent and Innovation Trends in Computing and Communication ISSN: 2321 - 8169

Volume: 3 Issue: 2 815 - 819


_______________________________________________________________________________________________
Home Automation using Android Application & Bluetooth
Home Automation System (HAS)

Prashant R. Chandre Aarti R. Salunke


P.G. Student, Electronics and Telecommunication Assistant Professor, Electronics and Telecommunication
Jawaharlal Nehru Engineering College Jawaharlal Nehru Engineering College,
Aurangabad, (M.S.) 431003 INDIA. Aurangabad, (M.S.) 431003 INDIA.
E-mail: [email protected] E-mail: [email protected]

Abstract— Smart Home System is the term that describes the intelligent control and monitoring of different home appliances to manage the
home environment in an intelligent, safe and comfortable way. Home automation allows us to control home appliances like TV, Refrigerator,
AC, fan, etc. Home automation not only refers to reduce human efforts but also plays vital role to save energy and time. The main objective of
home automation is to help handicapped and old aged people it will facilitate them to control home appliances. In the present era smart phone
market has been dominated by the Android operating system. Smart phones features made to communicate to any other devices using Bluetooth
technology. Bluetooth wireless technology is built into billions of products, from cars and mobile phones to medical devices and computer s and
even forks and toothbrushes. Bluetooth technology allows you to share voice, data, music, photos, videos and other information wirelessly
between paired devices. It is an essential element for bringing everyday objects into the connected world. Home Automation System (HAS) has
been designed for mobile phones having Android platform to automate an Bluetooth interfaced 8 bit AVR Microcontroller which controls a
number of home appliances like lights, fans, bulbs and many more using relays. In houses, lamp switches normally located at a high location and
it is hard to reach for the switches without help for kids and disable person including people who unable to move a lot due to accident cases.
These problems can be overcome by using the home Automation System Using Android Application & Bluetooth at home which is user friendly
and cost efficient.

Keywords - Home Automation System, Bluetooth Controller , Bluetooth Module HC-05, Microcontroller ATMEGA 32, Smart Phone.
__________________________________________________*****_________________________________________________

I. INTRODUCTION II. SYSTEM ARCHITECTURE


Everyone in this competitive world prefers to make the This Project put forward the design of home automation
things easy and simple to handle, this project sets an example system using Bluetooth Controller Android application. The
to some extent for controlling home Systems. Smart phones Bluetooth controller freeware Android based application is
have revolutionized the area of home automation with respect developed for smart phone users. The home appliances are
to an increased level of affordability and simplicity through the connected to the input/output ports of the embedded system
integration of home appliances with wireless connectivity. board and Microcontroller is interfaced with Android
Smart phones are built in features and can be made to application via HC-05 Bluetooth Module. Bluetooth
communicate to any other devices in an ad hoc network with a technology designed to operate in a noisy radio frequency
connectivity options like Bluetooth [1]. environment such as a home, the Bluetooth technology uses a
Bluetooth for a communication medium and a Mobile fast acknowledgement and frequency-hopping scheme to make
phone as the control terminal have been chosen in the proposed the link robust. Bluetooth technology would replace the
system. Bluetooth is a low cost short range wireless technology cumbersome cables used today to connect the Printers, PC’s to
works without the need for an infrastructure [2]. Bluetooth can any other digital device which is part of the Bluetooth
connect the home appliances and the Mobile phone without network.
wire and we believe it will become a standard feature for The controlling device of the whole system is ATMEGA
cellular phones in the near future. Bluetooth works over 2.4 32 an 8 Bit Microcontroller, Bluetooth Module and Relay
GHz ISM band frequency range up to the range of 10 m with 1 Driver and Relay Board. The system is based on serial data
Mbps speed, providing a safe and efficient solution for transmission using Bluetooth wireless communication in order
controlling home automation [7]. Android provides the to facilitate the appliances control in a HAS. A user interface
platform for the development of the mobile applications for the on the Android enabled mobile phone offers system
communication of different Android devices [3]. Bluetooth connection and control utilities. The data received by
Controller version 1.0 is a mobile application developed using Bluetooth module from Android application is fed as an input
Android targeting its vast market which will be beneficial for to Microcontroller. In achieving this control the
the many Android users [4]. According to the International Microcontroller is loaded with a C program written using
Data Corporation (IDC) Worldwide Quarterly Mobile Phone Embedded C Language. The controller acts accordingly on the
Tracker, Android maintained its leadership position in global relays to switch connected electrical appliances. ULN 2003
market share. relay driver, HC-05 Bluetooth module, AVR Studio 4 (IDE) for
compiling C Language Code and USB AVR Programmer for
burning the HEX file into Microcontroller.

815
IJRITCC | February 2015, Available @ http://www.ijritcc.org
_______________________________________________________________________________________
International Journal on Recent and Innovation Trends in Computing and Communication ISSN: 2321 - 8169
Volume: 3 Issue: 2 815 - 819
_______________________________________________________________________________________________

Figure 1
System Architecture

III. DEVELOPMENT PLATFORM Bluetooth Controller application can carry out the following
functions:
This section describes the technologies used for developing
the mobile phone application of the home Automation System. I. Click scan Button for connect to device Search the
The mobile phone application development presented in this Bluetooth devices present in the range.
paper is based on the following technologies: Android [3], II. After connected, Click Set Keys for setting Keys name
Bluetooth [2]. Android is a platform to developing and and data to be sent.
deploying android based applications on mobile devices III. Exchange data to and from paired Bluetooth devices.
supporting it. Bluetooth has its own benchmark as wireless
communication technologies for short range communication
B. Bluetooth Module
provide a facility to create Android based mobile applications.

Wireless networks for short range communications have a


A. Andriod Application wide spread usage of Bluetooth radio transmissions between
2400–2480 MHz by Telecom vendor Ericsson since 1994 [6]
Android is an open-source operating system. The Bluetooth Bluetooth technology forms small ad hoc networks termed as
controller Android Application shown in figure 2. The Personal Area Networks (PANs) also provides a mechanism to
Android application available on Google Store. The same has emulate the RS-232 data cables, supervised by the Bluetooth
been downloaded and installed on Samsung galaxy Pro mobile Special Interest Group, since 1998. Modern mobile devices
which is having Android version “2.3 GINGERBREAD” embed small, low-powered and cheap integrated chips
The home appliances are interfaced to the functioning as short-range radio transceivers for Bluetooth
radio communications. Device pairing, authentication,
input/output ports of the embedded system board and
encryption and authorization techniques have given recognition
Microcontroller is interfaced with Bluetooth Controller to Bluetooth technology due to its vital security mechanisms.
Android application wirelessly via HC-05 Bluetooth Module. Different types of Bluetooth applications can be developed
using Android platform architecture using the Bluetooth
profiles. The device manufacturers provide the services using
the support of these profiles in their devices to maintain
compatibility for the Bluetooth technology.

Figure 3 HC-05 Bluetooth Module

Figure 3 shows the HC-05 Bluetooth Module. This module


enables you to wireless transmit & receive serial data. It is a
drop in replacement for wired serial connections allowing
transparent two way data communication. You can simply use
it for serial port replacement to establish connection between
MCU or embedded project and PC for data transfer. The
Figure 2 Android App GUI
Bluetooth profile used in Home Automation System (HAS)
Android mobile phone application is the Bluetooth Serial Port
Profile. Normally, before commencing communication,
816
IJRITCC | February 2015, Available @ http://www.ijritcc.org
_______________________________________________________________________________________
International Journal on Recent and Innovation Trends in Computing and Communication ISSN: 2321 - 8169
Volume: 3 Issue: 2 815 - 819
_______________________________________________________________________________________________
devices can use two methods for initiating communication microcontroller based on the AVR RISC architecture [5]. By
with each other which can be done normally either by executing powerful instructions in a single clock cycle, the
discovering other nearby devices to detect the address and ATMEGA 32 achieves throughputs approaching 1 MIPS per
services that are provided by other devices or by knowing the MHz, allowing the system designed to optimize power
device address beforehand and directly using that address for consumption versus processing speed.
further communication process. In Home Appliance Control, We can interface the Bluetooth module with directly
the later method is used. Bluetooth devices have a 12 digit microcontroller pins since the level of module is at 5V level.
hexadecimal MAC address which is to be known beforehand We just need to configure our microcontroller to communicate
at 9600 baud rate. The TXD pin of MCU will go to RX-IN pin
for pairing with the device.
of Bluetooth module The RXD pin of MCU will go to TX-
OUT pin of Bluetooth module Ground & +5V Power Supply
C. AVR Studio 4(IDE) between Bluetooth module and microcontroller should be
connected [6]. The main objective of using ATMEGA 32
AVR Studio 4 will be used to develop programming for the Microcontroller is that maximum 30 appliances can be
microcontroller in this home automation system because it controlled and with small modifications in the C program the
provides enormous features. Win AVR is a suite of executable, GSM can be interfaced for remote control of home appliances
open source software development tools for the Atmel AVR by using the SMS service with minimum modifications.
series of RISC microprocessors hosted on the Windows
platform. It includes the GNU GCC compiler for C and C++. B. Relay Driver and Switching Relays
Win AVR contains all the tools for developing on the AVR.
This includes AVR-gcc (compiler), AVR-gdb (debugger) etc.
ULN 2003A Driver IC is used for handling the Relay coil
current The ULN2001A, ULN2002A, ULN2003 and
D. USB ASP Programmer ULN2004A are high voltage, high current Darlington arrays
each containing seven open collector Darlington pairs with
USB ASP Programmer is USB device programmer software common emitters. Each channel rated at 500mA and can
with a user-friendly GUI framework available for withstand peak currents of 600mA. Suppression diodes are
Windows95/98/ME/NT/2000/XP and Intel Linux. included for inductive load driving and the inputs are pinned
opposite the outputs to simplify board layout. We have
IV. HARDWARE IMPLEMENTATION specially used ULN 2003A as it is 5V TTL, CMOS IC. These
versatile devices are useful for driving a wide range of loads
Home automation hardware is work as client part in home including solenoids, relays DC motor, LED displays filament
automation system. Home automation system block diagram lamps, thermal print heads and high power buffers [8].
which is shown in figure 4 home Automation control board In this project we have incorporated SC5-S-DC 12V for
comprises of microcontroller ATMEGA 32, Serial Bluetooth handling the switching ON/OFF actions of electrical loads. It is
Module, Relay driver IC ULN2003, 12V relays and regulator capable of handling 10A current through contacts. These relays
IC7805 and a few discrete components. are widely used for UPS, Invertors, A/C Microwave, Vending
Machine, Timers, SMPS and Card Reader etc.

V. SOFTWARE IMPLEMENTATION

Microcontroller, when it is used to operate as a wireless


network involves following steps:

Figure 4 Home Automation Block Diagram

A. Microcontroller
There is a wide range of microcontroller available in the
market. But this particular project is developed using AVR
series of microcontroller (ATMEGA 32) because of its various Figure 5 Steps for Software Development
advanced features such as inbuilt ADC, EEPROM etc. The
Atmel AVR ATMEGA 32 is a low-power CMOS 8-bit In software implementation, it will be mainly the
programming of ATMEGA 32 microcontroller. AVR Studio 4
817
IJRITCC | February 2015, Available @ http://www.ijritcc.org
_______________________________________________________________________________________
International Journal on Recent and Innovation Trends in Computing and Communication ISSN: 2321 - 8169
Volume: 3 Issue: 2 815 - 819
_______________________________________________________________________________________________
will be used to develop programming for the microcontroller
in this home automation system because it provides enormous
features. The microcontroller, as the ‘brain’ of the system, is
responsible of processing the data. Besides, the
microcontroller will also do the job of receiving user’s inputs
and executing commands, such as turn on/off the device etc.
Coding / Debugging- Coding or debugging is one in a high-
level language (such as c). Compiler for a high level language
helps to reduce production time. To program the
microcontrollers Win AVR was used using C language. The
source code has been commented to facilitate any occasional
future improvement and maintenance.
Win AVR is a suite of executable, open source
software development tools for the Atmel AVR series of RISC
microprocessors hosted on the Windows platform. It includes
the GNU GCC compiler for C and C++. Win AVR contains all
the tools for developing on the AVR. This includes AVR-gcc
(compiler), AVR-gdb (debugger) etc. Compiling- After
compiling the program, it is converted to machine level
language in the form of 0’s ans1’s.
This file is called as the Hex file and is saved with the
extension (.Hex). The compiler also generates errors in the
program this should be removed for proper execution of the
program. Flashing - Flashing the machine language (hex) file
into the microcontroller’s program memory is achieved with a
dedicated programmer, which attaches to a PC’s USB port for
this purpose USB ASP Programmer, was used to burn the
machine language file into the microcontroller’s program
memory.
USB ASP Programmer is USB device programmer
software with a user-friendly GUI framework available for
Windows95/98/ME/NT/2000/XP and Intel Linux. The
program memory, which is of Flash type, has, just like the
EEPROM, a limited lifespan. On AVR microcontroller family
it may be reprogrammed up to a thousand times without any
risk of data corruption ATMEGA 32 Programmer (ISP) which
is used to burn the program into AVR microcontrollers.

A. Microcontroller Program Figure 6 Program flow chart

The program (Bluetooth.c) for the microcontroller is


written in C and compiled using AVR Studio 4 to generate hex VI. TESTING & RESULTS
code. The generated hex code is burnt into the microcontroller
using USB ASP Programmer. The program coding starts with Real implementation of HAS is shown in figure 7 and 7a. the
‘# include <avr/io.h>’ header files. The microcontroller port steps for operating the Automation system listed as follows:
pins are defined using ‘ define function for interfacing with
the surrounding peripherals. By Pressing Key from GUI of
home Automation Application program which is developed I. On powering up the hardware HC-05 Bluetooth
using Android installed on mobile device, will transmit ASCII Module make the Green LED flicker quickly. It
characters serially through Bluetooth and on the receiving side indicates the HC-05 module is power up and this can
Microcontroller receives data serially on RxD Port Pin of be paired.
ATMEGA 32. ‘UDR register’ will store this ASCII characters II. Open the Android application on mobile phone after
as equivalent HEX value and Microcontroller takes action that you will be asked for turning on the Bluetooth,
according to the C program and data received from Bluetooth Press YES to continue further.
module. The Port A is used as output port to control the relay III. Using scan key you can connect to HC-05 Module.
switching which in turn switch the appliances ON/OFF. IV. On pairing with HC-05 Bluetooth Module the
Microcontroller C program flow chart for home application appears with message “Connected to
automation system is shown in figure 6. HC-05” as shown in figure 7.

818
IJRITCC | February 2015, Available @ http://www.ijritcc.org
_______________________________________________________________________________________
International Journal on Recent and Innovation Trends in Computing and Communication ISSN: 2321 - 8169
Volume: 3 Issue: 2 815 - 819
_______________________________________________________________________________________________
V. Now pressing the keys you can control the home REFERENCES
appliances as per your requirement. On pressing “TV [1] J. Haartsen, "BLUETOOTH—The universal radio interface for ad hoc,
ON” key (here for sake of feasibility lamp is wireless connectivity", Ericsson Review No. 3, pp. 110-117, 1998.
connected) Lamp (Load) turned ON and feedback [2] “Mobile Communications” by Jochen H. Schiller second Edition
from controller is received i.e. TV ON. [3] Why Android ?, http://www.android.com/about/, last seen on October
2013.
[4] https://play.google.com/store/apps/details.
[5] http://www.atmel.com
[6] http://www.sunrom.com
[7] http://www.bluetooth.com
[8] http://www.st.com

Figure 7 Actual Testing of HAS

VI. On pressing “TV OFF” key (here for sake of


feasibility lamp is connected) Lamp (Load) turned
OFF and feedback from controller is received i.e. TV
OFF.

Figure 7a Actual Testing of HAS

VII. CONCLUSION
In conclusion, this low cost system is designed to improve the
remote control function by smart phone provides help and
assistance especially to disabled and elderly. The proposed
HAS is designed for Bluetooth based wireless monitoring and
controlling of different electric home appliances. The HAS is
tested with “2.3 GINGERBREAD” on Samsung galaxy Pro
mobile.
This study has its limitations, it is hoped that it will
serve as a basis for further study of home automation.

819
IJRITCC | February 2015, Available @ http://www.ijritcc.org
_______________________________________________________________________________________

You might also like