Вы находитесь на странице: 1из 2

2017 IEEE International Conference on Consumer Electronics (ICCE)


Realisation of a Smart Plug device based on Wi-Fi technology
for use in Home Automation systems
Sava Jakovljev, Miloš Subotić and Ištvan Papp
Research and Development Institute RT-RK. Novi Sad, Serbia
sava.jakovljev@rt-rk.com, milos.subotic@rt-rk.com, istvan.papp@rt-rk.com

Abstract—Existing devices used in home automation are mostly described in this paper another approach has been used. We
based on ZigBee or Z-Wave technologies. While these solutions will show that the complexity of home automation system can
are proven, they require additional hardware to be used as be reduced by installing the system to the existing Wi-Fi
gateways. These technologies are based on mesh topology and
routers, such as ones found in user houses and apartments, and
often require additional routers to provide better connectivity.
This increases cost of the system, and can increase communication by developing devices that are based on Wi-Fi. As a result,
latency time. Device described in this paper tries to solve these system will be easier to implement and its
problems using Wi-Fi technology, based on star topology, with no overall price will be lower.
additional hardware needed. Purpose of this paper is to compare In the Section II, some related work is described and some
the performance of an existing ZigBee solution with a device general comparisons of different wireless technologies are
based on Wi-Fi technology.
made. A detailed hardware and software solution is described
in Section III. Measured response times and comparison with
I. INTRODUCTION
ZigBee Smart Plug device are given in Section IV.
In home automation systems, there are few technologies
currently being used to communicate with end devices. Basic II. OVERVIEW OF TECHNOLOGIES
idea behind these systems is that a user can control end devices
End devices used in home automation systems are usually
both locally, over a smart-phone or tablet, and globally, over
based on ZigBee, Z-Wave or Bluetooth technology [4].
cloud services. This problem implies that there is a need that a
Most of the stand-alone smart devices are based on
system can support more technologies, leading to more
Bluetooth technology. A number of these devices doesn’t
complex software and hardware. A typical home
require a centralised system, but can communicate with a
automation system supports ZigBee, Z-Wave and Bluetooth
smart-phone or tablet directly. Bluetooth is designed for short
technology. This type of system also must be able to connect
range and cheap devices to replace cables for computer
to the Internet, using Ethernet or wireless connection.
peripherals, like printers. Nominal range of Bluetooth is 10
The standard way of controlling end devices based on
meters. In most cases, this is not enough to be used in home
ZigBee, Z-Wave or Bluetooth in a home automation system is
automation systems, and that is why most devices based on
by communicating with those device trough dedicated
Bluetooth are standalone devices. Also, maximum number of
hardware gateways. This complexity in hardware leads to
devices in a Bluetooth network is extremely low- only 7. An
increased price of the system, but there are also technical
example of Bluetooth powered device is OBLO BluePlug.
problems including interference between Wi-Fi and ZigBee
Price of this device is $40.
radios in close proximity [6]. Software complexity is increased
Most of the home automation devices are based on ZigBee.
by adding support for each new technology, leading to
ZigBee puts focus on low power consumption and it is
increased development and testing time, and ultimately,
optimised for battery powered devices. ZigBee provides
increased price of the system. The biggest problem with this
extremely reliable, multi-hop mesh network. It is ideal for use
approach is that it is necessary to include additional hardware.
in large networks with a large number of routers. Nominal
Also, software support for these technologies must be
range of ZigBee is 10-300 meters, and ZigBee network can
provided. Most commonly, this support is not open sourced.
have more than 60000 devices. Range can be increased using
Devices based on ZigBee can act as routers or end-devices. In
multi-hop communication [5]. An example of ZigBee smart
bigger networks, it is good practice to add additional routers to
device is OBLO ZigBee Smart Plug. This solution uses Texas
provide better connectivity. However, in smaller networks, star
Instruments provided, closed source software stack and the
topology based technology like Wi-Fi is more convenient.
price of this device is $60.
Low data rates of ZigBee and Z-Wave is a known problem
Wi-Fi is a well known, complex technology based on star
which can become even worse if there is a need for route
topology. It has a nominal range of 100 meters and up to 32
discovery, or when performing network setup and adding new
devices can coexist. Wi-Fi has a high data rate and high
devices.
security.
Because of these problems, for realisation of the device
The biggest advantage of Wi-Fi over ZigBee in home
automation system is the fact that a large number of
This paper was partially supported by the Ministry of Education, Science households are already equipped with a Wi-Fi router, most
and Technological Development of the Republic of Serbia, under grant
number: TR32014. often serving as an Internet gateway.

978-1-5090-5544-9/17/$31.00 ©2017 IEEE


