Keywords

1 Introduction

With the continuous development of IoT, its application domains are increasing, and the number of device deployment is exploding. According to forecasts, the number of connected IoT devices will continue to grow at a rate of 32% per year and it is estimated that there will be 500 billion devices connected with wireless communication by 2022 [1]. Compared with the Internet, some emerging IoT applications require merely less memory, bandwidth and processing ability of the device to efficiently complete their work [2, 3]. Traditional cellular networks and related technologies have been unable to satisfy the demands for “less of everything” in terms of network capacity, communication range, energy consumption and cost. Aiming at solving this issue, LPWAN, a very attractive and promising communication technology, is utilized to carry out the long-range communication with a large number of devices. And it is gradually applied on the smart home, metering application and other application fields [4,5,6]. LPWAN has the advantage on offering long-range connectivity for low power and low rate end devices. Therefore, it is suitable for those applications that are delay-tolerant, only need low data rates and typically require low power consumption. Recently, small payload packets with low amount of data have been garnered widespread attention in the IoT industry [7]. For example, for smart meters, each device is only required to transmit a packet per day. Other similar applications merely need transmit small amounts of discrete packet such as temperature and humidity. Such applications regularly use low-cost and low-consumption processors. When using LPWAN technology to transmit packets, the device can operate for several years with only one battery.

As an emerging LPWAN technology, LoRa has attracted much attention not only for its low power consumption and low deployment cost, but also for transfer of messages over a long-range. LoRa is a physical layer technique. Its MAC layer solution is regarded as LoRaWAN [8]. To keep the system free of complex routing protocols, LoRa technologies often rely on star topologies, in which end devices communicate directly with gateways in a single hop [9]. In order to achieve the scalability of LoRa network, LoRa technologies are required to provide connectivity for a massive number of IoT devices. And a large number of parameter settings will be generated from massive IoT devices which need to meet different IoT applications with varying communication patterns. LoRa provides a range of communication parameter settings, including Spreading Factor (SF), Bandwidth (BW), Code Rate (CR), Transmission Power (TP) and Packet Size (PS) [10]. Many combination settings are orthogonal and keep communications from simultaneous collision, it has to be noted that using the same parameters increases the probability of collision. A packet can have significant variations in ToA (Time on Air) depending on the selected setting. For example, a 20 bytes packet can vary between 7 ms and 2.2 s. For this reasons it is indispensable in a LoRa network that end devices with battery-powered make good transmission parameter choices.

In view of the above problems, some researches have proposed SF adaptive optimization strategy [8, 11, 12], which can effectively improve the fairness of Packet Error Rate (PER) in LoRa network. However, this method does not take into account the full spectrum of parameters governing such as BW, CR, TP and PS on scalability of LoRa networks. Considering the shortcomings of existing methods, in this paper, a model of channel collision and link budget for single-gateway LoRa network is established and implemented in NS3 simulator. By solving the model, the parameter combination with minimum collision probability obtained. Algorithm for solving multi-objective combinatorial problems with exhaustion method, genetic algorithm, simulated annealing algorithm. Considering that the end device is battery powered, the exhaustive method consumes too long time and is not suitable for this scenario. Simulated annealing algorithm is a random algorithm with slow convergence speed and cannot find the global optimal solution. The Genetic Algorithm (GA) processes the individual chromosomes encoded by the parameter set and can simultaneously process multiple individuals in the population. However, the core operation-crossover operator of the traditional GA is random in factor segmentation. The search has a certain blindness to some extent, which reduces the search efficiency of the algorithm. Therefore, the orthogonal design method is utilized to design crossover operator, and as a result, crossover operator self-adaptive to adjust the location for dividing the parents into several sub-vectors, so as to generate the population of genetic algorithm. In order to achieve a higher user experience quality at a lower power consumption, by using the dynamic parameter selection method based on orthogonal genetic algorithm (OGA), the communication device can independently select SF, BW, CR, TP and other parameters. In summary, the main work of this paper includes:

  • First of all by experiment, a study of the impact of the LoRa transmission parameters SF, BW, CR, TP and PS on communication performance is analyzed;

  • A channel collision and link budget model are established for single-gateway LoRa network and implemented in NS3 simulator. An OGA-based dynamic parameter selection algorithm is proposed. By using the cross-combination dynamic selection of parameters, the collision probability is minimized;

  • By simulating 10,000 end devices with the same PS, PDR was 30% better than the static deployment. Knowing different packet sizes have an impact on network performance, the experiment evaluated the impact of different PS on network transmission reliability under different parameter setting methods.

