Energy efficient context aware traffic scheduling for

0 downloads 0 Views 3MB Size Report
May 5, 2017 - multi-hop communication with efficient duty cycling for the wire- ...... [20] D. Camps-Mur , M.D. Gomony , X. Pérez-Costa , S. Sallent-Ribes , Leveraging ... [24] G.A. Shah , V.C. Gungor , O.B. Akan , A cross-layer design for qos ...
Ad Hoc Networks 62 (2017) 101–115

Contents lists available at ScienceDirect

Ad Hoc Networks journal homepage: www.elsevier.com/locate/adhoc

Energy efficient context aware traffic scheduling for IoT applications Bilal Afzal a,∗, Sheeraz A. Alvi a, Ghalib A. Shah b, Waqar Mahmood b a b

Al-Khawarizmi Institute of Computer Science, University of Engineering and Technology, Lahore 54000, Pakistan Sultan Qaboos IT Chair, University of Engineering and Technology, Lahore 54000, Pakistan

a r t i c l e

i n f o

Article history: Received 31 August 2016 Revised 12 April 2017 Accepted 4 May 2017 Available online 5 May 2017 Keywords: Internet of things Energy efficiency Traffic scheduling Context awareness Multi-hop communication

a b s t r a c t The evolution of Internet of Things (IoT) has increased the appetite for the energy efficient wireless infrastructures. Most of the IoT devices are inherently resource constrained and heterogeneous in respect of their traffic demand. Moreover, these devices need to be made adaptable to the varying environmental conditions. However, existing traffic scheduling and duty cycling algorithms lack the capability to meet the dynamic service quality requirements of IoT applications with variable context information. Specifically, they are infeasible for IoT use-cases where multi-hop communication is required. This paper strives to realize efficient resource allocation to the Wi-Fi based IoT devices in multi-hop IoT infrastructures. Firstly, IoT applications are characterized as per their heterogeneous traffic demand and mapped to the distinct weighted quality classes. Then, context awareness is introduced for IoT devices and an optimization model constrained by their service quality requirements and context priorities is presented. Further, an energy efficient context aware traffic scheduling (EE-CATS) algorithm is proposed wherein the convergence of model is specified by a sub-gradient projection method. The EE-CATS algorithm efficiently allocates resources to multi-hop IoT devices and reduce their total awake time by employing adaptive duty cycling. The performance evaluation is done for various IoT use-cases through simulations in Network Simulator (ns-2) and testbed implementation in Contiki operating system. The results suggest substantial improvements in the energy efficiency of IoT devices while ensuring their dynamic service requirements. In addition, the proposed algorithm minimizes the end-to-end delays in overall IoT networks. © 2017 Elsevier B.V. All rights reserved.

1. Introduction The immense growth of wireless sensor networks (WSNs) and wireless multimedia sensor networks (WMSNs) has multiplied the demand for energy efficient wireless deployments [1]. WMSNs are classified by the on-demand or dynamic multimedia data reporting and sharing among ubiquitously connected devices [2]. The multi-dimensional impact of WSNs and WMSNs can be contemplated as the networks of low-power devices aimed at reducing power consumption while reporting an event, and as high-capacity multimedia devices with mesh networking capabilities for information sharing, respectively. Internet of Things (IoT) further characterizes this phenomenon envisaged by these sensor networks as it enables smart heterogenous devices to interact, communicate as well as react intelligently and autonomously while leveraging the cloud based physical and virtual resources. The IoT paradigm, however, poses the challenges of heterogeneity of devices and heterogeneity of traffic shared among them; since IoT infrastructures ∗

Corresponding author. E-mail addresses: [email protected] (B. Afzal), [email protected] (S.A. Alvi), [email protected] (G.A. Shah). http://dx.doi.org/10.1016/j.adhoc.2017.05.001 1570-8705/© 2017 Elsevier B.V. All rights reserved.

comprise not only smart sensors, embedded devices, nano-devices, body sensors but also conventional electronic gadgets and other types of circuitry [3]. Owing to this heterogeneity of devices and their traffic, the two fundamental questions that arise include: how the traffic demand and associated scheduling for the devices in future IoT infrastructures will be provided as per their continuously varying environmental conditions (i.e. contexts)?; and how energy efficient communication will be ensured in IoT infrastructures while keeping the retrospective of cloud computing and existing (e.g. Wi-Fi, LTE, etc.) as well as future (e.g. 5G) wireless technologies in perspective?. Considering these anticipated IoT infrastructures, several state of the art IoT applications such as telemedicine, video surveillance, and smart cities necessitate the incorporation of available technologies in unusual ways to enhance the quality of service (QoS) for end users. For instance, ZigBee is currently the defacto standard technology for IoT radio devices, yet it does not provide higher bandwidth support which is essential for some of the use-cases such as smart grid’s backbone networks. Similarly, in certain smart cities applications, low power Wi-Fi modules can enable better communication for multi-hop network scenarios due to their superior coverage as compared to ZigBee or BLE (Bluetooth Low Energy)

102

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

Smart grid Video survellance and monitoring

Climate-Smart Agriculture

Industrial Automation

Smart Cities

Low data rate Moderate data rate High data rate High energy/storage devices Low energy/storage devices HD real time traffic Non-Real time traffic Real time traffic IoT devices wireless link

Internet

Ecosystem of Entertainment

Business Management Environmental sensing

Fig. 1. A concept figure of IoT applications infrastructures.

radios. Hence, in such IoT use-cases, IEEE 802.11 Standard (i.e. WiFi) based devices will be more well suited even though they are less energy efficient compared to the conventional ZigBee devices. In fact as suggested by Wireless Vision [4], Wi-Fi, together with Long Term Evolution (LTE) and 5G will ultimately comprise the future of Internet and mobile communication (their advanced versions with smaller cells and wider bands), to integrate the physical world with that of digital world and virtual environments. Therefore, this paper focuses on Wi-Fi based IoT infrastructures due to some key advantages including wider penetration of Wi-Fi technology, its compatibility with native IP-network, and reusability with the existing wireless deployments. Mostly, IoT devices are battery operated with short range radios having limited transmission capabilities. Since, a multi-hop route between source to sink devices in wireless networks allows improvement in energy utilization [5] by decreasing the transmit power of energy constrained devices (forwarding or end devices). Hence, adapting multi-hop topologies in IoT infrastructures can help in reducing the energy consumption of IoT devices and also in avoiding interference. Moreover, with the advancements in energy efficient Wi-Fi radios [6], the Wi-Fi based multi-hop IoT infrastructures will realize the concept of cooperative computing to facilitate the interaction and inter-communication of heterogenous IoT devices in various application scenarios. In fact many daily life IoT applications would require this support for multi-hop communication whereby intermediary devices cooperate with each other as well as with end devices. This allows efficient data delivery particularly in IoT applications where heterogeneous traffic is communicated among dissimilar devices. Fig. 1 provides a visual description of multi-hop IoT infrastructures illustrating several IoT applications with variable QoS specifications. The real-time IoT applications necessitate higher data rates support, while some other applications only require moderate or even low data rates. For example, video surveillance and entertainment applications with high energy resources require real time traffic exchange among IoT devices. While, a weather sensors application having low energy devices deployed in certain remote agricultural area only need to report non-real time temperature information, aperiodically. Similarly, smart cities IoT applications

can have high as well as low energy devices simultaneously with distinct data rate requirements. In addition, other IoT applications such as business management applications are delay constrained but may not require higher bandwidth support. Further, these IoT devices can also interact and support each other within and across the IoT applications in multi-hop network scenarios. For instance, smart cameras in traffic surveillance and tele-medicine applications can cooperate with each other to provide live streaming of an accidental event and facilitate the quick response from paramedical staff. In such scenarios, the dynamic traffic exchange among IoT devices in the form of context information will be required to enable their autonomous response to real life events. Thus, the frequent changes in surrounding environment of IoT applications (i.e. context variations) is another aspect that can be exploited while scheduling traffic among IoT devices. Consequently, it is inevitable to characterize these multidisciplinary IoT applications to extract their essential service quality requirements, while also considering the context variations triggered by the events happening in their volatile surroundings. In this paper, IoT applications are characterized in different quality classes depending upon their heterogenous traffic demand, which are then prioritized based on their variable context information. The primary objective is to maximize the application’s QoS by tweaking the various service quality parameters such as data rate, latency and queue lengths, while reducing the duty cycling of devices in multi-hop IoT infrastructures and scheduling the resources efficiently among these IoT devices. A convex optimization problem is formulated and a suboptimal distributed algorithm is presented for the efficient service provisioning to each of the various contextually prioritized classes. To serve this purpose, an IEEE 802.11n Standard compliant algorithm named as Energy Efficient Context Aware Traffic Scheduling (EE-CATS) algorithm is proposed. The EE-CATS algorithm extends the single-hop Power Save MultiPoll (PSMP) mechanism specified by IEEE 802.11 Standard to enable multi-hop communication in IoT infrastructures. It performs energy efficient traffic scheduling of weighted quality classes as per their assigned contextual priorities, to ensure the delay constrained data delivery while adjusting the service parameters of various traffic flows and network nodes (IoT devices). Thus, a novel context aware

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

