0% found this document useful (0 votes)
4 views45 pages

IoT Based Smart Home Applications Control

This paper proposes an affordable home automation system that utilizes Google Assistant for voice control, allowing users to manage up to eight appliances for approximately $10, excluding the cost of a smartphone. The system is built using the NodeMCU microcontroller and the Blynk application, enabling communication over Wi-Fi to control household devices through relays. The design aims to make smart home technology accessible to a broader audience, moving beyond the high costs associated with existing smart home solutions.

Uploaded by

khsheth
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views45 pages

IoT Based Smart Home Applications Control

This paper proposes an affordable home automation system that utilizes Google Assistant for voice control, allowing users to manage up to eight appliances for approximately $10, excluding the cost of a smartphone. The system is built using the NodeMCU microcontroller and the Blynk application, enabling communication over Wi-Fi to control household devices through relays. The design aims to make smart home technology accessible to a broader audience, moving beyond the high costs associated with existing smart home solutions.

Uploaded by

khsheth
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 45

IOT Based Smart Home Applications Control

ABSTRACT
This paper presents a proposal for home automation using voice via Google Assistant.
Home automation or domotics a term for home automation coined by Jim Hill has been evolving
drastically. We saw many home automation technologies introduced over these years from
Zigbee automation to Amazon Echo, Google Home and Home from Apple. It has become a craze
these days. Google Home price is around 150$ (USD) with an additional cost of the devices to be
connected to, the total cost of the system reaches over 250$ (USD). Apple Home Kit too is pretty
more expensive, over 100$ (USD) more than the Google Home just for a basic setup. Philips Hue,
a smart light which is controlled by the Google Assistant, Amazon Echo and Siri, voice assistant
by Apple is priced around 145$ (USD). Similarly, Belikin’s Wemo light is priced around 44$ (USD)
per unit and this can be controlled both by Siri and Google Assistant. So, overall we can see here
that to make our home smart we need to invest quite a lot, let’s say some 250$ (USD) for a basic
setup. What if we can automate our house within (cost of the Smartphone is not included as it is
assumed to be owned by every individual these days) 10$ (USD) and can control up to 8
appliances using Google Assistant? Well, this paper describes the implementation of such a
system. The system is implemented using ordinary household appliances using Blynk
application, the commands are decoded and then sent to the microcontroller, the
microcontroller in turn controls the relays connected to it as required, turning the device
connected to the respective relay On or OFF as per the users request to the Google Assistant.
The microcontroller used is NodeMCU (ESP8266) and the communication between the
microcontroller and the application is established via Wi-Fi (Internet).

Department of Electronics & Communication Engineering 1


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

1. INTRODUCTION

Home, it is the place where one fancies or desires to be after a long tiring day. People
come home exhausted after a long hard working day. Some are way too tired that they find it
hard to move once they land on their couch, sofa or bed. So any small device/technology that
would help them switch theirs lights on or off, or play their favorite music etc. on a go with their
voice with the aid of their smart phones would make their home more comfortable. Moreover,
it would be better if everything such as warming bath water and adjusting the room
temperature were already done before they reach their home just by giving a voice command.
So, when people would arrive home, they would find the room temperature, the bath water
adjusted to their suitable preferences, and they could relax right away and feel cozier and
rather, feel more homely.

Human assistants like housekeepers were a way for millionaires to keep up their homes
in the past. Even now when technology is handy enough only the well to do people of the
society are blessed with theses new smart home devices, as these devices costs are a bit high.
However, not everyone is wealthy enough to be able to afford a human assistant, or some smart
home kit. Hence, the need for finding an inexpensive and smart assistant for normal families
keeps growing.

This paper proposes such inexpensive system. It uses the BLYNL IoT application, the
Blynk application and the NodeMCU microcontroller as the major components along with a
relay board comprising of 4/8 relays along with ULN 2803 IC.

Department of Electronics & Communication Engineering 2


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

2.SYSTEM DESIGN AND IMPLEMENTATION

The system design is broken down into two main categories,

i. The hardware- It has the capability to connect to the router. It would also be able to
turn on/off specified devices, such as lights and fans. It is called the ‘Control Unit’. And,

ii. The Software- The Blynk app, Arduino IDE.

The Control Unit comprises of the microcontroller- NodeMCU and the 4/8 Channel Relay
board. Relay board uses ULN 2803 IC to control the relays. The Blynk app on an Android
device communicates with the microcontroller and sends the desired signal via the
internet. Figure 1 below shows the basic system design architecture.

Department of Electronics & Communication Engineering 3


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

3. PROPOSED HARDWARE ARCHITECTURE

LCD 2 X 16

DC
POWER SUPPLY

Temp Sensor
(DHT 11) Node

MCU

Relay
Driver

12 Channel
Relay

Department of Electronics & Communication Engineering 4


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

4.HARDWARE DESCRIPTION

