A Survey on Real-Time Communications in Wireless Sensor Networks

Generally, various traffic requirements in wireless sensor network are mostly dependent on specific application types, that is, event-driven, continuous, and query-driven types. In these applications, real-time delivery is one of the important research challenges. However,duetoharshnetworkingenvironmentaroundanode,manyresearchersusuallytakedifferentapproachfromconventional networks.Inordertodiscussandanalyzetheadvantageordisadvantageoftheseapproaches,somecomprehensivesurveyliteratures werepublished;howevertheyareeitheroutofdateorcompiledforcommunicationprotocolsonsinglelayer.Basedonthis deficiency,inthispaper,wepresenttheup-to-dateresearchapproachesanddiscusstheimportantfeaturesrelatedtoreal-time communicationsinwirelesssensornetworks.Asforgrouping,wecategorizetheapproachesintohard,soft,andfirmreal-time model.Furthermore,inallthesecategories,researchhasbeenfocusedonMACandschedulingandroutingaccordingtoresearch areaorobjectiveinsecondlevel.Finally,thearticlealsosuggestspotentialdirectionsforfutureresearchinthefield.


Introduction
As the wireless sensor network (WSN) becomes pervasive, lots of recent research works tend to focus on application specific properties.Among them, real-time communication remains one of research challenges depending on application types such as event-driven, continuous, and query-driven types.In these applications, data packets beyond deadline are regarded as affecting the system performance and quality.However, real-time communication is challenging problem in wireless networks which are subject to fading, interference, being unreliable, and rapid varying channel quality [1].Particularly, if real-time and non-real-time applications coexist, deadline of the real-time traffic cannot be met often due to shared wireless medium with non-real-time traffic as the amount of traffic increases.In addition to property of wireless link, severe constraints on node in WSN make it hard to support real-time communications.To deal with impact of traffic over wireless link, usually higher priority is given to real-time traffic than non-real-time one to minimize the contention on shared medium [2] or contention-free scheme is usually employed in WSN [3].Moreover, practical realtime communication issues in WSN are well presented and introduced in [4].In addition, serious unreliability problem of the contention-based medium access control (MAC) protocol and its default parameter values was mentioned in [5].The authors addressed the impact of power management system and low density for reliability with extensive analysis based on both simulation and experiments.
Based on the above motivation, most of research takes different approaches to focus on application specific property.Moreover, some literatures and one special issue were published and organized, recently.However, they are either out of date or mainly focus on communication protocols in single layer.Thus, they are not sufficient to provide insight into real-time communications in WSN and provide recent research trends.For example, Alanazi and Elleithy [6] presented state-of-the-art research work based on realtime QoS routing protocols for wireless multimedia sensor networks.Moreover, three comprehensive survey literatures

Real-Time Applications and Platform
In this section, we present the representative applications which require real-time delivery.In addition, several sensor node platforms to support real-time communications are briefly described.

Real-Time Applications.
We choose four examples for potential and practical real-time applications.In this section, we describe how real-time communication in each application is provided.

Health Monitoring.
One of the emerging and promising applications to demand real-time communications in WSN is health monitoring system which consists of monitoring and alarming system for patient health.First, a patient's monitoring system embedded with a set of medical sensors and wireless communication module was proposed by Al-Aubidy et al. [13].In this system, the patient health status is reported to medical center and checked by the doctor who is in charge of sending medical advice.The experimental results show the effectiveness of the implemented prototype in the aspects of accuracy, intelligence for making decision, and reliability.In addition, Li-Wan et al. [14] proposed a new type of wireless network monitoring systems to collect patients' physiological indicators by adapting the multichannel highfrequency wireless data transmission.The last example is about a portable real-time wireless health monitoring system which was proposed by Choudhary et al. [15].This system consists of ZigBee wireless standard and demonstration of pulse oximetry data monitoring on the patients.
2.1.2.Target Tracking.VigilNet [16] was proposed to track, detect, and classify targets in a timely as well as energy efficient manner by introducing both a deadline partition method and theoretical derivations to guarantee each subdeadline.Since end-to-end deadline is affected by many system parameters, system-wide global optimal solution was proposed in this work.In the proposed scheme, end-toend deadline is divided into multiple subdeadlines.To meet real-time requirements, activation, sentry detection, wakeup, aggregation, communications, and base processing delay and their tradeoff were analyzed and brought insights.For example, in the case of slow moving target tracking, the deadline is guaranteed by considering several factors such as a higher node density, increased wake-up delay, and fast detection algorithm.The VigilNet was implemented and tested for various cases to prove suitability for real-time communications.

