Professional Documents
Culture Documents
JANUARY 2014
i|Page
DECLARATION PAGE
I declare that this report is my original work and all references have been cited adequately as
required by the University.
Date: 16/May/2014
Signature:
Full Name: Norhamizan Bin A.Hamid
ID No.: 52208111095
ii | P a g e
APPROVAL PAGE
We have supervised and examined this report and verify that it meets the program and
Universitys requirements for the Bachelor of Engineering Technology (Hons) in Networking
System.
Date:
Signature:
Supervisors Name:Dr.Megat Farez Azril Zuhairi
iii | P a g e
COPYRIGHT PAGE
Any material contained in or derived from this unpublished research may only be used
by others in their writing with due acknowledgement.
ii.
MIIT UniKL or its library will have the right to make and transmit copies(print or
electronic) for institutional and academic purposes.
iii.
The MIIT UniKLs library will have the right to make, store in a retrieval system and
supply copies of this unpublished research if requested by other universities and
research libraries.
iv | P a g e
DEDICATION
I would like to dedicate this thesis to my parent, my sibling whom have supported me
throughout the four years in the university and to whom I am forever grateful. My friends that
have give full support to accomplish the work I have done. The work I have done on this
project is dedicated to them. Thank you for the support, love, faith and trust. I am truly blessed
as a family. I also want to dedicate this report to our entire lecturer for about 4 years lecture.
Thank you for the guide and support that you have showed me.
v|Page
ACKNOWLEDGEMENT
First and foremost, I thank Allah S.W.T for endowing me with health, patience,
and knowledge to complete this work.
I acknowledge, with deep gratitude and appreciation, the inspiration, encouragement,
valuable time and guidance given to me by Dr.Megat Farez Azril Zuhairi, who served as
my project supervisor and read my numerous revisions and helped make some sense of
the confusion. Thereafter, to my assessors, Husna BintiOsman, and Dr.Megat
NorulAzmi Megat Mohammad Noor, who offered guidance and support.
Next, my appreciations go to our family for always giving me love and support. Without
their attention, it would be difficult for me to get through all the circumstances in
completing this Final Year Project.
This project would not have been possible without the support from numerous friends
and all other relatives, for their emotional and moral support throughout my academic
career and also for their love, patience, encouragement and prayers.
vi | P a g e
TABLE OF CONTENTS
ix | P a g e
LIST OF TABLES
page on
Table 2.1 : Zigbee, Bluetooth, and Wi-Fi Characteristics
16
20
21
36
36
54
63
x|Page
LIST OF FIGURES
page on
Figure 2.1: Star Topology
10
10
17
18
18
19
24
27
28
29
30
32
33
35
38
39
39
40
41
42
43
xi | P a g e
44
44
45
45
Uno
Figure 4.12 : Arduino IDE folder
46
47
47
48
49
50
51
55
56
57
57
58
59
60
61
61
xii | P a g e
LIST OF ABBREVIATION
Name
Abbreviation
AODV
CSMA/CA
DSDV
DSSS
DSR
FSR
FHSS
GUI
HARP
Identification
ID
ICSP
ISM
IEEE
IDE
In VANET
Light-Emitting Diode
LED
MANET
PAN
Radio Frequency
RF
Task Group N
TGn
TORA
Transistortransistor logic
TTL
UART
USB
xiii | P a g e
VANET
WPAN
WRP
WBS
Zigbee Coordinator
ZC
ZDO
ZED
Zigbee Router
ZR
ZRP
ZHLS
xiv | P a g e
ABSTRACT
xv | P a g e
ABSTRAK
Kajian ini dijalankan untuk mengkaji kesan mobiliti kepada prestasi rangkaian mudah
alih ZigBee. Rangkaian ZigBee bergerak pesat digunakan dalam banyak industri. Ini
adalah kerana teknologi rangkaian ZigBee mempunyai ciri-ciri seperti operasi yang
menggunakan kuasa rendah , keupayaan sensor, dan faktor bentuk kecil mobiliti. Data
yang dikumpul dari nod sensor tunggal yang dihantar dari satu kepada yang lain
sehingga ia sampai ke lokasi pusat pengumpulan data. Projek ini memberi tumpuan
kepada satu kajian mengenai rangkaian mudah alih ZigBee dan corak pergerakan ini
yang merupakan mobiliti model Random Waypoint dan membina rangkaian topologi ad
hoc tanpa wayar mudah untuk menyiasat prestasi. Objektif projek ini adalah untuk
menubuhkan satu rangkaian wayarles mudah menggunakan yang ada alat-alat tanpa
wayar ZigBee. Selepas itu, peranti dinilai dalam persekitaran rangkaian, termasuk
corak mobiliti
xvi | P a g e
CHAPTER I: INTRODUCTION
1.0 Introduction
Zigbee Mobile Network is typically used in many industries. It is because the network
technologies have features such as low power operation, sensor capability, and small
form factor mobility. The data collected from a single sensor node is forwarded from
one to the other until it reaches the location of the data collection center. Typically,
Zigbee allows bi-directional communication to connect and communicate. Each node
has common parts, which include a radio transceiver with internal antenna or connection
to an external antenna and a microcontroller. Many industries have employed the
technology to automate process with minimum human intervention. Nevertheless, not
the entire node has mobility capability in their system. Simulation of mobility pattern is
a technique used to evaluate the performance of Zigbee network. It provides an
improvement in the mobile ad hoc environment and network performance. The purpose
of this project is to employ mobility pattern into the Zigbee network and then compare
the performance. The mobility pattern behavior of a node movement can be described
using both analytical and simulation models .In this project, the actual mobility pattern is
employed. For the mobility pattern, Random Waypoint Model is used in this project.
The mobility pattern can help the investigation of the network performance, which later
can be used to alleviate the weakness.
1|Page
This project focuses on a study about Zigbee mobile network and mobility's pattern
which is Random Waypoint mobility models and to construct a simple wireless ad
hoc network topology to investigate the performance.
The objective of this project is to study the Zigbee mobile network using by the
mobility patterns. The performance will be measured by using real-life node wireless
sensor in different network topology. Each mobility pattern use different individual
movement and the node's location. The wireless node employs protocol such as Ad
Hoc on-demand Distance Vector Routing (AODV).
The experiment is conducted in a real-life testbed to evaluate the performance
network with the mobility pattern. The network node hardware that can be used is XBee Series 2 (support Zigbee Protocol) and Arduino Uno as the microcontroller.
The outcome of the result is compared to see the attributes of mobility pattern.
The project focuses on setting up a simple wireless network using the current
available Zigbee wireless devices. Subsequently, the devices are evaluated in
network environment, which include mobility patterns. Initially experiments are
conducted empirically with using chain topology and later under various network
topologies. Based on the results, the data is analyzed and later a suitable application
for the Zigbee network nodes is proposed.
2|Page
The applications of ad hoc network are limited and many lack the ability to be
mobile. As such, the performance of Zigbee devices may be affected. In this project,
the mobility attributes of Zigbee is investigated.
The project expected outcome is to employ mobility pattern into Zigbee network. It
can be implemented into many industries such as agriculture, military, and medical.
It will help the features of mobility to their current networking system. With this
method, it may increases the performance of the network and the work or method of
collecting data will improve.
3|Page
2.1 Introduction
This chapter reports the literature review of the project to be developed, which is
Wireless Mobile Ad hoc Network. It discusses about ZigBee network and mobility
pattern of wireless node.
2. 2 Introduction of ZigBee
5|Page
Must always transmit and receive RF data through its parent. Cannot route
data.
Can enter low power modes to conserve power and can be battery-powered.
2.2.2 ZigBee network characteristic
There are several standard currently exist for wireless networking, including
Bluetooth, Wi-Fi, and Wimax. ZigBee is a new standard for wireless sensor and
control network. Besides features of lower power consumption, high density of nodes
per network and low costs, there are some features are enabled by the following
characteristics.
Regional operation in the 915 MHz (Americas) and 868 MHz (Europe).
Frequency agile solution operating over 16 channels in the 2.4 GHz
frequency.
ZigBee uses small packet compared with Wi-Fi and Bluetooth.
Easy to implement.
Low data rate. Maximum data rate for a ZigBee device is 250 Kbps.
Utilizes the industry standard AES-128 security scheme.
Fully hand-shake acknowledged protocol for transfer reliability.
Allocation of guaranteed time slots.
Allocated 16 bit short or 64 bit extended addresses.
6|Page
Application
Wireless LAN
IEEE ZigBee
802.15.1
802.15.4
Cable replacement
Control
IEEE
and
monitor
Frequency bands
2.4 GHz
2.4 GHz
2.4 GHz
868 MHz
915 MHz
0.1 5
17
100 700
30
65,000
Bandwidth
2 100 mbps
1 mbps
20 250 kbps
Range (meters)
1 100
1 10
1 75 and more
Topology
Tree
Tree
Standard current
2 * 10 3 amps
200 * 10 -6 amps
3 * 10 6 amps
Memory
100 kb
100 kb
32 60 kb
ZigBee uses the IEEE 802.15.4 2003 specification for its physical layer and MAC
layer. It offers star, tree, cluster tree and mesh topologies; however ZigBee only
supports star, tree and mesh topologies.
7|Page
1. Peer-to-peer topology
Star topology consists of a coordinator and several end devices (nodes). In this
topology, the end device will only communicate with coordinator. Any packet
exchange with end device must go through the coordinator. The disadvantage of this
topology is the operation of the network depends on the coordinator of the network
because all packets between the devices must go through the coordinator. In this
case, the coordinator may become bottlenecked.
There is also no alternative path from source to destination. The advantage of this
topology is that it is simple and packets go through at most two hops to reach their
destination. Figure 2.1 shows the example of star topology
8|Page
3. Tree topology.
In this topology, the network consists of a central node (root tree), which is a
coordinator, several routers, and end devices. The function of the router is to extend
the network coverage. The end nodes that are connected to the coordinator or the
routers are called children. Only routers and the coordinator can have children. Each
end device is only able to communicate with its parent. The coordinator and routers
can have children and, therefore, are the only devices that can be parents. An end
device cannot have children and, therefore, may not be a parent. A special case of
tree topology is called a cluster tree topology. Figure 2.2 shows the example of tree
topology
A cluster tree topology is a special case of tree topology in which a parent with its
children is called a cluster. Each cluster is identified by a cluster ID. ZigBee does not
support cluster tree topology, but IEEE 802.15.4 does support it. Figure 2.3 shows
the example of cluster tree topology
9|Page
5. Mesh Topology.
Mesh topology, also referred to as a peer-to-peer network, consists of one
coordinator, several routers, and end devices. Figure 2.4 shows the example of mesh
topology
The following are the characteristics of a mesh topology:
1. A mesh topology is a multihop network; packets pass through multiple hops
to reach their destination.
2. The range of a network can be increased by adding more devices to the
network.
3. It can eliminate dead zones.
4. A mesh topology is self-healing, meaning during transmission, if a path fails,
the node will find an alternate path to the destination.
5. Devices can be close to each other so that they use less power.
6. Adding or removing a device is easy.
7. Any source device can communicate with any destination device in the
network.
8. Compared with star topology, mesh topology requires greater overhead.
9. Mesh routing uses a more complex routing protocol than a star topology.
10 | P a g e
11 | P a g e
Besides adding two high-level network layers to the underlying structure, the most
significant improvement is the introduction of ZDOs. These are responsible for a
number of tasks, which include keeping of device roles, management of requests to
join a network, device discovery and security. Because ZigBee nodes can go from
sleep to active mode in 30ms or less, the latency can be low and devices can be
responsive, particularly compared to Bluetooth wake-up delays, which are typically
around three seconds. Additionally, ZigBee nodes can sleep most of the time,
average power consumption can be low, resulting in long battery life.
ZigBee is a low-cost, thus allowing the technology to be widely deployed in wireless
control and monitoring applications. It operates in the industrial, scientific and
medical (ISM) radio bands. Data transmission rates vary from 20 to 900
kilobits/second.
There a many ways to classify MANET protocol based on how routing information
is acquired and maintained by mobile nodes. Using this method, MANET routing
protocol can be divided into proactive routing, reactive routing and hybrid routing.
2.3.1.1 Proactive Routing Protocol
Proactive Routing also called "table driven" routing protocol. Nodes in MANET are
capable to continuously evaluate routes to all reachable nodes and attempt to
maintain consistent, up-to-date routing information so that source node can get
routing path immediately if needed.
Typical Proactive Routing Protocol
i.
DSDV is a proactive unicast routing protocol for MANET. It has the same concept
with AODV except their mechanisms to improve routing performance in MANET
are quite different.
An entry stores the next hop towards destination, the cost metric for routing path to
destination sequence number that created by the destination.
13 | P a g e
iii.
FSR is proactive unicast routing protocol based Link State routing with the effect of
reduced overhead to maintain network topology information. FSR can maintain the
accurate distance and path quality information about the neighbor node and progress
to reduce details when the distance increases.
2.3.1.2 Reactive Routing Protocol
Reactive Routing or also known as "on-demand" routing protocol. With this routing
protocol, routing path is searched only when needed. The discovery procedure
terminates when either route has found or no route are available after examination for
all route permutations.
i.
DSR is Reactive unicast routing protocol that utilizes source routing. In DSR each
node uses caching technology to maintain route information that the node has learnt.
There are two major phases in DSR, the route discovery and the route maintenance.
When the source node sends packet, it first consults with the route cache. Later if the
required route is available, the source node includes the routing information inside
the data packet before transmission.
ii.
AODV is reactive unicast routing protocol for MANET. It only maintains the routing
information about active path. Routing information is usually maintained in routing
tables at nodes. Every node keeps next-hop routing table, which contain destination
to which currently that have a route.
iii.
14 | P a g e
Hybrid Routing Protocol is proposed to combine the merits of both proactive and
reactive routing protocols and to overcome the weakness. Hybrid routing protocol for
MANET typically exploit hierarchical network architectures.
i.
ZRP is a hybrid routing protocol for MANET. The purpose of this protocol is to
reduce the control overhead of proactive routing approaches and decrease the latency
caused by route search operations in reactive routing approaches.
ii.
HARP is a hybrid routing scheme that exploits two level zones based hierarchical
network structure. Different routing approaches are utilized in two level, intra-zone
routing and inter-zone routing.
iii.
ZHLS is a hybrid routing protocol. Mobile nodes are assumed to know the physical
location with assistance from location system such as a GPS. The network is divided
into non-overlapping zones based on geographical information. It uses hierarchical
address scheme that contains zone ID and node ID. Node determines its zone ID
according to its location and the pre-defined zone map well known to all nodes in the
network.
Table 2.2 summaries the MANET routing protocol table
15 | P a g e
Mobility pattern of nodes can be described by mobility models. The mobility models
are designed to describe movement pattern of mobile users and how their location,
velocity and acceleration changes over time. After the nodes are initially placed, the
mobility model dictates how the nodes move within the network. Mobility Model is
usually used for simulation purpose when new communication or navigation
techniques are investigated. It characterizes user movement patterns. After nodes
have been distributed, the mobility model dictates the movement of the nodes within
the network. Because the mobility of the nodes impact directly the performance of
the protocol, the results obtained with unrealistic movement model will not correctly
give definitive of the true performance of the protocol. Emre Atsan and znur
zkasap [2] describe "A better understanding of the behavior of mobility models and
using the appropriate ones give us a chance to achieve realistic conclusion from
simulations, which improves the validity of the result ".
16 | P a g e
It is widely used mobility model that emulates the mobile users in real time. The
nodes are placed at random location in the network. All the movement of the node is
independent with another node in the network. The nodes have a uniformly
distributed speed between [minSpeed, maxSpeed]. After arriving at the destination,
again waits for the same period of time before moving to new place.S.Balaji Gupya,
T.Navnrrth, S.Sundar and C.M.Vidhyapathi [3] describe " the movement of the
mobile node in Random Waypoint Mobility is similar to the Random Walk Mobility
if the pause time is set to zero and [minspeed, maxspeed] = [speedmin, speedmax]
".Figure 2.7 shows the random waypoint pattern
17 | P a g e
Manhattan Model uses a grid road topology. The purpose of this topology is for the
movements in urban area, where the streets in organized manner and the mobile
nodes are allowed to move only horizontal or vertical direction. It also usually used
to emulate the movement pattern of mobile node on streets defined by maps. It is
also a model that is very similar to the Freeway Model. This model can be used in
Mobile Ad hoc Network (MANET) and Vehicular Ad hoc Network (VANET).
Figure 2.8 shows the Manhattan mobility pattern.
18 | P a g e
In Gauss-Markov Models, each mobile node is commenced with speed and direction.
In fixed intervals of time, movement occurs to updating the speed and direction of
each node.
2.3.2.4 Freeway Model
The Freeway Model emulates the motion of mobile node on Freeway. It can be
implemented in exchanging traffic status or tracking vehicle on a Freeway. The
model makes several uses of the maps. There are several freeways on the maps and
each freeway has lanes in both directions. Every mobile node is limited to the lane on
the freeway. The velocity of mobile node is temporally dependent on previous
velocity. Figure 2.9 shows the freeway mobility pattern.
MANET has two standards that are IEEE 802.11 standards and Bluetooth standard.
1. IEEE 802.11 Standards
IEEE 802.11 group protocol currently being develop for long-range communication
at much higher data rates and distance. The introduction of 802.11n as
implementation by Task Group N (TGn) stimulated lot of research in area of the
19 | P a g e
802.22 family of protocol. Many of the standards have been developed by IEEE
802.11 task force to improve communication in wireless network. It has different
characteristic in term of speed, throughput and compatibility of chipsets among
different vendors. The IEEE 802.11b is designed by the IEEE to have higher data
rates when operational and the frequency band of the operation is 2.4GHz. Other task
group or organization continues to improve the other standards such as IEEE 802.11
c, d, e, g, f and n.
IEEE 802.11 has become standard specifies MAC and physical layer for Wireless
LANs. The physical layer use different technologies like Frequency Hoping Spread
Spectrum (FHSS) and Direct Sequence Spread Spectrum (DSSS). MAC protocol
distributed coordinated function that has a carrier sense multiple accesses with
collision avoidance (CSMA/CA). Table 2.3 shows different wireless network.
Table 2.3: Summary of different wireless network
20 | P a g e
2. Bluetooth Standard
Bluetooth is a project that been develop by Special Interest Group SIG). Ajay Jangra,
Nitin Goel, Priyanka, Komal Kumar Bhatia [4] describe" Bluetooth was originally
started as a project by the Ericsson Company and later formalized by the
Bluetooth Special Interest Group (SIG), includes Sony Ericssion, IBM, Intel,
Toshiba and Nokia ".
Bluetooth is the de-facto standard for low-cost, short-range radio links between
mobile PCs, mobile phone and other portable devices. It has built-in short-range
radio transmitter. The data rate for Bluetooth is 1Mbps with 2.4GHz bandwidth.
Table 2.4 shows the standard for Bluetooth.
Table 2.4: Comparisons of Bluetooth Version
21 | P a g e
Currently there are only a handful of real life simulation but the parameter of the
experiment are followed by using network simulation software.Current researcher are
using network simulation software to run simulation to study the impact of mobililty
mobile pattern on the ZigBee mobile network performance. The previus network
simulation parameter and procedure are follow to conduct the real life experiment.
Past Related
A DETAILED
Performance
Performance
A Simulation Study on
Project
STUDY OF
Analysis of Reactive
Analysis of MANET
MOBILITY
Routing Protocols
Routing Protocols
Models on the
MODELS IN
over Different
Network Connectivity,
WIRELESS
Mobility Model in
Mobility Models
SENSOR
MANETs
Characteristics
Scope
NETWORK
Networks
Wireless sensor
Performance mobility
Performance
The high-level
networks (WSN) is
models on routing
comparison based on
existing routing
is a simulation-based
finds variety of
protocols
hoc networks.
applications in
military, movement
tracking, industries
hoc networks.
Mobility
Random Waypoint,
Random Waypoint,
Random Waypoint,
Model
Random direction,
Manhattan Grid,
Gauss-Markov model,
Random Walk,
Scenario model
Gauss-Markov,
Reference
(combination of
Reference Point
Point Group
Random Waypoint
Group and
Mobility model,
Heterogeneous
Column, Nomadic,
Model)
Mobility Models
22 | P a g e
Pursue, Exponential
Correated,
Manhattan
Routing
Protocol
DSR
23 | P a g e
3.1 Introduction
This chapter discusses methodology used in the project. The method is followed to
achieve the objectives of the project. To run this project, the methodology for this
project is based on project approach.
The methodology involves six phases which are planning, research, implementation,
analysis, result and documentation.
3.2 Project Methodology
It begins with data and information gathering process which are related to the project
and objectives. The process of searching data involves finding information from
Internet, journal, article and previous project that have similarity with the project.
The project model methodology is used as a guideline in the project.
The phases are dividing into 6 phase, which is Planning, Research, Implement, Analysis,
Result and Documentation.
3.2.1 Planning phase
In the planning phase, a problem is identified. To study the impact of mobility pattern on
the performance of ZigBee mobile network .There are not many of real life mobility
pattern research are being done Then, the solution is formulated by creating objectives
that can achieve the target. The planning to simulate mobility pattern using ZigBee
mobile network are being done. With the availability of the objectives, the project can
run smoothly and have direction for the project. In addition, the scopes of the project
need to be develop to make it easy to determine the scope of the project that need to be
reviewed. Then, propose an appropriate topic related to the scope, objectives and
problems that need to be solved.
3.2.2 Research phase
In research phase, it is very important to further the research to get better understanding
of the project that need to be done. In this phase, comprehensive studies need to be done
by reviewing previous projects, read research journals and understand the original
concept of the project. Also to study what MANET hardware is suitable for this project.
The hardware must meet the criteria of the project. After that, reviewed the methodology
to be applied in the project.
3.2.3 Implementation phase
In implementation phase, it involves the development of hardware and software for the
project. In this phase, the development of hardware design was developed by just plug in
the XBee series 2, XBee Shield and Arduino Uno. By using XBee Shield, it make a lot
easier to integrate the XBee series 2 and Arduino Uno. For the software design, the
source code from the Arduino playground. Than the source code are edit for suitable
need of the project. After the adjust source code are done. Upload the source code into
25
Arduino Uno. After that, the process can be carried out in real life simulation base on
random waypoint pattern.
In this phase, the mobility pattern and routing protocol need to be analyzed to get the
result. The parameters for the experiment simulation are following using the network
simulation software. This analysis can prove which mobility pattern and routing protocol
that is suitable for MANET.
3.2.5 Result phase
In this phase, all project objectives and scope must be achieved. The data from the test
can be collected. All the raw data than need to be calculate manually. After that, the data
will be compare than the result will be analysis to show the result
3.2.6 Documentation phase
In the documentation phase, data collection and analysis that has been done will be
documented. Besides that, the result can be use for further study.
26
Figure 3.2 shows the SKXBEE module. SKXBee has been designed for 5V TTL logic
interface, no extra voltage divider is necessary. With minimum interface, it is ready to be
connected to microcontroller for embedded XBee development. Furthermore, on board
USB to UART converter offer easy yet reliable communication to PC for functionality
test and as XBee dongle.
SKXBee can support both XBee and XBee PRO because they are interchangeable and
Pin-to-pin compatible with each other.
27
3.3.2 XBee-S2
Figure 3.3 shows the XBEE S2 module. It is XBee RF ZB (ZigBee) module, but often
refers to XBee Series 2. Series 2 improves on the power output and data protocol. Series
2 modules allow user to create complex mesh networks based on the XBee ZB ZigBee
mesh firmware. These modules allow a very reliable and simple communication
between microcontrollers, computers, systems, really anything with a serial port! Point
to point and multi-point networks are supported. These XBee Series 2 modules have the
same pin out as XBee Series 1
Features:
3.3V @ 40mA
Built-in antenna
8 digital IO pins
128-bit encryption
29
3.3.4 Arduino
30
An open source design. The advantage of it being open source is that it has a large
community of people using and troubleshooting it. This makes it easy to find someone to
help debug your projects
2.
An easy USB interface. The chip on the board plugs straight into USB port and
registers on your computer as a virtual serial port. This allows to interface with it
as through it were a serial device. The benefit of this setup is that serial
communication is an extremely easy (and time-tested) protocol, and USB makes
connecting it to modern computers really convenient.
3.
Very convenient power management and built-in voltage regulation. It can connect
an external power source of up to 12v and it will regulate it to both 5v and 3.3v. It also
can be powered directly off of a USB port without any external power.
4.
A 16 MHz clock. This makes it not the speediest microcontroller around, but fast
13 digital pins and 6 analog pins. These pins allow connecting external hardware to
your Arduino. These pins are key for extending the computing capability of the Arduino
into the real world. Simply plug devices and sensors into the sockets that correspond to
each of these pins and you are good to go.
6.
An ICSP connector for bypassing the USB port and interfacing the Arduino
directly as a serial device. This port is necessary to re-boatload chip if it corrupts and can
no longer talk to the computer.
7.
An on-board LED attached to digital pin 13 for fast an easy debugging of code.
8.
And last, but not least, a button to reset the program on the chip
31
3.4.2
Arduino IDE
Figure 3.7 shows the Arduino IDE interface. The Arduino development environment
contains a text editor for writing code, a message area, a text console, a toolbar with
buttons for common functions, and a series of menus. It connects to the Arduino
hardware to upload programs and communicate with them.
Software written using Arduino are called sketches. These sketches are written in the
text editor. Sketches are saved with the file extension .ino. It has features for
cutting/pasting and for searching/replacing text. The message area gives feedback while
33
saving and exporting and also displays errors. The console displays text output by the
Arduino environment including complete error messages and other information. The
bottom right hand corner of the window displays the current board and serial port. The
toolbar buttons allow verifying and uploading programs, creating, opening, and saving
sketches, and open the serial monitor.
3.5 Project Gantt chart
Gantt chart is a graphical illustration of schedule that helps people to coordinate, plan
and track their specific tasks in the project. Gantt chart is very useful tools for people to
plan and schedule their project. This tool allows people to estimate the length of the time
need to complete the project and determine the resource that need in the project. When
project is underway, Gantt chart can monitor the project progress. Gantt chart can be
referred in Appendix A.
34
Figure 3.8 shows the final year project work breakdown structure.This section shows the
overal project cost estimation. This project is about developing a system; the budget of
this project depends closely to the tools used in developing it which is hardware and
software. The estimate budget is shown in Table 3.1 and 3.2. Table 3.1 is shows
estimated cost for hardware; Table 3.2 illustrates the estimated cost for software. Budget
and costing are essential to produce a project, product or services.
35
Price (RM)
Unit
Total (RM)
RM
4700.00
Personal
Arduino Uno R3
RM
79.00
SKXBEE Board
RM
72.00
Battery 9 V
RM
9.90
RM
9.90
RM
115.00
RM
115.00
XBee Series 2
RM
99.00
RM
297.00
RM
34.00
RM
102.00
Total
RM
232.90
Price (RM)
Unit
Total (RM)
Arduino IDE
Freeware
Freeware
X-CTU
Freeware
Freeware
Total
RM
Free
36
4.1 Introduction
This chapter discusses the project implementation .It begins with hardware development
to software development. This is an essential stage to complete the research study of
Zigbee Mobile Network by using mobility pattern (Random Waypoint)
In this stage, the construction of hardware and experiment set up is done. Initially, the
project requirement are identified and studied in the pre-development phase.
The
development phase is divided into several stages, which include the implementation
of the hardware,
37
38
The following illustrates the procedure of setting the XBee Series 2 for experiment.
1. Connect XBee Series 2 into the SKXBEE. After that, the usb cable from Laptop is
connected to SKXBEE to enable XBee to be configured. Figure 4.2 shows the XBee
connection.
40
4. Figure 4.5 shows the Modem Configuration tab. The read button is pressed and later it
shows the configuration and information about the Modem (XBee). The user is allowed
to configure the Modem (XBee) based on the network specification.
41
5. Figure 4.6 shows the interface to setup XBee PAN ID. Click the network icon to
configure the PAN ID. The ZigBee networks are called personal area networks or PANs.
Each network is defined with a unique PAN IDentifier (PAN ID). For the sender and
receiver node to communicate, the PAN ID must be identical. This identifier is common
among all devices of the same network. ZigBee devices are either preconfigured with a
PAN ID to join, or they can discover nearby networks and later choose a PAN ID to
associate. In this setup, the XBee PAN ID are configured using 7779 as the PAN ID.
6. Figure 4.7 shows the configuration for Sender Node. It can be done by setting Zigbee
Router AT. Then, the configuration is written into Modem (XBee) for sender node.
43
7. Figure 4.8 and Figure 4.9 show the configuration for Relay mode. The same step is
repeated to the sender node configuration to configure relay and receiver node. However
in function set, choose Zigbee Coordinator AT for relay and Zigbee End Device AT for
receiver.
8. Figure 4.10 shows the connection of XBee to XBee shield .After the configuration of
the Sender, Relay and Receiver XBee is completed. The XBee is connected to XBee
Shield platform. Using XBee Shield, it allows XBee to communicate with Arduino Uno.
Figure 4.11: Integration Between XBee, XBee Shield and Arduino Uno
45
46
sufficient power and able to be operated. Figure 4.13 show an Arduino Uno power up
using USB cable.
47
7. Figure 4.15 shows the Arduino IDE selection board. The entry in the tools > board
menu that corresponds to the Arduino board used is selected.
48
9. Figure 4.16 shows serial port selection. The serial device of the Arduino board from
tools serial port menu is selected.
49
10. Figure 4.17 shows the code and the corresponding process of uploading to the
board. To do this, button upload in the environment is pressed. After that, the rx and tx
leads on the board is flashing. When the upload is successful, the message done
uploading appears in the status bar. The source code into is uploaded sender and
receiver Arduino Uno. The source code can be referred at Appendix B and C. The
source code includes the Time Stamp code and Packet Size for Appendix B and Time
Stamp in Appendix C.
50
Network diagram in Figure 4.18 indicates the network design for the project. It contains
of the proportion of network devices in the PAN for Zigbee. The purposes of design the
network to show the process of data are sending from sender to receiver.
51
5.1 Introduction
This chapter discusses the impact of mobility on the performance of ZigBee mobile
network. After the software and hardware implementation development, all the modules
are integrated to each other. The system is then tested to ensure the system meet the
requirements and achieves all the objectives. The Average End-to-End Delay, Total
Packet and packet delivery ratio are the three measurement used to study the impact of
mobility on the Performance of ZigBee mobile network using random waypoint mobility
pattern.. The behavior of the node is also discussed to show its functionality and output.
5.2 Metrics
The metrics used to study the impact of mobility on the performance of ZigBee mobile
network by using random mobility model pattern. To evaluate the performance, the
metrics shown in the subsequent section are discussed
5.2.1 Average End-to-End Delay
Average End-to-End Delay is an average time delay from source node to destination
node. It counts all possible delays that can occur in the source mode and all intermediate
nodes, including queuing time, packet transmission and propagation, and retransmission
at the MAC layer. The queuing time can be caused by network congestion or
unavailability of valid routes. Average end-end delay computation is shown by equation
5.1:
Average End-to-End Delay = (Arrive time - Send time)
...5.1
Number of connection
52
The ratio of the number of data packets successfully delivered to all destination
nodes and the number of data packets generated by all source nodes. Packet delivery
ratio formula computation is shown by equation 5.2:
Packet Delivery Ratio = Number of packet receive
...5.2
5.2.3 Throughput
...5.3
53
ZigBee Analysis
Meter 1 to meter 20
Meter 21 to meter 40
Meter 41 to meter 60
Meter 61 to meter 80
Meter 81 to 100
54
1. Figure 5.1 shows two Arduino Uno interface, which allow the Sender and Receiver
node to be monitored at the same time using one laptop.Com 5 represent Sender node
and Com 8 represent Receiver node
55
2. After that, the Serial Monitor icon to monitor packet sent and received is pressed.
Com 5 is the Sender node and Com 8 is the Receiver node. The packet that being sends
forms the sender to receiver is the "ABCDEF". Figure 5.2 shows the packet from sender
to receiver via XBee.
56
3. To capture the packet lifetime, there are two method can be employed. If the user use
window 7 operating system, user have to use the epoch time, than type T (epoch time)!
On the other hand for Ubuntu operating system, use the command referred in Appendix
D in the terminal. Figure 5.3 and 5.4 shows the captured timestamp
The
represent the relay for sender and the receiver node. The experiment are
conducted by using the network area size of 70mX30m to produce result for the study.
The sender and receiver node are carried using motorcycle as the medium of transport to
create an simulation movement for Random Waypoint pattern, while the relay are set as
stationary.
58
5.5 Result
Based on experiment conducted, the measurement of Total Packet, Average End-to-End
Delay, Packet Delivery Ratio and Throughput are collected. Each calculation of the
performance metric can be referred in equation 5.1, 5.2 and 5.3.
59
Figure 5.8 shows the Average End-to-End Delay. It is the average time taken by a data
packet to arrive at in the destination. It also includes the delay caused by route discovery
process and the queue in data packet transmission. Only the packets that successfully
delivered to destination that counts. A lower value of average end to end delay is ideal
for application which requires low latency such as voice over IP phone
61
Table 5.2 shows the complete result from the experiment conducted. The raw data can be refer in Appendix D
Table 5.2 Full Result
Packet
Packet Delivery
Average
Total
Total
Speed
Total Packet
Packet Lost
Receive
Ratio
Delay
Byte
Byte Lost
Throughput
179
62
117
0.654
7s
1074
372
702
0.024
10
180
53
127
0.706
3s
1080
318
762
0.032
15
119
60
59
0.496
4s
714
360
354
0.008
20
118
40
78
0.661
3s
708
240
468
0.021
25
181
60
121
0.667
5s
1080
360
729
0.024
62
6.1 INTRODUCTION
This chapter discusses about the project conclusion and recommendation. The
conclusion is a complete summary of the whole project, and it also known as
complete result of the project. From the project itself, a lot of challenges faced upon
finishing the research study of this project.
6.2 CONCLUSION
The project shows the capability of ZigBee technology and the impact of mobility on the
network performance. Although the project is completed it still need a lot of
improvement. Analysis and observation were conducted to test the impact of mobility on
the performance of ZigBee mobile network. To develop a reliable system in a real
environment requires significant effort. There are many elements of the technology
which has not been considered. Each can have influence on the performance of
MANET. Arduino IDE is the software used to interface the entire component to
microcontroller. In general, the system operated as expected even though there were
many difficulties encountered throughout the project. As such the objectives of the
project are successfully fulfilled.
The same movement models, size of network area and number of nodes were used and
the variable for the real life simulation parameter is the velocities of the node speed. By
using random waypoint as the mobility model pattern and ZigBee and Arduino Uno as
the network node, it is observed that the velocities of the node speed can affect the result
of the experiment as can be seen in the result in chapter 5. From the experiment, it is
shown that the packet varies lost if the velocities of the node speed are changed. One of
63
the factor that can affect the experiment result is the distance between sender and the
receiver at a certain point.
6.3 SUGGESTIONS
During the implementation of the hardware and software development, a few obstacles
were faced that could not be dealt with due to lack of knowledge and sufficient time. A
few suggestions and comments were also obtained during the FYP 2 presentation. The
following are a few suggestions and future recommendations that can be done
64