Performance assessment of static and dynamic routings using 6LoWPAN on small scenarios applied to monitoring of Barranquilla ash ood

The Internet of Things (IoT) is growing rapidly due to the wireless network that provides connectivity to devices at anytime and anywhere. Currently, the wireless sensor network is involved in many research elds like smart health monitoring, smart cities, and smart industries. From all of these, ood monitoring is the most important eld in the IoT wireless network to alert about the occurrence of any abnormalities. To monitor the environment wireless sensor network needs a decision-making protocol that sense and route the information timely. The present work includes numerous use of Low Power Wireless Personal Area Networks (6LoWPAN) with IPv6 protocol dened by the Internet Engineering Task Force (IETF) due to its different test conditions, analysing static and dynamic routing and its impact on different performance metrics such as latency and packet losses for their application in monitoring system of the ash oods in any region. In this study, we are using IPv6 6LoWPAN to develop a wireless warning system before a ood event in “The Brigade” in Barranquilla city. The basic purpose for making system is to secure the city from costly damage and life loss. Different types of trac and different 1-/2-hops scenarios have been considered. In order to implement our system, we use the well-known TelosB platform jointly with TinyOS, BLIP 2.0 and LPL. The experiment result shows that time on 512 ms and 1024 ms with a packet of 120 B obtain good performance on the metrics used for the tests.


Introduction
The Internet of Things (IoT) is growing due to wireless sensor network that provide smart devices connectivity from anywhere and is evolving many research elds like smart hospitals, smart tra c, smart city, environment monitoring and smart decision making systems. This wireless connectivity also increases the data tra c in IoT [1,2,3]. To transmit the data the network needs some new platform, technologies, network architectures and network protocols to route the data [4,5,6]. The wireless network has many protocols, one of these protocols is the IPv6 for Low Power Wireless Personal Area Networks (6LoWPAN), de ned by the Internet Engineering Task Force (IETF) in the RFC4944 [7]. It is very vastly in use IPv6 protocol over IEEE 802. 15.4 [8] due to its compatibility with wireless sensor nodes [7][8][9]. In IoT the research community has developed many environment monitoring applications like Early Warning Systems (EWS) for catastrophic events to improve the life quality and lifesaving [10,12,13]. In the case of the EWS, a monitoring system that is the objective of this work for the ash oods that occur in the rainy season in the city of Barranquilla -Colombia. This problem has occurred for many years in this city, therefor this work support by the University of the Coast at a zone known as "The Brigade" for generate alerts when this event is occurred [11,14]. The existing studies include damages of oods in terms of cost and life. We do not nd any study and EWS system for Barranquilla -Colombia to alert from ood. We develop a system and mitigate different kinds of tests with three nodes to send packets, using the 6LoWPAN logical addressing method and two routing protocols. This allow analysing the implementation of 6LoWPAN in the monitoring of ash oods in the area of "The Brigade" as shown in Fig. 1a section of the interest zone where the ash ood occurs.
In this context, the study of the performance of 6LoWPAN considering different routing methods, static and dynamic. In order to compare the performance, the present work is based on the TelosB platform [15] [17] and for energy saving purposes like, Low-Power Listening (LPL) [18] have been used. The results are more important in this work therefore the methodologies for the evaluation of 6LoWPAN performance with the established metrics, obtaining impacts important for the select routing type and the channel scan time for the energy saving with the LPL protocol. Furthermore, is possible to analysing the network performance according the select packet length. Criteria is also provided for the selection of TelosB platform and 6LoWPAN applied a monitoring network for ash oods in the "The Brigade" area of the city of Barranquilla. The rest of the paper is organized as follows: Sect. 2 provides an overview of the most relevant work about 6LoWPAN applications and metrics for WSN. Section 3 describes the materials and methods, as well as the test scenarios used. Section 4 presents the results and its analysis. Finally, Sect. 5 describes the most relevant conclusions of this paper.