Environmental Tracking.
Pozzebon et al. [17] proposed the new architecture of a heterogeneous WSN to monitor coastal sand dunes where three different typologies of integrated sensors were employed.The proposed architecture consists of Sand Level Sensor Network, environmental monitoring node, and Gateway.The ZigBee radio module transmits the collected data while anemometric station is in charge of data processing.In addition, a Gateway node provides external connection with GSM connection.Tse and Xiao [18] proposed WSN system which is able to sense multiple environmental factors and aggregate collected data in realtime.The data transmission is accomplished by the Wi-Fi module using the UDP protocol.Moreover, environmental monitoring system for air quality was presented in two papers [19,20], respectively.[21] proposed In-Motes EYE application based on In-Motes platform to obtain acceleration variations in an environments for automobile.Four different categories of In-Motes agent are the actor of application under layered architecture.Communications are performed by federation communication scheme.Based on this In-Motes platform, the application is to allow a user to monitor the acceleration pattern of a moving car by injecting a new job agent to the vehicles sensor and checking whether a car breaches the critical parameter of the application in test scenarios.By this experiment, In-Motes applications show possibilities to monitor real-time operation.

Platform for Real-Time Communications
2.2.1.FireFly.FireFly [22] is one of the well-known WSN platforms for monitoring, surveillance, and voice communication with battery-operated node through multihop mesh communications.Particularly, each node operates over Wireless Communications and Mobile Computing 3 IEEE 802.15.4 protocols over Nano-Resource Kernel realtime operating system.Global time synchronization works in energy efficient way by maximizing both common sleep time and throughput within bound end-to-end delay.In the aspects of real-time, each sensor node transmits and receives data packet within predetermined time on dedicated time slots.Thus, FireFly can be used for real-time applications such as delay sensitive voice communication through Real-Time Link (RT-Link) protocol, one of the TDMA MAC protocols, running over a network of FireFly nodes.Moreover, a new extended platform of FireFly Mosaic [23] was proposed to run on vision-enabled sensor networks with application to monitor people's daily activities at home.In this application, frequent particular activities were observed by multiple overlapping cameras to extract wanted information.[24] is a compact hard real-time operating system for WSN.To be optimized for real-time and best-effort tasks, preemptive multithreading and cooperative multithreading are employed.Both higher compactness and lower overheads than typical TinyOS are supported by hybrid multithreading.To realize the hard real-time feature, PAVENET OS is designed in accordance with a thread model and enabling preemption.PAVENET OS provides a wireless communication stack for hiding the exclusive controls to users.The protocol stack realizes modularity at each communication layers so the user can develop various communication protocols according to application demands easily.PAVENET OS employs a buffer management mechanism called pbuf to exchange data among layers.The experimental results show that PAVENET OS achieves 0.01% jitter while performing wireless communication tasks with low overhead in the aspects of size of RAM and ROM and minimum task switching time.[25] is a lightweight low-speed and lowpower WSN platform for voice communications.In order to meet requirement of voice communications and sensing data transmission, clock synchronous MAC protocol and data noninterference mechanisms are employed under star network topology.Moreover, A-LNT supports three types of voice communications in most conditions in order to reduce wireless transmission pressure.The audio channel capacity and delay are enough to support emergency voice communication, audio/sound sensor network, and health monitoring system.[26] is real-time protocol stack for time-synchronized, multichannel, and slotted communication in multihop wireless networks to meet latency requirement for industry automation and structural health monitoring.To bound delay within deadline, there are several factors such as MAC, routing, and clock synchronization protocols to be considered.A-Stack operates with multichannel TDMA, global time synchronization, and source routing.To be more detailed, A-Stack runs on the FreeRTOS real-time kernel; however, it can easily be transferred to any preemptive multitasking OS.Through experimental results, it is proven that A-Stack is suitable for low latency and high reliability real-time WSN applications and protocols.

Real-Time Communications in WSN
Despite its importance and necessity, real-time communications in WSN have faced many research challenges and misunderstanding.For this issue, Oliver and Fohler [4] have analyzed the suitability and applicability of the realtime communications in WSN with impacts of the number of assumptions and different evaluation criteria to infer a number of basic considerations.Even though it is difficult to provide real-time communications in WSN, a lot of researches have been conducted.Therefore, it is essential to identify the existing schemes with proper good insight into real-time communications in WSN.
To achieve above goal, real-time communications in WSN are classified into the categories hard, firm, and soft real-time without loss of generality like conversational classification.Hard real-time communications indicate missing deadline affects the operation on the system by causing failure of the whole system.So, it takes the worst case times to bound end-to-end delay within the deadline.Soft realtime communications attempt to reduce deadline miss so probabilistic guarantee can meet requirement where some misses are tolerable.Firm real-time communications have similar features from both hard and soft real-time model in that it allows for infrequently missed deadlines while the system can survive task failures so long as they are adequately spaced.
In this paper, we categorize the existing schemes for realtime communications into the above three classes.Particularly, as for firm real-time model, we explain well-known (, )-firm model which guarantees requirement that at least  out of any  consecutive messages from the stream must meet their deadlines, to ensure adequate quality of service.Figure 1 illustrates the classification of the existing real-time approaches.As for the second level classification, we focus on the research objective in homogenous way.As a result, we classify the existing schemes in two parts.One is MAC and scheduling and the other is routing.

