Here implementation of 802.15.4 (IEEE) WPANs for WSNs are explained. Performance of mechanism is compared with the model derived in [1]. It is based on (b, R) model which considers the linear arrival curve created by sensor nodes with GTS traffic. The cumulative arrival curve from application layer is upper bounded by a (t) = b + R*t where ‘b’ is the maximum burst size and ‘R’ denotes average arrival rate. The results and equations obtained from the simulations are compared with numerical model [1].
4.1 Medium Access Delay is the extra Back-off time that the packet at MAC layer has to wait before being successfully transmitted or dropped after number of failed retransmissions in a specified time interval.
Figure 5 displays the medium access delay for three scenarios. The maximum average delay was shown by the scenario using original algorithm and is found to be 12.7 ms and least was shown by simple adaptive BE-SF algorithm and came out to be 5.65 ms. Adaptive BE algorithm has average Medium Access Delay equal to 9.59 ms. This implies that the proposed algorithm helps reduce the Medium Access Delay by forty five percent approximately. According to the numerical model Ts given by (Tdata + Tidle) denotes the time slot duration in Superframe with SD and BI as Superframe duration and beacon interval then delay latency is given by
Dmax= (K * BI / µ*SD- Tidle) + (BI-Tdata- Tidle) (4)
Where Dmax is maximum delay, K is a constant, Tdata is the maximum duration for transmission of frame (data) inside GTS and Tidle is combination of IFS, acknowledgement time and other overheads.
Since the transaction has to complete before the GTS duration ends; So when SO and BO are made adaptive the bandwidth usage becomes better. The Superframe duration increases after certain threshold of arrival data rate. The CSMA algorithm reduces wait time (BI – Tdata – Tidle). The reason for this can be attributed to the fact that Medium Access Delay depends on the random BE which increases delay factor as the number of retries increase. But our algorithm prioritises the packets having retries more than two and allots them a lower BE until their retries become five. Thus, they are provided access faster thereby reducing the overall Medium Access Delay. This results in efficient use of CFP of the GTS. Now removing the wait time part from the equation we find:
Dmax = (K * BI / SD – Tidle) (5)
Since SD changes at run time and keeping BI same, more SD will result in lesser delay and hence the graphs obtained. The approximation equations obtained for the resultant graphs were as follows:
d = 0.0074*t + 4E-05,R² = 0.7275 (6)
d = 0.0061*t − 0.001, R² = 0.7344 (7)
d = 0.0052*t − 0.002,R² = 0.7381 (8)
Generalizing the above (6–8) equations, ignoring k2and replacing t from the equation of arrival curve (a = b + R*t), where b is maximum burst size and R is average arrival data rate, we get:
(K * BI / SD – Tidle) = k1*(a-b)/R (9)
This leads us to the conclusion that SD – Tidle α Rate (R). So as the rate increases if SD also increases, it contributes in giving better results and hence lower delays.
4.2 End to End Delay: It is the extra time taken (excluding the specified time period) by the packet to be transmitted from the original source to original destination. It depends on transmission, propagation, processing and packetization delays. It comprises of sender delay, network delay and receiver delay.
Figure 6depictsDelay (End to End) of three scenarios. The least Delay (End to End) is in Modified Adaptive BE-SF Algorithm. It is observed that Simple Adaptive BE-SF Algorithm reduces the Delay (End to End) by about three percent. The reasons for this can be estimated from (9) which shows that as the rate increases if SD also increases it mitigates the delay. The difference is less as compared to that in Medium Access Delay as End-to-End Delay is governed by other factors as given by following relation:
dend-end= N[ dtrans+dprop+dproc] (10)
where:
dend-end= Delay (end-to-end)
dtrans= Delay (transmission)
dprop= Delay (propagation)
dproc= Delay (processing)
N = Number of links.
Since propagation delay is majorly dependent on bandwidth which is 2.4 GHz for all the three scenarios and it depends on material medium of travel. Next is the transmission delay which may be defined as: dtrans = packet_length/data_rate, with data rate being constant at 250kbps for 2,4GHz frequency band. Since packet length and data rate are same for all scenarios, we come to processing delay. The dproc involves checking packet headers for errors and to check the next destination address for packet, accessing the medium etc. In this way the difference in Delay (End to End) can be explained.
Similar results are also given by the approximated equations obtained from simulation results as plotted on the graph as well. The equations (11–13) are respectively for three scenarios:
y = -0.00003x2 + 0.6029x − 1.9079, R² = 0.7531 (11)
y = 0.5031x − 1.5882, R² = 0.7545 (12)
y = 0.4886x − 1.5458, R² = 0.7531 (13)
Generalizing these equations (11–13) as in (9) simulation results have a very similar behavior as in case of analytical model.
4.3 Successfully Acknowledged Packets: Those packets out of the total sent towards the destination that successfully reach the destination and are acknowledged back to the source.
Figure 7 represents the successfully acknowledged packets. Maximum packets in numbers are successfully acknowledged in case of Simple Adaptive BE-SF Algorithm. The graph result shows an increase of thirty six percent (approx.) in number of packets successfully acknowledged in the same time frame.
The maximum packets in numbers that can be transmitted are be given by:
Np = Tdata + T idle / Ps + IFS (14)
Where Np is number of packets sent and Ps is maximum packet size and IFS being inter frame space.
Since IFS and Ps are constants for three scenarios then Np depends directly on Ts (Tdata + Tidle). This value is least in simple adaptive BE-SF algorithm as delay for this scenario is least as proved in (9).
The approximation for the simulation results give following variation for the packets successfully transmitted for three scenarios respectively.
p = 0.1341t2 − 1.1504t + 3.2393 R² = 0.9345 (15)
p = 0.0916t2 − 0.7139t + 1.8196 R² = 0.9172 (16)
p = 0.0954t2 − 0.9147t + 2.6661 R² = 0.8464 (17)
where ‘p’ denotes number of packets transmitted successfully and ‘t’ is the time elapsed.
The results in Fig. 7 and the approximated equations are in congruence with the numerical analysis and give better results for adaptive BE-SF Algorithm.This observation can be attributed to the fact that the changed CSMA-CA algorithm gives higher priority to the node which has tried twice or more than twice to transmit the packet but has failed to do so. Also, it ensures a smaller number of collisions and hence more acknowledged packets in same time duration by waiting for IFS time in addition to back-off-delay. This ensure that the nodes at the same distance from coordinator may sense the carrier to be idle when one of the node has already sent a packet. By waiting for IFS time, it is ensured that the packet gets successfully delivered to destination.
4.4 Dropped Packets: Number of packets that are dropped (those which are unable to reach the destination) from the total sent to the destination due to unavailability of medium or on exceeding the permitted number of retries.
The Fig. 8 above shows the dropped packets. The maximum number of packets were dropped in case of scenario 1 with original algorithm in play. The absolute number of packets dropped in original algorithm were two whereas in Modified Adaptive BE-SF Algorithm there were none. This observation can be attributed to the fact that the revised Simple Adaptive BE-SF algorithm avoids collision in a better way and prioritises the access by giving the access to node which has failed twice or more to send the data packet. Since the delay for channel access is reduced in new scheme the probability of packet drop reduces. Also, the Superframe duration is adjusted according to the incoming traffic which ensures proper utilisation of bandwidth.
Probability of packet drop α Medium Access Delay (18)
Since from (9) the Medium Access Delay is least for Simple Adaptive BE-SF algorithm and hence from (5) probability of packet drop is also least. The same results are also seen in the approximate equations from the simulations:
y = 0.0303x + 0.0902, R² = 0.7741 (19)
y = 0.0183x − 0.0761, R² = 0.6463 (20)
y = 0 (21)
with Eq. (19–21) for three scenarios respectively.
4.5 Battery Energy Consumed: The amount of energy consumed by the particular node for the transmission or reception.
From the Fig. 9 above it is observed that maximum battery consumption is in case of original algorithm and least in case of Simple Adaptive BE-SF Algorithm.
It should be noted that a low duty cycle conserves energy by putting device to sleep. But, a low value of duty cycle also reduces the bandwidth and increases delay. So, a fine balance of SO and BO values is needed which decide the duty cycle. The adaptive algorithm tweaks the value of SD in real time and increased bandwidth utilization.
Also in simpler terms the equation for energy consumption may be given by:
Energy = Power * Time (22)
The ‘Power’ includes the transmission or reception power and ‘Time’ represents the ‘Ts’.
In (9), it was found that the ‘Ts’ is least in Modified Adaptive BE-SF Algorithm. Since all motes considered are same, so their power values are also same. This leads us to an obvious conclusion of the energy consumption pattern.
The results obtained on running regression analysis of the data for battery consumption we get following best fit mathematical equations:
e = 3E-05t2 − 0.0001t + 0.0001, R²= 92% (23)
e = 4E-06t2 + 8E-06t − 2E-05, R²= 95% (24)
e = 3E-06t2 + 3E-05t − 5E-05, R²= 90% (25)
where ‘e’ is the energy consumed and ‘t’ is the time elapsed in seconds.
As the time elapses the data rate arrival increases thus increasing the battery consumption. This result is in accordance with the numerical analysis of the model. The equations (23–25) also show that on a longer period of time the best performance shall be given by Modified Adaptive BE-SF Algorithm which is in harmony with the numerical analysis as well.