Emerging technologies for Early Warning System
The natural hazards affect large part of the population, resulting in severe economic and human losses.
For mitigate the impact in the population of the natural hazards are implemented Early Warning System (EWS) in vulnerable areas. This System are an important tool to hazard risk management and many applications requires this solutions to face phenomenon such as tornadoes [19,20], oods [21,22], landslides [23,24], ash-oods [25,26], tsunamis [27], and similar. Therefore, the use of emerging technologies in EWS is relevance and is a challenge for the researchers. This technologies consist of innovations such as IoT, new protocols and low cost platforms, which have been implemented in solutions for monitoring system and IoT. For example, in Surabaya -Indonesia have development an IoT system in EWS to garbage collector robots and be able to monitoring severe and dangerous conditions; this prototype can monitoring the battery level information and operation to the robot; the ESP8266-12 module allows the WIFI communication with an android platform [28]. In Malaysia an IoT system is proposed for a ood EWS; this system consist of a wireless sensor networks, wind sensors and cellphone images that are sent to cloud using Zigbee and 3G for monitoring and warning to the users [29].In Pakistan, a low cost ood EWS is development using Raspberry Pi platform, video camera, temperature and humidity sensors, energy system (battery and solar panels); this system send GSM data to Web dashboard, showing the level water [30]. In Italy, a WSN (Wireless Sensor Networks) is used to estimate landslide; for this, the RF signal is analyzed in the nodes of the WSN and establish its location in draw a grid map; the change in the locate to the node can indicate that a landslide is present by soil movement [31]. For this work, the ash ood are the principal context, because have caused material and human losses in recent decades in the Barranquilla city, also causing congestion of tra c and dragging sediments by the ow. There are thirty zones where ash oods occur due to the absence of sewerage over the city, and although some canalizations work has been carried out in some cases, it is important to have systems based on emerging technologies that can generate warning for the vulnerable population.
This motivated different studies from the "Universidad de la Costa" to generate solutions to this problem in Barranquilla [32, 33, 34].

6LoWPAN and applications
The use of emerging technologies for environment applications is important for evaluate its possible As a trend, there are a lot of different studies about its performance like the one about high-precision agriculture [39] or the latency and energy consumption related to networking mobility (NEMO) [40], or even studies about network congestion problems [41], security in point-to-point networks [42], impact in medical applications within high-mobility environments [43,44] or deep analysis of the energy consumption among the nodes [45,46].
In the analysis of the literature different performance metrics was analyzed. Additionally the factors that produced incidence in the metrics were identi ed. Furthermore, the hardware and software platforms used for 6LoWPAN were analysed. Based on the above, some researches focused on high-precision agriculture have been developed using the TelosB platform with different sensors jointly with TinyOS, RPL-6LoWPAN and LPL. In this work different time intervals (512, 1024 and 2048 ms) and their impact in the battery lifetime have been analysed, resulting in an improvement of the lifetime through using a 2048 ms interval [47]. Other relevant work is focused on the carbon-cycle measuring in the Peruvian Amazon jungle, using the same platform [48]. Other applications use the same platform, testing instead of TinyOS, ContikiOS [49]. This revision is important for select the TelosB platform how a tool for the tests analysis in this work. Likewise for the time selection in the tests with the LPL protocol.
Different works have analysed the performance of different platforms, covering a wide spectrum among the use of various microcontrollers like Waspmote, TelosB, Arduino and radios like XBee, MicaZ and iMote2. These works also analysed different metrics and parameters, such as the delay in the message reception or the throughput using different payloads [50]. Researches in the eld of second layer protocols [51] have analysed different metrics such as the duty cycle, latency and throughput, looking for the optimal use conditions in ContikiOS [52].
The above analysis is important for the selection of the metrics, such as the latency and the packet loss. Similarly this analysis allows de ne the platform TelosB y the framework TinyOS for the use in the tra cs tests for the proposed scenario. On the other hand, RPL, as a part of 6LoWPAN, is being widely studied [53], not only in the eld of Wireless Personal Area Networks (WPANs), but also in the eld of Body Area Networks (BANs) [54,55]. Thus the comparative between RPL and static routing is an important factor for the analysis in the tests.
In this study, we are using IPv6 6LoWPAN to develop a wireless warning system before a ood event in "The Brigade" in Barranquilla city. The basic purpose for making system is to secure the city from costly damage and life loss. Different types of tra c and different 1-/2-hops scenarios have been considered. In order to implement our system, we use the well-known TelosB platform jointly with TinyOS, BLIP 2.0 and LPL. The experiment result shows that time on 512 ms and 1024 ms with a packet of 120 B obtain good performance on the metrics used for the tests.

Materials and methods
This section presents the scenarios and tests carried out. The present work is based on the TelosB platform, which is a low-cost and well-known platform in the academic world. This platform also offers support to the IEEE 802.15.4 and 6LoWPAN through the use of TinyOS, BLIP, RPL and LPL. In order to capture and analyse tra c, like the Internet Control Message Protocol version 6 (ICMPv6), Wireshark [54,56] has been used. The tra c for these tests is ICMPv6 (Internet Control Message Protocol for the Internet Protocol Version 6) packet, which has been generated using the tool PINGv6. As a result, Round Trip Times (RTT) of the nodes is received on the sink, measuring packet losses and packet delays for the performance analysis. The Fig. 3 show a owchart for the implementation of 6LoWPAN on the TelosB platform and the basics tests for the initially connectivity.