2 Related Work

To optimize the performance of LoRa, many work mainly focus on how to allocate the wireless resources effectively. Author Peng et al. [11] at SIGCOMM 2018 proposed PLoRa, an ambient backscatter design that enables long-range wireless connectivity for battery less IoT devices, but the author points out in the study that the limitation of PLoRa design is that only encoding a data rate (determined by SF, BW and CR). There are also many other works studied on performance improvements of network-related parameters. To sum up, the research on LoRa parameter configuration can be divided into two categories:

The first category is the static deployment method which refers to a setting where all end devices employ the same parameter. Martin et al. [9] adopted three static parameter settings for network communication, those are SN1, SN2, SN3. SN1, which is the longest ToA setting, SN2 is the shortest ToA setting, and SN3 is the default setting. These parameter settings are applied to evaluate the scalability of the LoRa network for the established link model. Thiemo et al. solved the problem of interference caused by deploying multiple independent LoRa networks in close proximity [12]. All experiments have the same parameter setting SN1 and SN3. SN3 is similar to SN1 except for a lower CR which reduces the ToA and leads to fewer collisions. A stronger CR is very energy-costly as packets contain redundant information, however, better communication performance can be achieved in areas with burst interference. It is possible to conclude that with the increase number of end devices, static parameter deployment cannot make the LoRa scaled well. Therefore, the dynamic configuration and autonomous selection of LoRa parameters are of great significance for reducing energy consumption of end device and improving network scalability.

The second category is the dynamic deployment method. Martin et al. [9] evaluated the impact of dynamic communication parameter selection on PDR. Three settings SN3, SN4, and SN5 are compared. SN3 is the same as the experiment in static deployment as a comparative experiment. In the case of SN4, set BW, SF, and CR to minimize ToA (with a constant TP = 14 dBm), SN5 sets the first ToA determined by BW, SF, CR and minimizes the selection of the TP. Dynamic parameter settings have significant improvements over static setting implementation in LoRa. But it has to be considered that this achievement is not practical and relies on quite optimistic assumptions. First, the minimum ToA setting has the lowest CR, which fail to provide sufficient protection. Second, due to environmental changes, it is necessary to re-evaluate selected settings from time to time and requires implementation of complex protocols to facilitate settings in the LoRa network. EXPLoRa heuristic method [13] aims to effectively allocate SFs between end devices, and proposes two SF allocation methods, EXP-SF and EXP-AT. EXP-SF distributed SFs equally among N nodes based on RSSI, EXPLoRa-AT is a more sophisticated method of transmitting data packets across SF channels by equalized ToAs. The two aforementioned methods use same BW, CR and TP, which leads to a higher overall data rate than in reality. Martin et al. [14] developed a link probing regime which enables us to quickly determine transmission parameter selection with lower energy consumption, but they did not evaluate the impact of different parameters on network scalability. Adelantado et al. [15] reported the characteristics and limits of LoRa according to the relationship between duty cycle and throughput of different PS. Taoufik et al. [16] pointed out that the consumed energy changes with different LoRa parameters such as SF, CR, BW, TP and PS. Optimizing these parameters are of great importance for both reducing sensor energy consumption and network scalability.

Although there have been studies on SF dynamic allocation, this category is still classified as static deployment in our study because other parameters such as BW, CR and TP are indeed fixed.

3 Overview of LoRa

3.1 LoRa Physical Layer Parameter

