EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and...

16
EVAM-MAC: An Event Based Medium Access Control for Wireless sensor Networks with Multihop Support Zaher Merhi 1 , Mohamed Elgamel 2 , Samih Abdul-Nabi 1 , Amin Haj-Ali 1 , and Magdy Bayoumi 3 1 Department of Computer and Communication Engineering Lebanese International University Beirut, Lebanon {zaher.merhi, samih.abdulnabi, amin.hajali}@liu.edu.lb 2 Arab Academy for Science Technology and Maritime Transport Alexandria, Egypt [email protected] 3 Center for Advanced Computer Studies University of Louisiana at Lafayette LA, USA [email protected] Abstract As wireless sensor network applications are becoming more complex, the need for a versatile medium access control that is able to deliver high data rates is es- sential. In event-based systems, sensor nodes spend most of their time at sleep state waiting for an event to occur. When an event is detected, sensor nodes experience a short abrupt period of high data con- tention where the data packets are large in size. As the number of sensor nodes per-hop increases, the contention generated will lower the throughput, in- crease latency and deteriorate the application’s per- formance. EVAM-MAC is a medium access control that is tailored specifically for event-based systems. EVAM-MAC shifts the contention generated by mul- tiple sensor nodes trying to deliver the collected mea- surements to the control phase. Furthermore, it ar- ranges data transfer in a contention free environment by dynamically creating a TDMA-like schedule with- out global synchronization or global slot assignments. EVAM-MAC offers a platform of configurable opera- tions that can be programmed prior to deployment. The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC presented its superiority in throughput, Latency and Energy con- sumption. Keywords : Clustering Algorithms, Event Detec- tion, Medium Access Control, Wireless Sensor Net- works 1 Introduction Medium access control protocols (MAC) are consid- ered an integral part of any wireless sensor network (WSN) application. These applications are usually constrained by both power and time. Typically, WSN are battery operated where replacing and/or charging the battery is not always feasible. Thus, it is crucial for the application longevity to preserve power con- sumption. Furthermore, real time applications such as target tracking, cannot tolerate latency in data de- livery. Dropped packets due to high data contention wastes both power and time. Initially, the trend with MAC protocols for wireless sensor networks was to trade for latency with energy consumption by duty cycling the radio transceiver [2] [3]. This suited monitoring application since wireless sensor devices transfer small amount of information every periodic timeframe. On the other hand, event based applica- tions spend most of their time at sleep state waiting IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 23 Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Transcript of EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and...

Page 1: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

EVAM-MAC: An Event Based Medium Access Control for Wireless

sensor Networks with Multihop Support

Zaher Merhi1, Mohamed Elgamel2, Samih Abdul-Nabi1,Amin Haj-Ali1, and Magdy Bayoumi3

1Department of Computer and Communication EngineeringLebanese International University

Beirut, Lebanon{zaher.merhi, samih.abdulnabi, amin.hajali}@liu.edu.lb

2Arab Academy for ScienceTechnology and Maritime Transport Alexandria, Egypt

[email protected]

3Center for Advanced Computer StudiesUniversity of Louisiana at Lafayette

LA, [email protected]

AbstractAs wireless sensor network applications are becomingmore complex, the need for a versatile medium accesscontrol that is able to deliver high data rates is es-sential. In event-based systems, sensor nodes spendmost of their time at sleep state waiting for an eventto occur. When an event is detected, sensor nodesexperience a short abrupt period of high data con-tention where the data packets are large in size. Asthe number of sensor nodes per-hop increases, thecontention generated will lower the throughput, in-crease latency and deteriorate the application’s per-formance. EVAM-MAC is a medium access controlthat is tailored specifically for event-based systems.EVAM-MAC shifts the contention generated by mul-tiple sensor nodes trying to deliver the collected mea-surements to the control phase. Furthermore, it ar-ranges data transfer in a contention free environmentby dynamically creating a TDMA-like schedule with-out global synchronization or global slot assignments.EVAM-MAC offers a platform of configurable opera-tions that can be programmed prior to deployment.The protocol is simulated with NS2 and comparedwith an implementation of S-MAC and 802.11 formultiple scenarios where EVAM-MAC presented itssuperiority in throughput, Latency and Energy con-

sumption.Keywords : Clustering Algorithms, Event Detec-tion, Medium Access Control, Wireless Sensor Net-works

1 Introduction

Medium access control protocols (MAC) are consid-ered an integral part of any wireless sensor network(WSN) application. These applications are usuallyconstrained by both power and time. Typically, WSNare battery operated where replacing and/or chargingthe battery is not always feasible. Thus, it is crucialfor the application longevity to preserve power con-sumption. Furthermore, real time applications suchas target tracking, cannot tolerate latency in data de-livery. Dropped packets due to high data contentionwastes both power and time. Initially, the trend withMAC protocols for wireless sensor networks was totrade for latency with energy consumption by dutycycling the radio transceiver [2] [3]. This suitedmonitoring application since wireless sensor devicestransfer small amount of information every periodictimeframe. On the other hand, event based applica-tions spend most of their time at sleep state waiting

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 23

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 2: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

for an event to occur. Once an event is detected, ashort abrupt period of high data contention is exhib-ited due to multiple nodes contending for the channel.Thus, trading energy for latency is no longer a validchoice [1].

High throughput applications usually employTDMA schemes. However, they are not efficient forwireless sensor networks [5], [6]. In TDMA schemes,data transmission is regulated by assigning a uniqueslot for each sensor node in the two-hop neighbor-hood. In event-based systems, only sensors detect-ing the event should participate in data transmission.Thus, time slots are wasted where sensors not wishingto transmit are forced to sleep. Slot reuse is employedby hybrid TDMA/CSMA schemes as in [7]. However,the overhead in creating and maintaining a scheduleacross multiple sensors at multiple hops consumes sig-nificant amount of energy. Although this overheadonly occurs at deployment the cost of updating theslot distribution across the network for nodes joiningand leaving the network (which is frequent in wire-less sensor networks) is significant and cannot be ne-glected. Moreover, these schemes also employ globaltime synchronization that incur even more overheadin packet exchange and in maintaining clock drift cor-rections over time.

On the other hand, wireless sensor network is anapplication centric device. MAC protocols should of-fer a set of policies and procedures that can be config-ured to optimize event-based systems according to theapplications’ designers need. Moreover, event-basedsystems exhibits certain characteristics that the MACprotocol should take into consideration to achieve anoptimized design. For an example, dynamic cluster-ing is very desirable in event-based systems as onlysensors detecting that event should wake up and de-liver measurements to a local cluster head. Further-more, it is more efficient to aggregate data at localcluster heads rather than having each node transmit-ting its measurements throughout the network. Staticclustering is not efficient for wireless sensor applica-tions since nodes are consistently joining and leavingthe network. However, as sensor node count increasesper cluster, the contention is heightened as multiplesensors try to deliver their recorded measurements tothe cluster head. Since measurements are highly cor-rupted by noise in wireless sensor networks, priori-tizing data transfer according to the received signalstrength (RSS) of the event restrains the system fromovershooting and insures quality of service [9]. Onthe other hand, measurements recorded from the cap-tured event are highly correlated which make it some-times useless to send more than a certain number ofmeasurements according to a certain policy. For an

example, in a 10-node network scenario, an applica-tion could be satisfied with only 5 high quality read-ings (i.e. high RSS). Transmitting all 10 readings willincrease contention and waste both bandwidth andenergy. A mechanism should be devised in order toinstruct a subset of sensors belonging to a cluster totransmit according to the quality of their readings.

Furthermore, optimizations can be achieved bytailoring the MAC protocol to a pattern of commu-nications that the application requires. For exam-ple, distributed signal processing application usuallyshare the readings recorded by the sensor nodes thatare in the one-hop neighborhood for processing viabroadcast. Afterwards the result is unicasted to thecluster head for aggregation. Some applications re-quire several rounds of such. The control packet over-head (RTS-CTS-ACK) can be minimized if the sensornodes participating in the event register their interest.Thus, the MAC protocol can be configured to followthe patterns required by the application by dynami-cally constructing an efficient schedule. Lowering thecontrol overhead will increase throughput and lowerenergy consumption by restraining the sensor nodesfrom contending for the channel each time a commu-nication sequence is started for the same event whendetected.