Scenarios
The scenario presented in this paper is based on three nodes and a host computer. The topology is pointto-point and involves a node working as sink and two as sensor nodes. The Fig. 4 shows the proposed scenario, where the node 1 jointly with the computer acts as sink and the node 2 acts as router.
This work considers the Line-Of-Sight (LOS) between nodes as a reference in order to deploy the nodes. Thus, the network has been designed avoiding the LOS between node 1 and 3 in order to generate a directed routing scheme (i.e. the 2-hops route used in the tests). For this network, both static and dynamic routing methods have been considered. Table 1 shows the static routing con guration, for the dynamic routing, RPL is the protocol used.

Test Description
The tests carried out have been based on the sending of PINGv6 messages, rst, to test the connectivity among nodes, afterwards, generating tra c during 5 minutes that can be captured and analysed with Wireshark. The performance of the network is based on the packet size and the distance between nodes. Table 2 shows all the different tests carried out.

Packet Losses
The packet losses have been measured rstly between the sink and the node 2, with only one hop, varying the payload, the time interval con guration of LPL and the distance between both nodes. After this test, a second analysis has been carried using all the nodes in the network and analysing the performance with two hops, varying also the time con guration of LPL and the routing type. The tra c monitoring has been focused on nodes 2 and 3.

RTT average time
To calculate this metric, the time between packet sending and packet response arrival has been measured. A previous theoretic analysis shows that the packets could suffer of delays, due to the processing time, which is associated to routing tasks among the network. It can be affected also by delays derived of the application of LPL. The RTT average time is measured as the sum of the RTT average time for a 5 minutes test, using the same tests and conditions than in the packet losses analysis.

RTT sending average delay
The RTT sending delay is measured as the elapsed time between sending two packets with acknowledging receive, consecutively. This metric is calculated because in some cases the packets sent from the sink do not produce any reply from the nodes. Then, the RTT sending average delay is the average time elapsed between sending two packets with acknowledging receive consecutively, using the same factors and conditions as in the packet losses analysis.
The RTT delay is measured in the sink by the information received in the Wireshark tool [58, 59].

Sending packet average delay
The packet sending response has been analysed, regardless of the successful acknowledge message reception, as the elapsed time between the sending of a packet from the sink node to the node 2. The tests carried out have been similar to the previous ones.

Average Jitter
The average jitter has been measured based on the time obtained from the subtraction of the delay to two consecutive packet sending time. The average of these results is calculated giving the nal average jitter measurement. Figures 5 and 6 and Tables 3 and 4 presents the results corresponding to the tests previously explained.   Figure 5A shows the results for the packet losses considering the distance differences, packet size and LPL use. These results show that without LPL, the loss rate is lower than with LPL, ranging from 1-10%.

Results And Discussion
Using LPL with a 1024ms sleep interval and 1133 Bytes packet size, the loss rate ranges from 68-72%. The distances chosen do not exceed 40m. These experiment results show that the packet size has an impact on the loss rate, even being twice as much as the rate for 1133B packet size. It results interesting that increasing the distance does not show any impact in the results for this scenario and con guration. Figure 6A shows the packet losses for nodes 2 and 3, using static and dynamic routing. LPL with a con guration of 0, 512 and 1024ms has been applied, resulting the 1024ms con guration, the best in terms of energy consumption. The Fig. 6A shows that the routing type does not affect the performance. Another interesting fact is that the node 2 does not lose any packet for the 0ms LPL-con guration, otherwise, the node 3 loses up to 50% more packets than the node 2 for the same scenario and con guration.
In the test with LPL the packet loss rate increases for the node 2 and 3, but the difference between different LPL-con gurations is not signi cant, even in the node 3, where the differences are higher than in node 2. Tables 3 and 4 show the average RTT latencies. Figure 5B shows similar results for the different distances tested in the 1-hop scenario. The RTT with a lower packet size shows a shortest duration, due to the shortest processing time among the route. There is no signi cant difference for the RTT duration sending 120B between 0 and 1024 ms LPL-con guration. On the other hand, the RTT duration increases up to 50% for 1133B sending with 1024 ms LPL-con guration. Finally, the best results are shown in the test sending 120B with 1024 ms LPL-con guration, showing also that the distances are not signi cant for the performance analysis. Figure 6B presents the RTT duration results for a 2-hops scenario, showing no signi cant difference in the results derived from the routing type. With 0 ms LPL-con guration the overall performance in terms of RTT duration is shorter than with the other con gurations. The Fig. 6B also shows differences of 0.3 s for node 2 and 0.5 s for node 3 with a 512 ms LPL-con guration, however the RTT duration is even higher for a 1024 ms LPL-con guration. These test results show that node 3 has a higher RTT, almost being twice as much as the duration than node 2 shows, in all the 2-hop tests carried out, considering all the different con gurations.

