1. See discussions, stats, and author profiles for this publication at: https://www.researchgate.net/publication/321502885
Low cost implementation of smart home automation
Conference Paper · September 2017
DOI: 10.1109/ICACCI.2017.8125883
CITATIONS
0
READS
1,585
2 authors, including:
Ravi Kishore Kodali
National Institute of Technology, Warangal
87 PUBLICATIONS 250 CITATIONS
SEE PROFILE
All content following this page was uploaded by Ravi Kishore Kodali on 21 December 2017.
The user has requested enhancement of the downloaded file.
3. Fig. 1: Block diagram of Smart Home Automation
System
nearly 50 billion devices will be connected to the Internet
or approximately 6.58 devices connected per person to
the Internet [6]. The proposed home automation system
as an IoT application is aimed to be secure, easily
accessible, efficient, scalable and also cost effective.
II. SYSTEM ARCHITECTURE
Fig. 2: Circuit Connection of the System
The hardware realization of the proposed system as
shown in Fig. 2 contains NodeMCU, the ESP8266 WiFi
board, is USB powered and the same is interfaced with
various home appliances like light, fan, bulb and charger
through the four SPDT relay channels by means of 230V
power supply. The ESP8266 WiFi board acts as web
server for the system and it sets number of GPIO pins
equal to the number of home appliances. The aim is to
create a simple HTTP server through which the status
of GPIO pins of ESP8266 is altered depending upon the
request. An example of changing the status of GPIO2 pin
of ESP8266 through an HTTP server has the following
format:
http://Server_IP/GPIO2/0 ...........set the GPIO2 Low
http://Server_IP/GPIO2/1 ...........set the GPIO2 High
where Server_IP is the IP address of the ESP8266 WiFi
board.
Once the NodeMCU is powered up using its USB
port it attempts to discover the access point whose SSID
and password have been stored already. This access
point may be connected to the Internet using either
wired or wireless medium or cellular connectivity. The
code is uploaded with required libraries [12] to the
NodeMCU using the Arduino IDE. Once the ESP8266
finds the matched combination of that particular SSID
and Password, it connects to the access point and be-
comes part of the WLAN. The NodeMCU has already
been programmed to act as web server with port address
of 80. The Server_IP is displayed in the serial monitor
of Arduino IDE which is the local IP of the server. Then,
it listens using port 80 and lets the client upload its data.
Depending on the data, the status of the GPIO pins of the
ESP8266 is modified and in turn the relay connected to
the corresponding GPIO pin is controlled. The relay acts
as a switch to control 220v AC power to the domestic
appliance. Table I provides the URLs used to turn on
and off AC power to various appliances.
TABLE I: URL based Domestic appliance control
S.No. URL Home Appliances Status
1 http://Server_IP/GPIO1/0 Turn OFF ’Light’
2 http://Server_IP/GPIO1/1 Turn ON ’Light’
3 http://Server_IP/GPIO2/0 Turn OFF ’Fan’
4 http://Server_IP/GPIO2/1 Turn ON ’Fan’
5 http://Server_IP/GPIO3/0 Turn OFF ’Bulb’
6 http://Server_IP/GPIO3/1 Turn ON ’Bulb’
7 http://Server_IP/GPIO4/0 Turn OFF ’Charger’
8 http://Server_IP/GPIO4/1 Turn ON ’Charger’
Nowadays, the use of Smart phone can be made
for security, safety and other protection purposes [7].
In this work, the Android app is designed using open
source web application MIT App Inventor 2. The user
has two options to control home appliances. The first
option is through the App in which the user is clicks the
buttons shown on the touch screen panel of the smart
phone, meant for the control of various home appliances,
462
4. the corresponding URL request as shown in Table I
is sent and the NodeMCU device makes the changes
suitably through its GPIOs. In the second option through
Voice using smart phone according to the specific voice
command the relevant want URL is sent as shown in
Table I in a similar manner and the NodeMCU controls
the relays.
A. Through APP
Fig. 3: MIT App Inventor 2 Component Designer- GUI
Button Layout Design
Fig. 4: MIT App Inventor 2 Blocks Editor - Behavior
Specification of the GUI buttons for Home appliances
Fig. 3 shows the Component designer’s window of
MIT App Inventor 2 which facilitates the design of visual
appearance of GUI and arrange various components like
buttons, text boxes and annotate the same using text
labels. The blocks editor screen of MIT App Inventor 2,
as shown in Fig. 4, is used to edit the behavior of various
components Android App such as what action needs to
take place upon touch if a button. The IP address of the
ESP8266 is entered in the text box provided and then can
perform any actions by simply clicking onto the buttons.
An approach and tool like Android URL Risk Assessor
(AURA) can assess scalable risk for the Android Apps
[8].
B. Through Voice
Fig. 5: MIT App Inventor 2 Component Designer- Voice
Command Layout
Fig. 6: MIT App Inventor 2 Blocks Editor - Control of
Home Appliances through Voice Commands
Fig. 5 shows the design window for controlling home
appliances through Voice Command in App Inventor 2,
while Fig. 6 provides the programming part of the same
in the blocks editor. The user has to enter the IP address
of the ESP8266 (server’s IP Address) and then simply
speak out the voice command as in Table II to control
the desired home appliance remotely using an Android
App. The interactive voice controller eases to control the
home appliances naturally [9].
III. DESCRIPTION OF HARDWARE
A. ESP8266 WiFi board
ESP8266 is low cost WiFi board best suited for IoT
application. The board comes with built in 2.4 GHz WiFi
module having 32- bit Tensilca L106 micro-controller
unit making it ultra low power consumption device [10].
463
5. TABLE II: List of Voice Commands to control various
Home Appliances
S.No. Voice Command
used for Control
1 turn off light
2 turn on light
3 turn off fan
4 turn on fan
5 turn off bulb
6 turn on bulb
7 turn off charger
8 turn on charger
It works with just 3.3 V supply and the General Input
Output Pins(GPIO) makes it possible to communicate
with the external world [10]. The use of ESP8266
WiFi board in home automated system makes the whole
system cost effective and robust. Table III provides the
specifications of ESP8266 board.
TABLE III: ESP8266 WiFi board Specification
Parameters Specification
Microcontroller TenSilica L 106
Processor Clock 80MHz-160MHz
Built-in WiFi 2.4GHz supports 802.11 b/g/n
GPIO pins 10
Operating Voltage 3.0V - 3.6V
Operating Current 80mA(Average)
B. 4- Channel Relay
The module has 4 relays of SPDT type with the coil
voltage 5V DC and the specifications of the same are
given in Table IV.
TABLE IV: 4 Channel Relay Specification
Parameters Specification
Type SPDT
No. of Relay Channels 4
Coil Voltage 5V (DC)
Load 10A, AC 250V/125V,
DC 30V/28V
IV. DESCRIPTION OF SOFTWARE
A. MIT APP INVENTOR 2
The open source web application MIT App Inventor
2 is comprises of two parts to create an Android App.
The first one is the Designer part where the app is
designed for the graphical user interface (GUI) providing
various components like texbox, label, buttons, web,
speech recognizer, notifier, etc [11]. The components can
be placed by ’drag and drop’ method onto the screen
provided and the layout can be customized as per the
need. The second part of the AppInventor 2 is the Blocks
Editor using which the components from the Designer
part are programmed to describe the Android app specific
behavior suitably [11].
V. EXPERIMENTAL RESULTS
Fig. 7: Messages in the Serial Monitor of Arduino IDE
The ESP8266 WiFi board is USB powered and the
program is uploaded to the NodeMCU board using
Arduino IDE. Once the uploading is completed and
the Serial Monitor in Arduino IDE displays various
messages as shown in Fig. 7, it attempts to be part of
the WLAN using specific SSID and Password which
have been included in the configuration section of the
program. Once the connection is established, it shows
WiFi is Connected and afterwards gives IP address of the
ESP8266 board which has been obtained by it through
DHCP in Serial Monitor as shown in Fig. 7. The web
services in the ESP8266 are enabled using its web server.
As soon as the client is connected to the server by
using the IP address of ESP8266 (Web server), the home
appliances may be controlled remotely and the status can
be observed as illustrated in Fig. 7.
464
6. Fig. 8: Screen-1 GUI of the Android App
Using the open source tool, MIT App Inventor 2,
once the design comprising of component designer Block
Editor has been completed, the apk file is generated using
the MIT App Inventor cloud platform and the same apk
file is deployed in any Android Smart phone. When the
installation is completed and app is activated, an initial
screen as shown in Fig. 8 giving the user two options
to control the home appliances either by using graphical
buttons or by using voice commands.
(a) Screen-2 view (b) Light button is
Click
Fig. 9: User Interface when select Use App on Screen-1
Fig. 9(a) shows the user interface when Use App
option is chosen on the initial screen (Screen-1) of the
designed Android App and the user has to enter the IP
address of the ESP8266 obtained from Serial Monitor
of Arduino IDE in the text box provided. The user can
control the home appliances remotely by simply clicking
on the button icons as shown in Fig. 9(b) or can go
back to the previous menu (Screen-1) by pressing Home
button.
Fig. 10 (a) shows the user interface when Use Voice
is selected on the initial screen of the designed Android
App and the user has to enter the IP address address of
the ESP8266 obtained from Serial Monitor of Arduino
IDE onto the text box provided and then tap the Speak
button to give the voice commands when speech rec-
ognizer initializes as shown in Fig. 10(b). The notifier
shows what has been spoken to it just now as shown
in Fig. 10(c). The user can control the home appliances
remotely with their voice commands as provided in Table
II or go to the previous menu (Screen-1) by pressing
Home button.
As shown in Fig.11(a) and Fig.11(b), the ESP8266 is
USB powered and the bulb is controlled remotely with
designed Android App with both the options of Use
App and Use Voice. The other appliances can also be
controlled using the same App by connecting them as
illustrated in Fig. 2.
(a) Screen-3 view (b) Speak button is
tap
(c) Notifier after
speaking
Fig. 10: GUI Screen-3: Use Voice on Screen-1 selected
VI. CONCLUSION
The proposed home automation system can be used for
both domestic and office environments. The remote con-
465
7. (a) Bulb is OFF (b) Bulb is ON
Fig. 11: The bulb is controlled remotely using designed
Android App
trol feature using the Android Smart phone assists elderly
and persons with disability. The ESP8266 NodeMCU is a
low cost device and has ultra low power consumption. A
different relay can be chosen based the load. The design
and app development has been demonstrated by using
MIT App Inventor 2 to support both GUI button based
and voice activated approaches. The automation system
is inexpensive, secure easily accessible and also scalable
so that the number of devices can be easily customized
by making minor modifications.
REFERENCES
[1] Sushant Kumar, S.S Solanki, "Voice and Touch Control Home
Automation", in 3rd International Conference on Recent
Advances in Information Technology(RAIT), 2016
[2] Yash Mittal, Paridhi Toshniwal, Sonal Sharma, Deepika
Singhal, Ruchi Gupta and V K Mittal, "A Voice-Controlled
Multi-Functional Smart Home Automation System", in IEEE
INDICON Conference, 2015
[3] World Health of Organization report on, "World Report on
disability", p.53, 2011
[4] http://censusindia.gov.in/Census_And_You/disabled_population.aspx
[5] M.Tharaniya soundhari, Ms.S.Brilly Sangeetha, "Intelligent
Interface Based Speech Recognition for Home Automation
using Android Application", in 2nd International Conference
on Innovations in Information Embedded and Communication
Systems(ICIIECS), 2015
[6] Dave Evans, "The Internet of Things, How the Next Evolution
of the Internet Is Changing Everything", Cisco Internet Business
Solutions Group (IBSG), April 2011
[7] Ravi Sekhar Yarrabothu, Bramarambika Thota, "ABHAYA: AN
ANDROID APP FOR THE SAFETY OF WOMEN", in IEEE
INDICON Conference, 2015
[8] Xuetao Wei, Iulian Neamtiu, Michalis Faloutsos, "Whom Does
Your Android App Talk To?", in IEEE Global Communications
Conference (GLOBECOM), 2015
[9] Jinn-Kwei Guo, Chun-Lin Lu, Ju-Yun Chang, Yi-Jing Li, Ya-Chi
Huang, Fu-Jiun Lu and Ching-Wen Hsu, "Interactive Voice-
Controller Applied to Home Automation", in 5th International
Conference on Intelligent Information Hiding and Multimedia
Signal Processing, 2009
[10] https://espressif.com/en/products/hardware/esp8266ex/overview
[11] http://appinventor.mit.edu/explore/designer-blocks.html
[12] https://www.arduino.cc/en/reference/libraries
466View publication statsView publication stats