EVAM-MAC is an event based medium accesscontrol that addresses all the problems listed above.When an event is detected EVAM-MAC will dynam-ically create a virtual cluster containing only nodesthat detected the event. The cluster is constructed byintroducing a control gap that registers sensor nodesthat have recorded viable data. A Schedule will becreated for this cluster that is unique across the two-hop neighborhood. Thus, each node will have a con-tention free slot to send their data. EVAM-MAC isthe extension of our work presented in [8] . Thisarticle is organized as follows: Section II discussesthe related work, Section III presents EVAM-MACprotocol design, Section IV discusses the simulationexperiments and results, and Section V is the conclu-sion and future work.

2 Related Work

Most medium access control for wireless sensor net-works lowers energy consumption by decreasing theduty cycle of the radio. Having a low duty indicatesthat the radio is spending most of the time at sleepstate. However, this has the effect of lowering thethroughput. In Event-based systems the sensor nodesspend most of their time at sleep state waiting for anevent to occur. Once the event is detected, a short

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 24

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 3: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

abrupt period of high data contention follows.S-MAC [2] and T-MAC [3] are scheduled based

protocols that preserve energy by duty cycling theradio. These MAC protocols trade energy with la-tency. However, in event-based systems it is desirableto have a real time response. S-MAC synchronizesnodes using a SYNC messages that assigns a scheduleto each node. The overhead produced by the SYNCmessages introduces huge latencies as the one hopeneighborhood grows in size. T-MAC [3] improves onS-MAC by reducing the idle time spent using a time-out scheme. All communications are moved to thebeginning of the frame which set the nodes into afierce mode for acquiring the channel. However, itstill suffers from the shortcomings of S-MAC.

Hybrid protocols such as the Z-MAC [7] and F-MAC [12], solves the problem of high data contentionby incorporating both CSMA (Carrier Sense MultipleAccess) and TDMA(Time Division Multiple Access)techniques. In Z-MAC, CSMA is used in low con-tention and TDMA is used in high contention. ituses DRAND [13] which assigns unique slots for theTDMA scheme in the two-hop neighborhood whichis performed at deployment. This operation is a re-source intensive task that includes neighborhood dis-covery, the operations of DRAND, and global syn-chronization. However, the overhead exhibited innodes joining and leaving the network is large andcannot be neglected. Global synchronization also in-duces an overhead in maintaining coherent timing in-formation that deteriorates the system performance.

Leach [14], [15] protocol groups sensor nodes intocluster where each node reports to the local clus-ter head. Data aggregation takes place at the localcluster head where aggregated data is sent directlyto the base station. Leach operations are dividedinto rounds where each round consists of a setup andsteady state phase. The disadvantage of Leach is thatall nodes are required to be in communication reachof a base station which is impractical for wireless sen-sor network applications. Moreover, the number ofsensors nodes and clusters formed are required to beknown a priori which limits the flexibility that char-acterizes wireless sensor networks.

In BMA [4], the cluster head forms a schedule byarranging data transfer at each round. The clusterhead accepts requests for data transfer and assigns aslot for each node wishing to transmit. Each round ofdata transfer is divided into contention, data trans-mission and idle period. Cluster formation is done byusing Leach protocol [14]. The drawback of this pro-tocol is that it permits centralized control where thecluster head is responsible for maintaining a scheduleacross nodes belonging to the same cluster. However,

in wireless sensor networks it is more efficient to havea decentralized control which eliminates single pointof failure. Moreover, nodes that have no data to sendwaste time slots in the contention period where idlelistening and overhearing occurs. Furthermore, eachsession has a fixed time for its completeness. Thus,if few nodes wish to send data, idle time is wastedthere which increase latency. Moreover, in dense de-ployment, if more nodes wish to send data, sessionsmay overlap and channel contention may occur in thedata transmission period especially if they join beforethe cluster head set up its candidate nodes.

B-MAC [16] and X-MAC [17] utilizes CCA (clearchannel assessment) to assess channel clarity andLPL (low power listening) for duty cycling the ra-dio. Channel activity is checked by measuring thesignal strength samples when the channel is assumedto be free. Nodes communicate with each other bysending a long preamble that is twice the check in-terval of the receiving nodes. Thus, nodes at sleepstate have enough to time to wake up and detect thetransmission. SCP-MAC [18] focuses on loweringthe duty cycle by combining scheduling and chan-nel polling. However, similar to previous protocols,they suffer from the problem of poor operation underabrupt high contention traffic especially in multihopscenarios.

AS-MAC [21] utilizes hello packets to build aneighborhood table. The receiver of the data packetfollows a periodic schedule that the sender is awareof. Based on this schedule Nodes wishing to send datapackets will wake up accordingly. AS-MAC uses staticclustering with is inefficient in event-based systems.Likewise, RI-MAC [19] also relies on the receiver toannounce its readiness to receive Data transmissionby sending a beacon frame. All nodes follow a pe-riodic schedule to check for pending data transmis-sion. When a beacon is received, nodes with pend-ing data start transmission. PW-MAC [20] enhancesRI-MAC by introducing a predictive wake up sched-ule on the sender side. The sender node will pre-dict the approximate time of the receivers wake-upschedule and transmit data based on that time. Al-though these MAC protocols present an enhancementon synchronous scheduled protocols, they still are notoptimized for event-based systems. EVAM-MAC isspecifically designed to address the needs of event-based systems where sensor node count per-hop ishigh. EVAM-MAC dynamically creates a contentionfree schedule each time an event is detected. EVAM-MAC achieves high throughput, maintains acceptableenergy consumption levels, and control packet over-head due to the reduced number of dropped datapackets.

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 25

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 4: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

3 EVAM-MAC Protocol De-sign

The main principle behind EVAM-MAC is to shiftcontention generated from multiple sensor nodes (inthe two-hop neighborhood) transmitting the collectedmeasurement from the data phase to the controlphase. In event-based applications for WSN such astarget tracking, sensor nodes transmit simultaneouslylarge amounts of data. Thus, dropped packets due tothe high contention generated, have a significant ef-fect on performance. Having an optimized contentionfree schedule is crucial for real time operation andenergy savings. EVAM-MAC creates a TDMA-likeschedule dynamically, and in a decentralized fashion.Furthermore, it eliminates the use of global synchro-nization that has a high overhead to maintain andsubstitutes for it with local synchronization. EVAM-MAC does not assume any infrastructure constraintsand does not require a setup phase as in hybrid pro-tocols which facilitates nodes joining and leaving thenetwork. Moreover, it prioritized the schedule basedon received signal strength (RSS) reading of the col-lected data by giving high priority for sensor nodeswith high RSS. This way sensor nodes with reliabledata can be given a higher privilege than those withlower ones which otherwise can deteriorate the con-vergence of the application.

Figure 1: Round operations

EVAM-MAC’s operation is divided into rounds asshown in Fig. 1. When an event is detected, onlysensor nodes detecting that event initiate a round.Each round is dedicated for a single event where sub-sequent events are buffered for future rounds. Thepurpose of a round is to fulfill the application layerrequirements for the successful delivery of the infor-

mation for processing. This includes the communica-tion pattern dictated by the application, such as, abroadcast of the collected data and then a unicast ofthe processed data to a dedicated node. EVAM-MACadopts a modified version of B-MACs CCA and LPLtechniques to assess channel activity and to duty cy-cle the radio. Instead of using a long preamble forLPL phase, EVAM-MAC replaces it with a train ofpackets to accommodate the CC2420 radio that isavailable on most wireless sensor motes. Once an ac-tivity is detected during LPL phase the sensor nodesstays awake for the entire round. As shown in Fig. 1,each round is divided into sub-rounds where each onehas a specific role.

3.1 Neighborhood Discovery