Hard Real-Time Communications in WSN.
When it comes to taking into account various constraints in WSN, hard real-time communications are very difficult to implement.Particularly, since multihop communications cannot bound deterministic end-to-end delay, star topology in single hop is preferred in most research.Based on this analysis, there are a few hard real-time schemes which are categorized into MAC and scheduling in TDMA as well as routing protocol.Moreover, hard real-time communications in WSN are usually employed in very critical applications such as automobile or industrial application.In this model, as for platform through integrated project, REWIN [28], real-time guarantees in wireless sensor networks, was launched to offer hard real-time guarantees to individual real-time flows over multihop WSN of arbitrary node deployments and arbitrary traffic pattern.These newly studied methods were proven to guarantee a small delay for disseminating the occurrence of critical events.

MAC and Scheduling.
In this section, we briefly describe MAC and scheduling algorithm for hard real-time model.First, Caccamo and Zhang [29] proposed Implicit Earliest Deadline First (I-EDF) based on famous Earliest Deadline First scheduling algorithm.In this scheme, each node is grouped in a form of hexagonal cells and supports intracellular communication and intercellular communication.I-EFP prevents collision through time-based scheduling based on multiple frequencies in intercellular communication.This time-based scheduling together with multiple frequencies guarantees the collision-free nature of I-EDF.Another scheduling algorithm, Source Aware Scheduling (SAS-TDMA) [30], was proposed to reduce overhead through information under cross-layered architecture.It includes the priority queuing model at the node based on average waiting time.N queue saturation point depends on the sum of the loads of the classes of priority up to .In addition, Enhanced Distributed Channel Access (EDCA) method is employed at the MAC layer.As for hard real-time protocol for WSN, a multipath routing protocol discovers disjoint paths where a source node selects its route dynamically and checks the quality of the alternative routes with delay metric.
Beside scheduling algorithm, Watteyne et al. [31] proposed real-time MAC protocol under random liner networks.The proposed Dual-MAC regulates medium access according to node's position.An unprotected mode prone to collisions and a slower protected mode free for collision were considered to guarantee worst case times.This property was validated by a formal model.Moreover, Kieckhafer [32] studied Wireless Architecture for Hard Real-Time Embedded Networks (WAHREN) under hard real-time deadline for national project, Pierre Auger Cosmic Ray.At the MAC layer, hybrid TDMA/CSMA window is employed where all infrastructure nodes transmit only within their preassigned TDMA slots and noninfrastructure nodes transmit only within the CSMA to avoid interference between them.Another applicable real-time communication to WSN was proposed by Aísa and Villarroel [33].Even though Wireless Chain net-worK Protocol (WICKPro) was proposed for wireless mesh networks with chain topology, its token passing approach and time-token protocol as well as cyclic executive can be implemented in WSN.Moreover, EchoRing is proposed by Dombrowski and Gross [34] to address communication at very short latencies together with high reliabilities for wireless industrial network.It introduces cooperative communication and improved fault tolerance functionality in decentralized way.The measured latency is maintained below 10 ms.At last, unlike single hop TDMA, Ergen and Varaiya proposed multihop TDMA scheme with access point which performs scheduling with gathered topology information.PEDAMACS [35] employs a polynomial-time scheduling algorithm which guarantees a delay proportional to the number of nodes instead of optimization problem as known NP-complete one.
In addition to MAC layer approach, Cherian and Nair [36] presented the priority queuing model at the node based on average waiting time.N queue saturation point depends on the sum of the loads of the classes of priority up to .In addition, Enhanced Distributed Channel Access (EDCA) method is employed at the MAC layer.As for hard real-time protocol for WSN, a multipath routing protocol discovers disjoint paths where a source node selects its route dynamically and checks the quality of the alternative routes with delay metric.Moreover, as an extension of IEEE 802.15.4, a new mode for Deterministic and Synchronous Multichannel Extension (DSME) and Low Latency Deterministic Network (LLDN) in IEEE 802.15.4e [37] can be regarded as acceptable solution for real-time communications in WSN.The former supports deterministic delay and high reliability to time-varying traffic and operating conditions while LLDN defines a fine granular deterministic TDMA access over star topology.Based on this feature, they are supposed to WirelessHART [40], extended from Highway Addressable Remote Transducer Protocol (HART) framework, has a centralized network management architecture, multichannel TDMA transmission, redundant routes, and avoidance of spatial reuse of channels for enhanced reliability and realtime performance.The important device, network manager, is responsible for controlling of scheduling and configuring the routing in the network.By the help of network manager, hard real-time communication is achieved by receiving data from each of the WirelessHART nodes in the network.In addition, network manager runs source and graph routing to meet real-time constraints.TDMA with 10 ms time lost is used at data link layer.Figure 2 illustrates the layering of WirelessHART.In addition to above layers, physical layer defines radio characteristics such as signaling method, signaling strength, and device sensitivity.Moreover, application layer defines various device commands, data types, and response.
In conformity with these rules, there are a few research works over WirelessHART platform.Nobre et al. [41] presented literature review of routing and scheduling for Wire-lessHART.In addition, some open issues in WirelessHART routing and scheduling algorithms were discussed.Moreover, Lu et al. [42] presented real-time Wireless Sensor-Actuator Networks (WSAN) for industrial control systems through WirelessHART.For real-time service, experimental WSAN testbed and scheduling algorithms were implemented and reviewed.Finally, some issues such as rate control for wireless control systems were presented.