What is NodeMcu ESP8266 ?

NodeMcu

NodeMCU is an open source IoT platform. Which includes firmware which runs on the
ESP8266 Wi-Fi Module from Espressif Systems,and hardware which is based on the ESP-
12 module. The term “NodeMCU” by default refers to the firmware rather than the dev
kits. NodeMCU firmware was developed so that AT commands can be replaced with Lua
scripting making the life of developers easier. So it would be redundant to use AT
commands again in NodeMCU.

NodeMcu ESP8266

Department of Electronics & Communication Engineering 5


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

The ESP8266 is a low-cost Wi-Fi chip with full TCP/IP stack and microcontroller capability
produced by Shanghai-based Chinese manufacturer, Espressif.

ESP8266 Feature:

Open-source

Interactive

Programmable

Low cost

Simple

Smart

WI-FI enabled

USB-TTL included

Plug & Play

NodeMCU DEVKIT 1.0 Specification:


Developer : ESP8266 Opensource Community
Type : Single-board microcontroller
Operating system : XTOS
CPU : ESP8266
Memory : 128kBytes
Storage : 4MBytes
Power By : USB
Power Voltage : 3v ,5v (used with 3.3v Regulator which inbuilt on Board using Pin VIN)
Code : Arduino Cpp
IDE Used : Arduino IDE
GPIO : 10
Department of Electronics & Communication Engineering 6
HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

NodeMCU Pinout ESP8266

NodeMCU ESP8266 based boards were first introduced with LUA scripting language for
programming but since Arduino IDE is most popular among electronic hobbyist for
programming the development boards, so this leads to the esp8266 package that needs
to be added to Arduino IDE for programming ESP based boards. Since the NodeMCU
ESP8266 boards were designed for a different architecture but later on implemented for
Arduino IDE, as a result, we needed GPIO pin mapping of NodeMCU pinout that is
marked on the board from D0-D8 but while in coding we use the mapped GPIO pin no.
so that (note that in latest IDE we can directly write the pins as D0, D1 or so.)

Here is the NodMCU Pinout of the Pins mapped with there corresponding values of
GPIO no. For example – D7 pin mapped to GPIO pin 13. so, in coding, we need to declare
the D7 as pin 13.

Department of Electronics & Communication Engineering 7


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Advantages of Node Mcu

 Low energy consumption

 Integrated support for WIFI network

 Reduced size of the board

 Low Cost

Disadvantages of Node Mcu

 Need to learn a new language and IDE

 Less pinout

]
Department of Electronics & Communication Engineering 8
HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

5.LITERATURE SURVEY

1. Microcontroller Based Home Security and Load Controlling Using


Gsm Technology
Mustafijur Rahman Dept of EEE, University of Asia Pacific Dhanmondi, Dhaka-1209, Bangladesh
Email: [email protected]

Abstract—“Home automation” referred to as „Intelligent home‟ or „automated home‟,


indicates the automation of daily tasks with electrical devices used in homes. This could be the
control of lights or more complex chores such as remote viewing of the house interiors for
surveillance purposes. The emerging concept of smart homes offers a comfortable, convenient
and safe and secure environment for occupants. These include automatic load controlling, fire
detection, temperature sensing, and motion detection and lock system etc. Furthermore it has
advanced security compared to other houses and can send a message to the user for action that
occur inside his/her house while he/she is away from home. It can also allow a person to control
appliances from a remote location by mobile phone using GSM technology.

Index Terms—Home automation, Load controlling, Fire detection, Temperature sensing,


Motion detection, Lock system, GSM technology.

INTRODUCTION
As technology is advancing, so houses are also getting smarter. Modern houses are gradually
shifting from conventional switches to centralized control system. Smart home automations
gives the owner of a home an ultimate control over his or her home by automating lighting
system, dimming, electrical appliances. Smart automated homes connect all the devices and
appliances in user‟s home so they can communicate with each other. This advanced technology
is used to do automation of a house activities, so it is also can be called as home automation [1],
[2]. A smart home can be controlled by remote interface to home automation system itself via
wireless technology [3], [4], [5]. A smart home automation can turn on and off a fan, light, air
condition and also can control the speed of fan with the help of a mobile controller according to

Department of Electronics & Communication Engineering 9


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

user needs. Because mobile controlled home automation system provides a simpler solution of
a GSM network [6], [7]. It will help to shut down the whole system, improves the convenience
and comfort of the user while it provides security and energy efficiency. GSM is used to
digitalize a signal or data and transmit signal or data to the receiver. GSM (Global System for
Mobile Communication) module can be used to send the signal over a mobile in a fixed
frequency to other mobile phone connected with the receiver. In between 1915 and 1920
electrical home appliance introduced. The smart home`s history can be easily traced back to the
early turn of the century, where electrical and telephone wiring were installed in new houses.
Integrated smart home infrastructure was usually built by hobbyist in the 1960s, built it was not
until 1984 the term ``Smart Home`` was coined by the American Association of Home Builders.
General Electric company was one of the first pioneers to develop a series of products made for
smart automated homes in the mid 60`s, these products included portable automatic dish
washers and microwaves.

