LoRa network performance analysis for IoT systems

. Low power wide area networks (LPWANs) are a new generation of wireless communication technology designed for the Internet of Things to provide low energy and long range connectivity. LoRa is one of the promising technology. In this paper, we examine LoRa system performance and analyze the scalability of this technology considering packet payload size, spreading factor, number of nodes and number of gateways.


Introduction
The internet of things (IoT) refers to the interconnection and exchange of data between devices/sensors. According to an estimate by the Statista Group, nearly 29 billion connected devices will be active globally in 2030; nearly three times the number in 2020. At the same time, the data generated will also grow exponentially, reaching 73.1 ZB by 2025, a 42% increase over 2019, according to IDC. [1] Therefore, low power wide area network (LPWAN) is a new generation of wireless communication technology developed for the IoT that delivers long range, low power and low cost connectivity.
A number of LPWAN technologies have emerged in licensed and unlicensed frequency bandwidths such as SigFox and LoRaWAN which are considered the leaders. The use of these technologies presents various challenges such as noise, network interference and wireless propagation effects. Collisions result when the receiver is receiving unwanted data from another transmitter on the same frequency.
However, our contribution is to analyze the scalability of LoRa technology and the determination of the maximum number of sensors that can be integrated in this architecture considering the collision probability, the spreading factor, the size of the packet payload and the number of gateways. The rest of this article is organized as follows: In Section II, we present related work. In Section III, we describe the physical and communication features of LoRaWAN, Section IV focuses on the experimental results of the developed model. Finally, section V concludes the paper.

Related Work
In what follows, we try to analyze which are, to our knowledge, the most significant studies related to our work in the scientific literature.
We found in the literature, research works that tried to analyze the performance of LoRa network. The authors of [2] the performance at the MAC layer for LPWAN technologies (LoRa, Sigfox and NB-IoT) in terms of PER based on carrier frequency, packet duration, number of channels and spectrum access. Alexandru Lavri analyzed the scalability of LoRa technology and also studied the influence of the payload of the packets for determining the maximum number of sensors that can be integrated in the approved architecture [3]. Mroue, Nasser. et al. focused on LoRa technology, studied the performance of LoRa deriving the BER in terms of its proprietary modulation parameters, primarily from end nodes to the gateway [4].

LoRa Technology
Long Range (LoRa) is the most widely used LPWAN technology that scales and modulates the signal using a proprietary spread spectrum technique in the unlicensed subGHz ISM band, i.e., in Europe 868 MHz, in North America 915 MHz and 433 MHz in Asia [5]. Depending on the channel bandwidth and the spreading factor, the data rate of this technology is approximately 300 bps to 50 kbps. In addition, messages sent with different spreading factors can be received simultaneously by the LoRa base station. In another aspect, the maximum payload length for each message is 243 bytes. [6] LoRaWAN is an open standard architecture developed by the LoRa Alliance to provide a mechanism for controlling access to the support and allowing terminals to communicate with one or more gateways [7]. The three main components of the LoRaWAN network are LoRa end nodes, gateways and a network server. Figure 1 shows the topology of the LoRaWAN network. LoRa terminal nodes communicate with the gateway via the LoRa physical layer. Gateways connect to network servers using high-speed IP connections such as Ethernet or cellular networks. The gateway transfers the packets between the LoRa end nodes and the network servers. [8]

Fig. 1. LoRa network topology
LoRaWAN has two security layers, one for the application layer and another for the network layer. Node authenticity assured by the network layer. The application layer ensures the security of the end user's application data. [9] LoRa technology requires many parameters to be defined to achieve the desired network performance. One of these parameters is the spreading factor SF which corresponds to the number of bits transmitted during the time T S , since in the CSS modulation a Chirp using SF represents 2 SF bits per symbol. [4] The transmission time (ToA) is the time passed from the transmission of the first bit of information to the last. The total ToA is the sum of the transmission time of the preamble and the payload transmission time: [10] With: Where: PL sym indicates Payload size in bytes, n preamble is the number of symbols in preamble (by default set to 8), CR indicates Coding Rate (CR can be in the range from 1 to 4), DE is 1 if low data rate optimization is enabled else 0 and H is the header option (0 if enabled, 1 if disabled).
The relation between the payload bit rate, symbol rate and chip rate for LoRa modulation can be expressed as follows: [11] R b = SF (kbps) (6) LoRa modulation also contains a variable error correction scheme that improves the robustness of the transmitted signal at the expense of redundancy. [12] R b = SF (kbps)