The main purpose of the RTS Sub-round operationis to allow nodes detecting the same event to be in-cluded in the contention-free schedule. Once an eventis detected by a group of sensor nodes that are inthe communication reach of each other the RTS sub-round timer is initiated as shown in Fig. 2. EVAM-MAC assumes that sensor nodes detecting the sameevent are in the 1-hop neighborhood of each other.This assumption is considered reasonable since thecommunication range is usually much larger than thesensing range for most applications. Only nodes de-tecting the event will start broadcasting RTS packetsto notify all nodes that a round is started. Each nodechecks for channel activity (using CCA) before trans-mitting its RTS packet. If the channel is busy, it backsoff and tries again. Nodes periodically send their RTSpackets to notify other nodes about the event. No ac-knowledgement is used for the RTS packets since eachnode detecting the event will continuously broadcastthe RTS packet regardless of any successful receptionas shown in Fig. 2. The reason behind this imple-mentation is that we don’t know a priori the numberof nodes in the communication reach of the trans-mitting node or the number of nodes detecting theevent. The RTS sub-round timer value is an applica-tion specific parameter that is provided according tothe approximate sensor count and application needs.Higher values of the RTS sub-round timer will givemore chances for nodes to be included in the sched-ule. The reason behind this is that as the sensor countincreases, collisions also increases and some nodes willnot be able to successfully broadcast their packets be-fore the round timer expires. However, care must betaken when choosing the RTS sub-round timer valuesince large values will incur unnecessary overhead andwith low values nodes may not be able to participatein the schedule.

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 26

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 5: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

Figure 2: RTS Round operations

The RTS round phase is responsible for choosingthe leader node, synchronizing neighboring nodes, dy-namically creating the cluster and constructing a pre-liminary schedule. All of these operations are per-formed simultaneously in the RTS sub-round. TheRTS packet is piggybacked with the following at-tributes:

• RSS: The received signal strength of the de-tected event (8-bits).

• Leader Node: The node with the lowest time todetect the event (8-bits).

• Recv Addr: The receiver address of the datapacket (8-bits).

• Rts Leader: Indicates if the sender node is aleader (1-bit), used for multi-hop resolution.

• TTE (Time to expire): The time required tofinish the RTS sub-round timer (16-bits).

• ID: Node ID (8-bits)

3.1.1 Leader Selection and Time Synchro-nization

Since each node detecting the event starts its RTSsub-round timer independently, time synchronizationis required for the next sub-rounds. When the sched-ule is created, each node detecting the event musthave a slot that is synchronized and unique across the2-hop neighborhood in the DATA sub-round. Oth-erwise, overlapping of data transmissions may occurwhich defies the whole purpose of EVAM-MAC (i.e.having a contention free channel for DATA transmis-sions).

EVAM-MAC implements only local synchroniza-tion each time an event is detected or a round is initi-ated. For the RTS sub-round, each node is faced with

two options, if it has detected the event or not. Anode detecting the event will have its RTS sub-roundtimer initiated and will be sending out RTS pack-ets. Moreover, it will assume leadership of this round.Leadership status has no advantages in terms of pro-cessing or capabilities. It is just a privilege granted toa node so that it can maintain synchronization andscheduling. Nodes detecting the event dynamicallyelect the Leader node. The criteria used to choosethe Leader node is the node with the earliest timeto detect the event. This value is computed by de-termining the remaining time to expire (TTE) of theRTS sub-round timer which is piggybacked with theRTS packet. Sensor nodes not detecting the eventin the two-hop neighborhood will be only receivingthe RTS packets. Moreover, these nodes will updatetheir RTS sub-round timer to be synchronized withother nodes. This step is crucial for nodes detectinga subsequent event not to interfere with an ongoinground. Furthermore, these nodes are forced to sleepfor the entire DATA sub-round if they are not the in-tended receiver of the data to be sent. When a nodereceives an RTS packet it checks first if its own RTSsub-round timer has already started. If not, it willupdate the leader node to the senders ID and startits RTS sub-round timer. The value of the timer isset in accordance to the remaining time of the RTSsub-round timer of the sender. If the RTS sub-roundtimer has already started, it will check if it shouldremain the leader. If so, it will add the senders IDto the Schedule and discard timing information. Ifthe node is not the earliest to detect the event, itwill update the leader node and its RTS sub-roundtimer. The details of the RTS sub-round is presentedin Algorithm 1

To illustrate the synchronization phase of the RTSsub-round operation, consider a 3 node topology thatis shown in Fig. 2. The details of the operations ispresented in Fig. 3. In this topology nodes 1 and3 have detected the event and node 2 is only moni-toring the round. Node 1 is the first node to detectthe event and consequently it will be the leader ofthis round. As shown in Fig. 3, the RTS sub-roundtimer of node 2 is started with the remaining portionof the Leaders RTS sub-round timer minus the timeto receive an RTS packet (TTR). TTR also includeany processing delays exhibited at the receiver andthe sender. These delays can be approximated basedon the sensor nodes platform. Node 3 will have torelinquish its leadership status and it will update itstimer based on the value received from node 1 mi-nus TTR. Nodes 1 and 3 will keep on broadcastingRTS packets until the RTS sub-round timer expireswhere both carry the same leader and TTE informa-

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 27

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 6: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

tion. All nodes receiving RTS packets will have theirtimer value expiring at the same time and these nodeswill be ready for the subsequent round.

Algorithm 1 EVAM-MAC RTS sub-round opera-tions

Duty Cycle(Node(i))if EventDetected then

if RTS STARTED == FALSE thenRTS Timer.start(RTS ROUND)Leader Node = icreateRTSPacket(RSS,LEADER Node,Rts Leader,Recv Addr, TTE, ID)if RTS Timer.Expired() == FALSE then

sendRTSTrain()end if

elsecreateRTSPacket(RSS,LEADER Node,Rts Leader,Recv Addr, TTE, ID)if RTS Timer.Expired() == FALSE then

sendRTSTrain()end if

end ifend ifif Received(RTS PACKET) then

if RTS STARTED == FALSE then{didnot detect the event}RTS Timer.start(RTS ROUND−RTS Packet.TTE − TTR){TTR: time to receive RTS packet}Leader Node = RTS Packet.Rts LeaderAddNodeToSchedule(RTS Packet.ID,RTS Packet.Recv Addr,RTS Packet.RSS){arrange schedule in decreasing order of RSS, savedestination address of the data packet}

elseTTE Recv = RTS ROUND −RTS Packet.TTE − TTRif TTE Recv < TTE then

RTS Timer.update(TTE Recv)LeaderNode = RTS Packet.RtsLeaderAddNodeToSchedule(RTS Packet.ID,RTS Packet.Recv Addr,RTS Packet.RSS)

elseAddNodeToSchedule(RTS Packet.ID,RTS Packet.Recv Addr,RTS Packet.RSS)

end ifend if

end if

3.1.2 Dynamic Clustering and Schedule Cre-ation

Most event-based WSN applications are based oncluster topology. This is mainly due to that fact thatredundant measurements are collected by the nodesdetecting the same event. It is inefficient to broad-

cast all collected data across the network as it wastedunnecessary bandwidth and exhibits an overhead inenergy consumption. Data is usually aggregated onthe local cluster head before it is broadcasted to thebase station. Clustering is usually static or dynamic.With static clustering, nodes arrange themselves intogroups based on the communication range. On thehand, dynamic clustering is achieved by creating agroup each time an event is detected. Although staticclustering has a lower overhand in creation, dynamicclustering is more efficient. This is mainly becausethe sensing range is much smaller than the communi-cation range in most applications. Moreover, as theevent is traversing the sensor field and arriving at theboundaries of two or more clusters, nodes detectingthe event will deliver their data to different clusterheads. This has the effect of increasing congestion anddeteriorating the application performance. Moreover,dynamic clustering eliminates single points of failureand minimizes the overhead of nodes joining or leav-ing the network. In our implementation, the electedleader node acts as a cluster head every time an eventis detected.

Figure 3: Locally synchronizing nodes and leader se-lection: All nodes are synchronized with the timervalue of the leader at 1

EVAM-MAC achieves dynamic clustering in theRTS sub-round. The cluster is created by the nodesthat detected the event. As shown in Algorithm 1,when a node receives an RTS packet, it add the sourceaddress of the packet to the virtual cluster. Moreover,it saves the RSS of the event detected and the receiveraddress. At the end of the RTS sub-round, each nodedetecting the event will generate the list of nodes thatare participating in the event in a decentralized fash-ion. The schedule for the data sub-round is createdby assigning a slot for each node in decreasing order ofthe RSS. If two nodes have the same RSS values, lowerID nodes will win the slot. Although the leader node

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 28

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 7: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