solution is presented which is scalable, customizable and dynamically adapts to the environmental variations in multiple IoT applications. This research is published in part in our conference publication [7] wherein the proposed algorithm and an analytical model for video data streaming (multimedia traffic class) over IoT is outlined. The EE-CATS algorithm is an enhancement to the algorithm presented in [7] as it exploits the context information of IoT devices, and also distinguishes among the various traffic classes within IoT applications. Our key contributions in this paper are as follows: • IoT applications are characterized into multiple traffic classes with prioritized scheduling based on the context priorities and service requirements. • An optimization model is formulated to fulfill the dynamic service requirements of different traffic classes; and a sub-gradient projection method is specified to prove the convergence of model in a distributed fashion. • The complete design of proposed EE-CATS algorithm pseudocode is presented for multi-hop IoT networks. • The performance evaluation of EE-CATS algorithm, its comprehensive analysis and comparison with the current state-of-theart protocols. • A real testbed implementation is done in Contiki (an OS specifically designed for IoT devices) running on IoT prototyping development boards.

2. Related work The advancements in the design of low power hardware modules has incited the growth and penetration of wireless sensor networks based on IEEE 802.11 Standard. This created a way forward in adopting the Wi-Fi as an alternative radio technology for deviceto-device communication. The potential of low power Wi-Fi sensors for IoT is crucial owing to their higher data rates support and compatibility with the existing wireless infrastructures. While, the IoT devices are heterogeneous in terms of their hardware as well as software specifications and requirements [8], many existing research studies are focused only on a few of the IoT infrastructures. Consequently, research interests are gradually shifting from the traditional ad hoc networks deployments for device-to-device communication towards the more focused research dimensions such as Internet of Vehicles (IoV) [9], Internet of Nano Things [10,11] and Internet of Multimedia Things (IoMT) [12], etc. This disparity in IoT infrastructures calls for the characterization of various IoT applications in multiple traffic classes so as to identify and realize their unique service quality requirements. In addition, considering these service requirements may dynamically vary due to the variation in the context of IoT devices, existing scheduling techniques are required to be examined for their potential to provide more efficient methods of energy conservation and resource allocation to these IoT infrastructures. Moreover, ZigBee is traditionally used as the underlying technology for IoT networks but it only supports data rate up to 250 Kbps. This limited data rate is infeasible for many IoT applications and particularly for the real-time multimedia communication over IoT (notion of IoMT). In this regard, Wi-Fi standard is considered as an alternate technology both for WMSNs [2] and IoT [6]. However, the existing power saving mechanisms of IEEE 802.11 Standard such as PS Mode (PSM), Automatic Power Save Delivery (APSD) [13], PSMP [14], and other power saving schemes in literature [15],[16] are not as much energy efficient as that of the ZigBee. Furthermore, these mechanisms and schemes do not provide the capability to adapt to the dynamic traffic demand and the associated QoS requirements of heterogenous devices in the various IoT infrastructures.

103

Specifically, a power saving scheme named as OLi (Offset listeninterval) is proposed in [17] that increases the lifetime of machineto-machine (M2M) communication. The OLi algorithm reduces the network contention and packet delay by evenly spreading the traffic across beacon intervals with pre-calculated offsets thus improving the network lifetime compared to standard PSM and PSMP mechanisms. Although the algorithm is scalable to several thousands of WLAN nodes in a M2M network, the primary drawback of OLi is that the offset calculation does not incorporate the variable QoS requirements due to the change in traffic demand as per the change in context information. Another power saving mechanism proposed in [18] employs a contention based traffic announcement scheme i.e. multi-hop PSM (MH-PSM). The MH-PSM scheme enables an IoT device to communicate with other devices along multi-hop route within single beacon interval and inform them to stay awake only if it has pending traffic for them. MH-PSM is standard compliant and based on IEEE 802.11 Standard PSM algorithm but when several nodes contend for the channel by transmitting the PS-Poll frames towards AP in order to retrieve their packet, the probability of packet collision increases which results in the wastage of energy and bandwidth resources. Additionally, MH-PSM scheme lacks the adaptive duty cycling feature and nodes involved in communication are kept awake for the whole beacon interval even after receiving the traffic destined for them. The power saving mechanisms in [19] and [20] propose packet aggregation and congestion control algorithms to reduce duty cycling of network nodes by buffering the packets in transmission queues and intentionally delaying their transmission. While some other energy saving schemes such as [21] and [22] focus on scheduling the beacon intervals aperiodically to improve the energy efficiency in the networks. These algorithms [[19]-[22]] though, do not consider the unique traffic requirements of various IoT applications and their performance in multi-hop networks is not investigated. In [23], a power saving technique is proposed which enhances the IEEE 802.11 PSM standard by prioritizing the reservation. The service periods are reserved for nodes to allow them to retrieve their traffic which are then scheduled to ensure the prioritized services. The prioritization scheme shows much better energy efficiency compared to standard PSM algorithm while providing the prioritized services to various nodes. This scheme, however, is an enhancement to PSM which is itself inherently contention based in contrast to PSMP algorithm. Thus the packet collision in IoT applications with heterogenous devices cannot be fully avoided. In addition, unlike EE-CATS algorithm, the prioritization process is not adaptable to the dynamic context variations in the IoT applications. Furthermore, in several IoT use-cases multi-hop communication is required, while the existing IEEE 802.11 Standard based mechanisms (including PSM, PSMP, APSD, etc.) lack the provisioning of multi-hop communication with efficient duty cycling for the wireless infrastructures. One of the exception is MH-PSM scheme ([18]) which enables multi-hop communication features within the PSM mechanism. However, the MH-PSM scheme is only focused on reducing the end-to-end delays in IoT networks and do not consider the multiple traffic classes of IoT applications. Indeed, all the above stated algorithms and the existing power saving techniques in IEEE 802.11 Standard do not consider the multiple traffic classes in IoT applications and their distinct service quality requirements while scheduling the resources to these devices. In [24], the issue of heterogeneous traffic classes is addressed in smart grid applications to provide specific QoS. It proposes a cross layer design to optimize the routing as well as spectrum access and allocation functions in cognitive radio networks. We consider that similar notion can be extended for IoT wherein several distinct kind of applications will have dynamic service requirements while the smart grids will become one subset of these IoT applications. Additionally, efficient

104

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

duty cycling of energy constrained devices is another key aspect to be considered while addressing the resource allocation problem in IoT applications. Recently, a well investigated scheduling method is proposed in [25] which considers traffic requirements from application level viewpoint for WSNs. This method includes consensus-based approach to solve multi-period scheduling problem for network utility maximization constrained by energy metrics in terms of sensing time. Similarly, authors in [26] provide an energy efficient framework for lifetime maximization of a large WSN while considering different application deployment scenarios. Their framework comprises a scalable approach for distributed task allocation in WSNs and encompasses a gossip based algorithm to share local information among sensor nodes. The distributed approach is tested on embedded hardware supported by simulation and experimental work. Although both [25] and [26] considers application requirements while allocating resources and reported promising results along with careful modeling of sensor’s energy consumption. However, they lack the separate categorization of IoT applications based on the service quality requirements while the context awareness perspective is also entirely missing. A Context-Aware Power Management (CAPM) scheme is proposed in [27] for WSNs wherein the system is made aware of residents individual patterns to handle network devices power management operations. While, the CAPM scheme is designed for a specific healthcare architecture, namely AlarmNet, its suitability for other applications is not discussed in [27]. Our proposed solution rather focuses on environmental variations around devices themselves instead of residents’ patterns, thus making them self-reliant and self-configuring devices. Hence, the implication of our proposed solution will not be specific to IoT devices in one particular application. Similarly, another context-aware protocol named as ECAB is proposed in [28] for duty cycling of WSN devices. However, the definition of ‘context’ is somewhat different as it focuses on gathering node’s neighborhood awareness and traffic load on the neighboring nodes to perform their duty cycling and the context-awareness aspect does not cater for environmental variations over a period of time. In fact, to the best of authors’ knowledge, none of the existing energy conservation and scheduling algorithms [13,28] in literature take into account the dynamically changing environmental context information about the IoT devices. Consequently, to fill this research gap we discuss the IoT infrastructures in a new perspective by characterizing the various IoT applications into multiple traffic classes and as per their corresponding service quality requirements. Henceforth, based on WiFi technology, a context aware scheduling algorithm is employed in an energy efficient and adaptive manner which considers the environmental context information to enable virtually distributed communication and resource sharing capabilities in IoT devices. The resulting EE-CATS algorithm will take into account the traffic classes of various IoT applications while allocating resources for IoT devices along with their duty cycling and then prioritize the scheduling operations based on the context information. It will be enabling IoT devices to seamlessly interact with each other, and also access or utilize the resources of other heterogenous devices within multi-hop IoT infrastructures. 3. Problem formulation and network model 3.1. Motivation: towards application characterization In this Section, we first discuss the motivation for characterizing various IoT applications into traffic classes having distinct QoS specifications. Subsequently, the context awareness perspective is elaborated followed by the formal definition of problem. Solution to the formulated problem is given in Section 4 along with the

