# Internet of Bikes: A DTN Protocol with Data Aggregation for Urban Data Collection
## 7 Performance Evaluation of IoB-DTN and IoB Long-Range

Table 3: Parameters used in our theoretical results. In this section, we compare the energy consumption and the throughput of IoB-DTN and IoB-LR. To evaluate the energy consumption, we assess the average transmission cost per bike and the average consumption background per bike. The average transmission cost per bike is shown in Figure 20. It is measured in mAh and calculated as follows:  
\[TC=[NPS*Tx*DP]+[NAR*(Tx+Rx)*DA]+\underbrace{[NPR*Rx*DP]}_{\text{for IoB}} \tag{1}\]  
where \(TC\) represents the transmission cost expressed in mAh; \(NPS\) is the number of sent packets; \(Tx\) and \(Rx\) correspond to the transmit and receive consumption, respectively, measured in mA; \(DP\) and \(DA\) represent the packet duration and the acknowledgment duration calculated in seconds, respectively; \(NAR\) is the number of received acknowledgments; and \(NPR\) is the number of received packets from nodes. In Figure 20, we notice that IoB-LR gives the highest average transmission cost per bike. This is because nodes forward data packets to only base stations. IoB protocol offers the smallest average sending cost per bike by dint of the multi-hop communications that decrease the forwarding cost per bike in the network. To respect the duty cycle (real period in which a resource is active) of radio devices regulated in Europe by Section 7.2.3 of the ETSI EN300.220 standard, we consider the maximum theoretical duty cycle allowed for the long range type LoRa which is 10% using the sub-bands (869.4-869.65 MHz) [51]. Thereby, we present, in Figure 20, the average forwarding cost per bike for LoRa technology by respecting the maximum theoretical duty cycle of 10%. From the simulated scenarios, the LB-SDC case, with 500 as buffer size and 50 s as duty cycle, corresponds to the real value of the maximum duty cycle allowed by LoRa technology. In other words, to fill \(\frac{1}{10}\) of 500 slots in 50 s, the duty cycle is then 10%. By following the same behavior for other cases, the duty cycles obtained are: 20% for SB-SDC, 60% for SB-LDC and 30% for LB-LDC. As final note for the transmission cost, it is important to mention that IoB gives the best results in terms of the average transmission cost per bike, thanks to the bike to bike communication, comparing to IoB-LR and LoRa technology by respecting the maximum allowed duty cycle. The average consumption background per bike is depicted in Figure 21. It corresponds to the overall consumption by bike, measured in mAh, and is calculated as follows:  
For IoB:  
\[BC=\sum_{i=1}(Ta-Td)*Rx \tag{2}\]  
Figure 20: Average transmission cost per bike. For IoB-LR:  
\[BC=\frac{Rx*BWT}{DC}*\sum(Ta-Td) \tag{3}\]  
where \(BC\) represents the average background consumption; \(Ta\) and \(Td\) are the arrival and the departure time of the bicycle, respectively, defined in seconds; and \(DC\) corresponds to the duty cycle expressed in seconds. After this period, each node forwards all data stored in its buffer. It takes as value 50 s or 150 s according to the simulated scenario. \(BWT\) represents the beacon waiting period measured in seconds and it is fixed to 10 s in all our measures. In Figure 21, we notice that IoB-DTN protocol has the highest average background consumption per bicycle. This is because the nodes require to be always in listening mode for beacons to relay data packets in the network. For IoB-LR, the nodes enter in sleep mode and they wake up few moments before starting the data packets sending. We also present, in Figure 21, an optimal average background consumption per bicycle for IoB and it is denoted IoB-DC. In IoB-DC, the nodes having a full buffer enter in sleep mode and they wake up few seconds before data packets forwarding. We note that IoB-LR has better background consumption per bike than IoB and IoB-DC. In Figures 20 and 21, IoB-LR, based on the long range technology, clearly provides lower energy consumption than the multi-hop IoB-DTN protocol. Figure 22 shows the average throughput expressed in _kbps_.