is guaranteed to be unique within all nodes, the neigh-borhood list may have some variations from node tonode depending on the level of congestion. This ismainly because not all sensor nodes will receive allRTS packets. The disambiguation in the schedule be-tween the nodes is resolved in the Leader and Addsub-rounds.

3.2 Leader, Add and Data Sub-rounds

As shown in Fig. 1, four sub-rounds follow theRTS sub-round: Leader sub-round-1, Add sub-round,Leader sub-round-2, and the Data sub-round. Thedetails of these four sub-rounds is presented in Algo-rithm 2. The purpose of the Leader sub-rounds is toresolve the discrepancies between schedules that werecreated independently by sensor nodes detecting thesame event. This sub-round has a predefined valuethat is known to all sensor nodes during which allnodes are awake and only the elected leader node isallowed to transmit. The leader node will send out aLeader packet that contains its own created schedule.Each node receiving this packet will discard its cre-ated schedule and adopts the leaders schedule. Thereason why all nodes create a schedule dynamicallyis that we dont know a priori the ID of the electedleader. The dynamic nature of EVAM-MAC offers theability for all nodes to be a leader node provided thatthey have the lowest time to detect the event. Thisinformation is not resolved until the RTS sub-roundtimer expires.

When nodes receive the Leader packet, they willcheck if their ID is present in the schedule providedthat they have detected the event. If their ID werenot found, they have the opportunity to add it in theAdd sub-round. Nodes that have their ID present inthe schedule are forced to sleep for the entire value ofthe Add sub-round thus reducing overhearing. TheAdd packet contains the senders ID and the intendedreceiver of the data packet. Once the leader receivesthis packet, it will add the ID of the sender at the endof the schedule. An Acknowledgment packet is sentout to the sender to restrain the node from sendingthe Add packet again.

As with all sub-round timers, the add sub-roundtimer is used to synchronize EVAM-MAC sub-rounds.The value of the Add sub-round timer is based onstatistics done on the topology of the sensor nodes.EVAM-MAC assign the value of the add sub-roundtimer to be 10% of the RTS sub-round timer. Al-though the add sub-round exhibits an overhead onEVAM-MACs round operations, its existence en-hances the overall performance. Depending on thelevel of congestion, some sensor nodes will not have

a chance to be included in the schedule especially indense topologies. These nodes will have to start an-other round for the same event which exhibits a muchlarger overhead than the add sub-round. Increasingthe value of the RTS sub-round timer will not have thesame effect since in that sub-round all sensor nodeswill continuously be sending out RTS packets in ahigh contention environment. In the Add sub-round,only sensor nodes that are not included in the sched-ule send out the Add packet. Thus, nodes are giventhe opportunity to send out their missing packets inan environment with less contention.

At the end of the Add sub-round, all nodes willwake in preparation for the Leader sub-round-2. Thisphase has the same effect and operation of Leadersub-round-1. The appended schedule is sent out toall sensor nodes in the communication reach and eachnode updates its schedule information. After thesecond leader phase the data sub-round is initiated.The data sub-round is divided into slots. The slot isgranted for nodes that are included in the final sched-ule. Each node has a unique slot that is guaranteedto be free across the two-hop neighborhood (as shownin the next section). Thus, the total value of theData sub-round timer varies from round to round de-pending on the number of nodes detecting the event.Nodes that did not detect the event and are not the in-tended receiver of any Data packet are forced to sleepfor the entire Data sub-round. During each slot onlythe sending node and the receiving node are awake,thus reducing idle listening. In case of a broadcastall nodes in the cluster will be awake to receive thedata. As opposed to TDMA like protocols, there areno wasted slots here. Only nodes that have data tosend are included in the schedule which reduces la-tency. The slot size is computed according to the sizeof the data packet. Although the medium is consid-ered to be free, an optional ACK packet can be sentduring the slot time to ensure delivery. Nodes thatdid not receive an ACK packet will participate in thenext round to send their captured data again.

3.3 Multi-hop resolution

Multi-hop networks poses a threat on the correctnessof EVAM-MAC since intersecting cluster as shownin Fig. 4 can introduce ambiguity in schedule infor-mation of each cluster. To resolve this issue, onlyone cluster in the two-hop neighborhood of the leadernode is allowed to transmit at a time. Each time acluster terminates its round, the remaining intersect-ing clusters contend for the current round at the RTSsub-round as shown later. Usually in event-based sys-tems for wireless sensor networks, the sensing range

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 29

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 8: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

is much smaller than the communication range. Thusin real deployments, sensors detecting the event willyield small sparse disconnected clusters with no in-terference between them. Events occurring in sparseclusters have no effect on the operations of EVAM-MAC. Events occurring interchangeably (i.e. not atthe same time) in intersecting clusters, as shown inFig. 4, also have no effect on the correctness of EVAM-MAC provided one round finishes before the other.Moreover, nodes detecting an event after the RTSsub-round timer of the neighboring cluster expires,will be aware of that round and will not initiate ituntil the current round is finished.

Figure 4: Two hop scenarios

As shown earlier, all nodes detecting the event willbroadcast the RTS packet to all neighboring nodes.Nodes belonging to two clusters (as shown in Fig. 4,scenario one) and/or are in the communication rangeof some nodes in each cluster (as shown in Fig. 4, sce-nario two) will notify each other by the RTS packets.Consider the case shown in Fig. 4, scenario one. As-sume that Cluster A detects the event before ClusterB and that the latter detects the event any time af-ter the RTS sub-round timer of the former expires.The intersecting node will broadcast its RTS packetto all the nodes in Cluster B that is in its communica-tion reach within the duration of the RTS sub-roundtimer. These nodes will start their RTS sub-roundtimer upon the reception of the RTS packet from theintersecting node. When the RTS sub-round timerexpires, these nodes will wait for the leader node totransmit its Leader packet. However, the leader nodeis not in communication reach of the nodes in Clus-ter B. The reason behind this is that nodes that canoverhear the leader node will belong to the cluster ofthe leader which is Cluster A. After the Leader sub-round expires, these nodes will not receive a Leaderpacket. They will then raise a multi hop flag and willbe forced to sleep for the entire duration of the nextsub-rounds. However, these nodes have no informa-tion about the duration of the Data sub-round since

the number of sensors in the schedule of cluster A isunknown to them. In order to relieve any possibleinterference, the amount of time assigned to the Datasub-round for nodes in Cluster B are given the max-imum value which is equal to the time to transmita DATA packet times the maximum number a clus-ter can attain. Although this technique introducesdelays, it is more efficient than actually forcing thenode to contend for the medium as it will introduceinterference on the transmitting nodes in Cluster A.Moreover, it will reduce overhearing thus achievinghigher energy efficiency. The maximum number anycluster can attain can be obtained before deploymentby approximating the number of sensors that are incommunication reach of each other. Any event oc-curring at cluster B after the RTS sub-round timerexpires will be buffered until nodes in Cluster B arewoken up. After the sleep timer expires, all nodes willrepeat the whole operation again.

On the other hand, multiple events can occur si-multaneously between neighboring clusters before theRTS sub-round timer expires. In this case all clustersin the communication range of each other contendto win the round. The cluster with the lowest TTE(time to expire) will win this round. If both clus-ters have equal TTE, the lowest ID leader node willwin the round. All other clusters are forced to sleepfor the entire round and defer their data transfer tothe subsequent round. Consider the case shown inFig. 4, scenario two. Following the same analogy asbefore, each node detecting the event will start theirRTS sub-round timer and broadcast periodically theRTS packet. Let’s assume that Clusters B detects theevent before Cluster A. The nodes that are in commu-nication reach of Cluster B will hear the RTS packetand update their leader and TTE information. Thesenodes will then broadcast their RTS packets piggy-backed with the new information. However, care mustbe taken to choose an RTS sub-round timer valuethat is large enough to make this propagation possi-ble. Upon a successful broadcast of an RTS packetof the leader node at Cluster B, any of the boundarynodes will notify Cluster A with the existence of theother round by also broadcasting a RTS packet. Asdiscussed earlier, the cluster will shut down for theentire round for the duration of the following sub-rounds where the Data sub-round has the maximumvalue. Nodes belonging to Cluster A will commencetheir round operation after the sleep timer expires.

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 30

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 9: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

Algorithm 2 EVAM-MAC Leader, Add, Data sub-rounds operations

