Internet of Things
Internet of Things
This project presents a low cost flexible and reliable home automation system with additional
security using arduino microcontroller, with ip connectivity through local wifi for accessing and
controlling devices by authorized user remotely using smart phone application. The proposed
system is server independent and uses internet of things to control human desired appliances
starting from industrial machine to consumer goods. The user can also use different devices for
controlling by the help of web-browser, smart phone or ir remote module. To demonstrate the
effectiveness and feasibility of this system, in this paper we present a home automation system
using arduino uno microcontroller and esp8266-01 as a connectivity module. It helps the user to
control various appliances such as light, fan, tv and can take decision based on the feedback of
sensors remotely. We have tested our system through conducted experiment on various
environmental conditions.
1
1.Introduction
IOT or internet of things is an upcoming technology that allows us to control hardware devices
through the internet. Here we propose to use IOT in order to control home appliances, thus
automating modern homes through the internet. This system uses three loads to demonstrate as
house lighting and a fan. Our user friendly interface allows a user to easily control these home
appliances through the internet. For this system we use an AVR family microcontroller. This
microcontroller is interfaced with a wifi modem to get user commands over the internet. Also we
have an LCD display to display system status. Relays are used to switch loads. The entire system
is powered by a 12 V transformer. After receiving user commands over the internet,
microcontroller processes these instructions to operate these loads accordingly and display the
system status on an LCD display. Thus this system allows for efficient home automation over the
internet. Presents a low cost flexible and reliable home automation system with additional
security using Arduino microcontroller, with IP connectivity through local wifi for accessing and
controlling devices by authorized user remotely using Smart phone application. The proposed
system is server independent and uses Internet of things to control human desired appliances
starting from industrial machine to consumer goods. The user can also use different devices for
controlling by the help of web-browser, smart phone or IR remote module. To demonstrate the
effectiveness and feasibility of this system, in this paper we present a home automation system
using Arduino UNO microcontroller and esp8266-01 as a connectivity module. It helps the user
to control various appliances such as light, fan, TV and can take decision based on the feedback
of sensors remotely. We have tested our system through conducted experiment on various
environmental conditions As rapid change in technology always aims to serve the mankind, the
expectation for living a simple yet advance life keeps on increasing Internet has become an
important part of human’s social life and educational life without which they are just helpless.
The Internet of things (Iot) devices not only controls but also monitors the electronic, electrical
and various mechanical systems which are used in various types of infrastructures. These devices
which are connected to the cloud server are controlled by a single user (also known as admin)
which are again transmitted or notified to all the authorized user connected to that network[2-5].
Various electronics and electrical devices are connected and controlled remotely through
2
different network infrastructures. Web browser present in laptop or smart phone or any other
smart technique through which we can operate switches, simply removes the hassle of manually
operating a switch. Now a day’s although smart switches are available they proves to be very
costly, also for their working we required additional devices such as hub or switch [3,6].As there
is rapid change in wireless technology several connectivity devices are available in the market
which solves the purpose of communicating medium with the device and the micro-controller.
Starting from Bluetooth to Wi-Fi, from zigbee to Z-wave and NFC all solve the purpose of
communicating medium. RF and zigbee are used to used in most wireless networks [4,7]. In this
project we have taken ESP8266-01 Wi-Fi module which is programmed through Arduino UNO
to control various devices.
Internet of Things (iot) is a new predominant technology for this advanced world. This technology can
change the lifestyle people lead. Question is what the Internet of Things is? Iot can be described as a
network of physical objects connected through the internet. Physical objects could be anything that
contains embedded electronics, software, sensor, etc. With the internet. Using the IP addresses, those
smart objects can exchange data among the network and can make a decision. A significant number of
researches is going on over the iot trends and projects. In this a Project , we will talk about a few iot
project ideas based on standard iot protocols, so that readers get the basic knowledge about the
Internet of Things. These internet of things example are keen, useful, and interesting to build.
3
Researchers are already working with advance, iot based projects. But we will narrate here basic level
iot projects. Let’s see how many readers like to drive their car using a mobile phone or control home
appliances from office. Similar internet of things example we will discuss below.
First, we are presenting a smart weather monitoring and reporting system here. To update the
report manually is time-consuming. Here the necessity of automated reporting update solution
arises. Iot based weather reporting system brings a solution where this system uses temperature,
humidity rain sensors to monitor weather and report weather statistics online.
It works constantly and sends data via microcontroller to the webserver using the WIFI internet.
This system allows the user to set a threshold for a particular situation and alerts the user if
weather reporting crosses the threshold value.
Important Features
This system does not need human attention to monitor, as it is an automated system.
It helps to collect data in tough environments like a volcano, minefield, polar zone,
etc.
Internet connection is needed to both ends.
The future advancement of this project would be predicting weather forecast and
disaster.
4
To build this project, you have to know how to use Arduino.
It uses a learn-do-review methodology.
Internet of things concept works with almost every machine. But when this is all about our home
appliances, iot proposes a smart, automated system. Using iot based automation system users can
control home stuff anywhere from the world.
In this article, we are talking about a touch-based home automation system based on
microcontroller. It contains WIFI, inbuilt touch sensing input pins, which makes it helpful to
make iot based projects like this.
Important Features
5
2. Literature Review
Home automation is a challenging one not only to the developer but also to the consumer. Developer
has to choose the component as per the customer requirement. Due to all the customer demands are not
equal hence they have to compromise with the existing products. Through detailed study of “Home
Automation Using Internet of Thing” proposed by Shopan Dey, Ayon Roy and Sandip Das, it is found
that they have used Raspberry pi module to connect ESP8266-01 module to the internet. Through this
module they are controlling various devices through web page and also through android application
[2]. K. Venkatesan and Dr. U. Ramachandraiah in their paper have implemented Zigbee module in
Arduino mega through which they are controlling devices. They have used various sensors for various
purpose. Also they have provided real time notification, feedback on web-server in which customers
can see what is happening in their home [1]. With the help of logic gates, a Raspberry pi, 555 timer
and flip-flop also the devices are controlled from web app. Paper proposed by Shashank Shiva Kumar
Jha, Vishwateja Mudiam Reddy, Tapan Pokharna, Naresh Vinay shows how this is operated and
controlled [3]
“Programmable Infrared Accessory Light Switch” by Warsuzarina Mat Jubadi and Normaziah Zulkifli
shows how TV remote is used to control room light and other appliances. Here IR remote and one IR
receiver is used and programmed in such a way that it stores the frequency of the existing remote and
use them directly to control appliances [4]. So, here we introduce Arduino Uno with ESP8266-01
module. This is not only cost-effective but also prove to be the easiest one when it comes in term of
programming and also implementation.
6
2.1. Concluding Remarks on Literature Review
From table 1, it is observed that Esp8266-01 works on 802.11 b/g/n protocol whereas Zigbee uses
802.14.5 protocol. Zigbee consumes least power as 3mw whereas Wi-Fi and Bluetooth consumes
nearly 100mw. But if we compare speed of Esp8266 has maximum speed up to 11mbps but Zigbee has
only 250kbps. Clearly esp8266 defeat Zigbee and Bluetooth not only in cost but also in speed [8,9].
Fig.1 is giving a brief idea about the interconnection of microcontroller , peripheral devices as well as
sensors and what is the architecture behind it.
7
Figure.1 . Network Architecture of iot devices Figure.2 Home automation system
3. System Design
Network Architecture of iot devices Home automation system Figure. Gives an idea about the
operation of home automation system. The four different appliances such as fan, light, room heater and
TV are operated remotely using Wi-Fi and through an application installed on android or iphone.
These appliances are connected through Arduino Uno with its digital input/output pins. These devices
are connected with local Wi-Fi using a communicating module called esp8266-01.
4. Hardware Description
This hardware implementation contains 4 different parts. (i) Arduino as decision maker (ii) Relay for
switching the load automatically, (iii) esp8266 version 1 for connecting to local Wi-Fi and (iv) local
Wi-Fi.
8
It has 6 analog input pins and 14 digital input/output pins[13]. It can operate with either 5V from USB
plug or 12V from external power supply. In Arduino Uno pin 1 and 0 are used as default transmission
and receiving pin.
9
Figure. 4: 4-Channel relay module
4.2.1 Relays
A relay is an electrically operated switch. Current flowing through the coil of the relay creates
a magnetic field which attracts a lever and changes the switch contacts. The coil current can be
on or off so relays have two switch positions and they are double throw (changeover) switches.
Relays allow one circuit to switch a second circuit which can be completely separate from the
first. For example a low voltage battery circuit can use a relay to switch a 230V AC mains
circuit. There is no electrical connection inside the relay between the two circuits, the link is
magnetic and mechanical.
The coil of a relay passes a relatively large current, typically 30ma for a 12V relay, but it can be
as much as 100ma for relays designed to operate from lower voltages. Most ics (chips) cannot
provide this current and a transistor is usually used to amplify the small IC current to the larger
value required for the relay coil. The maximum output current for the popular 555 timer IC is
200ma so these devices can supply relay coils directly without amplification.
Relays are usually SPDT or DPDT but they can have many more sets of switch contacts, for
example relays with 4 sets of changeover contacts are readily available.
Most relays are designed for PCB mounting but you can solder wires directly to the pins
providing you take care to avoid melting the plastic case of the relay.
The supplier's catalogue should show you the relay's connections. The coil will be obvious and it
may be connected either way round. Relay coils produce brief high voltage 'spikes' when they
are switched off and this can destroy transistors and ics in the circuit. To prevent damage you
must connect a protection diode across the relay coil.
The animated picture shows a working relay with its coil and switch contacts. You can see a
lever on the left being attracted by magnetism when the coil is switched on. This lever moves the
switch contacts. There is one set of contacts (SPDT) in the foreground and another behind them,
making the relay DPDT.
The relay's switch connections are usually labelled COM, NC and NO:
10
Connect to COM and NC if you want the switched circuit to be on when the relay coil is off.
11
4.3 ESP8266-01
The ESP8266-01 is a highly compact board, used as a peripheral for any board through serial
(RX/TX) and also as a standalone board. The board requires 3.3 V and can be programmed with
any FTDI operating at 3.3 V. The pins include power (+3.3 V and GROUND), RX / TX, CH_PD
to enable the chip and 2 General Purpose Input Output (GPIO) [14]
Figure. 6: ESP8266-01
4.4 WIFI
Wi-Fi(wireless fidelity) is a wireless communication technology which is used here to provide a
hotspot through which ESP8266-01 module can connect. The router will assign a unique IP
address to the module for establishing a connection between smart phone and ESP8266-01.
12
5. Software Design And Implementation
5.2 Implementation
Figure-8 is providing idea of overall operation of the system. Initially through Arduino
programming, the system checks the modules as well as their connections. If any kind of error is
detected by the system then it will indicate the ERROR status. If no error is found then the system
will indicate the status OK and proceed for establishing the connection with the local Wi-Fi. Here
the system will again check whether the ESP8266- 01 module is connected to the internet.
13
If there is no connection then the system will indicate the ERROR status or else the display will
show status SYSTEM ONLINE and show the IP address. The system will wait for the signal and
switch the load accordingly after receiving the command and update the display.
6. Working
14
Figure.8: Flow chart of programme
To implements our home automation system we have design a experimental setup as shown in fig.
[11]. Where we used Arduino Uno as a main controlling unit. And a four channel relay board to
control electrical home appliance. And we have included a Wi-Fi module in our system to connect
android and local Wi-fi present in the home of user. We have tested the experimental setup on
various loads.
15
7.Circuit Designing
STEP TAKEN WHILE PREPARING CIRCUIT
The main purpose of printed circuit is in the routing of electric currents and signals
through thin copper layer that is bounded firml y to and insulating base material some
times called the substrata. This base is manufactured with an integral bounded layer
of thin copper foil which has to be partl y etched or other wise removed to ar rive at a
pre-designed pattern to suite the circuit connections.
From the constructors point of view the main attraction of using PCB is its role as
the mechanical support for small components. There is less need for complicated and
time consuming metal w ork or chassis construction except perhaps in providing the
[mal enclosure. Most straight forward circuit designs can be easil y converted into
printed wiring layout the thorough required to carry out the conversion can often
highlights any possible error t hat would otherwise be missed in convention point to
point wiring. The finished project is usuall y neater and trul y a work of art.
Through proper design of PCB can get noise immunit y. The fabrication
process of the printed circuit board will determine to a large extent the price and
reliabilit y of the equipment. A common target aimed at is the fabrication of small
series of highl y reliable professional qualit y pcbs with low investment cost.
There are two types of PCB: -
16
factors cannot be neglected and single sided boards should be used wh enever a
particular circuit can be accommodated on such boards.
LAYOUT DESIGN
The layout of a PCB has to incorporate all the information on the board before one
can go on to the artwork preparation. This means that a conce pt, which clearl y
defines all the details of the circuit, is a prerequisite before the actual layout can
start. The detailed circuit diagram is varying important for the layout designer but
the must also be familiar with the design concept and with the phi losophy behind the
equipment. When designing the layout one should observe the minimum size
(component body length and weight). Before starting to design the layout have all the
required components to hand so that an accurate assessment of space can be mad e
care must be taken so as to allow for adequate air flow after the components have
been mounted.
It might be necessary to turn some components round to a different angular position
so that terminals are closer to the connections of other components. The s cale can be
checked by positioning the components on the squad paper. If any connection
crosses, then one can reroute to avoid such condition. All common or earth lines
should ideall y be connected to a common line routed around the perimeter of the
layout this will act as the ground plane. If possibl y try to route the outer suppl y line
ground plane. If possibl y try to route the other suppl y lines around the apposite edge
of the layout or through the center. The first step is to rearrange the circuit to
eliminate the crossover without altering the circuit detail in any way.
Plan the layout as if looking at the top side of the board first this should be
17
translated in reverse later for the etching pattern. Larger areas are recommended to
maintain good copper a dhesive. It is important to bear in mind always that copper
track width must be at least to the recommended minimum dimensions and allowance
must be made for increased width where termination holes are needed from this
aspect it can become little tricky to negotiate the route for connections to small
transistors. One can effect the copper interconnection pattern in the under side of the
board in a way described below Make the interconnections pattern looking like
conventional point to point writing by routi ng uniform width of copper from
component to component
ETCHING PROCESS
Etching process requires the use of chemicals, acid resistant dishes and a running
water suppl y. Ferric chloride is the maximum used solution, but other enchants such
as ammonium su lphate can be used.
Nitric acid can also be used but in general it is not used due to the poisonous fumes.
The pattern prepared is glued to the copper surface of the board using a latex t ype of
adhesive that can be cubed after use. The pattern is laid fir ml y on the copper, use
vary sharp knife to cut round the pattern carefull y and remove the paper
corresponding to the required copper pattern areas. Then appl y the resist solution
clean outlines as for as possible. While the board is drying to test all comp onents.
Before going to the next stage, check the whole pattern and cross check against the
circuit diagram check for any foreign matter on the copper. The etching bath should
be in a glass or enamel disk. If using crystal of ferric chloride these should b e
thoroughl y dissolved in water to the proportion suggested. There should be 0.5 Lt. Of
water for 125 gm of crystal. The board is then immersed in fecl3 solution for 12
hours, in this process onl y the non hidden copper portion is etched out by the
solution.
18
Waste liquid should be thoroughl y diluted and buried in water land never pour down
the drain. To prevent particles of copper hindering further etching, agitate the
solutions carefull y by gentl y twisting or rocking the tray. The board should not be
left in the bath a moment longer than is needed to remove just the right amount of
cooper. In spite of there being a resist coating, there is no protection against etching
away through exposed copper edges; this le ads to over etching. Have running water
ready so that the etched board can be removed properl y and rinsed; this will halt
etching immediate.
Now the paint is washed out by the petrol. Now the copper layout on PCB is rubbed
with a smooth sand paper slowl y and lightl y such that onl y the oxide layers over the
Cu is removed. Now the holes are drilled at the respective places, according to
component layout as shown in figure. Drilling is one of those operation that calls for
great care, because most of the hole s will be made and vary small drill. For most
purpose a no. 60 drill all holes with this size first those that need to be larger can be
easil y drilled again with the appropriate large size.
COMPONENT ASSEMBLY
There should be no damage, such as hair line crack in the copper on PCB that could
have a serious effect on the operational abilit y of the completed assembl y holes.
If there are, than they can and should be repaired first, by soldering a short link of
bare copper wire over the affected part. The mos t popular method of holding all the
items is to bend the wires further apart after they have been inserted in the
appropriate holes. This will hold the component in position ready for soldering.
Some component will be considerabl y larger than others, occu pying and possibly
partl y obscuring component. Because of this, it is best to start by mounting the
smallest first and progressing through to the largest, before starting, makes certain
19
that no further drilling is likel y to be necessary, because access may be impossible
later. When filling each group of components, mark off each one on the components
list as it is fitted and, if we have to leave the job, we will know where to
recommence.
Although transistors and integrated circuits are small items, there a re good reasons
for leaving the soldering of these until the last step. The main point is that these
components are varying sensitive to heat and if subjected to prolonged application of
the soldering iron, they could be internall y damaged. All the compone nts before
mounting are rubbed with sand paper so that oxide layer is removed iron their tips.
Now they are mounted according to the components layout.
Soldering Guide
How to Solder
20
Dampen the sponge in the stand.
The best way to do this is to lift it out the stand and hold it under a
cold tap for a moment, then squeeze to remove excess water. It
should be damp, not dripping wet.
Wait a few minutes for the soldering iron to warm up.
You can check if it is ready by trying to melt a little solder on the tip.
Wipe the tip of the iron on the damp sponge.
This will clean the tip.
Melt a little solder on the tip of the iron.
This is called 'tinning' and it will help the heat to flow from the iron's
tip to the joint. It only needs to be done when you plug in the iron,
and occasionally while soldering if you need to wipe the tip clean on
the sponge.
Hold the soldering iron like a pen, near the base of the handle.
Imagine you are going to write your name! Remember to never touch
the hot element or tip.
Touch the soldering iron onto the joint to be made.
Make sure it touches both the component lead and the track. Hold the
tip there for a few seconds and...
Feed a little solder onto the joint.
It should flow smoothly onto the lead and track to form a volcano
shape as shown in the diagram. Apply the solder to the joint, not the
iron.
Remove the solder, then the iron, while keeping the joint still.
Allow the joint a few seconds to cool before you move the circuit
board.
Inspect the joint closely.
21
It should look shiny and have a 'volcano' shape. If not, you will need
to reheat it and feed in a little more solder. This time ensure that both
the lead and track are heated fully before applying solder.
22
Some components require special care when soldering. Many must be placed the
correct way round and a few are easily damaged by the heat from soldering.
Appropriate warnings are given in the table below, together with other advice
which may be useful when soldering.
What is solder?
Solder is an alloy (mixture) of tin and lead, typically 60% tin
and 40% lead. It melts at a temperature of about 200°C.
Coating a surface with solder is called 'tinning' because of the
tin content of solder. Lead is poisonous and you should always
wash your hands after using solder.
The best size of solder for electronics is 22swg (swg = standard wire gauge).
Desoldering
At some stage you will probably need to desolder a joint to remove or re-position
a wire or component. There are two ways to remove the solder:
Set the pump by pushing the spring-loaded plunger down until it locks.
Apply both the pump nozzle and the tip of your soldering iron to the
joint.
Wait a second or two for the solder to melt.
Then press the button on the pump to release the plunger and suck
the molten solder into the tool.
Repeat if necessary to remove as much solder as possible.
The pump will need emptying occasionally by unscrewing the nozzle.
23
2. With solder remover wick (copper braid)
Apply both the end of the wick and the tip of your soldering iron to the
joint.
As the solder melts most of it will flow onto the wick, away from the
joint.
Remove the wick first, then the soldering iron.
Cut off and discard the end of the wick coated with solder.
After removing most of the solder from the joint(s) you may be able to remove
the wire or component lead straight away (allow a few seconds for it to cool). If
the joint will not come apart easily apply your soldering iron to melt the
remaining traces of solder at the same time as pulling the joint apart, taking care
to avoid burning yourself.
Always return your soldering iron to its stand immediately after use.
Allow joints and components a minute or so to cool down before you
touch them.
Never touch the element or tip of a soldering iron unless you are
certain it is cold.
24
8.Results & Discussion
The IOT system we have developed is tested in different load conditions for few houses
(Figure.8). After installing the experimental setup, the user needs to install the software to his/her
laptop or android phone. After proper installation of the provided software the16X2 LCD display
will show the IP address. After IP address and port address are obtained user can login from the
android application (Figure.5). As soon as the setup is completed, a home page will appear, from
which the user could keep a track of all the electronic and electrical devices which are connected
with the server as shown in figure .10
25
10.References
1. K. Venkatesan and Dr. U. Ramachandraiah, Networked Switching and polymorphingcontrol of
Electrical Loads with Web and Wireless Sensor Network, 2015 International Conference on
Robotics, Automation, Control and Embedded Systems (RACE), Chennai, (2015), 1-9.
2. Shopandey,Ayon Roy and sandipdas, Home Automation Using Internet of Thing , IRJET, 2(3)
(2016),1965-1970
3. Vishwatejamudiam Reddy, nareshvinay, tapanpokharna and Shashank Shiva Kumar Jha, Internet
of Things Enabled Smart Switch, Thirteenth International Conference on Wireless and Optical
Communications Networks (WOCN), Hyderabad, (2016),1-4
4. Warsuzarina Mat Jubadi and normaziahzulkifli, Programmable Infrared Accessory Light Switch,
International Conference on Intelligent and Advanced Systems, Kuala Lumpur,(2007), 1130-1134.
5. Shih-Pang Tseng, Bo-Rong Li, Jun-Long Pan, and Chia-Ju Lin, An Application of Internet of
Things with Motion Sensing on Smart House, International Conference on Orange Technologies,
Xian, (2014), 65-68.
6. Mandurano, Justin, and Nicholas Haber. House Away: A home management system, IEEE Long
Island Systems, Applications and Technology Conference (LISAT), Farmingdale, NY, (2012), 1-4.
7. Zhen Bi, Smart home with zigbee hardware simulation and performance evaluation,
International Conference on Mechatronic Sciences, Electric Engineering and Computer (MEC),
Shengyang, (2013), 2139-2142.
8. S. Karaca, A. Şişman and İ. Savruk, A low cost smart security and home automation system
employing an embedded server and a wireless sensor network, International Conference on
Consumer Electronics - Berlin (ICCE-Berlin), Berlin,(2016), 73-77.
9. T. Thaker, ESP8266 based implementation of wireless sensor network with Linux based web-
server, Symposium on Colossal Data Analysis and Networking (CDAN), Indore, (2016), 1-5
10.Y. P. Zhang, T. Liu, Z. X. Yang, Y. Mou, Y. H. Wei and D. Chen, Design of remote control
plug, 2015 IEEE International Conference on Applied Superconductivity and Electromagnetic
Devices (ASEMD), Shanghai, (2015), 29-30.
11.A. M. D. Celebre, A. Z. D. Dubouzet, I. B. A. Medina, A. N. M. Surposa and R. C. Gustilo,
Home automation using raspberry Pi through Siri enabled mobile devices, International Conference
26
on Humanoid, Nanotechnology, Information Technology,Communication and Control,
Environment and Management (HNICEM), Cebu City,( 2015), 1-6.
12.R. Piyare, and S.R. Lee, Smart home-control and monitoring system using smart phone, The 1st
International Conference on Convergence and its Application, 84, (2013) 83-86.
13.https://www.arduino.cc/en/main/arduinoboarduno 14.https://www.northdoor.co.uk/iot-device-
action International Journal of Pure and Applied Mathematics Special Issue 7.
27