LoRa uses the CSS modulation combined with the Forward Error Correction (FEC) to maintain low power and long communication range [17]. LoRa key properties are: long-range, high robustness, multipath resistance, Doppler resistance and low power [18]. A typical LoRa device provides several main modulation parameters SF, BW, CR and TP. Theses parameters influence the effective bit-rate of the modulation, its resistance to interference noise and ease of decoding. LoRa’s communication performance can be tuned by varying the selection of these parameter settings and the LoRa network scalability is determined by this key factors. BW is the width of frequencies in the transmission band. The higher is the BW, the shorter is the ToA and the lower is the sensitivity. SF is the number of bits encoded into each symbol, namely the ratio of chip rate to symbol rate. Each increase in SF allows a longer communication range, but doubles ToA and ultimately energy consumption. CR is the FEC code rate used by LoRa modem to protect from a burst of interference. Depending on the CR selected, additional robustness can be obtained with interference. A higher CR offers more protection, but increases ToA. A high TP will result in a higher RSSI, increasing the range of communication while allowing a lower PER. Maximum PS for a LoRa network is 255 bytes. In our testing, the packet sizes were configured as: 10 bytes, 20 bytes, 30 bytes, 40 bytes, 60 bytes, 80 bytes.

3.2 The Effect of Different Parameter

Each data rate, through the combination of SF, BW, CR and PS, experiences different ToA, thus different collision probability. Following these considerations, we analyzed the effects of different parameters on ToA and energy consumption through experiments. Figure 1 shows the comparison between ToA and energy consumption with different parameters. It can be seen from the figure that the ToA of data packets varies significantly with different communication parameter selections. For example, the ToA of packets of 20 bytes with different parameters varies between 7 ms–2 s. Therefore, the dynamic selection of communication parameters has a significant impact on the scalability of LoRa network deployment.

Fig. 1.
figure 1

Effect of different parameter on ToA and Energy.

4 System Modeling

In order to study the influence of communication parameters on LoRa network performance, in this section, we describe system model that are used in the paper.

4.1 Channel Collision Model

The LoRaWAN physical layer supports adjustable SFs, \(\mathrm{{SFs }} \in [7,12]\) and spread spectrum signals with different SFs have good orthogonality and can transmit in the same channel simultaneous without interference [19]. As shown in Fig. 2, in LoRaWAN, it is assumed that the available SFs are SF9 and SF11, and the following three cases are transmitted in the channel. In case 1, on account of two SFs 11 arrive at different channels simultaneously, they can be successfully received and decoded. In the case 2, SF9 and SF11 are in the same channel, and due to their orthogonality, collisions can be avoided. In the case 3, the same SF9 arrives at the same channel simultaneously, causing a collision to occur. When there are multiple SFs transmitting on the channel, two collide occur: Two packets with same SF arriving at the same channel simultaneous cause a collision, thus causing data packet loss. Collisions with the same SF: the probability of at least one collision with the same SF using the random access formula, as shown in Eq. (1):

$$\begin{aligned} {P_{coll,sf}} = 1 - {e^{ - 2{G_{sf}}}} \end{aligned}$$
(1)

where \({G_{sf}}\) is the amount of packets generated during the transmission of one packet with SF.

Fig. 2.
figure 2

Multiple access under the orthogonal SF.

The transmission time of a packet \({T_{sf}}\) in LoRa is given by Eq. (2)

$$\begin{aligned} {T_{sf}} = \frac{\mathrm{{L}}}{{{R_b}}} \end{aligned}$$
(2)

\({R_b}\) is bit-rate that can be expressed as:

$$\begin{aligned} {R_b} = SF \times \frac{{BW}}{{{2^{SF}}}} \times CR \end{aligned}$$
(3)

the amount of traffic generated per unit of time \(\lambda \) is given by

$$\begin{aligned} \lambda \ \mathrm{{ = }}\ \frac{N}{{{T_i}}} \end{aligned}$$
(4)

\({T_i}\) the average packet inter arrival time per end device. The amount of traffic \({G_{sf}}\) generated during the transmission of one packet using SF is

$$\begin{aligned} {G_{sf}} = \lambda {\partial _{sf}}{T_{sf}} \end{aligned}$$
(5)