if RTS Timer.Expired() == TRUE thenLeader1 Timer.Start()if IsLeader() then

createLeaderPacket(Schedule[0, 1, ..., n])sendLeaderPacket()

end ifend ifif Leader1 Timer.Expired() == TRUE then

AddTimer.start()if CheckNodeID(Schedule) == TRUE then

sleep()else

createAddPacket(ID, Recv Addr)while ACKNotReceived() do

sendADDPacket(LeaderNode)end while

end ifend ifif Add Timer.Expired() == TRUE then

wakeup()Leader2 Timer.Start()if IsLeader() then

createLeaderPacket(Schedule[0, 1, ..., n+appenedNodes])sendLeaderPacket()

end ifend ifif Leader2 Timer.Expired() == TRUE then

CheckSchedule()if CheckNodeID(Schedule) == FALSE then

sleep()else

wakeup(SlotID)if IsSender() then

sendData()end if

end ifend ifif Received.LeaderPkt() then

Schedule = LeaderPkt.Scheduleelse if Received.AddPkt() then

Schedule.append(AddPkt.ID)end if

In the case where we have more than two adja-cent cluster as shown in Fig. 4, scenario three, bothCluster A and C are forced to sleep provided thatCluster C detected the event after Cluster B. Con-sider the case where Cluster A detect the event firstthen Cluster C and lastly Cluster B. Provided enoughtime is given for the RTS sub-round timer, Cluster Cwill also be forced to sleep. However, Cluster C cancommence a round in parallel with Cluster A withno interference since Cluster B is forced to sleep. A

mechanism must be devised to notify Cluster C thatit can commence its round operations. In this con-text, a bit (RTS Leader) is piggybacked with the RTSpacket that is set if the RTS packet was received fromthe actual Leader node and unset if the packet wasforwarded from another node that is not the Leadernode. However, if a node received a RTS packetfrom the Leader node once, it will always set theRTS Leader bit disregarding any forwarded packetswith the same Leader address and TTE information.Cluster B will forward the RTS packets to Cluster Cwith the RTS Leader bit unset. Upon the receptionof the forwarded RTS packet, Cluster C will detectthat the RTS Leader bit is unset and will disregardthe Leader and TTE information and commence withits round. Thus the two Clusters (A and C) can op-erate in parallel. The disadvantage of this techniqueis that if Cluster B detects the event before ClusterC and the RTS packets from Cluster A didn’t haveenough time to reach Cluster C, Cluster C has noway of knowing the existence of Cluster A and as-sumes that its Cluster B’s turn. Thus, it has to waitfor the next round to operate.

3.4 EVAM-MAC Programmable fea-tures

The dynamic nature of EVAM-MAC makes it cus-tomizable for the applications needs and require-ments. Programmable feature is an option that isimplemented in EVAM-MAC that allows customiz-able Data sub-rounds. These options can be set bythe application layer at deployment. The default op-eration of EVAM-MAC is to unicast the data packetto the elected cluster head which will forward them tothe sink. However, some applications require severalrounds of communications provided by the same sen-sor nodes detecting the event. These rounds can bea mixture of broadcast and unicast. In target local-ization applications, sensor nodes usually broadcastthe collected measurement to the all sensor nodes de-tecting the target for processing. Once a location iscomputed, each sensor node will unicast the resultsback to the cluster head for aggregation. These opera-tions can be programmed in EVAM-MAC where eachround consists of 2 data sub-rounds, one for broad-cast and the other for unicast. Multiple data roundscan be added depending on the applications needs.In this case the same schedule is used over again withthe desired communication pattern. The overhead formultiple rounds is much lower than those of a singleround with respect to the amount of Data transfersince the amount of control packet exchanged stayedthe same. Thus, by lowering the control overhead

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 31

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 10: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

that is required to construct the data sub-rounds,and giving the application designers the freedom tochoose their communication patterns and operations,optimizations can be achieved in throughput, energyconsumption and control overhead.

Restraining sensor nodes transmissions is anotherprogrammable feature that is resourceful in WSN ap-plication. In dense deployments, sensor nodes col-lect several measurements for the same event thatare highly correlated. Some applications require onlya subset of sensor nodes detecting a certain type ofevent to transmit its collected data. For an example,consider a 15-node cluster monitoring a certain event.The application layer can be satisfied with only 5-highquality measurements. The number of measurementsrequired and the criteria used to indicate the qual-ity of the measurements is based on the application.EVAM-MAC arranges data schedule based on RSSof the event detected. If this feature is enabled, theLeader node will broadcast a schedule containing onlythe required sensor nodes disregarding the rest. Uponthe reception of the Leader packet, the sensor nodeswill check if their ID is present in the schedule. Whenthey realize that they are off the schedule, they forcethemselves to sleep for the entire Data sub-rounds.This way we achieve higher energy conservation byprohibiting all remaining sensors from transmittingtheir redundant Data packets.

4 Experimentation and Simula-tion Results

EVAM-MAC was implemented and simulated usingNetwork simulator (NS-2 [10]). Furthermore, EVAM-MAC is compared with an NS-2 implementation ofS-MAC [2] and 802.11 [11], for one-hop, two-hop andmulti-hop benchmarks. As shown in Table I, the com-munication bandwidth used for all benchmarks was19.2kbs and the DATA packet payload was 60 Bytes.The RTS sub-round timer was assigned a value of200ms for one-hop networks and 300ms for multi-hop networks since in multi-hop networks more timeis required at the RTS sub-round phase to propagatethe RTS packet to neighboring clusters. The Leaderand Add phases are fixed to 11ms and 22ms. Allsub-round values depend on the communication band-width. Higher bandwidth values will yield smallersub-round values. Table II presents a comparison ofthe control packet sizes for all three protocols. TheLeader packet of EVAM-MAC has a large value of27 bytes since it contains the piggybacked schedule.However, the Leader packet is only broadcasted twiceper round.

Three metrics were used to compare EVAM-MAC’s performance with other protocols: netthroughput, average energy consumption, and per-centage of control packet overhead for all three bench-marks. The net throughput is computed by countingthe number of DATA packets successfully received bythe sink where only the payload is considered. Theaverage energy consumption is computed by averag-ing the energy consumed by all nodes in the networkand dividing it by the total sensor count for the dura-tion of the simulation run. The percentage of controlpacket overhead is computed by averaging the num-ber of control packet bytes sent for all nodes in thenetwork with respect to the number of data bytes suc-cessfully received by the sink. For all three metrics,the setup phase of S-MAC was not included in thecomputation since it is an overhead that occurs onlyat deployment. However, the sync messages used af-ter the nodes are synchronized are considered in thecomputations.

Table 1: Default Parmeters for EVAM-MAC protocol

RTS-subround one-hop 200 ms

RTS-subround multi-hop 300 ms

Leader sub-round 11 ms

ADD sub-round 22 ms

DATA sub-round Variable

Data Payload 60 Bytes

Communication Bandwidth 19.2 kbs

Table 2: Packet Size Information for Differnet Proto-cols

Type EVAM-MAC S-MAC 802.11

RTS 16 Bytes 10 Bytes 44 Bytes

CTS NA 10 Bytes 38 Bytes

Leader 27 Bytes NA NA

ADD 5 Bytes NA NA

Sync NA 10 Bytes NA

ACK 5 Bytes 10 Bytes 38 Bytes

4.1 One-hop Benchmarks

