Internet of Things Mesh Network

Total Page:16

File Type:pdf, Size:1020Kb

Internet of Things Mesh Network Internet of Things mesh network Using the Thread networking protocol Anton Alm Faculty of Health, Science and Technology Computer Science 15HP Supervisor: Stefan Alfredsson Examiner: Per Hurtig Date: 2019:01:25 I Abstract This thesis summarizes my project in setting up a Thread network. The idea of this project was presented by the company ÅF in Karlstad, Sweden. ÅF wishes to upgrade their current demonstrator for IoT. The current demonstrator includes Azure Cloud component, Raspberry Pi, Bluetooth and Arduino components. The upgrade includes implementing Thread technology together with Thread verified hardware from Nordic semiconductor [1] and the Raspberry Pi Foundation [2]. Thread is an IoT mesh networking protocol that was released year 2014. Compared to Bluetooth it offers IP communication (including IPv6) combined with higher reliability, performance and security. The process of installing, compiling and configuring the Thread network is explained. The result is an operational thread network that has sensor devices sending data to an HTTP web server, where the data is stored and monitored. Though, there are many improvements and functions that can be implemented to make this demonstrator more appealing. II Contents 1 Introduction ...................................................................................... 1 1.1 Applications ..................................................................................................... 2 1.2 IoT Protocols ................................................................................................... 3 1.3 Thread .............................................................................................................. 4 1.4 Purpose ............................................................................................................ 5 1.5 Goals ................................................................................................................ 6 1.6 Structure .......................................................................................................... 7 2 Background ....................................................................................... 8 2.1 IoT market ....................................................................................................... 8 2.2 Thread .............................................................................................................. 9 2.2.1 Network Architecture ..................................................................................................... 10 2.2.2 Protocol stack.................................................................................................................. 12 2.2.3 IP Addressing .................................................................................................................. 14 2.3 Constrained Application Protocol .................................................................. 15 2.4 Hardware ....................................................................................................... 16 2.4.1 Hardware specification .................................................................................................. 17 2.4.2 Hardware Usage ............................................................................................................. 18 3 Design .............................................................................................. 19 3.1 Network layout .............................................................................................. 19 3.2 Installation .................................................................................................... 20 3.2.1 Software development kit ............................................................................................. 20 3.2.2 Border router ................................................................................................................. 20 3.2.3 Network Co Processor ................................................................................................... 20 3.2.4 Sensor devices ................................................................................................................. 21 3.2.5 Web Server ...................................................................................................................... 21 3.3 Network configuration .................................................................................. 22 3.3.1 Border router .................................................................................................................. 22 3.3.2 Network co-processor .................................................................................................... 22 4 Implementation ............................................................................... 23 4.1 Network settings and commissioning ........................................................... 23 4.1.1 Network co-processor .................................................................................................... 24 4.1.2 Sensor device .................................................................................................................. 24 III 4.2 Sensor devices ............................................................................................... 26 4.2.1 Main function and global variables. .............................................................................. 26 4.2.2 Timer, buttons and CoAP messages .............................................................................. 29 4.3 Web server ..................................................................................................... 34 4.3.1 Port forwarding............................................................................................................... 34 4.3.2 Crosscoap ........................................................................................................................ 34 4.3.3 Database .......................................................................................................................... 35 4.3.4 PHP & HTML .................................................................................................................. 36 5 Results ............................................................................................. 40 5.1 Packet trace analysis ......................................................................................41 5.2 Database visualization ................................................................................... 44 6 Evaluation ....................................................................................... 45 6.1 Goals .............................................................................................................. 45 6.2 Future work ................................................................................................... 46 6.3 Problems ........................................................................................................ 47 7 Summary and Conclusions .............................................................. 48 References ............................................................................................ 50 IV List of figures Figure 1: ÅF's IoT demonstrator. ............................................................................. 5 Figure 2: An example of a Thread network architecture ....................................... 10 Figure 3: HTTP and CoAP protocol stacks. ............................................................ 15 Figure 4: The Nordic Semiconductor nRF52840 Development Kit ..................... 16 Figure 5: The Raspberry Pi Model 3B .................................................................... 16 Figure 6: The programmable buttons on the nRF52840 DK. ................................ 17 Figure 7: The Raspberry Pi and development kit forming the Border router. ..... 18 Figure 8: An overview of the network layout. ........................................................ 19 Figure 9: DK's connected to Embedded Studio and J-Link on the laptop. ...........21 Figure 10: Network co-processor status ................................................................ 22 Figure 11: Network co-processor status ................................................................. 24 Figure 12: Joining the network as a sensor device. ............................................... 24 Figure 13: Configuration settings and testing the network for sensor device. ...... 25 Figure 14: Main function. ....................................................................................... 26 Figure 15: Global variables ..................................................................................... 27 Figure 16: Function thread_instance_init. ........................................................... 27 Figure 17: Function thread_coap_init. .................................................................. 28 Figure 18: Function thread_bsp_init. ................................................................... 28 Figure 19: Function thread_coap_utils_temp_timer_init. .................................. 29 Figure 20: Function temp_timer_handler. ........................................................... 29 Figure 21: Function thread_coap_utils_send_message. ....................................... 31 Figure 22: Start of function bsp_event_handler. .................................................. 32 Figure 23: End of function bsp_event_handler. ................................................... 33 Figure 24: MYSQL
Recommended publications
  • Key Infection: Smart Trust for Smart Dust
    Key Infection: Smart Trust for Smart Dust Ross Anderson Haowen Chan Adrian Perrig University of Cambridge Carnegie Mellon University Carnegie Mellon University [email protected] [email protected] [email protected] Abstract and building safety. As sensor networks become cheaper and more commoditised, they will become attractive to Future distributed systems may include large self- home users and small businesses, and for other new appli- organizing networks of locally communicating sen- cations. sor nodes, any small number of which may be sub- A typical sensor network consists of a large number of verted by an adversary. Providing security for these small, low-cost nodes that use wireless peer-to-peer com- sensor networks is important, but the problem is compli- munication to form a self-organized network. They use cated by the fact that managing cryptographic key ma- multi-hop routing algorithms based on dynamic network terial is hard: low-cost nodes are neither tamper-proof and resource discovery protocols. To keep costs down and nor capable of performing public key cryptography effi- to deal with limited battery energy, nodes have fairly min- ciently. imal computation, communication, and storage resources. In this paper, we show how the key distribution problem They do not have tamper-proof hardware. We can thus ex- can be dealt with in environments with a partially present, pect that some small fraction of nodes in a network may be passive adversary: a node wishing to communicate securely compromised by an adversary over time. with other nodes simply generates a symmetric key and An interesting example of a sensor network technology sends it in the clear to its neighbours.
    [Show full text]
  • Shared Sensor Networks Fundamentals, Challenges, Opportunities, Virtualization Techniques, Comparative Analysis, Novel Architecture and Taxonomy
    Journal of Sensor and Actuator Networks Review Shared Sensor Networks Fundamentals, Challenges, Opportunities, Virtualization Techniques, Comparative Analysis, Novel Architecture and Taxonomy Nahla S. Abdel Azeem 1, Ibrahim Tarrad 2, Anar Abdel Hady 3,4, M. I. Youssef 2 and Sherine M. Abd El-kader 3,* 1 Information Technology Center, Electronics Research Institute (ERI), El Tahrir st, El Dokki, Giza 12622, Egypt; [email protected] 2 Electrical Engineering Department, Al-Azhar University, Naser City, Cairo 11651, Egypt; [email protected] (I.T.); [email protected] (M.I.Y.) 3 Computers & Systems Department, Electronics Research Institute (ERI), El Tahrir st, El Dokki, Giza 12622, Egypt; [email protected] 4 Department of Computer Science & Engineering, School of Engineering and Applied Science, Washington University in St. Louis, St. Louis, MO 63130, 1045, USA; [email protected] * Correspondence: [email protected] Received: 19 March 2019; Accepted: 7 May 2019; Published: 15 May 2019 Abstract: The rabid growth of today’s technological world has led us to connecting every electronic device worldwide together, which guides us towards the Internet of Things (IoT). Gathering the produced information based on a very tiny sensing devices under the umbrella of Wireless Sensor Networks (WSNs). The nature of these networks suffers from missing sharing among them in both hardware and software, which causes redundancy and more budget to be used. Thus, the appearance of Shared Sensor Networks (SSNs) provides a real modern revolution in it. Where it targets making a real change in its nature from domain specific networks to concurrent running domain networks. That happens by merging it with the technology of virtualization that enables the sharing feature over different levels of its hardware and software to provide the optimal utilization of the deployed infrastructure with a reduced cost.
    [Show full text]
  • Wireless & Self-Powered Internet of Things
    Wireless & self-powered Internet of Things The Dolphin products are based on miniaturized energy converters, ultra-low power electronics and robust radio technology in open standards like EnOcean, zigbee and Bluetooth Low Energy for OEM product manufacturers. Building automation Smart home LED lighting M2M Our technology The Dolphin modules and white label products use the energy harvesting principle, in which energy is obtained from the surroundings, to supply self-powered wireless sensor networks. The modules are based on miniaturized energy converters that convert motion, light or temperature differences into electrical energy. Together with an efficient energy management system, the energy harvesting technology facilitates communication between maintenance-free IoT devices based on open wireless standards, such as EnOcean, zigbee and Bluetooth Low Energy. The solutions are used in building automation, smart homes, LED lighting control systems as well as industrial applications. Energy harvesting Wireless Ultra-low power The Dolphin portfolio for OEM product manufacturers The Dolphin portfolio includes the product lines “868 MHz EnOcean” for Europe, “902 MHz EnOcean” for North America and “928 MHz EnOcean” in Japan based on the EnOcean wireless standard introduced by the EnOcean Alliance (ISO/IEC 14543-3-1X) on the sub 1 GHz band, which has proven to be a resounding success in building automation and smart homes. The Dolphin porftolio also includes the “2.4 GHz zigbee” product line in the 2.4 GHz band, which can be used in smart home applications all over the world, and the “2.4 GHz BLE” portfolio for Bluetooth systems for modern lighting control. Energy converter Energy harvesting Energy harvesting Controlers Tools wireless switches wireless sensors Products in 868 MHz EnOcean for Europe Products with 868 MHz are suitable for Europe and other countries adopting RED.
    [Show full text]
  • Comparison of Zigbee, Z-Wave, Wi-Fi, and Bluetooth Wireless Technologies Used in Home Automation
    Comparison of Zigbee, Z-Wave, Wi-Fi, and Bluetooth Wireless Technologies Used in Home Automation Salim Jibrin Danbatta Asaf Varol Department of Software Engineering Department of Software Engineering Firat University Firat University Elazig, Turkey Elazig, Turkey [email protected] [email protected] Abstract— Most of the home automation wireless technologies A literature review is presented in section II, home on the internet of things are based on ZigBee, Z-Wave, Wi-Fi, automation wireless technologies are discussed in section III. and Bluetooth wireless technologies. While these solutions are The research design is described in section IV while results and good enough, users of smart homes are facing challenges of discussion are presented in section V, and section VI describes selecting the best technology. This paper compares the the conclusions of the study. performance of ZigBee, Z-Wave Wi-Fi and Bluetooth technologies from the user’s perspective. Power consumption, range, cost, ease of use, scalability, and interoperability are the six indices developed as guidelines to potential users, and hence, II. LITERATURE REVIEW the results of this study. With this knowledge, the users can make the appropriate choice of wireless technology solution to use in Several studies about home automation systems have been their home automation systems. done in the past. They include experimental, descriptive, and comparative analysis involving different wired and wireless Keywords—internet of things, home automation, wireless technologies used in Home Automation. technologies, Zigbee, Z-Wave, Wi-Fi, Bluetooth Sikandar et al. [5] show how SMS (short message service) based and wireless technology enhance the controlling of home I.
    [Show full text]
  • ZIGBEE EXPLOITED the Good, the Bad and the Ugly
    08 ZIGBEE EXPLOITED The good, the bad and the ugly Tobias Zillner – August 6th 2015 Cognosec © 2015 | Castellezgasse 16/2 | 1020 Vienna, Austria ZigBee Exploited Version 1.0 TABLE OF CONTENTS ABSTRACT ..................................................................................................................................................... 1 INTRODUCTION ............................................................................................................................................. 1 THE ZIGBEE STANDARD .............................................................................................................................. 1 ZIGBEE SECURITY ........................................................................................................................................ 2 Network Layer Security ................................................................................................................................ 2 Application Support Sublayer Security ......................................................................................................... 2 ZIGBEE APPLICATION PROFILES ............................................................................................................... 3 ZigBee Home Automation Public Application Profile (HAPAP) .................................................................... 3 ZigBee Light Link Profile (ZLL) ..................................................................................................................... 4 SECBEE – A NEW ZIGBEE SECURITY
    [Show full text]
  • Concepts General Concepts Wireless Sensor Networks (WSN)
    Wireless Sensor Networks – Concepts General Concepts Wireless Sensor Networks (WSN) are built based on a combination of multiple sensors placed in diverse locations, wireless communication network infrastructure and software data processing to monitor and record multiple parameters. Commonly monitored parameters are temperature, atmospheric pressure, humidity, vibration, illuminance, sound level, power consumption, chemical concentration, body health signals and many others, dependant on the selected available sensors. The WSN are used in multiple fields, ranging from remote environment monitoring, medical health, to home surveillance and industrial machines monitoring. In some cases, WSN can also be additionally used for control functions, apart from monitoring functions. Typically a WSN is made of sensor nodes that are wirelessly connected to a gateway that is then connected to a main computer (Fig. 1). In some WSN the sensor nodes can also be connected to each other, so that is possible to implement multi-hop wireless mesh networks. The gateway connects to the main computer through a cabled or wireless connection. Figure 1 – Wireless sensor network The wireless communications used in WSN depend on the application requirements, taking into consideration the needs in terms of transmission distance, sensor data bandwidth, energy source and power consumption. Common communications include standard protocols such as 2.4 GHz radio based on either IEEE802.15.4 (ZigBee, ISA 100, WirelessHart, MiWi) or IEEE802.11 (WiFi) standards. Each sensor node typically includes an embedded microcontroller system with adequate electronic interface with a sensor (or set of sensors), a radio transceiver with antenna (internal or external) and an energy source, usually a battery, or in some cases an energy harvesting circuit.
    [Show full text]
  • Flexis—A Flexible Sensor Node Platform for the Internet of Things
    sensors Article FlexiS—A Flexible Sensor Node Platform for the Internet of Things Duc Minh Pham and Syed Mahfuzul Aziz * UniSA STEM, University of South Australia, Mawson Lakes, SA 5095, Australia; [email protected] * Correspondence: [email protected]; Tel.: +61-08-8302-3643 Abstract: In recent years, significant research and development efforts have been made to transform the Internet of Things (IoT) from a futuristic vision to reality. The IoT is expected to deliver huge economic benefits through improved infrastructure and productivity in almost all sectors. At the core of the IoT are the distributed sensing devices or sensor nodes that collect and communicate information about physical entities in the environment. These sensing platforms have traditionally been developed around off-the-shelf microcontrollers. Field-Programmable Gate Arrays (FPGA) have been used in some of the recent sensor nodes due to their inherent flexibility and high processing capability. FPGAs can be exploited to huge advantage because the sensor nodes can be configured to adapt their functionality and performance to changing requirements. In this paper, FlexiS, a high performance and flexible sensor node platform based on FPGA, is presented. Test results show that FlexiS is suitable for data and computation intensive applications in wireless sensor networks because it offers high performance with low energy profile, easy integration of multiple types of sensors, and flexibility. This type of sensing platforms will therefore be suitable for the distributed data analysis and decision-making capabilities the emerging IoT applications require. Keywords: Internet of Things (IoT); wireless sensor networks (WSN); sensor node; field-programmable Citation: Pham, D.M.; Aziz, S.M.
    [Show full text]
  • A Zigbee-Based Wireless Biomedical Sensor Network
    A ZIG BEE -BASED WIRELESS BIOMEDICAL SENSOR NETWORK AS A PRECURSOR TO AN IN-SUIT SYSTEM FOR MONITORING ASTRONAUT STATE OF HEALTH by XIONGJIE DONG B.S., Kansas State University, 2011 A THESIS submitted in partial fulfillment of the requirements for the degree MASTER OF SCIENCE Department of Electrical & Computer Engineering College of Engineering Kansas State University Manhattan, Kansas 2014 Approved by Major Professor Steve Warren ABSTRACT Networks of low-power, in-suit, wired and wireless health sensors offer the potential to track and predict the health of astronauts engaged in extra-vehicular and in-station activities in zero- or reduced- gravity environments. Fundamental research questions exist regarding (a) types and form factors of biomedical sensors best suited for these applications, (b) optimal ways to render wired/wireless on-body networks with the objective to draw little-to-no power, and (c) means to address the wireless transmission challenges offered by a spacesuit constructed from layers of aluminized mylar. This thesis addresses elements of these research questions through the implementation of a collection of ZigBee-based wireless health monitoring devices that can potentially be integrated into a spacesuit, thereby providing continuous information regarding astronaut fatigue and state of health. Wearable biomedical devices investigated for this effort include electrocardiographs, electromyographs, pulse oximeters, inductive plethysmographs, and accelerometers/gyrometers. These ZigBee-enabled sensors will form the nodes of an in-suit ZigBee Pro network that will be used to (1) establish throughput requirements for a functional in-suit network and (2) serve as a performance baseline for future devices that employ ultra-low-power field-programmable gate arrays and micro-transceivers.
    [Show full text]
  • A Comparative Study Between Operating Systems (Os) for the Internet of Things (Iot)
    VOLUME 5 NO 4, 2017 A Comparative Study Between Operating Systems (Os) for the Internet of Things (IoT) Aberbach Hicham, Adil Jeghal, Abdelouahed Sabrim, Hamid Tairi LIIAN, Department of Mathematic & Computer Sciences, Sciences School, Sidi Mohammed Ben Abdellah University, [email protected], [email protected], [email protected], [email protected] ABSTRACT Abstract : We describe The Internet of Things (IoT) as a network of physical objects or "things" embedded with electronics, software, sensors, and network connectivity, which enables these objects to collect and exchange data in real time with the outside world. It therefore assumes an operating system (OS) which is considered as an unavoidable point for good communication between all devices “objects”. For this purpose, this paper presents a comparative study between the popular known operating systems for internet of things . In a first step we will define in detail the advantages and disadvantages of each one , then another part of Interpretation is developed, in order to analyze the specific requirements that an OS should satisfy to be used and determine the most appropriate .This work will solve the problem of choice of operating system suitable for the Internet of things in order to incorporate it within our research team. Keywords: Internet of things , network, physical object ,sensors,operating system. 1 Introduction The Internet of Things (IoT) is the vision of interconnecting objects, users and entities “objects”. Much, if not most, of the billions of intelligent devices on the Internet will be embedded systems equipped with an Operating Systems (OS) which is a system programs that manage computer resources whether tangible resources (like memory, storage, network, input/output etc.) or intangible resources (like running other computer programs as processes, providing logical ports for different network connections etc.), So it is the most important program that runs on a computer[1].
    [Show full text]
  • Zigbee-Based System for Remote Monitoring and Control of Switches
    Copyright is owned by the Author of the thesis. Permission is given for a copy to be downloaded by an individual for the purpose of research and private study only. The thesis may not be reproduced elsewhere without the permission of the Author. ZigBee-Based System for Remote Monitoring and Control of Switches A thesis presented in partial fulfilment of the requirements for the degree of Master of Engineering at Massey University, Albany, New Zealand. © Matthew Lyon October 2010 1 Abstract Home automation technology has existed for nearly four decades, but is nonetheless mostly absent in the average home today. The systems that do exist are often highly customised and expensive, catering to a very niche market, or overly sophisticated and complicated. Many of these also require extensive, dedicated cabling as their communications backbone and as such are only practical to install during the construction of a new house. The core aims of this project are to develop a cheap and simple home automation system that can be easily installed in new and existing houses. These aims are achieved by creating a centralised system where most of the intelligence is managed by a PC server and the end nodes are kept as simple as possible. The server is responsible for basic security, maintaining awareness of the current system state and providing the user interface. At the outer edge of the system is a ZigBee network of wall switches and, in between, a home gateway provides a protocol translation service between the two. The new, “smart” switches are designed to be entirely compatible with existing wall switches in terms of their mounting and wiring requirements, and so ZigBee is chosen to provide a reliable wireless communication channel between the end nodes and the gateway.
    [Show full text]
  • What's New in Zigbee 3.0
    White Paper SWRA615A–June 2019 What's New in Zigbee 3.0 Zigbee is an industry-proven worldwide standard for low power, self-healing, robust mesh networks offering a complete and interoperable IoT solution for home and building automation. Based on the IEEE 802.15.4 standard and providing a simplified approach to commissioning devices securely, it enables users the ability to form networks involving over 250 devices for large coverage areas. Through adherence to a profile specification and ZCP (Zigbee Compliant Platform) testing, Zigbee devices can become certified for interoperability across various platforms. Texas Instruments™ CC13x2 and CC26x2 devices are part of the SimpleLink™ microcontroller (MCU) platform. Zigbee based applications can be developed on these devices using the TI Z-Stack included with the SimpleLink™ CC13x2 and CC26x2 software development kit (SDK). This SDK includes everything needed to develop Zigbee certifiable solution including tools, application examples, documentation and source code. It uses Zigbee 3.0, the latest specification from the Zigbee Alliance which unifies former application segments under a common certification process. The following sections intend to give users an overview of all of the new features introduced in the Zigbee 3.0 specification. 1 Overview At the core of Zigbee 3.0 is the Zigbee PRO 2017 (R22). Note that previously Zigbee Pro 2015 (R21) was required for Zigbee 3.0, which has now been replaced with the newer Zigbee Pro 2017 (R22) specification. Older implementation based on the R21 specification are still compatible with the new R22 specification. The Zigbee PRO Specification adds child device management, improved security features, and new network topology options to Zigbee networks.
    [Show full text]
  • Cybersecurity of Industrial Cyber-Physical Systems: a Review
    CYBERSECURITY OF INDUSTRIAL CYBER-PHYSICAL SYSTEMS: AREVIEW Hakan Kayan Matthew Nunes School of Computer Science and Informatics School of Computer Science and Informatics Cardiff University, UK Cardiff University, UK [email protected] [email protected] Omer Rana Pete Burnap School of Computer Science and Informatics School of Computer Science and Informatics Cardiff University, UK Cardiff University, UK [email protected] [email protected] Charith Perera School of Computer Science and Informatics Cardiff University, UK [email protected] January 12, 2021 ABSTRACT Industrial cyber-physical systems (ICPSs) manage critical infrastructures by controlling the processes based on the “physics” data gathered by edge sensor networks. Recent innovations in ubiquitous computing and communication technologies have prompted the rapid integration of highly intercon- nected systems to ICPSs. Hence, the “security by obscurity” principle provided by air-gapping is no longer followed. As the interconnectivity in ICPSs increases, so does the attack surface. Industrial vulnerability assessment reports have shown that a variety of new vulnerabilities have occurred due to this transition while the most common ones are related to weak boundary protection. Although there are existing surveys in this context, very little is mentioned regarding these reports. This paper bridges this gap by defining and reviewing ICPSs from a cybersecurity perspective. In particular, multi-dimensional adaptive attack taxonomy is presented and utilized for evaluating
    [Show full text]