Routing.
There is one protocol to address hard real-time communications in WSN since most of schemes assume onehop communications.Ergen and Varaiya [43] proposed new real-time routing protocol to consider network lifetime.At first, a scheme to maximize the minimum lifetime of each node is presented without considering delay as programming problem.The second approach is to incorporate delay guarantee into energy efficient routing by constraining the length of the routing paths.

Soft Real-Time Communications in WSN.
Followed by few hard real-time protocols in WSN, routing and MAC protocol for soft real-time communication are described in this section.In this model, three platforms have been presented.RAP [44] architecture attracts researcher's interest.Since RAP provides the query/event service API, hence it is used for registering the query for specific sensing event.
The query stores timing constraints, transmission period, and destination location information.Hence, when a registered event occurs, the query result is automatically transmitted to the destination.RAP uses velocity monotonic scheduling to match the end-to-end deadline of query result packets.It uses the requested deadline and the distance to the destination to obtain the requested velocity, assigns a high priority to the packet with the higher requested velocity, and ensures that transmission is done within the packet's deadline.Another framework to consider both real-time communications and energy efficiency is Real-Time Power-Aware (RTPAW) framework [45].Key feature of RTPAW includes aggregation layer between MAC and routing layer under cluster architecture.Aggregation layer is responsible for creating and maintaining cluster to balance energy consumption by control of active and sleep period.The other architecture called Wi-STARK [46] was proposed to consider both fault tolerance and real-time communication at the same time.It has compliance with standard IEEE 802.15.4 and provides service interface which can be used in building control application.Guarantee of timeliness as well as resilient communication services is achieved in onehop communication domain by real-time communication suite which consists of message request dispatcher and protocol bundle.To be detailed, Figure 3 shows architecture of Wi-STARK with three different layers.There are three major components such as real-time communication suite, timeliness and partition control (TPC), and networking and management control.Particularly, networking and management control in mediator layer is responsible for integrating all functionalities as well as providing management services.

MAC and Scheduling.
Several soft real-time MAC protocols were proposed.Matischek et al. proposed Real-Time Hybrid MAC (RTH-MAC) protocol [47] to combine both TDMA and FDMA to offer soft real-time communications.
To meet real-time requirement, centralized approach that eliminates collisions, minimizes interferences, and ensures a small bounded end-to-end delay was taken.Moreover, RTH-MAC employed an acknowledgment mechanism and duty cycling ratio for reliability and adaptability.As another type of combined MAC, Abdeli et al. [48] presented MAC protocol which provides network traffic prioritization in order to guarantee worst case message delays for a set of highprioritized nodes automotive applications.The proposed, Soft Real-Time Shared Time slot (SRTST), uses a shared time slot method by combining TDMA and CSMA/CA mechanisms in a special two-step way.
In addition, GinLITE [49] was developed as one of the components of GINSENG system to offer time-critical and reliable data delivery by utilizing a purely static topology with precomputed and static TDMA schedule.Basically, GinLITE is a mesh under TDMA MAC protocol which operates through static topology/schedule information.A new MAC protocol with black-burst (BB) mechanism was proposed to provide real-time access in [50].But, in order to decrease energy loss and latency caused by long length, a binary coding scheme is applied to coding-black-burstbased protocol.Zhang et al. [27] presented real-time MAC protocol to meet high throughput, low latency, and energy consumption by accurate time synchronization.To achieve this goal, hybrid approach to combine TDMA with novel time synchronization approach and Frequency Hopping Spread Spectrum (FHSS) was presented to include antijamming and collision prevention.Particularly, for real-time communication, command and data packets are delivered in a bucket brigade-like manner for bandwidth utilization.Figure 4 shows the example of tree topology to communicate with sink node.Each sensor node is grouped by cluster so it transmits sensed data to cluster header.As shown in Figure 4, each sensor node communicates with parent node during phase 1 while communication with child node is performed during phase 2.Moreover, Shukeri et al. [51] studied cluster architecture for adaptive TDMA scheduling in WSN.Through the adaptive scheme to type of flows, channel is dynamically allocated to achieve better utilization by minimizing the number of unused channels.
In addition to new MAC protocol development, Ali et al. [52] presented experimental results for prototype of TSMAC which is implementation of a multihop mesh topology realtime IEEE 802.15.4-basedMAC protocol for Contiki OS.To implement TSMAC, radio duty cycle was modified to realize the slotted transmission mode.In the testbed, the network operates in Beaconless mode and all nodes are powered by USB hub.Throughout the experimental results, TSMAC shows higher throughput and lower collision and jitter than existing CSMA.
Furthermore Real-Time X-layer Protocol (RTXP) [53] aims at guaranteeing an end-to-end requirement while keeping energy consumption.It relies on a hop-count-based Virtual Coordinate System (VCS) which classifies nodes having the same hopcount from the sink, allows forwarder selection, and gives to the nodes a unique identifier in a 2-hop neighborhood allowing deterministic medium access.Another scheme to feature cross-layer forwarding and medium access control was presented in Service-Differentiated Real-time Communication Scheme (SDRCS) [54].It integrates real-time routing and prioritized MAC by performing packet speed estimation and admission control in a distributed way under dynamic network topologies.To be detailed, local prioritized packet forwarding is performed to maximize packet speed.