The one-hop benchmarks consist of 20 nodes whichare all in the communication range of each other andof a sink. Two applications were employed for thisevaluation. The first application is a UDP (UserDatagram Protocol) agent with a CBR (constant bit

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 32

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 11: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

0

2

4

6

8

10

12

2 4 6 8 10 12 14 16 18 20

Net

Thr

ough

put(k

bps)

Number of Nodes

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(a) Throughput wrt sensor count

50

100

150

200

250

300

350

400

2 4 6 8 10 12 14 16 18 20

Ave

rage

Ene

rgy

(J)

Number of Nodes

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(b) Avg. eng. wrt sensor count

0.5

0.55

0.6

0.65

0.7

0.75

0.8

0.85

0.9

0.95

1

2 4 6 8 10 12 14 16 18 20

Perc

enta

ge C

ontro

l Ove

rhea

d

Number of Nodes

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(c) % of all control pkts sent

Figure 5: One-hop simulations for nodes with CBR and UDP agents Traffic rate = 8 pps

0

1

2

3

4

5

6

7

8

9

10

0 2 4 6 8 10 12

Ave

rage

Net

Thr

ough

put (

kbps

)

Packets per Second (pps)

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(a) Throughput wrt sensor count

0

50

100

150

200

250

300

350

400

0 2 4 6 8 10 12

Ave

rage

Ene

rgy

Cons

umpt

ion

(J)

Packets per Second (pps)

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(b) Avg. eng. wrt sensor count

0.65

0.7

0.75

0.8

0.85

0.9

0.95

0 2 4 6 8 10 12

Perc

enta

ge C

ontro

l Ove

rhea

d

Packets per Second (pps)

EVAM-MACS-MAC 10% Duty

S-MAC No Duty802.11

(c) % of all control pkts sent

Figure 6: One-hop simulations for nodes with CBR and UDP agents Number of nodes = 10

rate) traffic generator. All nodes generate traffic atapproximately similar time and unicast their data di-rectly to the sink. Two simulation experiments wereperformed. In the first experiment, the sensor countis increased from 2 to 20 while the data traffic is keptconstant to a value of 8 packets per second. As shownin Fig. 5a, the net throughput is compared for dif-ferent MAC protocols as a function of sensor count.EVAM-MAC produces an exponential growth fromsensor count 2 to 15 while it saturates around 10kbs.S-MAC was operated with a 10% duty cycle where itsperformance is the worst since the overhead of syn-chronization deteriorates the throughput severely. S-MAC with no duty cycle and 802.11 achieve similarperformance. EVAM-MAC achieves higher through-put than all other protocols when the sensor countincrease above 5. This is because the RTS sub-roundtimer is fixed to a value taking into account that 20nodes may have data to send at the same time. When5 nodes or less are transmitting, the RTS sub-roundtimer is large enough to lowers the throughput. How-ever, EVAM-MAC is tailored for high sensor countand traffic application. Moreover, as shown in Fig. 5b,EVAM-MAC has the lowest energy consumed withrespect to all MAC protocols. Fig. 5c, shows theaverage percentage of control packets sent by eachMAC protocol of all nodes with respect to all packets

sent. EVAM-MAC has the lowest control overheadas sensor count increases above 9 nodes. This is dueto the fact that the percentage of control bytes sentstays constant since the RTS sub-round timer is fixedwhile the number of DATA bytes increases. In the sec-ond experiment we fixed the number of nodes to 10and we varied the number of packets sent per secondsfrom 1pps to 12pps. This experiment is performedto evaluate EVAM-MAC from low to high traffic con-ditions. As shown in Fig. 6a, the net throughput ofEVAM-MAC is superior to all other protocol whenthe traffic generated by each node is equal or greaterto 2pps. EVAM-MAC is also superior to all proto-cols compared in terms of energy consumed as shownin Fig. 6b, and percentage of control overhead sentshown in Fig. 6c. This proves the effectiveness ofEVAM-MAC in both high sensor count and high traf-fic application in single hop networks.

The second application is a simulated event basedsystem where nodes detecting an event are required tobroadcast their Data packets to all nodes. After eachnode receives a data packet from every other nodedetecting the event it will unicast a Data packet tothe sink. However, the number of nodes detecting theevent is required to be known so that nodes receivingthe broadcast information know when to unicast itsData packet. For EVAM-MAC, the number of nodesdetecting the event can be known from the collected

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 33

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 12: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

RTS packets. However, for S-MAC protocol, nodeswill have no a priori information about the number ofnodes detecting the event. In this scenario, we assumea fixed number of nodes that is supplied to them atdeployment. In real deployment, S-MAC will have toexchange some packets to know the number of nodesdetecting the event. This will incur an overhead in en-ergy consumption and will increase latency. EVAM-MAC uses the two round programmable feature thatwas discussed in Section 3.4. As shown in Fig. 6a, thenet throughput is compared as the number of nodesdetecting the event increases. EVAM-MAC through-put growth is exponential which reaches a value of12kbs. EVAM-MAC’s performance is superior to S-MAC when the sensor count increase above 5. Fur-thermore, as shown in Fig. 6b and Fig. 6c, EVAM-MAC has similar energy consumption values and con-trol packet overhead to that of SMAC with 10% dutycycle. Thus, EVAM-MAC can achieve nearly doublethe throughput of S-MAC with no duty cycle with thesame value of energy spent and control packet sent ofS-MAC with 10% duty cycle.

4.2 Two-hop Benchmarks

To prove the correctness of EVAM-MAC for two hopscenarios, we simulated the proposed algorithm forscenarios 1 and 2 shown in Fig. 4. In both scenar-ios, detected event forms two clusters simultaneouslywhere the maximum number of nodes in each clusteris equal to 12. In scenario 1, one node is in commu-nication range of both clusters. In scenario 2, threenodes are in the interference range of both clusters.Each cluster has a sink that is in communication reachof all nodes belonging to that cluster. When an eventis detecting all nodes will unicast their Data packetsto the sink of the corresponding cluster. As shownin Fig. 7a, d, the net throughput is compared as thenumber of sensors detecting the event increases atboth clusters. All protocols show a linear increase asthe number of sensors detecting the event increases.However, EVAM-MAC presents superiority when thesensor count is around 16, which translates to 8 sen-sor nodes per cluster. The reason behind this is thatEVAM-MAC shuts down the whole cluster while theother cluster is delivering data. As the number ofsensor nodes in each cluster reaches 8, it becomesworthwhile to shut down the cluster as the contentionproduced from two neighboring clusters introduces la-tency. In Fig. 7b, e, the average energy consumed ofEVAM-MAC has close performance with respect toS-MAC with no duty cycle. 802.11 has the worstenergy consumed with respect to all compared pro-tocols. Moreover, EVAM-MAC has greater control

packet overhead with respect to S-MAC (no duty cy-cle) as shown in Fig. 7c, where 802.11 has also theworst performance. However, this overhead is com-pensated for by the reduced number of dropped datapacket which is evident in Fig. 7b,e.

4.3 Multi-hop Benchmarks

Figure 8: Multihop Layout

To evaluate EVAM-MAC in a multi-hop scenario, theproposed algorithm was simulated in a 60 node net-work as shown in Fig. 8. The maximum number ofnodes detecting the event simultaneously is equal to50. Four clusters exist as shown in Fig. 8 where clus-ter A, B and C are 4 hops away from the sink andeach contain 12 nodes. Cluster D is 5 hops away fromthe sink and contains 10 nodes. To eliminate theoverhead of routing, fixed routing tables were sup-plied to the nodes. Each node detecting the eventwill unicast its data to the local sink. Upon the re-ception of all data packet for all nodes detecting theevent, the local sink will forward the aggregated Datapacket through several hops until it reaches the fi-nal sink as shown in Fig. 8. Four metrics were usedfor this simulation: net throughput, average energyconsumed, average control packet overhead and aver-age latency. The average latency is the average timethat all nodes take to transmit their packet to thefinal sink. As shown in Fig. 9a, we evaluated EVAM-MAC’s throughput as a function of the number of

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 34

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 13: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

0

1

2

3

4

5

6

7

8

9

0 5 10 15 20 25

Net

Thr

ough

put (

kbps

)

Number of contender Nodes

EVAM-MACS-MAC No Duty

802.11

(a) Throughput wrt sensor count (sce-nario 1)

0

2

4

6

8

10

12

14

16

0 5 10 15 20 25 30

Ave

rage

Ene

rgy

Cons

umpt

ion

(J)

Number of contender Nodes

EVAM-MACSMAC No Duty

802.11

(b) Avg energy consumed wrt sensorcount (scenario 1)

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65

0.7

0.75

0.8

0 5 10 15 20 25

Perc

enta

ge C

ontro

l Ove

rhea

d

Number of contender Nodes

EVAM-MACSMAC No Duty

802.11

(c) Percentage of all control pkts sent(scenario 1)

0

1

2

3

4

5

6

7

8

0 5 10 15 20 25

Net

Thr

ough

put(k

bps)

Number of contender Nodes

EVAM-MACS-MAC No Duty

802.11

(d) Throughput wrt sensor count (sce-nario 2)