System model and analysis
This section presents the scalability of LoRa technology. To evaluate the performance level, the packet error rate (PER) parameter is analyzed. It represents the ratio between the number of erroneous packets received and the total number of packets transmitted.
For this study, we simulated several devices sending 30 byte packets. This choice is due to IoT systems covering large geographical areas such as water level monitoring, traffic and parking control and also other applications as in the health and agriculture sector, therefore LoRaWAN supports large networks that can contain millions of devices for which a large volume of data needs to be transported. Table 1 shows the LoRa bit rates and the time on air (ToA) for each spreading factor. The objective of this study is to determine the number of devices supported for a single gateway and two gateways to receive messages sent without loss. In this simulation, we first determine the frequency range and frequency interval, duration, number of packets, packet duration, packet payload, number of gateways. The specified parameters are a frequency range of 125 KHz, a frequency interval of 200 Hz, the number of packets 1, a period of 60 seconds and a time interval of 20 ms, the payload of the packets is fixed in 30 bytes and a single gateway for the first simulation and two gateways for the second simulation.
First, we examined the impact of the number of devices on the PER as shown in Figure  2. The PER parameter is strictly influenced by the number of possible collisions on the communication channel. Most often these collisions are caused by a large number of sensors. Then he PER increases as the number of nodes in the network increases. The simulated model uses SF 7 and SF 12 because they are the lowest and highest SFs so results will be minimal and maximal so that differences in PER and number of collisions between the lowest and highest SF can be compared.
In the first case, the model simulates the number of messages per minute delivered to a single gateway, using spread factors (SF=7) for a 30 byte message, at their respective bit rates. Figure 3 shows that in the initial state the number of collisions and the packet error rate are null. Once 20 messages are sent simultaneously, a packet error rate begins to appear and a series of collisions occurs. At 500 messages per minute, 58% of messages are lost due to collisions. And for 2000 devices, the packet error rate reaches 95% as shown in Figure 4. Using spread factors (SF=12) for 500 devices as shown in Figure 5. At the beginning the message started to collide and at 500 messages sent, the packet error rate is 100%.   that can be integrated in the network. Figure 6 shows that from 4 messages sent the packet error rate and a number of collisions start to occur. At 40 messages the PER reaches 90%. SF 7 spends less time in the air, resulting in a lower collision rate and number of collisions than SF 12. With SF 12, more messages are sent, more collisions appear and the PER approaches 100%. In the second case, the model simulates hundreds of messages per minute delivered to two gateways, using spread factors (SF =7) for a 30 byte message, at their respective bit rates. Figure 7 shows that with two gateways and a SF=7 for 2000 devices, the PER that does not exceed 10% starts to appear from the moment 20 messages are sent, while a series of collisions occurs only from 50 messages sent. For SF=12 and 40 sensors the packet error rate starts to appear and a series of collisions occurs when 3 messages are sent simultaneously then it returns to zero when 6 messages are transmitted, at 40 messages the PER is 90% as shown in figure 8. Therefore, with two gateways an acceptable performance level is achieved. By comparing the results obtained in Figs. 9 and 10, we can extract the following analyses:  With a high number of nodes, we get high PERs.  The higher the SF, the greater the possibility of packet collisions.  The number of gateways used has a significant impact on network performance.  To reduce the collision rate, several gateways can be integrated in network architecture.  In this paper, we perform a scalability analysis to estimate the performance capability of LoRa technology. A primary objective was to determine the maximum number of devices that could be integrated in such IoT architecture. We performed simulations in two cases based on the gateway number. In each case, we used the packet error rate (PER) as a performance measure. The experimental results obtained show that the maximum number of LoRa sensors that can communicate on the same channel is 2000 in the configuration with a SF of 7 and a payload of 30 bytes. The higher the propagation factor in the LoRa wireless communication protocol, the more possibility of packet collisions. This happens because the longer the packet transmission time, the higher the risk of collision with other packets. Also, as the payload of packets increases, they take longer to send and are more susceptible to collisions. So the spreading factor must adapt to the demands of the number of connected devices in the IoT system.
A possible solution would be to implement and integrate multiple gateways into the network which can reduce collisions that decrease the performance of the architecture as the further the node is from the gateway, the weaker the signal is at the reception.