Routing.
First of all, various types of soft real-time routing protocol have been proposed.Among them, SPEED [55] has good reputation and diverse variations for realtime communication.SPEED is a real-time communication protocol, which supports feedback control and nondeterministic geography forwarding so as to guarantee the desired delivery speed.In the stateless nondeterministic geographic forwarding (SNGF) module used by SPEED, the node with the highest relay speed is being selected as the next hop.In order to calculate the relay speed in SNGF module, neighbor node distance and location information are collected by exchanging beacon.Moreover, in order to determine transfer delay between nodes, data packet is sent to the neighbor node.After the ACK message is received, it is possible to acquire delay estimation through the round trip time.SNGF offers not only Back-pressure Rerouting (BR) but also Neighborhood Feedback Loop (NFL) models which provides traffic and congestion control in order to guarantee desired delivery speed.NFL uses neighbor nodes miss rate information to decide if a node cannot maintain more than a single hop relay speed.When NFL has been activated, instantly the average transfer delay value of each node within the congestion area is added to back-pressure beacon and transferred into the upstream node.After receiving this beacon packet, the upstream node controls the sending rate by stopping to send the packets into the area of congestion.
In parallel with SPEED, MMSPEED [56] creates a virtual multiple speed layer and performs virtual isolation to classify the incoming packets into the appropriate priority queues according to the required delivery velocity to prevent packets from being delayed by slow packets in the queue.MMSPEED groups single or multiple forwarding path of the packet depending on the required reliability level of the packet.In other words, packet layering is performed according to the reliability of a packet.The lower reliability packet is transmitted to a single path while the high reliability packet is transmitted to a destination via multiple paths.Moreover, energy efficient SPEED [57] was proposed.Like the existing SPEED routing protocol, it transmits routing information and its own residual energy information to neighbor nodes through beacon exchange.In the SPEED routing protocol, it is highly likely that the node with the highest relay speed among the other neighbor nodes will be selected as the next hop.But, in the proposed routing protocol, the weight function of the neighboring nodes is calculated based on the information exchanged with the beacon exchanging method and the neighboring node with the highest value in weight function is the one that is selected as the next hop.Furthermore, Zhou et al. proposed POWER-SPEED [58] which does not use a control packet but uses the upstream hop-by-hop delay in the data packet at each relaying node to the destination to perform future hop-byhop delay estimation.In addition, to support energy efficient routing in POWER-SPEED, the minimum value of total energy consumption required for transmission is calculated, and then the transmitter power level required for the relay to the neighboring node is adaptively set according to this value.Furthermore, remaining energy was concerned in [59] by introducing weight which is calculated by adding delay with remaining energy of neighbor node.Furthermore, Aissani et al. [60] presented EA-SPEED to drop the delayed packets in early time and extend the stateless nondeterministic geographic forwarding (SNGF) of the SPEED protocol.In this extension, next hop was decided while considering speed and residual energy instead of random selection in original SPEED.Another energy aware real-time protocol, EARQ [61], was proposed to support real-time, reliable delivery of a packet and energy awareness in wireless industrial sensor networks.To do this, each node exchanges beacon messages with its neighbor nodes and records the energy cost, time delay, and reliability needed to reach the sink node into its routing table.Since the path with less energy cost is more likely to be selected than another path, if the reliability of the selected next hop is lower than the required reliability, a new next hop is selected and then the redundant packet is transmitted so as to ensure reliable packet delivery.
In the aspects of fault tolerance, another extension of SPEED, FT-SPPED [62], focused on fault tolerant property.FT-SPEED solves the void problem which existed in the previous SPEED protocol by adding Void Announce Scheme (VAS) and a Void Bypass Scheme (VPS).In addition to fault tolerance and energy efficiency in SPEED, IMMSpeed [63] transmits the other copy of the remaining packet to the remaining nodes if the required number of neighbors is insufficient.IMMSpeed does not select the neighboring node with the fastest forwarding speed as the next hop; rather it selects the node with the highest energy among the neighboring nodes that can keep the real-time deadline as the next hop.Although the energy is the same then the neighboring node with the fast forwarding speed is selected as the next hop.In addition, alternative path selection algorithm based on Neural Network [64] was additionally applied to SPEED for the case of path failure and sleep node.In this work, Neural Network is applied to evaluate QoS parameter and get the optimized path.Some of these addressed protocols were compared and analyzed in [65] through proposed energy model to verify the acceptable performance.
Besides SPEED and its variants, some soft real-time routing protocols have been proposed.First, Enhanced Real-Time with Load Distribution (ERTLD) [66] selects optimal forwarding node based on Received Signal Strength Indicator (RSSI), remaining battery level of sensor nodes, and packet delay.For this purpose, the ERTLD uses the corona mechanism, which computes the corona level of the mobile node according to the distance from the mobile sink, and each mobile node sets one-hop neighbors with a corona level smaller than or equal to itself as forwarding candidate nodes.Each mobile node computes the optimal forwarding (OF) value using three parameters among the selected forwarding candidate nodes with mentioned procedures.These parameters are packet rate, RSSI as link quality, and remaining power.Therefore, the neighbor node with the highest OF value is the one that ends up being selected as the next hop.Another protocol called Potential-based Real-Time Routing (PRTR) [67] divides the packet into realtime and non-real-time packets to prevent the shortest path from being congested by nondelay sensitive packets in WSN.The real-time packet selects the shortest path and the nonreal-time packet selects another routing path; thereby these approaches reduce the congestion of the shortest path and reduce the transmission delay of the real-time packets.For this operation, PRTR uses the flag field of each packet header  to distinguish whether the packet is a delay sensitive packet or a nondelay one and allows the delay sensitive packet to be transmitted ahead of other packets using the priority queue.Figure 5 shows the example of data forwarding in PRTR.As illustrated in Figure 5, nondelay sensitive packet is forwarded along the different path to prevent congestion.Each packet is identified by flag field in the packet header.Quang and Kim [68] proposed combining a Two-Hop Velocity based Routing (THVR) algorithm and a gradient-based network to reduce deadline miss ratio (DMR) and improve energy efficiency in industrial wireless sensor networks.Moreover, Mahapatra et al. [69] proposed an energy aware dualpath routing scheme considering packet delivery deadlines, efficient energy consumption, and reliability in WSN.Each node periodically exchanges HELLO PKT as beacon message and calculates the location, remaining energy, and estimated time delays of neighboring nodes.After that, each node calculates an urgency factor based on the remaining distance and slack time information until the packet arrives at the destination.Moreover, urgent packets based on the urgency factor are transmitted to the boundary of the transmission range.At last, Rachamalla and Kancharla [70] proposed Energy Efficient Adaptive Routing Protocol (EE-ARP) by combining adaptive transmission power algorithm with any geographic routing to improve energy efficiency.

