Abstract

In recent years, indoor positioning systems (IPS) are increasingly very important for a smart factory, and the Lora positioning system based on round-trip time (RTT) has been developed. This paper introduces the ranging characterization, RTT measurement, and position estimation method. In particular, a particle filter localization method-aided Lora pseudorange fitting correction is designed to solve the problem of indoor positioning; the cumulative distribution function (CDF) criteria are used to measure the quality of the estimated location in comparison to the ground truth location; when the positioning error on the -axis threshold is 0.2 m and 0.6 m, the CDF with pseudorange correction is 61% and 99%, which are higher than the 32% and 85% without pseudorange correction. When the positioning error on the -axis threshold is 0.2 m and 0.6 m, the CDF with pseudorange correction is 71% and 99.9%, which are higher than the 52% and 94.8% without pseudorange correction.

1. Introduction

Indoor positioning systems are increasingly very important for a smart factory, such as finding the location of workers, goods, or vehicles [14]. However, the Global Positioning System (GPS) is unable to provide the indoor positioning service, which is commonly used for outdoor positioning. The research on indoor positioning technologies has been conducted for more than three decades, such as Radio Frequency Identification (RFID) [5, 6], WiFi [7, 8], Ultra Wide Band (UWB) [911], Pseudolite [1214], Bluetooth [15], and Inertial Navigation System (INS), but they may not be suitable for Internet of Things (IoT) applications in terms of cost, application mode, and terminal power consumption.

With the continuous progress of sensor and Internet of Things [16, 17] technologies, increasing attention has been paid to IPS using Lora WAN. Semtech has developed a Lora positioning system based on round-trip time [18], which is called the SX1280 transceiver. The SX1280 transceiver family provides ultra-long-range communication in the 2.4 GHz band with a time-of-flight functionality; its radio is fully compliant with all worldwide 2.4 GHz radio regulations including EN 300440, FCC CFR 47 Part 15 [19], and the Japanese ARIB STD-T66 [20]. Very small wearable products to track and localize assets in logistic chains and people for safety can easily be designed thanks to the high level of integration and the ultralow current consumption which allows the use of miniaturized batteries.

But the most difficult challenge for Lora indoor positioning is the ranging error caused by multipath in the indoor environment. Liang et al. carry out the study focused on the indoor propagation of the Lora signal, and the main contribution of this work is to measure the round-trip time and packet delivery ratio by changing send power, payload length, and air rate in a multilevel building from the 1st floor to the 12th floor [21]. Huynh and Brennan verify the UWB transmission characteristics of an indoor RTT signal by generating synthetic received signals using ray tracing plus Rayleigh distributed random multipath clusters as well as random amplitude and delay factors [22]. Staniec and Kowal describe outcomes of measurement campaigns during which the Lora performance was tested against a heavy multipath propagation and a controlled [23], Lora configurational space is divided into three distinct sensitivity regions: in the white region, it is immune to both interference and multipath propagation; in the light-grey region, it is only immune to the multipath phenomenon but sensitive to interference; and in the dark grey region, Lora is vulnerable to both phenomena.

On the other hand, location based on a filtering algorithm is the only effective solution currently known, and the Bayesian filtering algorithm occupies an important role. In the early days, the Kalman filter positioning algorithm is mainly used to solve the problem achieving efficient state estimation for linear Gaussian systems [24]. Moreover, to deal with unwanted errors and nonlinear distortions, particle filter (PF) is applied as a nonparametric filter to location, which is recursive implementations of Monte Carlo-based statistical processing [2527] and performs well in localization efficiency, stability, and accuracy.

In the following sections, a Lora indoor positioning system is introduced, which overcomes the problem of long distance, low power consumption, and low cost. The main contributions and research content of this paper are as follows: Firstly, a Lora-aided particle filter localization method is designed to solve the problem of indoor positioning. Secondly, numerous experiments were carried out with real Lora RTT measurement data to evaluate the performance of the proposed approach; we used the CDF criteria to measure the quality of the estimated location in comparison to the ground truth location. The results show that the indoor positioning accuracy is improved obviously with the help of the piecewise fitting correction method. At the same time, the Lora indoor positioning system can achieve a positioning accuracy of 1 m under the condition of LOS.

2.1. Lora RTT Measurement

In this paper, we focus on one of the latest techniques called the RTT scheme-based ranging and localization [2830], which can give accurate measurements by the time stamp from the initiator (Lora_) to the responder (Lora_) with nanosecond resolution. Figure 1 shows the RTT measurement illustration; the pseudorange measurement can be built as where or is the pseudorange measurement between Lora_ and Lora_, or is the geometric range between Lora_ and Lora_, is the clock offset of Lora_ at the receiving time, is the clock offset of Lora_ at the transmitting time, is the clock offset of Lora_ at the receiving time, and is the clock offset of Lora_ at the transmitting time.