proposed EE-CATS algorithm. The performance evaluation is done in Section 5 while Section 4 constitutes the concluding remarks. We articulate the QoS requirements of few of the most important IoT applications, as specified in [3,12], and [29] among others; which can be distinctly mapped to separate traffic classes in terms of service quality parameters such as latency (∂ ) , data rate (γ ), and queue-length (ψ ) exhibiting storage capacity. Since, the number of IoT applications and their use-cases are unlimited but IoT devices are mostly resource constrained; therefore, it is not possible to maintain service queues for each application’s traffic class. For this reason, we define limited set of traffic priority classes along with their appropriate service quality requirements in Table 1. Each class has unique attributes such as high definition (HD), real time (Rt ) or non-real time traffic - representing the bandwidth and latency requirement; critical or non-critical data rate (Ra ) - representing delay tolerance level; storage and power resources representing limited (BL ) or alternate energy resources (BA ) such as battery, solar, thermal, wind, etc. Whereas H signifies a higher demand and X represents the absence of any requirement while the application users can be both humans or IoT devices. Thus every traffic class has distinct service quality requirements. For example, a video surveillance and monitoring application requires high data rate communication for real-time streaming in order to detect intrusion and take necessary actions. On the contrary, a smart device employed in business vicinity or a sensor employed in smart metering system both are latency tolerant. Similarly, most of the IoT devices are battery operated, thus duty cycling is another important parameter which is considered while characterizing IoT application scenarios. Besides the predefined specification of application and its corresponding class assignment, the context awareness feature is added to it by assigning contextual priority owing to its varying surroundings conditions. 3.2. Context awareness The context awareness feature articulates the pervasive vision of IoT, capturing the variations in application’s behavior as per the change in the state of environment which may be interesting to the user. The context information can be a timing context, i.e. duration of deployment and data reporting time, physical context, i.e. device connectivity, surrounding and location in which a device is deployed, user attribute context, i.e. nature of traffic, user profiling, and many others. We therefore map some of the most significant IoT applications to the respective traffic classes (identified in Table 1), while considering their QoS specification and by assigning them contextual priorities as proposed in Table 2. The parameter α cj represents the contextual priority of specific class c which takes on different values as j ∈ {1, 2, 3, . . . , n} from contextual priority set of each class (c ), i.e. α cj ∈ c = {α1 , α2 , α3 , . . . , αn }; according to any change in the context of an application over a period of time. The application-to-class mapping will vary at the runtime according to the variable environmental conditions, i.e. context information. Hence, an application is mapped to a particular class in accordance to its criticality (significance) as per contextual priority (α cj ) assigned to it in terms of numeric values. In this manner, contextual priorities are associated to the applications and incorporated while scheduling the traffic demand in various IoT network scenarios. For example, smart devices in business vicinity may have low priority initially in terms of their service requirements, but if fire erupts in a warehouse or smoke is detected by sensors then it needs to be reported immediately. Consequently, now the contextual priority of same application will be higher then any multimedia sensor device deployed for video surveillance in a non-hostile place. However, this higher priority will linearly decays after reporting the critical event and the

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

105

Table 1 Traffic classes for IoT applications with service parameters. Classes

γ



ψ

HD real-time/Highly critical rate/Limited battery banks (HRt HRa BL ) Real-time/Highly critical rate/Alternate power resources (Rt HRa BA ) Real-time/Critical rate/Alternate power resources (Rt Ra BA ) Non real-time/Highly critical rate/Alternate power resources (XHRa BA ) Non real-time/Critical rate/Limited battery banks (XRa BL ) Non real-time/Non-critical rate/Alternate power resources (XXBA )

high medium high high low low

high high medium medium medium low

limited adaptive adaptive adaptive limited adaptive

Table 2 IoT applications mapping to traffic classes and their context identities. IoT applications

Traffic classes

Contextual priority variation based on criticality level α cj ∈ c = {α1 , α2 , α3 , , , , , αn }

Video Surveillance and Monitoring

Rt HRa BA

Smart Grid Applications

Rt Ra BA

Climate-Smart Agriculture

XXBA

Transportation & Logistic

Rt HRa BA

Industrial Automation

XHRa BA

Healthcare & Telemedicine

Rt HRa BA

Smart Building Automation Systems

R t Ra BA

Business Management & Intelligence

XRa BL

Security, Intrusion Detection

Rt HRa BA

Ecosystem of Entertainment

HRt HRa BL

Personal, Social and Futurisic

HRt HRa BL

Theft, Burglary or Trespassing reporting, Accident reporting, Behaviorial Interpretation based monitoring Automatic Pricing, SCADA, Transmission monitoring, Outage signaling & management, AMI Crops yield reporting, Animal activity monitoring, Meteorological (CO2 , humidity/temperature, shocks) status Traffic monitoring, Mobile ticketing, Logistic support, Augmenting realtime maps, Assisted driving Industrial plants monitoring, Machines/Robots status response, Automatic ERP orders placement Sharing medical history (X-rays, MRI, etc.), Patients tracking, Live operation monitoring Monitoring and Alarm systems, Energy conservation, Comforting lifestyle Supply chain management, Smart banking and wallets, Retailing and realtime order management Emergency response generation, Public-safety announcements, Sensors based intelligent alarm triggers Real-time HD transmissions, Enhanced gaming experience, Smart gym machines maintaining exercise profiles Historical user profiling, Social networks integration, Device-to-device relationships, Driverless cars

3.3. Problem definition End device Forwarding device Accesss Point Bidirectional link Traffic flows of different classes

Fig. 2. Topology of multi-hop IoT network with different actors.

application will eventually settles on its usual priority over a longer period of time. Another scenario could be that the video surveillance device is suppose to generate alarm while reporting theft or burglary but at the same time, multimedia device deployed across the roadside for usual monitoring reports an accidental event which leaves some passengers in life-threatening situation requiring immediate medical assistance. In such a scenario, although both multimedia data streaming devices have similar service quality requirements, but owing to its criticality the contextual priority of accidental event will be higher then that of the event reported by the surveillance devices. Thus, traffic classes and their associated scheduling are required to be prioritized as per variations in the context information of devices in IoT network scenarios. An example of a multi-hop IoT network topology with several forwarding and end devices along with the traffic flows of different classes is provided in Fig. 2.