Firm Real-Time Communications in WSN.
The research for (, )-firm communications in WSN was conducted in two directions.One is to extend the existing scheme to accommodate (, )-firm requirement streams and the other is to develop new communication protocols to meet (, )firm requirement.Even though two types of mechanisms have different objectives, most approaches have in common the fact that they make use of Distance Based Priority (DBP) value to differentiate priority or choose the next hop.DBP value is used to indicate the current stream status.
In this model, Lee et al. [71] presented new architecture to solve scalability problem by new architecture for (, )-firm streams.In the new integrated architecture, flow aggregation scheme derived from compositional hierarchical model and velocity based protocol were proposed to solve  the scalability problem.In addition, hybrid MAC protocol and congestion control scheme were proposed to meet (, )firm constraints in efficient way. Figure 6 shows the example of operation in the proposed scheme.All source nodes first select the adequate streams.If this stream is delivered to the same node, streams are aggregated into one stream.If the congestion happens at node , a Level Adjustment message is back to  to reduce sending traffic rate.The sink or destination node measures the QoS level periodically and sends reply to each source node.This reply triggers stream selection procedure if the condition is met.As an sequential approach, optimization solution for (, )-firm stream was not presented yet.

MAC and Scheduling.
There are several approaches to develop new MAC and scheduling mechanism to meet (, )-firm streams.As for scheduling, Kim [72] proposed a new scheduling algorithm for (, )-firm stream.The priority of packet was dynamically assigned by DBP value, slack time, distance to sink node, and link stability.Particularly, network congestion around the sink node is crucially concerned by adjusting weighting factor.Moreover, Zhao and Xiong [73] proposed a channel-aware scheduling algorithm through packet partitioning and real-time delivery.The former combines static assignment and dynamic adjustment to minimize the number of packets over bad channel state while the latter is accomplished by automatic repeat request.Moreover, Semprebom et al. [74] presented dynamic Guaranteed Time Slot (GTS) scheduling approach based on the (, )-firm task model to prevent starvation problem as well as ensure delivery of at least m messages in each window.Due to inherent limitations in processing power and energy consumption, a fixed priority scheduling algorithm rather than dynamic one was proposed.At last, even though Matusovsky [75] proposed a recovery from data losses to support real-time application in wireless networks, this proposed scheme can be easily applicable in WSN.In this work, a recovery was accomplished by retransmission of failed packets under a point to multipoint network with fixed number of nodes.The proposed algorithm was derived from Reinforcement Learning theory.
Moreover, a new MAC protocol to enhance IEEE 802.15.4/ZigBee was proposed by Semprebom et al. [76].The proposed scheme aimed at improving CSMA/CA algorithm by assigning decentralized priorities based on the (, )firm task model.So, occurrences of dynamics failures can be reduced by assigning the highest priority level to node which is close to a dynamic failure condition.By the help of the highest priority, success probability increases in the next transmission.