0

2

4

6

8

10

12

14

16

0 5 10 15 20 25 30

Ave

rage

Ene

rgy

Cons

umpt

ion(

mJ)

Number of contender Nodes

EVAM-MACSMAC No Duty

802.11

(e) Avg energy consumed wrt sensorcount (scenario 2)

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65

0.7

0.75

0.8

0 5 10 15 20 25

Perc

enta

ge C

ontro

l Ove

rhea

d

Number of contender Nodes

EVAM-MACSMAC No Duty

802.11

(f) Percentage of all control pkts sent(scenario 2)

Figure 7: Two hop simulations for an event based system

0

2

4

6

8

10

12

0 5 10 15 20 25 30 35 40 45 50

Net

Thr

ough

put (

kbps

)

Number of contender Nodes

EVAM-MACS-MAC No Duty

(a) Throughput in multi-hop Scenario

0

0.2

0.4

0.6

0.8

1

1.2

1.4

0 5 10 15 20 25 30 35 40 45 50

Ave

rage

Ene

rgy

Cons

umpt

ion

(J)

Number of contender Nodes

EVAM-MACS-MAC No Duty

(b) Average Energy Consumption

0

0.05

0.1

0.15

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0 5 10 15 20 25 30 35 40 45 50

Perc

enta

ge C

ontro

l Ove

rhea

d

Number of contender Nodes

EVAM-MACS-MAC No Duty

(c) Percentage of control overhead

0

0.5

1

1.5

2

2.5

3

3.5

4

4.5

5

0 5 10 15 20 25 30 35 40 45 50

Late

ncy

(s)

Number of contender Nodes

EVAM-MACS-MAC No Duty

(d) Total Latency in (s)

Figure 9: Multihop Simulation

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 35

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 14: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

sensors detecting the event. EVAM-MAC achieveshigher throughput than S-MAC with no duty cycleas the number of sensors detecting the event growsabove 15. We didn’t compare our protocols with S-MAC with duty cycle since it is not scalable to thisamount of nodes. Fig. 9b presents the average energyconsumed by all nodes as sensor count increases. Ini-tially, EVAM-MAC has similar performance as that ofS-MAC with no duty cycle. However, when the sen-sor count increases above 25 EVAM-MAC has lowerenergy consumption. On the other hand, the controlpacket overhead of EVAM-MAC is higher than thatof S-MAC as shown in Fig. 9c. However, this over-head didn’t reflect negatively on energy consumptionsince the percentage of dropped packets is greatly re-duced with EVAM-MAC. Moreover, EVAM-MAC haslower latency than S-MAC as shown in Fig. 9d. Whenthe number of sensors detecting the event reaches 50,EVAM-MAC has a 3 to 1 advantage over S-MACin latency. Thus, EVAM-MAC achieves lower la-tency and higher throughput without introducing abig overhead in energy consumption and control pack-ets sent. EVAM-MAC is very desirable in event basedsystems as it reliefs contention from multiple nodescontending for the Data packet delivery.

5 Conclusion and Future Work

In this work a novel MAC protocol tailored for eventbased systems for wireless sensor networks is pre-sented. EVAM-MAC creates a contention free sched-ule for the collected measurements for transmission ina dynamic decentralized fashion. EVAM-MAC doesnot require any global synchronization or setup phaseat deployment. This has the advantage of eliminatingthe overhead of nodes joining and leaving the net-work. EVAM-MAC shifts the contention generatedby multiple sensor nodes detecting an event from theData phase to the control phase where packet sizes aremuch smaller in size. Furthermore, EVAM-MAC pro-vides a rich platform of programmable features thatthe application designers can utilize to achieve highperformance operations. EVAM-MAC presented itssuperiority in throughput and energy conservation forsingle and multi hop scenarios when compared withS-MAC and 802.11.

Our future work includes performing a real wire-less sensor implementation on wireless sensor motes.EVAM-MAC will be tested on target localization ap-plication for wireless sensor networks. Furthermore,more simulations and experimentation with differ-ent topologies and higher sensor count is being per-formed.

References

[1] P. Suriyachai, U. Roedig, A. Scott,”A Surveyof MAC Protocols for Mission-Critical Applica-tions in Wireless Sensor Networks”, In IEEECommunications Surveys & Tutorials , vol.14,no.2, pp.240-264, Second Quarter 2012, doi:10.1109/SURV.2011.020211.00036

[2] W. Ye, J. Heidemann, and D. Estrin, ”AnEnergy-Efficient Mac Protocol for WirelessSensor Networks”, Proc. IEEE Conf. Com-puter and Communications Societies (INFO-COM 2002), vol. 3, pp. 1567-1567, Jun. 2002,doi: 10.1109/INFCOM.2002.1019408.

[3] T.V. Dam and K. Langendoen, ”An AdaptiveEnergy-Efficient Mac Protocol for Wireless Sen-sor Networks”, Proc. ACM Conf. EmbeddedNetworked Sensor Systems (SENSYS ’03), pp.171-180, Nov. 2003, doi: 10.1145/958491.958512.

[4] J. Polastre, J. Hill, D. Culler, ”Versatile LowPower Media Access for Wireless Sensor Net-works”, Proc. ACM Conf. Embedded NetworkedSensor Systems (SENSYS ’04), pp. 95-107, Nov.2004, doi: 10.1145/1031495.1031508.

[5] W. Ye, J. Heidemann, and D. Estrin. Mediumaccess control with coordinated adaptive sleep-ing for wireless sensor networks. IEEE/ACMTrans. Netw., 12(3):493-506, 2004. doi:10.1109/TNET.2004.828953

[6] Shams ur Rahman, Mushtaq Ahmad, ShafaatA. Bazaz, ”A new Energy-Efficient TDMA-basedMAC Protocol for Periodic Sensing Applicationsin Wireless Sensor Networks”, In IJCSI Interna-tional Journal of Computer Science Issues, Vol.9, Issue 4, No 1, July 2012.

[7] I. Rhee et al., ” Z-MAC: a hybrid MAC for wire-less sensor networks”, Proc. ACM Conf. Embed-ded Networked Sensor Systems (SENSYS ’05),pp. 90-101, Nov. 2005, doi: 1098918.1098929.

[8] Z. Merhi, M. Elgamel, and M. Bayoumi,”EVA-MAC:An EVent based Medium AccessControl for Wireless Sensor Networks”, Proc.of the IEEE Workshop on Signal Process-ing Systems (SiPs2011), pp. 61-66, Oct. 2011,doi:10.1109/SiPS.2011.6088950

[9] Z. Merhi, M. Elgamel, and M. Bayoumi, ”ALightweight Collaborative Fault Tolerant Tar-get Localization System for Wireless Sensor Net-

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 36

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 15: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

works,” IEEE Transactions on Mobile Com-puting, 29 Apr. 2009. IEEE computer SocietyDigital Library. IEEE Computer Society, doi:10.1109/TMC.2009.81

[10] The Network Simulator NS-2,http://www.isi.edu/nsnam/ns/, 2009.

[11] LAN MAN Standards Committee of the IEEEComputer Society, ”Wireless LAN medium ac-cess control (MAC) and physical layer (PHY)specification”, IEEE, New York, NY, USA, IEEEStd 802.11-1997 edition, 1997.

[12] G. Ahn et al., ” Funneling-MAC: a localized,sink-oriented MAC for boosting fidelity in sen-sor networks”, Proc. ACM Conf. Embedded Net-worked Sensor Systems (SENSYS ’06), pp. 293-306, Nov. 2006, doi: 10.1145/1182807.1182837.

[13] I. Rhee, A. Warrier and L. Xu, ” Randomizeddining philosophers to TDMA scheduling in wire-less sensor networks” Technical report, Com-puter Science Department, North Carolina StateUniversity, Raleigh, NC, 2004.

[14] W. B. Heinzelman , A. P. Chandrakasan,and H. Balakrishman, An application-specificprotocol architecture for wireless microsen-sor networks, IEEE Trans. Wireless Com-munication, vol. 1, pp. 660670, Oct. 2002,doi:10.1109/TWC.2002.804190.

[15] Chunyao FU et. al, ”An Energy Balanced Algo-rithm of LEACH Protocol in WSN” in IJCSI In-ternational Journal of Computer Science Issues,Vol. 10, Issue 1, No 1, January 2013.