In order to support the variable service quality necessities of heterogenous traffic demand of IoT applications along with their varying context, we model the traffic requirements in distinct priority classes. Let C be the set of priority classes each of which is attributed by quality parameters namely latency (∂ i ), data rate (γ i ) and queuing length threshold (ψ i ) of flow i passing through any node. Here, latency is defined in terms of end-to-end packet delay over the multi-hop links on the selected route, data rate is given in bps defined by the user capacity demand, and queuing threshold is defined in terms of storage capacity at network nodes (IoT devices). Thus, each class is bounded by maximum and minimum threshold c , ∂c c c values of latency (∂min max ), data rate (γmin , γmax ) and queuing c , ψ c ). Moreover, we describe number of length threshold (ψmin max flows belonging to each class in its corresponding flow set, Fc (t). Therefore, the ith traffic flow fic (∂i , γi , ψi ) belonging to a particular traffic class c will use the respective time slots τ i . Further, the priority of a class c to be privileged in data delivery is defined in terms of its service quality priority i.e. αic as well as in terms of its contextual priority i.e. α cj . The service priority factor, αic defines the initial priority value of the flow i belonging to class c for allocating resources. While the parameter α cj represents the contextual priority of the same flow i of class c, whose service priority is αic . It may linearly vary and dynamically takes on different numeric values over a period of time, which results in corresponding change in the overall priority (represented by α c ) of class c. Hence, α c = αic + α cj is the composite priority factor as it signifies both the service and contextual priorities of each class. The utility function associated with set of flows of each class c ∈ C is thus ob c tained by Xuc ( f ) = f ∈Fc α x(f), where x(f) is the utility function of

106

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

Table 3 Definition of variables used in the model.



Symbols

Description

f ic (∂i , γi , ψi ) ∂p γ u, i ψ u, i ρu αic

Traffic flow i of class c with service parameters ∂ , γ , ψ Associated end-to-end delay with packet p Data rate of node u on flow i belonging to class c Number of packets in queue Qu of node u packet size at a source node u Service priority (in terms of ∂ , γ , ψ ) of flow i belonging to class c Contextual priority of flow i belonging to class c, variable as j ∈ {1, 2, .., n} Composite priority factor of each class: α c = αic + α cj Set of allocated slots, where τi = {t0 , t1 , t2 , t3 , . . .} Maximum flow rate between source u to destination v Binary scheduling variable indicating slot allocation

α cj αc τi rni yti ( f )

flow f and α c is the composite priority coefficient translated into application utility in terms of profit on attaining the appropriate service quality (Table 3). This utility function, x(f), is described to define the utility of a particular IoT application to meet its per flow QoS requirement. Considering an application which specifies its desired latency to earn profit, its utilization depends upon the capability that the system energy efficiency is maximized while taking into account that the desired application latency requirement is achievable by the network. For example, the communication delay of a video surveillance application is set in such a way that real-time multimedia streaming is realizable while ensuring the appropriate dutycycling for various network nodes or else, it may compromise the security of a building due to the delay in streaming. Similarly, for high speed data communication, we set the required data rate to satisfy a particular application’s QoS within the allocated time slots. Similar notion can be applied to queuing length threshold utility. Hence, utility function for service parameters is defined as Xuc (∂i , γi , ψi ). Let Xuc (∂i ), Xuc (γi ), Xuc (ψi ) express the utilities of meeting the latency, data rate and queuing threshold requirement of flow fi passing through network node u at time t, respectively. Thus cumulative utility function for various quality parameters is defined as γ

ψ

Xuc (∂i , γi , ψi ) = αi∂ Xuc (∂i ) + αi Xuc (γi ) + αi Xuc (ψi )

αic

(1)

γ ψ = αi∂ + αi + αi

where the service priority factor assigns weights to service quality parameters (∂ i , γ i , ψ i ) of each class c. We formulate an ILP problem whose objective is to maximize utility functions, Xu (∂ i , γ i , ψ i ), of all the network flows and for all τ i where τi = {t0 , t1 , t2 , . . .}, subject to the constraints in terms of latency ∂ i , supported data rate γ i , and queueing length threshold ψ i . Let N be the set of network nodes and Quc = { p1 , p2 , .., pm } be the corresponding queue of class c at node u, where m represents c . The following the queue size which is upper bounded by ψmax problem is formulated to maximize the utilities of source node u through destination node v over the multi-hop route: Maximize:



Xuc

(∂i, γi, ψi ),

∀u ∈ N

(2)

c∈C fi ∈Fc

c ∂ pl ≤ ∂max , ∀ti ∈ τi , ∀ p ∈ Quc

ρu ψu,i ≤ ∂ p1 , ∀ti ∈ τi , ∀ p ∈ Quc γu,i n  k=1

(6)

γvk ,i ≤ rni , ∀ fi ∈ Fc

4. Energy efficient context aware traffic scheduling algorithm 4.1. Lagrangian multiplier based distributed approach In the above optimization problem, the utility function for node u depends on data rate, latency, queue-length threshold (storage) and energy consumption while transmitting the data from source u to destination v nodes. Solution to this problem requires coordination among all the nodes along the multi-hop flow fi between source-destination pair (u, v) which is practically not feasible in dynamic IoT environments. However, we can decouple the constraints by introducing slack variables, and the resultant constraints set will still remain convex since the primal problem (2) has convex constraint set. Hence, assuming that the utility function Xu (∂ i , γ i , ψ i ) is an increasing continuously differentiable concave function, we write down associated Lagrangian to decouple the constraints and to solve the primal problem with dual decomposition approach. By relaxing the constraints, the Lagrangian is given as follows, where λu , μu and ηu are the Lagrangian multipliers at node u to node v and can be interpreted as the implicit utility of data rate, latency and queue length, respectively. Thus, each node ‘u’ at flow fi independently solves its own utility maximization problem:

L(∂ , γ , ψ ; λ, μ, η ) =

 c∈C fi ∈Fc



Xuc (∂i, γi, ψi ) +



 c λu ∂max −

i

μu (∂ p1 γu,i − ρu ψu,i ) +

i

(3)

l=1

γu,i +

∀ti ∈ τi , ∀ fi ∈ Fc ,

The Constraint (3) in above formulation ensures end-to-end delay constraint along the multi-hop route for a set of allocated slots τ i . In particular, the associated end-to-end delay ∂ pl with a packet pl buffered at the queue Quc , across the multi-hop flow between source node u to destination node v, should not exceed its maxic mum latency limit for a specific class c, i.e. ∂max . In addition, the delay induced by buffering a packet in queue is in turn dependent upon the queuing length threshold and data rate; thus Constraint (4) mandates that the number of packets, ψ u, i , in Quc of node u are constrained by the delay bound (∂ p1 ) of the oldest packet in this queue. Here, ρ u defines the packet size of a particular node u. In addition, the data rate should ensures that all the packets in queue are transmitted within this delay bound. Thus, data rate γ u, i of node u should be enough to meet the capacity demand of passing flows at one node, hence Constraint (5) ensures that the data rate of node u and other intermediary nodes vk should not exceed the maximum flow rate (rni ) of multi-hop route. While, Constraint (6) defines a scheduling variable yti ( f ) and set it to ‘1’ only if there is slot allocation to a flow fi of class c in time period t, and ‘0’ otherwise, ensuring that a given time slot is atmost allocated to a single node.

+

Subject to: m 

yti ( f ) ≤ 1,

f ∈Fc

(4)

(5)

 i



m 

 ∂ pl

l=1

ηu rni − γu,i −

n 

 γv,k

(7)

k=1

In above expression, the Lagrangian can be reduced into many sub-problems that can be evaluated separately in its variables λu , μu and ηu which will correspondingly allow us to reach at the optimal values of ∂ , γ and ψ , respectively. While each problem will be solved locally using the local variables. Now that the Lagrangian is separable, each node can optimize its dual problem:

D(∂i , γi , ψi ; λu , μu , ηu ) = − max− L(∂i , γi , ψi ; λu , μu , ηu ) → → → ∂i ,− γi , ψ i

(8)

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

and the dual function of primal optimization problem (2) is then given by

min

λu ≥0,μu ≥0,ηu ≥0



c C

− +

(Xuc (∂i, γi, ψi ) −

γu,i − 



n 

+ γv,k )

(11)

k=1

i



date rate values at each node.

ηu (t + 1 ) = ηu (t ) − κt (rni − γu,i −

D(∂i , γi , ψi ; λu , μu , ηu )

To solve this dual problem, we consider the separable form of Lagrangian given in problem (7) and conduct its maximization in parallel at each source node u:

max

107

n 



∂ pl (λu ) − ρu ψu,i (μu )

l=1

γv,k (ηu )) +

k=1

μu (∂ p1 γu,i ) +

i

m 





c λu (∂max )



i

ηu ( r n i )

In Step 3, each node u update its lagrangian multiplier μu at each iteration as in Eq. (12) where υt is the non-negative stepsize and μu can be viewed as a scalar multiple of queue length of packets stored at node u and destined to node v. For γ u, i , the updated value estimated in Step 2 is used. Thus, ψ i can be viewed as the solution of the problem in (7) for a given set (λ, η, μ) and Eq. (12) thus corresponds to the evolution of queue length at each node.

(9)

μu (t + 1 ) = μu (t ) − υt (∂ p1 γu,i −

c c c subject to λu ≥ 0, μu ≥ 0, ηu ≥ 0; ∂min ≤ ∂i ≤ ∂max ,γmin ≤ γi ≤ c ,ψ c c γmax ≤ ψ ≤ ψ i max min Solving the first order condition of derivatives of Lagrangian expression will give three equations with three unknowns which can help to arrive at unique solution to the problem. Since the constraint set of primal problem (2) are feasible then the Slater condition [30] for strong duality will hold. Moreover, as the constraint variables are positive then from ([30] Section 5.2.3), the primal variable (γ , ∂ , ψ ) are proved to be the global optimal solution of primal problem as identified by the distributed approach. Additionally, the Slater’s condition is satisfied for primal problem, then the Karush-Kuhn-Tucker (KKT) conditions [31] is both necessary and sufficient for optimality; i.e. γ ∗ , ∂ ∗ , ψ ∗ are optimal if there exist λ∗ , μ∗ , η∗ that satisfy the KKT conditions.

4.2. Subgradient projection method for convergence The primal problem in (2) circumscribes a wide range of IoT applications with variable service requirements which necessitate distinct design methodologies to reach at their fitting utility functions. As a result, the strict concavity of the objective function is not verifiable and the dual function, D(∂ i , γ i , ψ i ; λu , μu , ηu ), may not be continuously differentiable. It means that the derivatives of dual function which are required to satisfy KKT conditions may not be computable. Therefore, a distributed approach is presented which can be solved at each node u, i.e. solving its subproblem locally, and then notifying its information (which can be communicated by sending ACK packets at MAC layer) to the neighboring destination node v. To achieve this, a subgradient projection method ([32],[33] and [34]) is used, to distributively solve the dual problem in (7). In the first step (Step 1), each node u updates its values of Lagrangian multiplier λu at each iteration t by using locally available information: c λu (t + 1 ) = λu (t ) − ht (∂max −

+

ρu ψu,i )

(12)

i=1

i



m 

m 

+ ∂ pl )

(10)

l=1

where ∂ i is the solution of problem in (7) for a set (λ, η, μ), ht is a non-negative stepsize and the Lagrange multiplier λu can be viewed as a scalar multiple of the data rate for flow fi between node u to node v. Eq. (10) thus corresponds to the evolution of the delay values at each node u which then communicates this utility value to other nodes vk along the multi-hop route. Next, in Step 2, each node u updates its lagrangian multiplier ηu at each iteration as in Eq. (11) where κ t is the non-negative stepsize and ηu can be viewed as a scalar multiple of the data rate for any flow fi . Thus, γ i is the solution of the problem in (7) for a given set (λ, η, μ) and Eq. (11) corresponds to the evolution of the

In Step 4, problem (7) is distributively solved for each node u. In this way, at each iteration t, the dual decomposition of problem is carried out into many sub-problems at node u to locally determine the required data rate, latency and queue lengths for transmitting the data packets, in order to reach at the optimal values (λ∗ , η∗ , μ∗ ) of dual variables. The convergence of this method to optimal solution (∂ ∗ , γ ∗ , ψ ∗ ) can be verified by standard distributed subgradient algorithms [30,31]. From the proposition 1 of [32], we deduce our proposition. Proposition 1: • When step-sizes ht , κ t and υt are small then the iterations (10), (11) and (12) converges to the small neighborhood of optimal values of λ∗ , η∗ and μ∗ respectively. When step-sizes are chosen in time-varying manner such that ht = β h0 , κt = δκ0 , and   υt = θ υ0 then as β → 0, ht = ∞ as δ → 0, κt = ∞ , and i i  as θ → 0, i υt = ∞ then the dual variables will converge to the optimal solution of the dual problem. • There is no duality gap and minimal values of dual function coincides with optimal value of primal problem. Hence, there exist continuous mapping from λ to ∂ , η to γ and μ to ψ , respectively. We can conclude that the data rate γ , latency value ∂ , and the queue length ψ will converge to the optimal values of γ ∗ , ∂ ∗ and ψ ∗ . 4.3. EE-CATS algorithm operations Once the nodes solve the problem locally and reach the optimal values of data rate, latency and queue length; next step is to allocate the available bandwidth resources to various flows of different classes along with efficient duty cycling of IoT devices. To serve that purpose, we employ EE-CATS algorithm which is an extension of QoS aware Multi-Hop Power Save Multi-Poll (mPSMP) protocol proposed in our earlier work [7]. The mPSMP algorithm enables multi-hop communication in IEEE 802.11n Standard PSMP protocol [14] and optimize it for multimedia traffic streaming over IoT. However, mPSMP protocol is equally extensible for other traffic classes as well. To do this, we modify it first by relaxing the assumption of uniform traffic demand from each node and then by prioritizing the resource allocation (i.e. transmission opportunity (TXOP)) according to the service quality parameters of traffic classes and the node’s context information. This extended version is named as EE-CATS algorithm which is IEEE 802.11n Standard compliant and well suited for the efficient resource allocation while assuring the required service quality requirements. Hence, the mPSMP protocol (proposed in [7]), which only considers multimedia traffic class, has now become a specialized subset of the EE-CATS algorithm, while in this case other traffic classes of IoT use-cases are also incorporated.

108

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

The EE-CATS algorithm allocates transmission opportunity to nodes in a scalable Time Division Multiple Access (TDMA) fashion wherein each node is only responsible for its next hop neighbors (child nodes) to provide more efficient QoS. Hence the associated communication, computation and signaling overheads of fully centralized access mechanism are avoided which is crucial for the contextually variable IoT application scenarios. The algorithm aggregates the particular flows into prioritized classes and then QoS is guaranteed for these flows by dedicating the resources for exchanging packets among the nodes thus making it scalable, and at the same time the service requirements of various classes are being met within the delay bounds. It is noteworthy that the operational behavior of these nodes may vary over a period of time due to the variation in their environment contexts. This adaptability becomes the necessary feature for multi-hop IoT infrastructures in order to share the node’s local parameters such as its service requirements and energy resources with other network nodes to employ efficient duty cycling in the overall network. The EE-CATS algorithm provides such flexibility and dynamically change the resource allocation to the nodes in these multi-hop networks as per their context information. The Algorithm (1) outlines the pseudocode of EE-CATs algorithm. Firstly, AP (or a node initiating Independent Basic Service Set (IBSS)) advertises its service set identifier (SSID) using beacon frame to connect with nodes who want to join the network. It synchronizes with them using Timestamp (TS) subtype in beacon frame and assigns their Association IDs (AIDs). Then, the amount of TXOP to be assigned to a node (STA) is defined, governed by priority factor (αic ) which tells the TXOP amount to be allocated within a PSMP Sequence. The nodes with higher contextual priority (α cj ) will be given preference. Thus, each child of a parent node may have distinct contextual priority which is variable at run-time. EE-CATS algorithm sort the contextual priorities in an array of ascending order by employing bubble sort function. It then assigns first PSMP Sequence to one-hop away nodes from AP (or parent node) and also generate number of PSMP Sequences for multi-hop away nodes as per the number of all STAs (denoted by s ) having child at their next hop. A parent node schedules the TXOP to all of its associated child nodes within single PSMP Sequence. In this way, PSMP Sequences are generated and within the PSMP Frame, AP (or parent node) indicates the traffic buffered for next hop nodes in traffic indication Map (TIM) field. The PSMP Frame includes STA Info field which notifies each node their PSMP uplink (PSMP-UTT) and downlink (PSMP-DTT) transmission time offsets. This indicates a node when it should start traffic exchange with parent node and upon completion, it goes into sleep state during transmission time of other nodes. Hence, a node receiving PSMP Frame stays awake only for its indicated PSMP-UTT and PSMP-DTT time, and for rest of the PSMP Sequence it stays in sleep state. A node can also go into sleep state for its own TXOP time if its transmission queue is empty. The details of EE-CATS algorithm are enumerated in Algorithm (1) indicating various steps of resource allocation (TXOP) to the network nodes as per the service requirements and contextual priorities. Further details on PSMP protocol are avoided for brevity; and for a comprehensive understanding readers are referred to mPSMP protocol in [7] and IEEE 802.11n Standard PSMP protocol operations [14]. 5. Performance evaluation In this section, we present the performance evaluation results by carrying out simulations in ns-2 simulator and testbed implementation in Contiki OS. To simplify the evaluation of our proposed algorithm for various IoT infrastructures, we consider few daily life use-cases of IoT applications, in a smart city environment, with distinct traffic class requirements. For example, use-case I:

Algorithm 1 EE-CATS algorithm. 1: 2: 3: 4: 5: 6:

Input: No. of slots (τ1 , τ2 . . .n ) and STAs (u0 , u1 . . . un−1 ) Output: TXOP allocation sets (S1 , S2 . . . Sc ) ∀ u[i] ∈ C function SendBeacon(SSID, T S, AID)  SSID-Service set ID, TS-Timestamp, AID-Assoc. ID Let X[u0 , u1 ,…. un−1 ] be the set of n STAs for i = 0 to n − 1 do u[i] ↔ AID[i+1]  assign AIDs to STAs α n i

c

Given

7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37:

c i=1 αi

(T XOP ),

 %age TXOP of u[i]

Assign array[n] ↔ context _ priority(u[i] ) end for end function function SendPSMPFrame(T IM, T XOP )  Sender STA Process Broadcast TIM(STAS AID)  Advertise STAs in TIM function bubblesort(array[n]) for i = 0 to n − 1 do for j = 1 to n do if (array[i] > array[ j]) then swap array[i] and array[ j] end if end for end for end function for P SMP _Seq[0] do Allocate TXOP in P SMP _Seq[0] to u[i] at 1-hop end for Generate s PSMP Sequences  s is No. of all STAs with child STAs for i = 1 to s do Allocate TXOP in P SMP _Seq[i] to u[i] at s-hop i = i + 1; end for  reiterate ∀u[i] at next-hop to assign TXOP end function function RecvPSMPFrame(T IM, T XOP )  Receiver STA Process if (ST Ai in T IM) then SleepTime: (PSMP_Seq_Dur - (PSMPFrame_Dur + SIFS + T XOPi ) else SleepTime: (PSMP_Seq_Dur - (PSMPFrame_Dur + SIFS)) end if end function

Table 4 Traffic classes along with service quality parameters values. Classes

c γmin

c γmax

c ∂min

c ∂max

c ψmin

c ψmax

XRa BL Rt HRa BA HRt HRa BL

6.5 Mbps 11 Mbps 26 Mbps

11 Mbps 26 Mbps 54 Mbps

0.5 s 150 ms 50 ms

1s 400 ms 200 ms

50 pkts 20 pkts 20 pkts

100 pkts 50 pkts 50 pkts

‘Smart Shopping Mart and Retailing’ specifies the traffic class ‘non real-time, certain data rate and limited resources’ (XRa BL ). Usecase II: ‘Healthcare and Telemedicine Facility’ specifies the traffic class ‘real-time, critical data rate (indicating delay-sensitive applications) and alternative battery resources’ (Rt HRa BA ). For a better insight, Use-case II is segmented into two parts since the typical patient medical records reporting or retrieval events (Rt HRa BA 1) would require less resources as compared to the events where live monitoring of operations (Rt HRa BA -2) are underway. Use-case III: ‘Intelligent Multimedia Streaming System’ specifies the traffic class ‘High Definition (HD) real-time, highly critical data rate and limited battery resources’ (HRt HRa BL ). The service quality specifications of these use-cases are specified in Table 4. Although the simulations and testbed implementation presented here are specific to

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

these distinct IoT use-case scenarios. Nevertheless, the results are equally viable for any kind of Wi-Fi based IoT infrastructures, since the traffic classes would remain the same. Moreover, the proposed algorithm is scalable as well as reproducible, since it extends the power saving mechanism of existing Wi-Fi standard widely used in WLANs with low overhead cost, and as it is implemented as a part of open source stack of Contiki OS extensively used in IoT community. These use-cases are implemented by simulating various scenarios in ns-2, wherein the context information of participating devices (network nodes) are dynamically varying with time. The proposed EE-CATS algorithm is thus employed to appropriately prioritize and schedule the resources (TXOP) to network nodes along with their efficient duty cycling. The following values are considered for the simulation model; Tx Power = 660 mW, Rx Power = 395 mW, Idle Power = 35 mW, Sleep Power = 1 mW, Initial Energy = 10 0 0 J. The simulation results are taken for an infrastructure network of 40 nodes, including several nodes reporting scaler data as well as other nodes carrying multimedia data towards AP over multi-hop route. The different traffic classes represent various IoT use-cases and each use-case has an associated service quality requirements. The results are averaged for multiple flows of several distinct topologies and each simulation runs for a 200 secs duration. Since these simulations incorporate distinct IoT network scenarios with continuously variable environmental contexts, the inherent simplicity of proposed algorithm and its distributed nature ensures that the similar results are replicable for other IoT infrastructures such as large scale IoT networks without compromising the performance. In the following sub sections, the performance evaluation of EE-CATS algorithm is presented in terms of aggregate energy consumption, effect of traffic density variation on node’s duty cycling, energy efficiency, and end-to-end delays. Firstly, the comparison is done with the IEEE 802.11n Standard PSMP [14] since the proposed EE-CATS algorithm is an enhancement to the PSMP algorithm which is a promising power saving mechanism for IoT devices. It is pertinent to note that the PSMP algorithm implementation is not available in ns-2, therefore we have implemented it ourself. Secondly, since the EE-CATS algorithm enables multihop communication in PSMP algorithm, hence in the subsequent sub-section we compare our algorithm with another power saving scheme namely MH-PSM [18] which enables multi-hop communication in IEEE802.11 Standard PSM algorithm. Thirdly, we evaluate EE-CATS algorithm performance by comparing the simulation results taken in ns-2 with the analytical results calculated from the mathematical energy model proposed for the performance analysis of mPSMP algorithm in our earlier work [7].

5.1. Comparison with IEEE 802.11n standard PSMP Initially, we investigate the aggregate energy consumption of overall network for various traffic classes. The comparison of EECATS algorithm with the state-of-the-art IEEE 802.11n Standard PSMP algorithm is shown in Fig. 3. In order to meet the service requirements of different traffic classes, the energy consumption is accordingly variable and with a change in the traffic demand, algorithms have to adjust the time spent in awake state to achieve the desired QoS. However, EE-CATS outperforms the PSMP algorithm in terms of aggregate energy consumption (15% less energy consumption) in various traffic classes. The reason is that, the EE-CATS algorithm is dynamically changing the slots allocation to any node as per its traffic demand and prioritize it as per the latency requirements, so avoiding any unoccupied slots and unnecessary delay unlike the PSMP algorithm. Further, EE-CATS algorithm incorporates adaptive duty cycling to ensure that a node goes into sleep

109

state as soon as its transmission queue gets empty which helps in more energy conservation. The adaptive duty cycling phenomenon is more significant when the traffic density is varied to examine its affect on the energy consumption in various use-cases. Fig. 4 shows how the adaptive duty cycling helps in limiting the idle listening period by allowing the non traffic generating nodes (which are allocated TXOPs but currently in-active) to go into sleep state. This novelty introduced in EE-CATS algorithm is lacking in PSMP algorithm and is particularly vital in reducing the nodes’ duty cycling when the contextual priorities are variable at run-time. Moreover, PSMP algorithm does not specify the power saving mechanism for multi-hop communication. Thus the intermediary nodes, which act as parent nodes (for their next-hop child nodes to allocate them TXOPs), have to stay awake for their own PSMP Sequence and for the subsequent PSMP Sequences of their childs to retrieve and send their traffic towards Access Point. Hence, irrespective of use-cases, these intermediary nodes draw considerable amount of energy. This effect of traffic density is evident in Fig. 4, the energy consumption with PSMP algorithm is around 281 J even with minimum traffic density i.e. only 7 active nodes, and it goes up to 394 J when all the 40 network nodes are generating their traffic. On the contrary, when EE-CATS algorithm is employed, the energy consumption is considerably less and even in fully functioning network (40 active nodes), it remains less than 226 J in all the four use-case scenarios. Hence, EE-CATS algorithm is much more adaptable to the traffic density variations as compared to the PSMP algorithm. Fig. 5 demonstrates the advantage of EE-CATS algorithm over the PSMP algorithm in terms of achievable energy efficiency for various use-cases. It shows that the EE-CATS algorithm significantly improves the energy efficiency of the network while the changes in traffic classes, including data packet sizes and/or packet interval variations, do not drastically affect the energy efficiency of network nodes with EE-CATS algorithm unlike PSMP algorithm. In use-case I, the energy efficiency is almost 90% with EE-CATS algorithm, while with PSMP algorithm the efficiency is reduced to 75%. Similarly, for multimedia traffic class (use-case III), the energy efficiency computed with EE-CATS algorithm is higher than 76%. With PSMP algorithm, the energy consumption for the same multimedia use-case considerably increases which eventually reduces the energy efficiency of overall network to 60%. Thus, EE-CATS algorithm is 15% more energy efficient compared to standard PSMP algorithm. The reduction in energy efficiency with standard PSMP algorithm are attributed to its lack of adaptability to the run-time variations in assigning the traffic opportunities. While considering the different traffic classes and their service quality requirements, we have observed a generic trade-off in evaluating the energy consumption of network nodes. For instance, the use-cases where nodes are more data intensive (e.g., nodes generating multimedia traffic) require higher data rates in order to cater for the latency requirements and to stay within the delay bound limits. The higher data rates allow less energy expenditure in transmission but however, the processing power is increased. On the other hand, the use-cases where nodes are less data intensive (reporting scaler data) expend less computational energy. However, the low data rates requirements for these nodes results in increasing their transmission time, consequently they spend less time in sleep state. In addition, there are instances when a node reporting scaler data and having lower priority is required to be assigned higher contextual priority owing to the sensitivity of information (e.g., reporting an accidental event). In such instances, the latency of other nodes generating multimedia traffic is affected and data rates have to be flexibly adjusted to meet the application delay bound thresholds. Due to this tradeoff between transmission energy and computational energy, when all the 40 networks nodes are active, the aggregate energy consumption for multimedia

110

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

Fig. 3. Aggregate energy consumption in various traffic classes: Comparison of EE-CATS algorithm with Standard PSMP.

Fig. 4. Aggregate energy consumption with variation in traffic density: Comparison of EE-CATS algorithm with PSMP.

Fig. 5. Energy efficiency comparison of EE-CATS algorithm with PSMP.

use-case (HRt HRa BL ) in Fig. 4 is only slightly higher than another use-case (XRa BL ) of shopping mart where more or less only scaler data is to be communicated to the destination node (AP). Fig. 6a shows a particular simulation scenario of use-case I with an AP and 6 network nodes, along with their time slots allocation in Fig. 6b. Therein, the impact of EE-CATS algorithm in a situation with variable context information is examined. A surveillance camera (STA-1) deployed at the entry door of shopping mart detects a customer’s entry into the premises. The customer turns on her mobile (STA-4) which gets connected to the local cloud (STA-2) and checks the availability of items on customer’s wish list. The transmission opportunity priority of all these stations is the same while the camera nodes have higher contextual priority. Another node (STA-6), a smoke sensor installed in the mart is assigned less transmission opportunity resources (only scaler data is expected). Now, if fire extinguishes in a certain part of the mart, smoke sensor has

to report this critical event. Thus, EE-CATS algorithm dynamically elevates the contextual priority of the smoke sensor and the event is instantly reported to the local server (which generates fire alarm to evacuate the place) and then towards the AP (which informs fire extinguishers) while deferring the scheduling of other events such as cameras streaming the multimedia content. As a result, in next iteration forwarding node (STA-2) of smoke sensor (STA-6) will be prioritized on camera node (STA-1) to immediately report the event at AP. This may cause a momentary delay in cameras’ streaming, but triggering fire alarm is more critical in this particular context. Later on, the contextual priority of smoke sensor linearly decays after reporting the event. Moreover, the algorithm ensures that the associated delay in multimedia streaming is still less than 400 ms to avoid a considerable lag or disruption. This scenario explains the allocation of slots, shown in Fig. 6b, is prioritized on the basis of the pre-defined service priority and as per

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

111

Fig. 6. (a) Use case-I application scenario with 7 active nodes. (b) A time-line of slot-allocation to network nodes.

Fig. 7. EE-CATS algorithm performance: Traffic classes and their respective end-to-end delays over each hop.

dynamically changing context priority, while this dynamic adaptability of EE-CATS algorithm is missing in standard PSMP or other scheduling algorithms. Further, we consider the entire network of 40 nodes to calculate the end-to-end delay results experienced by the network nodes across the multi-hop routes. Fig. 7 shows that as the number of hops increases between source to destination nodes, the latency is also increased. However, the EE-CATS algorithm ensures that the latency stays minimal and the service quality requirements of each traffic class is met thanks to the algorithm’s adaptability as per the variable context information. The end-to-end delay calculations are especially crucial for multimedia devices to keep the latency for data frames within the delay limitations of multimedia traffic to guarantee better application’s QoS. For smooth video streaming, the end-to-end delays for all use-cases are kept within the 150– 400 ms delay bound limit as specified in standard recommendations by ITU-T G.114 [35]. Particularly, for multimedia-streaming use-case, the context priorities are set such that the end-to-end delays stay less than 250 ms for all the multi-hop flows between video-streaming nodes and AP. However, there are few occasions when the end-to-end delays achieved by EE-CATS algorithm exceed the latency results achieved by that of PSMP mechanism. This happens when a given intermediary node across the multi-hop route goes to sleep state before transmitting the queued packets destined for its next hop node within one PSMP sequence. In such cases the remaining packets have to stay in the packet queue of intermediary node until next iteration (i.e. until the re-allocation of next PSMP Sequence). With standard PSMP mechanism this extra delay may be avoided since the intermediary node does not incorporate duty cycling and stays awake for all the remaining PSMP Sequences of its child nodes as well.

5.2. Comparison with MH-PSM For end-to-end delays over multi-hop route, we compare the performance of EE-CATS algorithm with MH-PSM scheme proposed in [18]. Since, the various IoT use-cases are not considered in [18], we restrict our comparison to a particular simulation scenario with packets interarrival time and Beacon Interval (BI) both are kept at 200 ms. Fig. 8 shows that the performance of both algorithms is almost similar but EE-CATS performs better at first 2 hops as it schedules traffic in the series of PSMP Sequences each having 8.184 ms duration which is much shorter than the BI. As the number of hops increases, end-to-end delay induced by MH-PSM becomes closer to that of EE-CATS algorithm and beyond 5 hops, lesser delay with MH-PSM scheme is observed. This happens since the next-hop neighbors of a node are awake and their packets are transmitted immediately without waiting for next BI. Moreover, in order to check the performance of adaptive duty cycling feature of EE-CATS algorithm in a real testbed environment, we have implemented it within Contiki OS running on Arduino boards with Atmel micro-controllers (MCUs). Contiki OS is one of the most popular OS for resource constrained IoT devices. Our testbed platform consists of Atmel SAM3X8E ARM Cortex-M3 CPU based micro-controller running Contiki OS, and a USB Wi-Fi dongle for communication among network nodes as shown in Fig. 9. While the hardware configuration for the Atmel Cortex-M3 MCU is 96 KB SRAM, 512 KB Flash which signifies that our algorithm is smoothly employable for the constrained IoT devices requiring low memory footprints. The comparison is done in terms of average sleep period and its corresponding effect on the energy utilization. For this purpose, we have used an open source implementation of MH-PSM ([18]) which is used as an underlying power saving mech-

112

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

Fig. 8. EE-CATS Algorithm comparison with MH-PSM: End-to-end delays over each hop.

Table 5 Comparison of EE-CATS duty cycling feature with MH-PSM scheme.

Fig. 9. Hardware Platform for the testbed implementation.

anism within WLAN driver of Contiki OS for radio duty-cycling. The details of MH-PSM implementation within Contiki OS can be found in [18] and [36]. The MH-PSM algorithm included within the WLAN driver of Contiki OS is replaced with the EE-CATS algorithm. This allows any node to dynamically go into sleep state as soon as its packet transmission (and/or reception) queue gets empty within a BI. Thanks to this adaptive duty cycling, Fig. 10a shows that the average time spent in sleep state with EE-CATS algorithm is much more in comparison to the MH-PSM algorithm. Specifically, when the Beacon Interval is kept at 200 ms, average sleep duration of a node with MH-PSM is 112 ms while with EE-CATS algorithm the average sleep duration is 147 ms. Consequently, less energy is consumed when

Attributes

EE-CCATS

MH-PSM

Comments

Total time Time spent in sleep state Radio On time (duty-cycling) Energy spent in awake state Per second energy consumption

316.8 s 192.6 s 39.2% 620 0 0 mJ 196.2 mJ

316.8 s 150.8 s 52.5% 830 0 0 mJ 262.6 mJ

System active time More is good Less is good Less is good Less is good

any node is in awake state. As shown in Fig. 10b, the average energy consumed by a power saving node in awake state is 27.2 mJ with EE-CATS algorithm and 43.2 mJ with MH-PSM algorithm. This reduction in energy consumption is due to the fact that the adaptive duty cycling allows a node to go into sleep state immediately after receiving its pending traffic instead of waiting for the end of remaining beacon interval. The results of testbed implementation are specified in Table 5. 5.3. Comparison of simulations with analytical results Further, we also compare the simulations results of our algorithm with the analytical results computed from the mathematical model proposed in [7]. Here we will check the validity of simulations considering the fact that this mathematical model is specifically designed for the evaluation of mPSMP algorithm which has now become a specialized subset of EE-CATS algorithm. The total

Fig. 10. Contiki OS results. (a) Average time spent in sleep state (b) Average energy consumed in awake state.

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

113

Fig. 11. EE-CATS algorithm performance: simulation vs. analytical results.

Fig. 12. EE-CATS algorithm performance: Throughput provisioning according to network size variation.

energy spent in awake state, Eawake , is computed from the equation (13) of mathematical model for the overall network.

Eawake = Ptx × Taw,i



= Ptx ×



and EE-CATS algorithm guarantees that the throughput demand of that node is being served while also considering its other service requirements.

 i, j (2 × ×Tt,i + 3 × Tsi f s + Tp f + Twait ) (13)

i=1, j=1

While the same energy consumption is also computed by the simulations results when the network nodes are in the awake state and comparison is presented in Fig. 11. Specifically, EE-CATS algorithm performs significantly well for delay sensitive applications (use-case IV: HRt HRa BL ) wherein, the average total energy consumption computed through simulations is 244 J in overall network of 40 nodes. While with the mathematical model the total energy consumption is 221 J. On average, a difference of 20-30 J of energy consumption is observed between simulation and analytical results owing to the reason that some higher priority parent nodes are still kept alive for longer duration by simulated algorithm to serve the traffic demand of their child nodes. On the contrary, in case of mathematical model these parent nodes are scheduled to sleep immediately after sending their own traffic and their child nodes traffic is only transferred in next schedule cycle. However, this extra energy consumption in simulations plays its role in fulfilling the latency limitations of child nodes in delay sensitive applications. So, the comparison particularly validates the proposed algorithm’s applicability for the multimedia application scenarios and analytically verifies the simulation results from the mathematical model as well. Lastly, Fig. 12 shows the overall throughput provisioning for different use-cases as per the network size variations. The EE-CATS algorithm ensures the energy-efficient throughput provisioning for various IoT applications while keeping the context priorities of each node in perspective. Thus, a TXOP for a particular node is allocated dynamically, according to its variable contextual priority,

6. Conclusion The myriad of IoT use-cases entails the need for the traffic characterization of IoT applications as per their dynamically varying environmental contexts. In this regard, an energy efficient context aware traffic scheduling (EE-CATS) algorithm is proposed for Wi-Fi supported devices in multi-hop IoT infrastructures. The proposed algorithm considers the service quality requirements and context priorities of various IoT applications to map them to distinct traffic classes and provides energy-efficient resource allocation for IoT devices. The algorithm is compared with the state of the art IEEE 802.11 PSMP protocol and with a multi-hop power saving scheme (MH-PSM). Simulations are carried out in ns-2 and testbed implementation is done on IoT prototyping development boards running Contiki OS. The results show notable improvements in the energy efficiency, reduction in the end-to-end delays and duty cycling of network nodes. Thus, prioritizing the resource allocation to devices in IoT applications based on their contexts and traffic requirements significantly enhance the service quality of end users and consequently, elevate the overall performance of IoT networks.

Acknowledgment This work is carried out at IoT Lab, Al-Khwarizmi Institute of Computer Science, University of Engineering and Technology, Lahore, Pakistan. It is funded by National ICT R&D Fund, Government of Pakistan under Grant no. ICTRDF/TR&D/2013/04. We gratefully acknowledge this support.

114

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

References [1] I.F. Akyildiz, T. Melodia, K.R. Chowdhury, A survey on wireless multimedia sensor networks, Comput. Netw. 51 (4) (2007) 921–960. [2] M.A. Hoque, M. Siekkinen, J.K. Nurminen, Energy efficient multimedia streaming to mobile devicesa survey, IEEE Commun. Surv. Tutor. 16 (1) (2014) 579–597. [3] L. Atzori, The internet of things: a survey, Comput. Netw. 54 (15) (2010) 2787–2805. [4] K. David, N. Jefferies, Wireless visions: a look to the future by the fellows of the wwrf, Veh. Technol. Mag. IEEE 7 (4) (2012) 26–36. [5] Y.-C. Tseng, C.-S. Hsu, T.-Y. Hsieh, Power-saving protocols for IEEE 802.11-based multi-hop ad hoc networks, Comput. Netw. 43 (2003) 317–337. [6] S. Tozlu, Wi-fi enabled sensors for internet of things: a practical approach, Commun. Mag. IEEE 50 (6) (2012) 134–143. [7] B. Afzal, S.A. Alvi, G.A. Shah, Adaptive duty cycling based multi-hop PSMP for internet of multimedia things, in: 2016 13th IEEE Annual Consumer Communications & Networking Conference (CCNC), IEEE, 2016. [8] D. Singh, G. Tripathi, A.J. Jara, A survey of internet-of-things: future vision, architecture, challenges and services, in: IEEE World Forum on Internet of Things (WF-IoT), 2014, IEEE, 2014, pp. 287–292. [9] M. Gerla, Internet of vehicles: from intelligent grid to autonomous cars and vehicular clouds, in: IEEE World Forum on Internet of Things (WF-IoT), 2014, IEEE, 2014, pp. 241–246. [10] I.F. Akyildiz, J.M. Jornet, The internet of nano-things, Wirel. Commun. IEEE 17 (6) (2010) 58–63. [11] J.M. Jornet, I.F. Akyildiz, The internet of multimedia nano-things, Nano Commun. Netw. 3 (4) (2012) 242–251. [12] S.A. Alvi, Internet of multimedia things: vision and challenges, Ad Hoc Netw. 33 (2015) 87–111. [13] , Ieee standard for information technology - telecommunications and information exchange between systems - local and metropolitan area networks - specific requirements - part 11: wireless lan medium access control (mac) and physical layer (phy) specifications, IEEE Std 802.11–2007 (Revision of IEEE Std 802.11–1999), 2007, doi:10.1109/IEEESTD.2007.373646. [14] IEEE 802.11N-2009 standard for information technology, local and metropolitan area networks, specific requirements, part 11: wireless LAN medium access control (MAC)and physical layer (PHY) specifications amendment 5, IEEE 0 0 0 0. [15] S.-L. Tsao, C.-H. Huang, A survey of energy efficient MAC protocols for IEEE 802.11 WLAN, Comput. Commun. 34 (1) (2011) 54–67. [16] Ł Budzisz, Dynamic resource provisioning for energy efficiency in wireless access networks: a survey and an outlook, IEEE Commun. Surv. Tutor. 16 (4) (2014) 2259–2285. [17] R.P. Liu, G.J. Sutton, I.B. Collings, Wlan power save with offset listen interval for machine-to-machine communications, IEEE Trans. Wirel. Commun. 13 (5) (2014) 2552–2562.

[18] V. Vukadinovic, Enhanced power saving mode for low-latency communication in multi-hop 802.11 networks, Ad Hoc Netw. 23 (2014) 18–33. [19] V. Bernardo, M. Curado, T. Braun, An IEEE 802.11 energy efficient mechanism for continuous media applications, Sustain. Comput.: Inform. Syst. 4 (2) (2014) 106–117. [20] D. Camps-Mur, M.D. Gomony, X. Pérez-Costa, S. Sallent-Ribes, Leveraging 802.11 n frame aggregation to enhance qos and power consumption in wi-fi networks, Comput. Netw. 56 (12) (2012) 2896–2911. [21] J. Manweiler, R. Roy Choudhury, Avoiding the rush hours: wifi energy management via traffic isolation, in: Proceedings of the 9th International Conference on Mobile Systems, Applications, and Services, ACM, 2011. [22] D. Jung, R. Kim, H. Lim, Power-saving strategy for balancing energy and delay performance in WLANs, Comput. Commun. 50 (2014) 3–9. [23] X. Lei, S.H. Rhee, Enhancement of the IEEE 802.11 power saving mode by prioritized reservations, Int. J. Distrib. Sens. Netw. 2015 (2015) 9. [24] G.A. Shah, V.C. Gungor, O.B. Akan, A cross-layer design for qos support in cognitive radio sensor networks for smart grid applications, in: IEEE International Conference on Communications (ICC), 2012, IEEE, 2012. [25] J. He, L. Duan, F. Hou, P. Cheng, J. Chen, Multiperiod scheduling for wireless sensor networks: a distributed consensus approach, IEEE Trans. Signal Process. 63 (7) (2015) 1651–1663. [26] V. Pilloni, Deployment of applications in wireless sensor networks: a gossip-based lifetime maximization approach, IEEE Trans. Control Syst. Technol. 24 (5) (2016) 1828–1836. [27] A.D. Wood, Context-aware wireless sensor networks for assisted living and residential monitoring, IEEE Netw. 22 (4) (2008). [28] D. Ghrab, Study of context-awareness efficiency applied to duty cycled wireless sensor networks, in: Wireless Communications and Networking Conference (WCNC), 2016 IEEE, IEEE, 2016, pp. 1–6. [29] M.C. Domingo, An overview of the internet of things for people with disabilities, J. Netw. Comput. Appl. 35 (2012) 584–596. [30] S. Boyd, L. Vandenberghe, Convex Optimization, Cambridge University Press, 2004. [31] D.P. Bertsekas, Nonlinear Programming, Athena Scientific, 1999. [32] X. Lin, A tutorial on cross-layer optimization in wireless networks, IEEE J. Select. Areas Commun. 24 (2006) 1452–1463. [33] S. Liao, Distributed optimization for utility-energy tradeoff in wireless sensor networks, in: IEEE International Conference on Communications, 2007. ICC’07., IEEE, 2007, pp. 3190–3194. [34] A. Nedic, A. Ozdaglar, Distributed subgradient methods for multi-agent optimization, IEEE Trans. Autom. Control, IEEE volume 54 (2009). [35] International Telecommunication Union (ITU), Recommendation G. 114, Oneway Transmission Time, 2003. [36] I. Glaropoulos, V. Vukadinovic, S. Mangold, Contiki80211: an IEEE 802.11 radio link layer for the contiki OS, in: 2014 IEEE 11th International Conference on Embedded Software and Systems (HPCC, CSS, ICESS), IEEE, 2014, pp. 621–624.

B. Afzal et al. / Ad Hoc Networks 62 (2017) 101–115

115

Bilal Afzal is a graduate from National University of Science and Technology (NUST) Islamabad, Pakistan. He worked as research associate at NUST School of Electrical Engineering and Computer Sciences (SEECS) for one year. Currently he is Sr. Research Officer at Al-Khawarizmi Institute of Computer Science (KICS), University of Engineering and Technology (UET) Lahore, Pakistan. His research interests include Computer and Wireless Networks, Internet of Things, machine to machine (M2M) communication and Next Generation Networks. He has served as the Co-Chair and session manager in IEEE ICOSST 2014, 2015 conferences. He is the regular reviewer of various impact factor journals including Elsevier FGCS, JNCA, COMPELECENG, etc., IEEE Network Magazine, and multiple IEEE conferences.

Sheeraz Akhtar Alvi is currently a Ph.D. fellow at Australian National University. He worked as Sr. Research Officer at KICS, University of Engineering and Technology, Lahore. Before joining KICS he also worked as a Research Assistant in National University of Sciences and Technology (NUST), Islamabad. He holds a BS degree in Electronics Engineering from the International Islamic University, Islamabad (IIUI) and a MS degree in Electrical Engineering from the NUST, Islamabad. He has served as a reviewer for many prestigious journals and conferences. His current research interests are in Internet of Things, multimedia communication and wireless networks.

Ghalib A. Shah [M’09] received his Ph.D. degree in computer engineering from Middle East Technical University, Turkey in 2007. He is currently an Associate Professor and Sultan Qaboos IT (SQIT) Co-Chair, at UET Lahore and leading the research center of SQIT. He has been awarded many research grants by national and international funding organizations. He is a regular technical committee member of many reputed international conferences and reviewer of various high impact factor journals. His research interests include the design and analysis of communication protocols from MAC to Transport layer for cognitive radio networks, wireless multimedia networks and Internet of things.

Waqar Mehmood did his Bachelor’s from University of Engineering and Technology Lahore in 1989, Masters and PhD from Georgia Tech USA in 1992 and 1996, respectively all in Electrical Engineering. He has served in industry as well as academia in the North America and Pakistan. He served as Director Process Development in CIENA Corporation, Maryland; He was selected as voting member and US delegate to the IEC committee on optical interconnect standardization. He is currently the Director of Al-Khwarizmi Institute of Computer Science (KICS) and SQIT Chair at UET, Lahore. He has also served as faculty member in National University of Science and Technology, Islamabad prior to joining KICS. His research interests include optical communications, process technology development, discrete event systems, Networking systems, wireless systems, energy optimization, power systems and renewable energy.