If the clock characteristics of Lora_ and Lora_ are stable, and at the adjacent time of receiving and transmitting. The time-of-flight (ToF) measurements can be written as where is the time-of-flight (ToF) measurements of Lora_ from Tx_ to Rx_, is the time difference of Lora_ between Rx_ and Tx_.

The geometric distance can be calculated by

The pseudorange measurement can be built as where , , and are the transmitting antenna coordinates of Lora_; , , and are the transmitting antenna coordinates of Lora_; and is measurement error.

2.2. Position Estimation

Four distance measurements of Lora transceivers whose positions are known are used to determine the three-dimensional coordinates of an unknown position [31], as shown in Figure 2. The position of user () can be calculated by where is the pseudorange measurement of , is the AP index, and is the user index, () are the locations of , and is the measurement error of .

The geometric distance can be calculated by where is called a geometry matrix.

The observation equations of Lora RTT can be expressed as the following matrix form:

The matrix on the right-hand side of Equation (8) is defined as and , and the two-column vectors on the left-hand side are defined as . Equation (8) can be written as

If an initial value is used for the solution-updating process, the Newton-Raphson method is described as. The least-squares updated solution can be represented as

Then, the position can be updated iteratively according to

It should be noted that the measurement error is considered Gaussian white noise, when using the least-squares method.

3. Ranging Characterization of Lora

3.1. Clock Error

It is supposed that the clock offsets of devices Lora_ and Lora_ are and ; therefore, the ranging error will increase with the increase of flight time. The equation of ranging error is as follows: where is ranging error caused by the clock offsets.

If the clock error of Lora_ and Lora_ is the same, Equation (12) can be written as

It is supposed that the distance between the two Lora nodes is between 10 meters and 5000 meters; then, is from 3 ns to 1500 ns. The clock error of packaged crystal oscillator (PCO) is generally more than 25 ppm, the temperature compensated crystal oscillator (TCXO) is from 0.5 ppm to 5 ppm, and the oven-controlled crystal oscillator (OCXO) may be less than 0.1 ppm. According to the above parameters, we estimate the influence of clock error on Lora ranging accuracy, as shown in Table 1. It can be found that TCXO and OCXO are best used as the clock of the Lora positioning system.

3.2. Ranging Accuracy and Characterization

The reflection of the indoor environment to the Lora positioning signal is very serious, for example, irregular room structure, walking people, tables and chairs, and glass. Because of signal interference and multipath effect, Lora’s ranging error may be non-Gaussian distribution. We collect the ranging data of Lora under different conditions such as line-of-sight (LOS), non-line-of-sight (NLOS), and human occlusion, which is compared with the real distance to analyze the ranging characterization.

Three sets of ranging data are collected under the LOS condition; the ranging error of Lora is shown in Figure 3. The average error is -0.61 m, the maximum error is 1.2 m, and the minimum error is -5.24 m. It can be found that the ranging error of LOS has a linear trend, which can be corrected by the polynomial fitting method.

Similarly, three sets of ranging data are collected under the NLOS condition, such as using people’s bodies to block Lora’s antenna; the ranging error of Lora is shown in Figure 4. The average error is -0.01 m, the maximum error is 8.6 m, and the minimum error is -3.32 m. It can be found that the ranging error of NLOS is much worse than that of LOS; therefore, it is better to use the Lora indoor positioning system under the condition of LOS.

In order to analyze the distribution characteristics of Lora ranging error, the six groups of data collected above are combined, as shown in Figure 5. Figure 5(a) shows the histogram with a distribution fit, and Figure 5(b) is the normal probability plot. It can be concluded that the probability distribution of Lora ranging error is non-Gaussian white noise. Therefore, it is necessary to use nonlinear filter to solve the location problem.

The piecewise fitting correction method of LOS is used to correct the Lora ranging value, as shown in Figure 6. The formula of the piecewise fitting correction method can be expressed as where is the pseudorange measurement of Lora, is the corrected pseudorange, is the correction function, and are the linear correction factors, and and are the stages; the above data of LOS are divided into three sections; that is, .

3.3. Geometry Factor

The dilution of geometry precision (GDOP) [32, 33] can be expressed as

If is defined as , the diagonal elements of are as follows:

and can be defined as where means the dilution of precision (DOP) for the -coordinate and means the DOP for the -coordinate.