[16] J. Polastre, J. Hill, D. Culler, ”Versatile LowPower Media Access for Wireless Sensor Net-works”, Proc. ACM Conf. Embedded NetworkedSensor Systems (SENSYS ’04), pp. 95-107, Nov.2004, doi: 10.1145/1031495.1031508.

[17] M. Buettner et al.,” X-MAC: A Short PreambleMAC Protocol For Duty-Cycled Wireless SensorNetworks”, In Proc. of 5th ACM Conference onEmbedded Networked Sensor Systems (SenSys2006), November 2006.

[18] W. Ye, F. Silva, and J. Heidemann,” Ultra-Low Duty Cycle MAC with Scheduled ChannelPolling” In Proc. of 5th ACM Conference onEmbedded Networked Sensor Systems (SenSys2006), November 2006.

[19] Yanjun Sun, Omer Gurewitz, and David B.Johnson. ”RI-MAC: A receiver initiated asyn-chronous duty cycle MAC protocol for dy-namic traffic loads in wireless sensor networks”.In Proc. of 6th ACM Conference on Embed-ded Networked Sensor Systems (SenSys’08),2008.do:10.1145/1460412.1460414

[20] Lei Tang, Yanjun Sun, O. Gurewitz, D.B. John-son, ”PW-MAC: An energy-efficient predictive-wakeup MAC protocol for wireless sensor net-works,” In Proc. of the 30th IEEE InternationalConference on Computer Communications ((IN-FOCOM 2011), pp.1305-1313, 10-15 April 2011,doi: 10.1109/INFCOM.2011.5934913

[21] Beakcheol Janga, Jun Bum Limb, Mihail L. Si-chitiuc, ”An asynchronous scheduled MAC pro-tocol for wireless sensor networks” In ElsevierJournal on Computer Networks, 2012

Zaher M. Merhi received the B.Sc. degree and theM.Sc. degree in computer engineering from the Uni-versity of Balamand, Lebanon, in 2002 and 2005. Healso received the M.Sc. and the PhD degree in com-puter engineering from the University of Louisianaat Lafayette, USA, in 2007 and 2010. Since 2010 hejoined the Lebanese International University (LIU) asan assistant professor at the computer and commu-nication engineering (CCE) department. Currentlyhe is the associate chairperson of the CCE depart-ment at LIU. His research interests include low powerembedded systems, distributed DSP applications forwireless sensor networks, data fusion techniques andmedium access controls (MAC) for wireless sensornetworks.Mohamed A. Elgamel received the B.Sc. de-gree in computer science from Alexandria Univer-sity, Alexandria, Egypt, in 1991, the M.Sc. degreein computer engineering from Arab Academy for Sci-ence and Technology (AAST), Alexandria, Egypt, in1998, the M.Sc. and the PhD degrees in computer en-gineering from University of Louisiana at Lafayette,Louisiana, USA, in 2000 and 2003 respectively. Heis currently an Associate Professor at the Faculty ofComputing and Information Technology, AAST. In2013, he was a visiting professor at The InternationalTelematic University (UNINETTUNO), Rome, Italy.From 2003-2010, he has been a Graduate Faculty atThe Center for Advanced Computer Studies, Univer-sity of Louisiana at Lafayette, USA. From 1999 to2003, he served as a Research Assistant and AdjunctFaculty at the Center for Advanced Computer Stud-ies, University of Louisiana at Lafayette, USA. From1991 to 1999, he was a Senior Analyst Programmer

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 37

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.

Page 16: EVAM-MAC: An Event Based Medium Access Control for ...The protocol is simulated with NS2 and compared with an implementation of S-MAC and 802.11 for multiple scenarios where EVAM-MAC

at Arab Academy for Science and Technology, Egypt.His research interests include CAD tools, EmbeddedSystems, Wireless Sensors Networks, Software Engi-neering, and digital video processing. His researchwas supported by funds from federal agents like DOE,NSF and the Louisiana Governor ITI. Dr. Elgamelis a senior IEEE member. He is also a member onthe IEEE Technical Committee on Communicationand IEEE-TC on VLSI. He served on the programcommittees and chaired sessions of several conferencesand as a reviewer/Reviewer Committee Member forseveral conferences and journals. Dr. Elgamel re-ceived the 2002 Richard E. Merwin Student Scholar-ship for demonstrating outstanding involvement in anIEEE-CS and excellence in academic achievement. Hewas the first place winner in the student paper contestin the 46th IEEE International Midwest Symposiumon Circuits and Systems, (MWSCAS2003). He wasthe president of the IEEE Computer Society studentchapter at the University of Louisiana at Lafayette.Samih Abdul-Nabi received his B.E. degree inElectrical Engineering in 1990 from the Lebanese Uni-versity, Beirut, Lebanon and his M.S. degree in Com-puter Sciences in 1993 from the University of Mon-treal, Canada. Since 1993, Mr Abdul-Nabi worked inmany related engineering fields in both Canada andthe U.S. His last industrial assignment was at DieboldInc. as Senior Systems Engineer providing technicalsupport to one of the largest banks in Canada. Hisis currently a lecturer at the Lebanese InternationalUniversity working on some research topics that in-cludes Network Coding and encryption.Amin A. Haj-Ali received his B.E. degree in Com-puter and Communications Engineering in 1993 fromthe American University of Beirut, Beirut, Lebanon,his M.S. degree in Electronics and Computer Con-trol Systems in 1994, and his Ph.D. in Electrical En-gineering (Systems and Soft Computing) and Com-puter Science (Minor) in 2002 from Wayne State Uni-versity, Detroit, USA. Dr. Haj-Ali earned a Mastersin IT Project Management from George WashingtonUniversity, Washington DC, USA. Since 1996, Dr.Haj-Ali worked in many related engineering fields inboth Lebanese and international corporations. Hislast industrial assignment was at DaimlerChrysler

Corporation Scientific Labs and Proving Grounds,Auburn Hills, MI USA where has registered a patent(US07043963B2). Currently Dr. Haj-Ali is the As-sociate Dean of the School of Engineering and Asso-ciate Professor at the Lebanese international Univer-sity. His research interest includes Machine Vision,Embedded Systems, Fuzzy Systems and Neural Net-works.Magdy A. Bayoumi received the B.Sc. and M.Sc.

degrees in electrical engineering from Cairo Univer-sity, Cairo, Egypt, the M.Sc. degree in computerengineering from Washington University, St. Louis,and the Ph.D. degree in electrical engineering fromthe University of Windsor, Windsor, ON, Canada.He is the Director of the Center for Advanced Com-puter Studies (CACS) and Department Head of Com-puter Science Department, University of Louisiana,Lafayette. He is also the Z.L. ”Zeke” Loflin EminentScholar Endowed Chair at the Center for AdvancedComputer Studies, University of Louisiana, Lafayette,where he has been a faculty member since 1985. Hisresearch interests include VLSI design methods andarchitectures, low power circuits and systems, digi-tal signal processing architectures, parallel algorithmdesign, computer arithmetic, image and video signalprocessing, neural networks, and wideband networkarchitectures Dr. Bayoumi was the vice presidentfor the technical activities of the IEEE Circuits andSystems Society and the chairman of the TechnicalCommittee on Circuits and Systems for Communi-cation and the TC on Signal Processing Design andImplementation. He was a founding member of theVLSI Systems and Applications Technical Committeeand was its chairman. He is a member of the NeuralNetwork and the Multimedia Technology TechnicalCommittees. He was an Associate Editor of the Cir-cuits and Devices Magazine, the IEEE Transactionson Very Large Scale Integration (VLSI) Systems, theIEEE Transaction on Neural Networks, and the IEEETransaction on Circuit and Systems II: Analog andDigital Signal Processing and Integration. He wasalso the chairman of many conferences and workshopsincluding MWSCAS’94, GLSVLSI’98, MWSCAS’03,ISCAS’07, and ICIP’09.

IJCSI International Journal of Computer Science Issues, Vol. 10, Issue 4, No 2, July 2013 ISSN (Print): 1694-0814 | ISSN (Online): 1694-0784 www.IJCSI.org 38

Copyright (c) 2013 International Journal of Computer Science Issues. All Rights Reserved.