where \({\partial _{sf}}\) is the fraction of devices using the same SF. Finally, the probability of collision can be expressed as

$$\begin{aligned} {P_{coll,sf}} = 1 - {e^{ - 2[\frac{{{2^{sf}}}}{{sf}}\frac{L}{{BW \times cr}}{\partial _{sf}}\lambda ]}} \end{aligned}$$
(6)

The probability of packet collision during transmission is closely related to the combination of these parameters and \({\partial _{sf}}\), which is the variable used to optimize the PDR. Therefore, the channel collision model is established as the objective function to improve PDR by dynamically selecting the combination of parameters, so as to improve the reliable transmission of the network.

4.2 Link Budget Model

The solution to our problem is not merely to minimize the probability of collision, but also to increase the correct reception of the gateway. The gateway is determining the reception depending on the receive sensitivity. These parameters also have significant influence on the receive sensitivity [20]. The increase of BW will reduce the sensitivity of the receiver, while the increase of SF will increase the sensitivity of the receiver. The evaluation and analysis of link budget depend on link parameters such as SNR and receive sensitivity, and receive sensitivity is positively correlated with SNR. The SNR is calculated as follows:

$$\begin{aligned} SNR = \frac{{{2^{sf}} \times {{\mathop {\text {P}}\nolimits } _{rx}}}}{{BW \times NF \times K \times T}} \end{aligned}$$
(7)

where \(P_{rx}\), NF, K and T are the received power, receiver architecture noise figure, the Kelvin constant, the temperature respectively. The sensitivity can be defined in the following equation:

$$\begin{aligned} {S_R}(SF,BW) = \mathrm{{ - 174 + 10lo}}{\mathrm{{g}}_{\mathrm{{10}}}}(BW) + NF + SNR \end{aligned}$$
(8)

Equation (8) depicts the \(L_{path}\) expression, Thus, real path loss in LoRa can be mathematically defined as:

$$\begin{aligned} {L_{path}} = \frac{{{P_{tx}}}}{{{S_R}(SF,BW)}} \end{aligned}$$
(9)

In wireless communication, the MCL is defined as the maximum link budget allowed for each value of SF, BW and TP. To ensure correct signal demodulation, \(L_{path}\) must be smaller than MCL:

$$\begin{aligned} p = \left\{ {\begin{array}{*{20}{c}} 1&{}{MCL > {L_{path}}}\\ 0&{}{else} \end{array}} \right. \end{aligned}$$
(10)

where MCL is determined based on the sensitivity of the gateway and TP used by the end device as follows:

$$\begin{aligned} MCL = TP - {S_R}(SF,BW) \end{aligned}$$
(11)

4.3 Packet Delivery Rate

In this paper, we define reliability as the ratio of the packets successfully received by the gateway to the total number of packets transmitted from the end device over a period of time. The main evaluation metric used in the simulation to estimate the performance is called packet delivery rate (PDR). The packets transmitted from the end device fail to deliver if they could not satisfy the condition mentioned in (10). The \(L_{path}\) defined in (9) refers to the average statistical path loss in the city environment. However, in real-life scenarios, path loss fluctuates and exact path loss is hard to estimate. This happens because wireless communication is effected by several unpredictable factors [21,22,23] such as the blocking of signals caused by large obstacles, fluctuation caused by weather conditions. Therefore, in order to simulate the real scenario as much as possible, we need to fully consider the impact of these parameters on communication.

5 Proposed Solution

In this section, we will explain in detail the proposed method. First, we specify the feasibility of the proposed method. Following it, we describe the implementation process of the algorithm. With small data rate and resource limited LoRa end device, configuration of optimal settings becomes challenging. Especially when the number of end device is large, how to utilize an appropriate dynamic selection algorithm becomes particularly important. For the LoRa parameter, the set S= {SF, BW, CR, TP}, where \(\mathrm{{SFs}} \in [7,12]\) has 6 levels, BW = 125 kHz, 250 kHz and 500 kHz have 3 levels, CR = 4/5, 4/6, 4/7, 4/8 have 4 levels, and there are 13 levels in \(\mathrm{{TP}} \in [2,14]\). When N nodes are considered, the search space for optimal parameter for each node is \({N^{6 \times 4 \times 3 \times 13}}\), this optimization problem can easily be solved by GA. The advantage of GA is reflected in the extensiveness of the representation of the feasible solution. The object it deals with is not the parameter itself, but the individual gene obtained by encoding the parameter set and can simultaneously process multiple individuals in the population, which is very suitable for parameter configuration in LoRa network.

5.1 OGA Dynamic Selection

Although GA has been successfully applied in many optimization problems. However, a large number of studies have shown that traditional GA has many shortcomings [25], such as premature convergence and poor local search ability. Crossover operator imitates the natural process of chromosome gene recombination, and the core operation of GA. In the traditional way to carry out crossover operation, the location of factor segmentation is randomly generated and the search has certain blindness, which greatly reduces the search efficiency of the algorithm. In order to solve this problem, this paper adopts OGA as a solution to the problem, by integrating the orthogonal design into crossover operator, the position of the segmentation of the individual factors of the parent generation can be adjusted adaptively to generate the population of the GA. Among many combination parameters of LoRa, the two parent individuals involved in the crossover operation are: \({p_\mathrm{{1}}}\mathrm{{:(7,125,1,2)}}\), \({p_{\mathrm{{2:}}}}\mathrm{{(8,250,2,5)}}\). If the first and second dimensions of \({p_\mathrm{{1}}}\) and \({p_{\mathrm{{2}}}}\) are denoted as factor 1, third and fourth are considered as factor 2 respectively, the position of factor segmentation is shown in the dotted line in the equation. In this way, the cross operation of \({p_\mathrm{{1}}}\) and \({p_{\mathrm{{2}}}}\) is transformed into a two-factor, two-level experimental problem. Finally, orthogonal design is arranged in orthogonal table to generate offspring population \({p^1}\), as shown

$$\begin{aligned} \left\{ {\begin{array}{*{20}{c}} {{p_1} = \left( {7, \left| {\mathrm{{125}}} \right. ,1,2} \right) }\\ {{p_2} = \left( {8,\left| {\mathrm{{250}}} \right. ,2,5} \right) } \end{array}} \right. \Rightarrow {p^1} = \left\{ {\begin{array}{*{20}{c}} {\left( {7,125,1,2} \right) }\\ {\left( {7,250,2,5} \right) }\\ {\left( {8,125,1,2} \right) }\\ {\left( {8,250,2,5} \right) } \end{array}} \right. \end{aligned}$$
(12)

After the three methods are utilized to segment the factors, eight descendant individuals including two fathers are generated. In the multi-point crossover operation, the cross combination method exists in various ways. As the number of intersections increases, the number of combination methods will increase sharply, and the number of intersections and the position of the cross operation are adaptively adjusted hence improve search efficiency. The specific method of factor segmentation is shown in step 1 of the algorithm. In the N-dimensional space, set Q parents involved in the recombination be \({p_1},{p_2}, \ldots {p_Q}\). Each parent involved in the recombination was regarded as a level of the orthogonal design, namely the Q level. Then, each parent was divided into T groups, and each group was considered as one factor. In this way, the recombination problem of Q parent individuals is transformed into the orthogonal design problem of Q level and T factor. The whole algorithm flow is as follows: (1) The Q parent individuals involved in the recombination were considered as a level of the orthogonal design, and the i-th level was denoted as \({\beta _i}\), \({i} \in \left\{ {1,2,3, \cdots Q} \right\} \) (2) The specific grouping method is: randomly generate \(T-1\) integers, that is \(\;{k_1},\mathrm{{ }}{k_2}...,\mathrm{{ }}{k_{T - 1}}\), and satisfy the requirement that \(1< {k_1}< {k_2}< ...< {k_{T - 1}} < N\). Individual \( X = ({X_1},{X_2} \ldots ,{X_N})\) is divided into T parts, each of which represents a factor of individual X.

$$\begin{aligned} \left\{ {\begin{array}{*{20}{l}} {{f_1} = \left( {{x_1},{x_2}, \cdots ,{x_{k1}}} \right) }\\ {{f_2} = \left( {{x_{{k_1} + 1}},{x_{{k_1} + 2}}, \cdots ,{x_k}_2} \right) }\\ \cdots \\ {{f_T} = \left( {{x_{{k_{T - 1}}}},{x_{{k_{T - 1}} + 1}}, \cdots ,x{}_N} \right) } \end{array}} \right. \end{aligned}$$
(13)

Therefore, the Q levels of the i-th factor can be expressed as

$$\begin{aligned} \left\{ {\begin{array}{*{20}{l}} {{f_i}(1) = \left( {{\beta _k}{{_{_{i - 1}}}_{ + 1,1}},{\beta _k}{{_{_{i - 1}}}_{ + 2,1}} \ldots ,{\beta _{k,1}}} \right) }\\ {{f_i}(2) = \left( {{\beta _k}{{_{_{i - 1}}}_{ + 1,2}},{\beta _k}{{_{_{i - 1}}}_{ + 2,2}} \ldots ,{\beta _{k,2}}} \right) }\\ \cdots \\ {{f_i}(Q) = \left( {{\beta _k}{{_{_{i - 1}}}_{ + 1,Q}},{\beta _k}{{_{_{i - 1}}}_{ + 2,Q}} \ldots ,{\beta _{k,Q}}} \right) } \end{array}} \right. \end{aligned}$$
(14)

(3) Select orthogonal table and M descendants were generated according to the orthogonal table

$$\begin{aligned} \left\{ {\begin{array}{*{20}{l}} \displaystyle {\left( {{f_1}({b_{1,1}}),{f_2}({b_{1,2}}), \cdots {f_T}({b_{1,T}})} \right) }\\ {\left( {{f_1}({b_{2,1}}),{f_2}({b_{2,2}}), \cdots {f_T}({b_{2,T}})} \right) }\\ \cdots \\ {\left( {{f_1}({b_{M,1}}),{f_2}({b_{M,2}}), \cdots {f_T}({b_{M,T}})} \right) } \end{array}} \right. \end{aligned}$$
(15)
figure a

The proposed OGA uses dynamic selection of optimal setting \({S_i}\) based on estimated path loss, depending on the parameter combination with a minimum probability of collision, as per (11). In this paper, each settings is a combination of independently varying SF, BW, CR and TP and thus is a subset of \(\mathrm{{S = \{ SF, BW, CR, TP\} }}\). At the beginning, the proposed method initializes \({S_i}\) by using orthogonal design method to generate the initial population \(S = ({7,125,1,2}), ({7,500,4,11}), ({8,250,2,5}), ({8,500,3,14}), ({9,500,3,8}), ({9,125,2,8}), ({10,125,4,11}), ({10,250,1,5}), ({11,125,3,2}), ({11,250,4,14}) \), as it generate among all possible settings in LoRa transmission. Then set the maximum iterations \(T=30\), the initial iteration \(T=0\). After generating the population, it is first determined whether the number of iterations is reached. Random select two parent individuals to perform three cross operations at different positions. Calculate the fitness value (\(L_{path}\)) of the candidate solution, that is, the process of the above multi-point cross, hence generate the child generation population \(t+1\). The probability of selection = individual fitness value/total fitness value. The method then iterates over all possible setting and chooses the \({S_i}\) which minimum collision possibility (fitness value) is within 4% for successful communication.

6 Evaluation and Results of Simulation Experiments

We used NS3 simulator to evaluate the scalability of LoRa networks. Since large-scale network deployment would be prohibitively expensive, it is not feasible to evaluate the scalability of such LoRa networks in real scenarios. For scalability, we focus on the capacity of a single gateway. This section presents the numerical results of the proposed method. We calculated PDR with respect to the total number of devices ranging from 0 to 10,000. The parameters in the experimental simulation are shown in Table 1.

Table 1. Parameters set.

6.1 The Impact of Parameter Selection

In this subsection, we first present the results of simulations with different SFs as a function of the number of end devices (up to 5000). Figure 3 shows PDR with different SFs from 7 to 12. We can see that PDR decreases when the number of end device increases. The SF7 has better PDR compared with the others due to its short ToA but its range is reduced. Figure 4 shows the PDR with different SFs and CR. We can conclude that the higher CR (4/8) experience better PDR because it provide more protect. This means selection of parameters has a significant impact on network performance.

Fig. 3.
figure 3

The impact of SF selection.

Fig. 4.
figure 4

The impact of CR and SF selection.

6.2 End Device Distribution Assessment

We define the ratio of devices using SF i as \({\partial _i}\). The motivation of our study is to optimize the PDR in environments where a large number of devices can use the same SF, thus the biased deployment must be considered. The optimized distribution of end devices \(({\partial _7},{\partial _8},{\partial _9},{\partial _{10}},{\partial _{11}},{\partial _{12}})\) is (0.3, 0.1, 0.1, 0.2, 0.3, 0). The sum of the devices allocated by all SF is the total number of devices in the network. Although SF12 provides a larger coverage, it also increases the probability of collision, so we neglect its allocation. The network is serviced by a gateway located in the center of a circle with a radius of 8 km. The device distribution is shown in the Fig. 5.

Fig. 5.
figure 5

End device distribution without SF = 12.

Fig. 6.
figure 6

PER control parameter selection within 4%.

6.3 Scalability Analyses

Before assessing PDR, first analyzes the PER of TP and DR determined by different SF, BW and CR, and the Fig. 6 of the DR value of 1 to 6. The SF, BW, and CR corresponding to the DR are shown in Table 2, according to the basic trend is rising with the increase of power, in the case of DR for 1 and 2, may be affected by the power of saturated, the overall PER are relatively low. Figure 6 shows the parameter selection with the set fitness value controlled within 4%.

Table 2. SF, BW and CR corresponding to different DRs.
Fig. 7.
figure 7

Compare with dynamic parameter settings of PDR under 1000 device.

Figure 7 shows the PDR of the dynamic parameter method LoRa-TS and LoRa-AT under 1000 end device. With the increase number of end devices, the proposed method of dynamic parameter selection has a significant improvement on PDR. The Fig. 8 shows a comparison of PDRs for different dynamic methods of up to 10,000 end devices. The method in NS3, for each end device, by dynamically assigning the SF of lowest PER below a certain threshold and employed same parameters such as BW, CR and TP, the PDR based on OGA method was always high regardless of the number of end devices. In SN5, dynamic parameter selection is used, the minimum ToA and minimum TP are selected each time. When the number of end devices is less than 2000, there is no obvious difference in PDR, but when the number of end devices is large, the OGA method proposed in this paper has obvious advantages, it is worth noting that above situations all have the same PS with 20B.

The proposed OGA method also has some advantages in terms of PS. We change the PS for end devices and measure the corresponding PDR. From the Fig. 9, it can be seen that the PDR difference between different methods is not obvious when the payload is smaller as the gateway is not saturated. As the PS increases and the gateway becomes saturated, however, increasing the PS decreases the capacity, as expected. Specially, for 200 devices, the PDRs achieved for payload size of 80 are improved about 70%, which is quite significant.

Fig. 8.
figure 8

Different dynamic parameter settings of PDR under 10000 device.

Fig. 9.
figure 9

Different PS of the PDR with 200 devices.

7 Conclusions

In this paper, The OGA method is introduced to solve the established channel collision and link budget model, which made the parameters of LoRa network selected dynamically. By the above method, the minimized collision probability parameter combination of which probability is 30% higher than the static parameter could be obtained. It is verified that LoRa network can be well scale by dynamic parameter selection. LoRa can support the deployment of a large number of applications, such as smart meters, smart parking and street lighting. However, most support multiple applications over a single current network deployment studies only support network simulation using a single IoT application, and different IoT applications have different data requirements on the amount of data to be transmitted and quality of service requirements. So our next step is to study application’s data generation rate for different applications.