In order to analyze the influence of the geometry factor on Lora positioning performance, a simulation of geometry distribution is designed, which is composed of four Lora transceivers. Suppose the length and width of the room are 40 meters and the height is 3 meters, as shown in Figure 7. The of the indoor positioning system is given in Figures 8(a) and 9(a); the GDOP of the indoor positioning system is given in Figures 8(b) and 9(b). The results show that four Lora transceivers can obtain the suitable geometric distribution in their projection area, whose and are less than 1.2. However, outside the projection area, the geometric distribution will deteriorate; and will be greater than 2, which will make the positioning error more than twice of the ranging error.

4. Methodology Based on Particle Filter

4.1. Recursive Bayesian Estimation

Applied nonlinear filtering is based on discrete-time nonlinear state-space models relating a hidden state to the observations , denote the observations at time by , the Bayesian solution to compute the posterior distribution is given by where is the time stamp, is the state variable, is the posterior probability distribution of the last moment, is the state transition probability, is the prior probability distribution, is the likelihood function, and is the normalization function.

4.2. Particle Filter

Supposed that particles from the posterior probability of the state can be extracted, where is the state of the particle, is the weight of the particle; then, where is the Dirac delta function and is the number of particles.

The Sequential Importance Sampling (SIS) method is used to calculate the weight of particles, which is written as

The prior probability distribution is used as the importance density function:

Then, the formula for calculating the weight of particles is where is time stamp, is the number of particles, and is the weight of particles.

4.3. Particle Filter Implementation

The particle filter algorithm is summarized in Table 2. Firstly, the state parameters and weights of particles are initialized; secondly, the iterative process of the particle filter algorithm is divided into four steps, which includes measurement update, estimation, resampling, and time update.

5. Experimental Results and Analysis

5.1. Experimental Setup

The performance of the Lora positioning system is evaluated in a room as shown in Figure 10; the size of the room is about 25 meters long, 4 meters wide, and 2.5 meters high; and the antenna coordinates of Lora are surveyed precisely with a total station.

5.2. Experimental Results

Figure 11 shows the static test without pseudorange correction for the Lora positioning system, Figure 11(a) is the positioning results, Figure 11(b) is the -axis positioning error, and Figure 11(c) is the -axis positioning error. The average positioning error is 0.11 m in the -axis and 0.07 m in the -axis, the maximum positioning error is 1.25 m in the -axis and 0.59 m in the -axis, and the standard deviation of the -axis and -axis errors is 0.42 m and 0.18 m, respectively.

Figure 12 shows the static test without pseudorange correction (the piecewise fitting correction method) for the Lora positioning system, Figure 12(a) is the positioning results, Figure 12(b) is the -axis positioning error, and Figure 12(c) is the -axis positioning error. The average positioning error is 0.01 m in the -axis and 0.07 m in the -axis, the maximum positioning error is 0.72 m in the -axis and 0.70 m in the -axis, and the standard deviation of the -axis and -axis errors is 0.22 m and 0.12 m, respectively.

The positioning error in terms of the cumulative distribution function on the databases with and without pseudorange correction is shown in Figure 13. When the positioning error on the -axis threshold is 0.2 m and 0.6 m, the CDF with pseudorange correction is 61% and 99%, which are higher than the 32% and 85% without pseudorange correction. When the positioning error on the -axis threshold is 0.2 m and 0.6 m, the CDF with pseudorange correction is 71% and 99.9%, which are higher than the 52% and 94.8% without pseudorange correction.

6. Conclusions

The long-distance transmission of Lora wireless technology makes it possible to be widely used in the smart factory; this paper proposes Lora RTT measurement for indoor positioning, which has two key aspects of innovations: Firstly, a Lora-aided particle filter localization method is designed to solve the problem for indoor positioning. Secondly, numerous experiments were carried out with Lora RTT measurement data to evaluate the performance of the proposed approach; we used the CDF criteria to measure the quality of the estimated location in comparison to the truth location. The results show that the indoor positioning accuracy is improved obviously with the help of the piecewise fitting correction method. At the same time, the Lora indoor positioning system can achieve a positioning accuracy of 1 m under the condition of LOS. In the future, we will focus on Lora indoor positioning and pseudorange correction under the condition of NLOS.

Data Availability

No data were used to support this study.

Conflicts of Interest

The authors declare that they have no conflicts of interest.

Acknowledgments

This research was supported by the project “Key technologies of multi-mode integration of navigation and positioning with 5G,” which is part of the Key R&D projects in Hebei Province, Contract No. 20310901D.