3.3.2.
Routing.An approach to extend SPEED described in previous section was presented in [77].In the extended (, )-firm SPEED, the next hops selection depended on velocity of link and current DBP value.If DBP value is greater than 0, probabilistic selection is performed among the possible links having higher speed than threshold in order to distribute the load.Otherwise, a suitable link is selected according to DBP value.The next extension is made on Plum-Slowly Fetch-Quickly (PSFQ) to support the (, )-firm stream efficiently in [78].To meet (, )-firm requirement, a segment is divided into m subsegments.If the current DBP value carried on the packet is negative, more strict requirement is temporarily made to ensure the packet delivery as well as control the retransmission.Unlike the addressed approach which is based on real-time scheme, extension of general ad hoc routing was presented by Tekaya et al. [79].The objective of this extension is to introduce scheduling policy to increase admission rate of real-time traffic over AODV protocol.
Beside extension of the existing protocol, Jiang et al. [80] proposed Link Quality Estimation based Routing (LQER) protocol to monitor environmental monitoring in wetlands through (, )-firm link quality estimating.To achieve energy efficiency, LQER employed minimum hop field based routing protocol by limiting the number of participating nodes in the transmission of packets.Even though LQER introduced (, )-firm model, its applicability was limited to use of (, )-firm as metric of the link.Thus, a new approach to use (, )-firm as application requirement emerged.Moreover, Kim and Sung [81] proposed a new geographical routing protocol to meet (, )-firm requirements.The new protocol took delay, distance, and remaining slack time into account for priority-based scheduling and a geographic forwarding scheme.For the latter, new measurement for link quality and adaptive next hop selection algorithm were presented.
In addition to previous communication protocols, the following papers focused on recovery scheme for (, )firm stream.Li and Kim [82] proposed a new fault recovery mechanism by employing a local status indicator (LSI) to adjust transmission capability.LSI is used to make the intermediate nodes that were bared aware of their local transmission conditions.By the help of LSI and streams DBP, three different major sources for packet loss and long delay are identified clearly.They are congestion, link failure, and void in the networks, respectively.Depending on one of them, different recovery scheme is adaptively applied.This LSI based routing protocol for (, )-firm stream was improved by the same authors in [83].The extension is for energy efficiency so next hop is selected by node with maximum remaining energy.Furthermore, Nam [84] proposed a load balancing routing protocol (LBRP) to meet (, )-firm constraints while taking into account energy efficiency and extended network lifetime.In this mechanism, each node maintains two different groups for forwarding.The next hop is chosen from each group sequentially to prevent energy consumption by multiple forwarding.The candidate set for next hop consists of nodes having higher speed than threshold.
Unlike previous general layered architecture, crosslayered approach was presented by Kim and Sung [85].In this approach, new scheme was developed in each layer with (, )-firm requirement passed from the application.Based on this information, adjustment of transmission range in physical layer was developed.Also, prioritization of packet in MAC layer and multiple paths establishment in network layer are completed to meet (, )-firm constraints dynamically.Moreover, one framework that integrates each scheme shows the low failure probability for real-time requirements on (, )-firm stream by the help of the proposed scheme.However, since there are researches for communication protocol, Kim and Sung [86] presented traffic model and new routing protocol together.Particularly, application and clustering scheme were firstly mentioned and addressed in this work.According to DBP value, duplicated data packets were assumed to be transmitted to recover negative DBP status and link stability was presented in a form of (, ).High performance was measured and obtained by these two schemes.Despite the above approaches, there is applicability problem to introduce (, )-firm in WSN.To address this problem, Azim et al. [87] presented multicriteria system for forwarding for (, )-firm stream since current existing protocols applied these parameters sequentially without any prioritization.This implied that there are many perspective parameters to be considered in forwarding scheme.Optimization is achieved by two approaches, fuzzy interference system and analytical hierarchical process in conjunction with the gray relational analysis.These two protocols took delivery ratio, energy, speed, and (, )-firm stream requirement as well as current stream status to select the next hop.As final approach, a new clustering scheme for (, )-firm stream was proposed by Kim [88].For the clustering scheme, header and members are chosen by (, )-firm requirement or deadline.