RTT Latency
The application of a 0 ms LPL-con guration results in an increment in terms of energy consumption but it also results in an improvement of the RTT duration time. Thus, between a 512 ms and a 1024 ms LPLcon guration, the RTT duration time differences are not signi cant, so it would be better to use a 1024 ms LPL-con guration in order to improve the energy consumption. Figure 5C presents the results in terms of RTT send average delay for 1-hop, showing a shorter delay for the 0 ms LPL-con guration con guration. Delay lightly increases with the distance as show the difference of 0.2s between 10 and 40 m scenarios. This small difference does not affect the development of the tests. Figure 6C shows the results of RTT send average delay for 2-hops scenario, showing no signi cant differences between routing types. For a 0 ms LPL-con guration the RTT delay is generally shorter than for other LPLcon gurations. In this scenario, the difference between nodes is signi cant, reaching 2-3 seconds. For 512 and 1024 ms LPL-con gurations there is no signi cant difference. Like in other scenarios, a 1024 ms LPL-con guration results in better energy consumption. Tables 3 and 4 show the packet sending delay and the jitter results for the 1-and 2-hops scenarios under different con gurations. Figure 5D presents the packet sending delay for 1-hop scenarios, showing 1 s delay for all the distances considered, regardless the packet size. The delays detected have been very short 3-4 ms, which have been associated to the processing time among the route. There are no signi cant differences between 0 and 1024 ms LPL-con guration for 120B sending. Moreover, the distances do not present any signi cant in uence in the jitter results. Figure 6D presents the packet sending delay for 2-hops scenarios, con rming that routing type does not have any impact in the sending delay. For both routing types, 0 ms LPL-con guration shows a shorter delay than a 1024 ms LPL-con guration, but as collateral drawback shows higher energy consumption and 4 ms delay. Regarding to the jitter, Fig. 5E shows a higher jitter for 1-hop scenarios than for 2-hops scenarios. Con guration also plays a major role, showing a higher jitter sending 1133B and using 1024ms LPL-con guration. Changes in distances do not show any signi cant impact in jitter results. Figure 6E presents the jitter results for 2-hops scenarios, and it shows lightly differences, around 6 ms for all the cases analysed. For these tests, the shortest jitter is shown with a 0 ms LPL-con guration, whereas the other LPL-con gurations do not present any signi cant difference. The difference between a 0 and 1024 ms LPL-con guration remains under 4 ms, resulting much more suitable the 1024 ms LPLcon guration in order to reduce the energy consumption. Again, the routing type does not impact the overall performance in terms of jitter.

Conclusion
Based on the 1-hop tests carried out, it seems to be better the use of 1024 ms as channel scanning time con guration (LPL-con guration) because the network performance does not drop and the energy consumption is reduced. It has been observed that the packet size is signi cant for this scenario, resulting the use of 1133B payload in longer delays and higher packet losses. Packet losses increase for 2-hops scenarios, reaching its maximum for node 3. The impact of the LPL-con guration is lightly signi cant in terms of packet losses, but more signi cant in terms of energy consumption. A 1024 ms LPL-con guration results in a good compromise between losses and energy consumption. Routing types do not present any signi cant difference for the different metrics analysed in the present paper. Packet sending delays are not signi cant between 1-and 2-hops scenarios, remaining under 5 ms, thus, there is no signi cant impact in the network performance. Distances between nodes do not seem to be signi cant for the performance of network, at least, not for the considered scenarios and con gurations. It is highly recommended to use 1024 ms LPL-con guration, not only for 1-hop scenarios, but also for 2-hops scenarios in order to obtain an overall improvement in terms of energy consumption.
Finally, the TelosB platform is a system that allows its use for evaluation of data transmission. Although it is not a robust system, its use for monitoring ash oods is possible by implementing sensors such as rain gauges, given its easy integration. Currently the literature does not evidence works that apply the TelosB platform and the 6LoWPAN method for ash ood monitoring systems.

Declarations
Availability of data and materials: The authors declare that all the data and materials in this manuscript are available.
Competing Interest: There is no competing interest.
Funding: As the paper is supported by the 1 st author by the Universidad de la costa< Barranquilla, Colombia.