2. Remote-Controlled Home Automation Systems with Different


Network Technologies
Armando Roy Delgado, Rich Picking and Vic Grout Centre for Applied Internet Research (CAIR),
University of Wales, NEWI, Wrexham, UK {a.delgado|r.picking||v.grout}@newi.ac.uk

Abstract
This paper describes an investigation into the potential for remote controlled operation of home
automation systems. It considers problems with their implementation, discusses possible
solutions through various network technologies and indicates how to optimize the use of such
systems. The home is an eternal, heterogeneous, distributed computing environment (Greaves,
2002) which certainly requires a careful study before developing any suitable Home Automation
System (HAS) that will accomplish its requirements. Nevertheless the latest attempts at
introducing Home Automation Systems in actual homes for all kinds of users are starting to be
successful thanks to the continuous standardization process that is lowering the prices and
making devices mo re useful and easier to use for the end user. Even so several important issues

Department of Electronics & Communication Engineering 10


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

are always to be handled strictly before developing and installing a Home Automation System;
factors like security, reliability, usefulness, robustness and price are critical to determine if the
final product will accomplish the expected requirements. Keywords Home Automation Systems,
Home network, Domotics, Ubiquitous access, User-friendly interfaces, Standards.

Introduction:
Evolution of Home Automation Systems. The concept of “automation” has existed for
many years. It began with a student connecting two electric wires to the hands of an alarm clock
in order to close a circuit of a battery and light bulb. Later, companies developed automated
systems of their own to control alarms, sensors, actuators and video cameras and, in so doing,
created the first automated buildings. The term “intelligent home” followed. Due to the obvious
advantages of these systems, their influence on the conventional home was predictable and
finally, in 1988, the term domotics was coined. “Domotics is the application of computer and
robot technologies to domestic appliances. It is a portmanteau word formed from domus (Latin,
meaning house) and robotics” (click on this link for more information
http://en.wikipedia.org/wiki/Domotics). A modern definition of Domotics could be the
interaction of technologies and services applied to different buildings with the purpose of
increasing security, comfort, communications and energy savings (Moraes et al., 2000). At the
beginning automated devices were independent or, sometimes, grouped in small independent
systems. But the idea of giving them interoperability using a common “language” keeps on
growing up, consequently following such idea the first Home Automation Systems (HASs)
appeared bringing a new concept of a home network full of possibilities, but this included also
new factors to bear in mind.

Department of Electronics & Communication Engineering 11


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

BASICS OF IoT:
Definition the Internet of Things (IoT) is the interconnection of uniquely identifiable
embedded computing devices within the existing Internet infrastructure. The “Internet
of Things” connects devices and vehicles using electronic sensors and the Internet.

Introduction The Internet of Things (IoT) is the network of physical objects devices,
vehicles, buildings and other items embedded with electronics, software, sensors, and
network connectivity that enables these objects to collect and exchange data. The IoT
allows objects to be sensed and controlled remotely across existing network
infrastructure, creating opportunities for more direct integration of the physical world
into computer based systems, and resulting in improved efficiency, accuracy and
economic benefit, when IoT is augmented with sensors and actuators, the technology
becomes an instance of the more general class of cyber physical systems, which also
encompasses technologies such as smart grids, smart homes, intelligent transportation
and smart cities. Each thing is uniquely identifiable through its embedded computing
system but is able to interoperate within the existing Internet infrastructure.

So, Internet of Things or IoT is an architecture that comprises specialized hardware


boards, Software systems, web APIs, protocols which together creates a seamless
environment which allows smart embedded devices to be connected to internet such
that sensory data can be accessed and control system can be triggered over internet.

Department of Electronics & Communication Engineering 12


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

HARDWARE DESCRIPTION
REGULATED POWER SUPPLY:

The power supplies are designed to convert high voltage AC mains electricity to
a suitable low voltage supply for electronic circuits and other devices. A RPS (Regulated
Power Supply) is the Power Supply with Rectification, Filtering and Regulation being
done on the AC mains to get a Regulated power supply for Microcontroller and for the
other devices being interfaced to it.

A power supply can by broken down into a series of blocks, each of which
performs a particular function. A d.c power supply which maintains the output voltage
constant irrespective of a.c mains fluctuations or load variations is known as “Regulated
D.C Power Supply”

For example a 5V regulated power supply system as shown below:

Department of Electronics & Communication Engineering 13


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Transformer:
A transformer is an electrical device which is used to convert electrical power from
one Electrical circuit to another without change in frequency.

Transformers convert AC electricity from one voltage to another with little loss
of power. Transformers work only with AC and this is one of the reasons why mains
electricity is AC. Step-up transformers increase in output voltage, step-down
transformers decrease in output voltage. Most power supplies use a step-down
transformer to reduce the dangerously high mains voltage to a safer low voltage. The
input coil is called the primary and the output coil is called the secondary. There is no
electrical connection between the two coils; instead they are linked by an alternating
magnetic field created in the soft-iron core of the transformer. The two lines in the middle
of the circuit symbol represent the core. Transformers waste very little power so the
power out is (almost) equal to the power in. Note that as voltage is stepped down current
is stepped up. The ratio of the number of turns on each coil, called the turn’s ratio,
determines the ratio of the voltages. A step-down transformer has a large number of turns
on its primary (input) coil which is connected to the high voltage mains supply, and a
small number of turns on its secondary (output) coil to give a low output voltage.

An Electrical Transformer

Department of Electronics & Communication Engineering 14


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Turns ratio = Vp/ VS = Np/NS


Power Out= Power In
VS X IS=VP X IP
Vp = primary (input) voltage
Np = number of turns on primary coil
Ip = primary (input) current

RECTIFIER:

A circuit which is used to convert ac to dc is known as RECTIFIER. The process of


conversion ac to dc is called “rectification”

TYPES OF RECTIFIERS:

 Half wave Rectifier


 Full wave Rectifier
1. Centre tap full wave rectifier.

2. Bridge type full bridge rectifier.

Department of Electronics & Communication Engineering 15


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Comparison of rectifier circuits:


Type of Rectifier

Parameter Half wave Full wave Bridge

Number of diodes 1 2 4

PIV of diodes Vm 2Vm Vm

D.C output voltage Vm/z 2Vm/ 2Vm/

Vdc at no-load 0.318Vm 0.636Vm 0.636Vm

Ripple factor 1.21 0.482 0.482

Ripple frequency f 2f 2f

Rectification efficiency 0.406 0.812 0.812

Transformer Utilization
Factor(TUF)
0.287 0.693 0.812

RMS voltage Vrms Vm/2 Vm/√2 Vm/√2

Department of Electronics & Communication Engineering 16


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Full-wave Rectifier:
From the above comparison we came to know that full wave bridge
rectifier as more advantages than the other two rectifiers. So, in our project we are using full
wave bridge rectifier circuit.

Bridge Rectifier:
A bridge rectifier makes use of four diodes in a bridge arrangement to
achieve full-wave rectification. This is a widely used configuration, both with
individual diodes wired as shown and with single component bridges where the
diode bridge is wired internally.

A bridge rectifier makes use of four diodes in a bridge arrangement as shown in fig (a) to
achieve full-wave rectification. This is a widely used configuration, both with individual diodes
wired as shown and with single component bridges where the diode bridge is wired internally.

Fig (A)

Operation: During positive half cycle of secondary, the diodes D2 and D3 are in forward
biased while D1 and D4 are in reverse biased as shown in the fig(b). The current flow direction is
shown in the fig (b) with dotted arrows.

Department of Electronics & Communication Engineering 17


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Fig (B)
During negative half cycle of secondary voltage, the diodes D1 and D4 are in forward
biased while D2 and D3 are in reverse biased as shown in the fig(c). The current flow direction is
shown in the fig (c) with dotted arrows.

Fig(C)

Filter:
A Filter is a device which removes the ac component of rectifier output but allows the
dc component to reach the load.

Department of Electronics & Communication Engineering 18


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Capacitor Filter:

We have seen that the ripple content in the rectified output of half wave rectifier is
121% or that of full-wave or bridge rectifier or bridge rectifier is 48% such high percentages of
ripples is not acceptable for most of the applications. Ripples can be removed by one of the
following methods of filtering.

(a) A capacitor, in parallel to the load, provides an easier by –pass for the ripples voltage though
it due to low impedance. At ripple frequency and leave the D.C. to appear at the load.

(b) An inductor, in series with the load, prevents the passage of the ripple current (due to high
impedance at ripple frequency) while allowing the dc (due to low resistance to dc).

(c) Various combinations of capacitor and inductor, such as L-section filter section filter,
multiple section filter etc. which make use of both the properties mentioned in (a) and (b)
above. Two cases of capacitor filter, one applied on half wave rectifier and another with full
wave rectifier.

Filtering is performed by a large value electrolytic capacitor connected across the DC


supply to act as a reservoir, supplying current to the output when the varying DC voltage from
the rectifier is falling. The capacitor charges quickly near the peak of the varying DC, and then
discharges as it supplies current to the output. Filtering significantly increases the average DC
voltage to almost the peak value (1.4 × RMS value).

To calculate the value of capacitor(C),


C = ¼*√3*f*r*Rl
Where,
f = supply frequency,
r = ripple factor,
Rl = load resistance
Note: In our circuit we are using 1000µF hence large value of capacitor is placed
to reduce ripples and to improve the DC component.

Department of Electronics & Communication Engineering 19


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Regulator:
Voltage regulator ICs is available with fixed (typically 5, 12 and 15V) or variable output
voltages. The maximum current they can pass also rates them. Negative voltage regulators are
available, mainly for use in dual supplies. Most regulators include some automatic protection
from excessive current ('overload protection') and overheating ('thermal protection'). Many of
the fixed voltage regulators ICs have 3 leads and look like power transistors, such as the 7805
+5V 1A regulator shown on the right. The LM7805 is simple to use. You simply connect the
positive lead of your unregulated DC power supply (anything from 9VDC to 24VDC) to the Input
pin, connect the negative lead to the Common pin and then when you turn on the power, you
get a 5 volt supply from the output pin.

Fig 6.1.6 A Three Terminal Voltage Regulator

78XX:

The Bay Linear LM78XX is integrated linear positive regulator with three terminals. The
LM78XX offer several fixed output voltages making them useful in wide range of applications.
When used as a zener diode/resistor combination replacement, the LM78XX usually results in an
effective output impedance improvement of two orders of magnitude, lower quiescent current.
The LM78XX is available in the TO-252, TO-220 & TO-263packages,

Department of Electronics & Communication Engineering 20


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Features:

• Output Current of 1.5A

• Output Voltage Tolerance of 5%

• Internal thermal overload protection

• Internal Short-Circuit Limited

• Output Voltage 5.0V, 6V, 8V, 9V, 10V, 12V, 15V, 18V, 24V.

Department of Electronics & Communication Engineering 21


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Relay Driver ULN 2803:

IC ULN 2004

1 16

2 15

3 14

4 13

5 12

6 11

7 10

8 9
Vcc

Department of Electronics & Communication Engineering 22


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Since the digital outputs of the some circuits cannot sink much current, they are not capable of
driving relays directly. So, high-voltage high-current Darlington arrays are designed for
interfacing low-level logic circuitry and multiple peripheral power loads. The series
ULN2000A/L ICs drive seven relays with continuous load current ratings to 600mA for each
input. At an appropriate duty cycle depending on ambient temperature and number of drivers
turned ON simultaneously, typical power loads totaling over 260W [400mA x 7, 95V] can be
controlled. Typical loads include relays, solenoids, stepping motors, magnetic print hammers,
multiplexed LED and incandescent displays, and heaters. These Darlington arrays are furnished
in 16-pin dual in-line plastic packages (suffix A) and 16-lead surface-mountable SOICs (suffix
L). All devices are pinned with outputs opposite inputs to facilitate ease of circuit board layout.

The input of ULN 2004 is TTL-compatible open-collector outputs. As each of these outputs can
sink a maximum collector current of 500 mA, miniature PCB relays can be easily driven. No
additional free-wheeling clamp diode is required to be connected across the relay since each of
the outputs has inbuilt free-wheeling diodes. The Series ULN20x4A/L features series input
resistors for operation directly from 6 to 15V CMOS or PMOS logic outputs.

1N4148 signal diode:

Signal diodes are used to process information (electrical signals) in circuits, so they are
only required to pass small currents of up to 100mA. General purpose signal diodes such
as the 1N4148 are made from silicon and have a forward voltage drop of 0.7V.

Department of Electronics & Communication Engineering 23


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

6.RELAYS

6.1 Introduction:

One simple method of providing electrical isolation between two circuits is to place a
relay between them, as shown in the circuit diagram of figure 1. A relay consists of a coil which
may be energised by the low-voltage circuit and one or more sets of switch contacts which may
be connected to the high-voltage circuit.

Fig: 6.1 Relay Providing Isolation between two circuits

6.2 How Relays Work

In figure 2a the relay is off. The metal arm is at its rest position and so there is contact
between the Normally Closed (N.C.) switch contact and the 'common' switch contact.

If a current is passed through the coil, the resulting magnetic field attracts the metal arm
and there is now contact between the Normally Open (N.O.) switch contact and the common
switch contact, as shown in figure 2b.

Department of Electronics & Communication Engineering 24


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Fig: 6.2 Showing Mechanical Operation of Relay

6.3 The Latching Relay Circuit

If a relay is connected as shown in figure 3, it will become 'latched' on when the coil is
energised by pressing the Trigger button. The only way to turn the relay off will then be to cut
the power supply by pressing the Reset button (which must be a push-to-break type).

Fig: 6.3 Showing The Latching Relay Circuit

Department of Electronics & Communication Engineering 25


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

DHT11 Temperature and Humidity Sensor

DHT11 is a part of DHTXX series of Humidity sensors. The other sensor in this series is
DHT22. Both these sensors are Relative Humidity (RH) Sensor. As a result, they will
measure both the humidity and temperature. Although DHT11 Humidity Sensors are
cheap and slow, they are very popular among hobbyists and beginners.

The DHT11 Humidity and Temperature Sensor consists of 3 main components. A


resistive type humidity sensor, an NTC (negative temperature coefficient) thermistor (to
measure the temperature) and an 8-bit microcontroller, which converts the analog
signals from both the sensors and sends out single digital signal. This digital signal can
be read by any microcontroller or microprocessor for further analysis.

Department of Electronics & Communication Engineering 26


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

DHT11 Humidity Sensor consists of 4 pins: VCC, Data Out, Not Connected (NC) and GND.
The range of voltage for VCC pin is 3.5V to 5.5V. A 5V supply would do fine. The data
from the Data Out pin is a serial digital data.

The following image shows a typical application circuit for DHT11 Humidity and
Temperature Sensor. DHT11 Sensor can measure a humidity value in the range of 20 –
90% of Relative Humidity (RH) and a temperature in the range of 0 – 500C. The sampling
period of the sensor is 1 second i.e.

Department of Electronics & Communication Engineering 27


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

How DHT11 Measures Temperature and Humidity

Inside the DHT11, there is a humidity sensing component along with a Thermistor.

Humidity sensing component has two electrodes with moisture holding substrate
sandwiched between them.

The ions are released by the substrate as water vapor is absorbed by it, which in turn
increases the conductivity between the electrodes.

The change in resistance between the two electrodes is proportional to the relative
humidity. Higher relative humidity decreases the resistance between the electrodes,
while lower relative humidity increases the resistance between the electrodes.

Department of Electronics & Communication Engineering 28


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

DHt11 also contains a NTC/Thermistor to measure temperature. A thermistor is a


thermal resistor whose resistance changes drastically with temperature. The term “NTC”
means “Negative Temperature Coefficient”, which means that the resistance decreases
with increase of the temperature.

On the other side, there is a small PCB with an 8-bit SOIC-14 packaged IC. This IC
measures and processes the analog signal with stored calibration coefficients, does
analog to digital conversion and spits out a digital signal with the temperature and
humidity.

DHT11 Module Hardware Overview

At the heart of the module is the digital temperature & humidity sensor manufactured
by AOSONG – DHT11.

Department of Electronics & Communication Engineering 29


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

DHT11 Sensor

DHT11 can measure temperature from 0°C to 50°C with ±2.0°C accuracy, and humidity
from 20 to 80% with 5% accuracy.

Note that the sampling rate of the DHT11 is 1Hz, meaning you can get new data from it
once every second.

Supporting Circuitry

The module comes with all the essential supporting circuitry, so it should be ready to
run without any extra components.

Department of Electronics & Communication Engineering 30


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

The DHT11 sensors usually require external pull-up resistor of 10KΩ between VCC and
Out pin for proper communication between sensor and the Arduino. However, the
module has a built-in pull-up resistor, so you need not add it.

The module also has a decoupling capacitor for filtering noise on the power supply.

DHT11 Module Pinout

The DHT11 module is fairly easy to connect. It has only three pins:

Department of Electronics & Communication Engineering 31


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

+ (VCC) pin supplies power for the sensor. 5V supply is recommended, although the
supply voltage ranges from 3.3V to 5.5V. In case of 5V power supply, you can keep the
sensor as long as 20 meters. However, with 3.3V supply voltage, cable length shall not
be greater than 1 meter. Otherwise, the line voltage drop will lead to errors in
measurement.
Out pin is used to communication between the sensor and the Arduino.
– (GND) should be connected to the ground of Arduino.

Department of Electronics & Communication Engineering 32


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

All the DHT11 Sensors are accurately calibrated in the laboratory and the results are
stored in the memory. A single wire communication can be established between any
microcontroller like Arduino and the DHT11 Sensor.

Also, the length of the cable can be as long as 20 meters. The data from the sensor
consists of integral and decimal parts for both Relative Humidity (RH) and temperature.

Department of Electronics & Communication Engineering 33


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

7.SOFTWARE REQUIREMENT

Arduino

Arduino is a type of computer software and hardware company that offers open-source
environment for user project and user community that intends and fabricates
microcontroller based inventions for construction digital devices and interactive objects
that can sense and manage the physical world. For programming the microcontrollers,
the Arduino proposal provides an software application or IDE based on the Processing
project, which includes C, C++ and Java programming software. It also support for
embedded C, C++ and Java programming software.

Arduino is an open-source computer hardware and software company, project and user
community that designs and manufactures microcontroller-based kits for building digital
devices and interactive objects that can sense and control the physical world. The
boards feature serial communications interfaces, including USB on some models, for
loading programs from personal computers. For programming the microcontrollers, the
Arduino platform provides an integrated development environment (IDE) based on the
Processing project, which includes support for C, C++ and Java programming languages.

An Arduino board consists of an Atmel 8, 16 or 32-bit AVR microcontroller with


complementary components that facilitate programming and incorporation into other
circuits. An important aspect of the Arduino is its standard connectors, which lets users
connect the CPU board to a variety of interchangeable add-on modules known as shields
. Some shields communicate with the Arduino board directly over various pins, but
many shields are individually addressable via an I²C serial bus so many shields can be
stacked and used in parallel. Official Arduinos have used the mega AVR series of chips,
specifically the ATmega8 , ATmega168.

Department of Electronics & Communication Engineering 34


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

An Arduino's microcontroller is also pre-programmed with a boot loader that simplifies


uploading of programs to the on-chip flash memory, compared with other devices that
typically need an external programmer. This makes using an Arduino more
straightforward by allowing the use of an ordinary computer as the programmer.
Currently, opti boot loader is the default boot loader installed on Arduino UNO. An
Arduino's microcontroller is also pre-programmed with a boot loader that simplifies
uploading of programs to the on-chip flash memory, compared with other devices that
typically need an external programmer. This makes using an Arduino more
straightforward by allowing the use of an ordinary computer as the programmer.

Department of Electronics & Communication Engineering 35


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

How Blynk Works

Blynk was designed for the Internet of Things. It can control hardware remotely, it can
display sensor data, it can store data, vizualize it and do many other cool things.

There are three major components in the platform:

Blynk App - allows to you create amazing interfaces for your projects using various
widgets we provide.

Blynk Server - responsible for all the communications between the smartphone and
hardware. You can use our Blynk Cloud or run your private Blynk server locally. It’s
open-source, could easily handle thousands of devices and can even be launched on a
Raspberry Pi.

Blynk Libraries - for all the popular hardware platforms - enable communication with
the server and process all the incoming and outcoming commands.

Now imagine: every time you press a Button in the Blynk app, the message travels to
space the Blynk Cloud, where it magically finds its way to your hardware. It works the
same in the opposite direction and everything happens in a blynk of an eye.

Department of Electronics & Communication Engineering 36


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Features

 Similar API & UI for all supported hardware & devices

 Connection to the cloud using:

 WiFi

 Bluetooth and BLE

 Ethernet

 USB (Serial)

 GSM

Department of Electronics & Communication Engineering 37


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

 Set of easy-to-use Widgets

 Direct pin manipulation with no code writing

 Easy to integrate and add new functionality using virtual pins

 History data monitoring via SuperChart widget

 Device-to-Device communication using Bridge Widget

 Sending emails, tweets, push notifications, etc.

 … new features are constantly added!

What do I need to Blynk?

At this point you might be thinking: “Ok, I want it. What do I need to get started?” – Just a couple of
things, really:

1. Hardware.

An Arduino, Raspberry Pi, or a similar development kit.

Blynk works over the Internet. This means that the hardware you choose should be able to connect
to the internet. Some of the boards, like Arduino Uno will need an Ethernet or Wi-Fi Shield to
communicate, others are already Internet-enabled: like the ESP8266, Raspberri Pi with WiFi dongle,
Particle Photon or SparkFun Blynk Board. But even if you don’t have a shield, you can connect it over
USB to your laptop or desktop (it’s a bit more complicated for newbies, but we got you covered).
What’s cool, is that the list of hardware that works with Blynk is huge and will keep on growing.

Department of Electronics & Communication Engineering 38


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

2. A Smartphone.

Enter the Blynk App

The Blynk app is available for free on Android and iOS. It’s the starting point for your
projects, featuring a simple to use drag and drop system for building custom controls for
your IoT setup. The workflow is fast: when starting a new project you’re prompted to
choose your development board from an extensive list, and also your method of
connection. The app then sends an authorization token via email for connecting to your
device over the Blynk server.

Control elements are called Widgets: various types of input methods and output
displays including buttons, sliders, a joystick, graphs and text feedback. There are also
component specific widgets, with stylized controls for LEDS, LCD displays, and even live
streamed video. Also notable are widgets that add features, like automatic posting to
Twitter, and custom notifications.

While the app is free, it limits how many widgets you can use at once by giving them all
an “Energy” cost. The app gives a balance of 2,000 to play with, with the option to buy
more if needed.

Department of Electronics & Communication Engineering 39


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Each widget has an editing menu allowing you to change the name and color. You then
choose which pin to affect (whether it be a pin on your board or one of Blynk’s virtual
pins) along with the range of values to send. For output displays such as graphs and text
boxes, you can also choose how often you wish it to be updated, potentially saving
precious bandwidth.

Blynk also features the ability to assign instructions to “virtual” pins, which are user
configured connections between the app and the hardware. A single button in the app
can therefore be used to trigger many different events on the device. We’ll cover how
to use these later in the article. The app gives the option of sharing the project with
others. A QR code is generated which can be sent via email or scanned directly, and
used by anyone who also has the Blynk app.

Department of Electronics & Communication Engineering 40


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Flowchart:

Department of Electronics & Communication Engineering 41


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

Conclusion

The project is implemented in hardware and software components that interact through
network connections. The main challenge is to implement the project in an economical
way such that it can be easily deployed and used by homeowners. The data is collected
from sensors by the Arduino. Arduino microcontroller is connected to the LAN with
Ethernet shield. The configuration of the Arduino for Ethernet shield contains a static IP
address for the shield and the local server. Arduino via the shield sends data every 5
seconds (can be adjusted) to the server via a URL using Get method. Server accepts the
data and updates the database in the right columns and through in the same time gets
the manual/automatic command with other switch status from the correct columns too.
The smartphone reads data from the server using JSON method to get sensor values and
display them on screen and updates the switch columns on the database if the user has
clicked on them.

Limitations and future work.


 The project has few limitations that as follows:

 The system is vulnerable to the different types of attacks.

 Hardware limitation i.e. NodeMCU have low performance and low number of pins

 The need of a laptop as local server

 There must be an internet connection on the router.

 Low range of connectivity i.e. we can’t connect outside the range of LAN.

Department of Electronics & Communication Engineering 42


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

8.ADVANTAGES AND DISADVANTAGES

Advantages :

1. Smart phone provides help and assistance especially to disabled and elderly.
2. In order to provide safety protection to the user.
3. A low voltage activating switches is replaced current electrical switches.
4. Implementation of wireless Bluetooth connection in control board allows the system
install in more simple way.
5. This low cost system is designed to improve the standard living in home.

Disadvantages :

1. Coverage area is within some limit.


2. Requirement of smart phones.

APPLICATIONS:

1. Home Automation
2. Office, school, college
3. Garden automation
4. Status Monitoring and Control
5. Intelligent Buildings
6. Signs and Information Displays
7. Fire and Security Alarm System

Department of Electronics & Communication Engineering 43


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

9.CONCLUSION AND FUTURE WORK

The aim of this paper was to propose a cost effective home automation
controlling general appliances found in one’s home. The approach discussed in the
paper was successful as IoT home automation design was successfully implemented.
This system is highly reliable and efficient for the aged people and differently abled
person on a wheel chair who cannot reach the switch for the switching ON/OFF the
device and are dependent on others.

The future scope for IoT home automation can be huge. There are many factors
to improve on to make IoT home automation more powerful, intelligent, scalable, and
to become better overall for home automation. For example, controlling the speed of
the fan, more number of devices can be integrated, like a coffee machine, air
conditioner etc. To make the system respond more faster own private Blynk server can
be made. Well, no system is ever perfect. It always has a scope for improvement. One
just needs to put on a thinking cap and try and make the system more better.

Department of Electronics & Communication Engineering 44


HKE Society’s Women’s Polytechnic, Kalaburagi
IOT Based Smart Home Applications Control

REFERENCES
*1+ IEA, “Fact Sheet: Standby Power Use and the IEA “1 Watt Plan”,” Apr.2007.
http://www.iea.org/

textbase/papers/2007/standby_fact.pdf

*2+ IEA, “Reducing Standby Power Waste to Less Than 1 Watt: A Relevant Global Strategy that
Delivers,”

2002.http://www.iea.org/Textbase/papers/2002/globe02.pdf

*3+ Calboun B.H., Chandrakasan A.P., “Standby Power Reduction Using Scaling and Carry Flip-
Flop Structures,” IEEE Journal of Solid-State Circuits, vol.39, no.9, pp.1504-1511, Sep. 2004.

[4] Bo-Teng Huang, Ko-Yen Lee and Yen-Shin Lai, “Design of a Two-Stage AC/DC Converter with
Standby Power Losses Less Than 1 W,”Proceedings of Power Conversion Conference 2007,
pp.1630-1635, Apr. 2007.

*6+ Joon Heo et al, “Design and Implementation of Control Mechanism for Standby Power
Reduction,” IEEE Trans. on Consumer Electronics, vol.53, no.1, pp.179-185, Feb. 2008.

[7] Chia-Hung Len, Ying-Wen Bai, and Ming-Bo Lin, “Remote- Controllable Power Outlet System
for Home Power Management,” IEEE Trans. on Consumer Electronics , vol.53, No.4, pp.1634-
1641, Nov. 2007.

[8] Chi-Hung, Chi-Hsiung Lin, Ying-Wen Bai, Ming-Fong Liu and Ming- Bo Lin, “Remotely
Controllable Outlet System for Home

Power Management,” Proceedings of the 2008 International Symposium on Consumer


Electronics, Algarve, Portugal, 14-1 Apr. 2008.

Department of Electronics & Communication Engineering 45


HKE Society’s Women’s Polytechnic, Kalaburagi

You might also like