Open Issue
4.1.Multicast and Broadcast.As we explained in the previous section, most of real-time communication is performed in unicast communication.However, there are increasing demands for either group communications or data delivery to whole nodes.For example, a sink node delivers new mission to whole nodes or inform some nodes for object information to be tracked.Thus, real-time multicast and broadcast are critical and essential research challenge.However, fewer researches for real-time multicast and broadcast have been conducted than unicast.To be detailed, since multicast and broadcast are largely dependent on delivery tree, tree initialization and maintenance procedure should take deadline into account.

Energy Efficiency.
Due to node operation with battery, energy efficiency issue is always given to higher priority than other features in WSN.Particularly, most schemes for realtime communications are likely to choose a path with least cost repeatedly.In this case, a node's battery along the path will be quickly drained so it becomes unavailable at early time.Consequently, failure on node results in short network lifetime.So, real-time communications protocol should be designed in energy efficient way.Duty cycle in MAC layer and utilizing multiple paths are good approach to achieve energy efficiency.In addition, energy aware scheduling for TDMA and QoS routing needs to be explored as further study.

Simulation Model.
Performance of most research for real-time communication is accomplished by simulation.Currently, various simulation platforms including TOSSIM, OMNeT++, and NS-2/3 are general frameworks to conduct simulation for WSN.Particularly, Lalomia et al. [89] proposed hybrid simulation model with augmented version of TOSSIM by merging actual and virtual nodes seamlessly as well as interacting with each other.To ensure soft realtime in WSN, simulation timing is constrained to handle simultaneous events by scheduler.In addition, Rousselot et al. [90] presented OMNeT++ simulation models based on the IEEE 802.15.4 with four evaluation models to validate the timeliness.However, a validated simulation model for real-time communications for WSN is not released yet.So, adding on module for real-time communications should be implemented and integrated with current simulator.4.4.Network Architecture.Most of protocols for real-time communications for WSN are designed by assuming flat network architecture.On the other hand, several clustering schemes for real-time communications have been proposed in mobile ad hoc networks.Clustering scheme results in low energy consumption and routing overhead.Also, since clustering can solve scalability problem, real-time communication for large scale WSN should take clustering into account.In addition, end-to-end delay is closely related to number of hops so reduced hops contribute to meeting deadline requirement.Consequently, details to create and maintain clustering as well as path selection are worth being studied.In this aspect, cross-layered architecture and approach are another promising research area to improve the performance.Related to this issue, it is worth mentioning that superframe duration allocation schemes for cluster-heads lead to improvement throughput for cluster-tree [91].Through the proposed allocation scheme, network congestion around the PAN coordinator, high message communication delays, and a high number of discarded messages due to buffer overflows are significantly reduced.Thus, it is very suitable for widescale networks with energy efficiency QoS.

Programming Models and Tools.
Even though many programming models and tools were introduced in [92] for WSN, there are no programming model and tool for realtime communications yet.Moreover, since they are related to operating system and debugging tools together, programming tool-chain needs to be explored.Moreover, programming tools should consider the specific application for realtime requirements; appropriate Application Programming Interface (API) to manage component needs to be developed.Moreover, Integrated Development Environment (IDE) is demanded to allow user to develop real-time application easily.
4.6.Applicability to Ad Hoc Networks.Since WSN is based on ad hoc network technology, most of the presented schemes work in ad hoc networks without significant changes even though the opposite is not feasible.However, some schemes which are designed to be specific to WSN need to be modified or extended to be applied in ad hoc networks.Thus, protocols assuming high density of nodes and data aggregation in WSN need to be modified to reduce the interference.For example, in case of original SPEED [55] protocol, each node keeps a neighbor table with nodes in transmission range for reliability.However, the limited number of nodes around boundary of transmission range is enough for table in case of ad hoc networks where wider range and bandwidth than WSN are given.On the other hand, if such limited resource constraints on sensor node get loosen, current protocols can support real-time communications easily in ad hoc networks.

Deployment and Applications.
Even though FireFly was reported to be deployed in coal mine for people tracking with voicemail communication, there is no scheme overwhelming others.Also, there is only one application, voice communications, which makes use of real-time communications in WSN.This indicates that more optimization and customization for the protocol and framework are demanded for killer application.Related to this issue, since real operation is affected by limitation on wireless link and energy constraints, integration with wireless cellular networks or LAN needs to be studied.For example, Al-Rousan and Kullab [93] presented two-tiered architecture for real-time communications in WSN.In their approach, WLAN serves as a backbone to an adaptively clustered Low Energy Adaptive Clustering Hierarchy-(LEACH-) based wireless sensor network.Through this architecture, reliable data delivery with reduced delay bounds and lower energy consumption is observed in WSN.

Conclusion
In this paper, we reviewed recent literatures for real-time communications in WSN.Even though it is not easy to provide real-time communication in WSN when it comes to take harsh environments into account, the demands for real-time delivery are more increasing.In order to meet this demand, various approaches based on hard and soft real-time model were taken.In addition, we explained existing research work for (, )-firm model in WSN.Each protocol was briefly introduced and explained.Finally, further research challenges and issues were presented to give guideline for research trend.