2017 IEEE International Conference on Consumer Electronics (ICCE)

Quick view of the differences between Wi-Fi, Bluetooth commercial wireless router. First, 10 plugs were connected to
and ZigBee technologies is given in Table I [3]. the system, and after 10 more plugs were added. For
comparison, identical setup with ZigBee has been made, only
with using the necessary ZigBee gateway. For this testing,
ZigBee HA 1.2 profile has been used. Response times are
measured as a mean time needed to get a response from the
furthers device in the system. That distance was changing in
range from 10 to 35 meters. Average response times are given
in Table II. From these measurements we can see that average
communication latency for ZigBee device is greater than for
Wi-Fi devices.

ZigBee router Wi-Fi router


10 devices 420 ms 248 ms
Table I. Comparison of wireless technologies 20 devices 670 ms 394 ms
Table II. Results of measuring response
III. STANDARD ELEMENTS times for ZigBee and Wi-Fi plugs

One of the challenges for this device is to make hardware


Price of the ZigBee plug is $60, while the Wi-Fi plug has an
simple and cheap. One option was to put the MCU and
estimated price of $70. Wi-Fi solution makes it possible to
wireless processor on the same PCB, leading to
install home automation system on commercial routers.
bigger PCB and more expensive device. Because of that,
Solution described in this paper is convenient for
Texas Instrument’s CC3200 MCU was selected.
small systems counting maximum of 30 devices.
CC3200 is a Wi-Fi certified chip with fully embedded
Because of ZigBee mesh topology, it is often required to
TCP/IP and TLS/SSL stacks. It contains a dedicated wireless
purchase additional ZigBee routers to provide better
coprocessor that completely offloads the main MCU. This
connectivity. With Wi-Fi router and Wi-Fi devices additional
additional coprocessor includes an 802.11 b/g/n radio,
equipment is not necessary. Other important issue is power
baseband and MAC with a cryptographic engine for secure
consumption. ZigBee was designed to be very power efficient,
connections with 256-bit encryption. [2].
so if a device is battery powered ZigBee is a better solution.
Software for this device is written in programming language
C and is based on real-time operating system FreeRTOS. For V. CONCLUSION
our solution, MQTT client library was developed. This library
enables the device to be used as a MQTT client, and it This paper showed that small home automation systems are
provides a full implementation including a service thread easier to implement using only Wi-Fi technology.
which is in charge of dispatching received messages and Communication time latency of Wi-Fi devices is less than
making sure that sent messages have been delivered. communication time latency for ZigBee devices. If a network
Developed MQTT client library contains less than 1000 lines with a large number of devices is needed, ZigBee is a better
of code [1]. solution.
For the plug to become a part of the system, it must know
the SSID and password key of the network. For this purposes, REFERENCES
Texas Instruments has developed appropriate library called [1] S. Jakovljev, “Realisation of a Smart-Plug device using MQTT
protocol”, Bachelor Thesis, October 2015.
SmartConfig. This library can be embedded in mobile [2] Texas Instruments, CC3200 Wireless MCU,
application for Android or iOS, and in that way user can http://www.ti.com/product/CC3200
“teach” the device about the network it should connect. [3] Andres Lundgren, “Software Development Tool Optimize ZigBee
Performance”, https://wirelessdesignmag.com/blog/2012/09/software-
After connecting to the Wi-Fi network, the device must find development-tools-optimize-zigbee-performance, September 2012.
out the IP address of the message broker, so it could establish [4] Jin-Shyan Lee, Yu-Wei Su and Chung-Chou Shen, “Comparative Study
a MQTT connection with it. For this purposes, CC3200 has of Wireless Protocols: Bluetooth, UWB, ZigBee and Wi-Fi”, The 33rd
Annual Conference of the IEEE Industrial Electronics Society (IECON),
fully embedded mDNS protocol stack. The basic idea is that
2007.
the device sends an IP multicast query, requesting from the [5] Thoraya Obaid, Haleemah Rashed, Ali Abou-Elnour, Muhammad
home automation system to identify itself. The system will Rehan, Mussab Muhammad Saleh and Mohammed Tarique, “ZigBee
respond with its IP address, making itself visible. Technology and its application in wireless home automation systems: A
survey”, International Journal of Computer Network & Communications
(IJCNC) Vol. 6, No. 4, July 2014.
IV. RESULTS AND DISCUSSION [6] Garima Khanna and Gaurav Gupta, “A review on techniques for
establishing coexistence between Wi-Fi and ZigBee”, International
Device described in this paper was tested using OBLO Journal of Science and Research, July 2015.
home automation system, which was installed on a

978-1-5090-5544-9/17/$31.00 ©2017 IEEE

Вам также может понравиться