Ranging error compensation method for indoor positioning precision time measurement
By identifying the differences between LOS and NLOS signals and RSSI information, and combining particle filtering algorithm and least squares fitting, the NLOS error is dynamically compensated, solving the ranging error problem under non-line-of-sight conditions in indoor positioning systems, and improving positioning accuracy and robustness.
Patent Information
- Application Number
- CN202410468338.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-18
- Publication Date
- 2025-10-24
AI Technical Summary
In indoor positioning systems, ranging errors under non-line-of-sight conditions make it difficult to achieve meter-level positioning accuracy. In particular, the offset error is large under line-of-sight conditions, which affects the accuracy of high-precision positioning applications.
By identifying the differences between LOS and NLOS signals, RSSI information, and power attenuation models, a LOS/NLOS error compensation model is designed. This model is then combined with a particle filter algorithm for error correction, dynamically compensating for ranging errors under NLOS conditions. The least squares method is used to fit the LOS error data and correct the LOS ranging data.
It improves indoor positioning accuracy, reduces false positives and false negatives, is suitable for real-time positioning in mobile environments, and enhances the adaptability and robustness of the positioning algorithm under complex and variable signal conditions.
Smart Images

Figure CN120835377A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of indoor positioning, and particularly relates to a ranging error compensation method for indoor positioning precise time measurement. BACKGROUND
[0002] With the popularity of intelligent devices and the development of Internet of Things technology, indoor positioning technology has become a research hotspot. Indoor positioning technology is mainly divided into two categories: range-based and range-free. Range-based technology usually provides higher positioning accuracy, but has higher requirements for sensor nodes and is easily affected by external environment. Range-free technology realizes positioning through signal feature matching and other methods, although the accuracy is relatively low, but it is more practical in some scenarios.
[0003] FTM technology is a precise time measurement method introduced in IEEE 802.11-2016 protocol, which measures distance through Round-Trip Time (RTT) round-trip time. The advantage of FTM technology is its high-precision time synchronization capability, which can significantly improve the accuracy of indoor positioning. However, due to the non-Gaussian nature of noise in 802.11mc, it is difficult to further improve the accuracy, resulting in difficult to achieve meter-level positioning accuracy. The application of FTM technology is getting attention, especially in the field of indoor positioning. Through FTM, more accurate ranging can be achieved, thereby improving the overall performance of the positioning system. At present, the ranging scheme based on FTM usually has an offset error of 1-2 meters in line-of-sight environment, but the accuracy improvement in non-line-of-sight environment is a challenge.
[0004] In indoor positioning systems, ranging error compensation under non-line-of-sight (NLOS) and line-of-sight (LOS) conditions is crucial for improving positioning accuracy. Due to the complexity of indoor environment, wireless signals are often affected by various factors such as the blocking and reflection of obstacles such as walls, furniture, and human bodies during transmission. These factors can cause the signal transmission path to be deflected, resulting in non-line-of-sight effects. Under non-line-of-sight conditions, the signal transmission path is no longer a straight line, which can increase the ranging error and affect the accuracy of positioning.
[0005] The ranging error under line-of-sight conditions mainly comes from the time delay in the signal transmission process and the synchronization error of the hardware devices. Although the error under line-of-sight conditions is relatively small, it cannot be ignored in high-precision positioning applications. For example, in medical, industrial manufacturing and other scenarios with extremely high positioning accuracy requirements, even a small error can cause serious consequences.
[0006] To address these issues, researchers and engineers have developed various error compensation techniques. These techniques aim to reduce ranging errors under both line-of-sight (LOS) and non-line-of-sight (NLOS) conditions through algorithm optimization and signal processing. For example, some advanced algorithms can utilize machine learning techniques to identify and distinguish between LOS and NLOS signals, thereby correcting NLOS signals. Additionally, by establishing multi-path propagation models and signal attenuation models, the loss of signals during propagation can be more accurately predicted and compensated for.
[0007] In practical applications, the effectiveness of error compensation techniques is typically verified through experiments. By conducting a large number of tests in different environments, rich data can be collected to evaluate the performance of error compensation algorithms. These data not only help to optimize existing algorithms, but also provide valuable references for the development of new error compensation techniques. SUMMARY
[0008] The present application aims to provide a ranging error compensation method for indoor positioning precise time measurement. By utilizing the differences between line-of-sight (LOS) and non-line-of-sight (NLOS) signals, received signal strength indication (RSSI) information, and power attenuation models, an error type identification method is established to accurately identify LOS and NLOS signals. LOS / NLOS error compensation models are then established to improve positioning accuracy. Finally, the corrected ranging data is input into a particle filter positioning algorithm for mobile target positioning.
[0009] The present application provides a ranging error compensation method for indoor positioning precise time measurement, comprising the following steps:
[0010] Step 1: Collecting precise time measurement (FTM) ranging data sets in a mixed LOS / NLOS environment;
[0011] Step 2: Discriminating the collected ranging data through LOS signal and NLOS signal identification conditions,
[0012] If the ranging data is determined to be NLOS, input the ranging data into the NLOS error compensation model for error correction to obtain error-corrected ranging data,
[0013] If the ranging data is determined to be LOS, input the ranging data into the LOS error compensation model for error correction to obtain error-corrected ranging data;
[0014] Step 3: Designing a particle filter positioning algorithm, inputting the error-corrected ranging data into the particle filter positioning algorithm to obtain the final target object position information.
[0015] Preferably, step 1 includes the following sub-steps:
[0016] Step 1.1: Deploy at least three devices supporting the Wi-Fi Precise Time Measurement (FTM) protocol in the corners of the target site. These devices act as fixed access points (APs) to send and receive FTM signals. Target objects carrying FTM-capable devices act as mobile stations (STAs).
[0017] Step 1.2: Collect FTM ranging data between STA and AP in real time.
[0018] Preferably, step 2 includes the following sub-steps:
[0019] Step 2.1, calculate the relative position and relative distance error of the target;
[0020] Step 2.2, design error identification conditions under mixed environment;
[0021] In step 2.3, a nonlinear error compensation method is designed. After compensation through the NLOS / LOS error compensation model, the corrected ranging data is obtained and input into the particle filter algorithm as observation data to adjust the particle weight.
[0022] Preferably, in step 2.2, the distance measurement data d at the current moment and the previous two moments are integrated i The standard deviation I1, the standard deviation I2 of the received signal strength indicator (RSSI), and the received power P o Relative to the transmit power P r The difference between |P o -P r |Standard deviation I3,
[0023] Through a large amount of measurement data, the weight constants a, b and c corresponding to the standard deviation are set to establish the discrimination formula between LOS signal and NLOS signal
[0024] Preferably, in step 2.2, determine the discrimination threshold M dis , through the discrimination threshold M dis , judge the discriminant of the distance measurement data at the current moment Is it greater than the discrimination threshold M dis ,
[0025] If M>M dis , then the corresponding distance data d i The distance at which NLOS transmission is determined;
[0026] The error is corrected through the NLOS error compensation model to obtain more accurate NLOS ranging data for the subsequent operation of the positioning algorithm.
[0027] If M<M dis , then the corresponding distance data di The distance when the LOS propagation is determined and the LOS error compensation is performed through the PSO-DNN-based neural network error compensation model.
[0028] Preferably, in step 2.3, when it is detected that the current ranging information of one of the FTM ranging devices is NLOS information, the position information of the previous two time points (x k-2 ,y k-2 ), (x k-1 ,y k-1 ) is extracted through the particle filter positioning algorithm.
[0029] The Euclidean distance d is calculated using the position coordinates (x k ,y k ) output by the variable-direction constant-speed prediction model and the device coordinates (x ap ,y ap ) identified as NLOS ranging information. The distance d is used to replace the NLOS ranging data d ap , so as to realize error correction of the NLOS ranging data.
[0030] Preferably, in step 2.3, when it is detected that the current ranging information of the ranging device is LOS information, the least squares method is used to fit the relationship between the ranging error and the actual distance, and the least squares method is used to fit the collected ranging data, so as to establish the LOS error compensation model.
[0031] Preferably, in step 2.3, the relationship between the ranging error e i and the actual distance d i is represented as
[0032] where k0, k1,..., k n are fitting coefficients, and n is the order of the polynomial. If there are n ranging error data, an error matrix equation can be constructed:
[0033] By constructing the error matrix K, the distance matrix D, and the error vector E, and then applying the least squares method to solve the coefficient matrix A = (D T D) -1 D T E.
[0034] Preferably, in step 2.3, for new LOS ranging data, the theoretical distance d theo is first calculated, then the compensated error e comp is calculated using the constructed LOS error model, and finally the compensated distance d comp = d theo -e comp .
[0035] Preferably, in step 3, the particle filter algorithm is used to conduct indoor positioning by using the particle instead of the position and speed information of the moving object.
[0036] Compared with the prior art, the present application has the following obvious substantial features and significant technical progress:
[0037] 1. A comprehensive error identification method is proposed, which can more accurately identify NLOS signals by combining the differences between LOS and NLOS signals, RSSI information and power attenuation model, thereby reducing misjudgment and omission and improving the accuracy of error correction.
[0038] 2. A dynamic compensation mechanism is designed, which uses a prediction method based on constant speed and variable direction motion for NLOS error signals, and can dynamically predict and compensate the ranging error under NLOS conditions. This dynamic compensation considers the speed and direction changes of the moving object, and is more suitable for real-time positioning in mobile environments compared with traditional static compensation methods. For LOS error signals, the least squares method is used to fit the collected LOS ranging error data to establish an error model and correct the LOS ranging data.
[0039] 3. The particle filter algorithm is introduced into the model, which can update the distribution of particles according to real-time data, improving the adaptability and robustness of the positioning algorithm to complex and variable signal conditions under NLOS environment.
[0040] 4. These correction models are not only applicable to the current FTM technology, but also can be extended to other indoor positioning technologies based on time measurement, such as Ultra-Wideband (UWB) and Bluetooth Low Energy (BLE) etc. BRIEF DESCRIPTION OF DRAWINGS
[0041] Figure 1 The flowchart of the ranging error compensation method in the embodiment of the present application;
[0042] Figure 2 The process diagram of the FTM protocol in the embodiment of the present application;
[0043] Figure 3 The schematic diagram of the variable direction constant speed prediction model in the embodiment of the present application;
[0044] Figure 4 The ranging compensation flowchart in the embodiment of the present application;
[0045] Figure 5 The flowchart of the particle filter indoor positioning algorithm in the embodiment of the present application. DETAILED DESCRIPTION
[0046] The application aims to provide a ranging error compensation method for indoor positioning precise time measurement, which utilizes the difference between line-of-sight (LOS) and non-line-of-sight (NLOS) signals, received signal strength indication (RSSI) information and power attenuation model to establish an error type identification method, accurately identify LOS and NLOS signals, and respectively establish LOS / NLOS error compensation models to improve positioning accuracy, and finally input the corrected ranging data into a particle filtering positioning algorithm for positioning of a moving target.
[0047] In order to make the technical means, creative features, purposes and effects of the application easy to understand, the application is further described below in combination with specific embodiments.
[0048] Figure 1 For the ranging error compensation method flowchart in the embodiments of the application, Figure 2 For the FTM protocol process chart in the embodiments of the application.
[0049] Referring to Figure 1 , 2 The embodiment provides a ranging error compensation method for indoor positioning precise time measurement, comprising the following steps:
[0050] Step 1, collecting a precise time measurement (FTM) ranging data set in a LOS / NLOS mixed environment.
[0051] Step 1 comprises the following sub-steps:
[0052] Step 1.1, deploying at least 3 or more devices supporting Wi-Fi precise time measurement (FTM) protocol at the corners of a target site, the devices serving as fixed access points (APs) for transmitting and receiving FTM signals, and a target object carrying a device supporting the FTM protocol, serving as a mobile station (STA), which moves in an indoor environment and whose position needs to be accurately determined.
[0053] Step 1.2, collecting FTM ranging data between the STA and the AP in real time.
[0054] The distance between the STA and the AP is measured in real time through the FTM protocol. The FTM technology utilizes the round trip time (RTT) of wireless signals to calculate the distance between the STA and the AP.
[0055] In this embodiment, 3 ESP32-S3 development boards are deployed as fixed access points (APs) in the corner of the target site. The target object carries a device supporting the FTM protocol, acting as a mobile station (STA). The STA is a device that initiates an FTM request to the AP, and the AP is a wireless network device that receives and responds to the FTM request. When the STA initiates an FTM request, the AP decides whether to accept the FTM ranging according to the protocol; once both parties agree, the AP starts sending FTM messages and records the sending timestamp t1; the AP waits for the STA's acknowledgement (ACK), the STA receives the ACK message and records the arrival timestamp t2 of the FTM message, then sends the STA's ACK to the AP and records the sending timestamp t3 of the ACK; the AP receives the ACK message and records the timestamp t4; the round-trip time is calculated by the sending timestamp and the receiving timestamp The AP can send multiple FTM messages, but cannot send new FTM messages before receiving the STA's ACK. The distance between the ESP32-S3 and each AP is calculated according to the speed of light c and the RTT
[0056] In this embodiment, FTM can achieve meter-level or even higher accuracy positioning using precise time synchronization and measurement.
[0057] Step 2, the collected ranging data is distinguished by the LOS signal and NLOS signal identification condition.
[0058] If the ranging data is determined to be NLOS, the ranging data is input into the NLOS error compensation model for error correction to obtain error-corrected ranging data;
[0059] If the ranging data is determined to be LOS, the ranging data is input into the LOS error compensation model for error correction to obtain error-corrected ranging data.
[0060] Specifically, step 2 includes the following sub-steps:
[0061] Step 2.1, the relative position and relative distance error of the target are obtained;
[0062] Step 2.2, the error identification condition in a mixed environment is designed;
[0063] Step 2.3, a nonlinear error compensation method is designed, and after compensation by the NLOS / LOS error compensation model, the corrected ranging data is obtained as the observation data input into the particle filter algorithm to adjust the particle weight.
[0064] Figure 3 The variable-direction constant-speed prediction model in the embodiment of the application is shown in the schematic diagram, Figure 4 The ranging compensation flowchart in the embodiment of the application is shown in the schematic diagram.
[0065] In step 2.2, see Figure 3 、 4 In this embodiment, the distance measurement data d at the current moment and the previous two moments are combined i The standard deviation I1, the standard deviation I2 of the received signal strength indicator (RSSI), and the received power P o Relative to the transmit power P r The difference between |P o -P r |Standard deviation I3.
[0066] Through a large amount of measurement data, the weight constants a, b and c corresponding to the standard deviation are set to establish the discrimination formula between LOS signal and NLOS signal
[0067] At the same time, determine the discrimination threshold M dis , through the discrimination threshold M dis , judge the discriminant of the distance measurement data at the current moment Is it greater than the discrimination threshold M dis .
[0068] If M>M dis , then the corresponding distance data d i The distance when it is determined to be NLOS propagation is corrected by the NLOS error compensation model to obtain more accurate NLOS ranging data for subsequent positioning algorithm operation.
[0069] If M<M dis , then the corresponding distance data d i The distance at which LOS propagation is determined is used to establish a LOS error compensation model through a discrete point fitting method based on least squares (LS) to compensate for the LOS error.
[0070] In step 2.3, when it is detected that the current distance information of one of the FTM ranging devices is NLOS distance, the position information of the previous two moments (x k-2 ,y k-2 )、(x k-1 ,y k-1 ); Through the variable direction uniform speed prediction model, it is assumed that the target moving direction angle θ is variable and the speed v is constant. The NLOS error correction model replaces the direction vector of the current moment with the direction vector of the previous two moments, that is, Then, the displacement of the moving target in the x and y directions at the current moment is calculated according to Δx = v·Δt·cosθ and Δy = v·Δt·sinθ, where Δt is the time difference from the previous moment to the current moment. The current position (x ky k ); wherein x k = x k-1 + Δx, y k = y k-1 + Δy. The Euclidean distance d is calculated using the position coordinates (x k , y k ) output by the variable direction constant velocity prediction model and the device coordinates (x ap , y ap ) identified as NLOS ranging information The distance d is used to replace the NLOS ranging data d ap , and the error of the NLOS ranging data is corrected.
[0071] When it is detected that the current ranging information of the ranging device is LOS information, a least squares method can be used to fit the relationship between the ranging error and the actual distance. The least squares method is used to fit the collected ranging data, and an LOS error compensation model is established.
[0072] The relationship between the ranging error e i and the actual distance d i may be expressed as wherein k0, k1,... k n are fitting coefficients, and n is the order of the polynomial. If there are n ranging error data, an error matrix equation can be constructed:
[0073] By constructing the error matrix K, the distance matrix D, and the error vector E, and then applying the least squares method to solve the coefficient matrix A = (D T D) -1 D T E, for new LOS ranging data, the theoretical distance d theo is calculated first, and then the compensated error e comp is calculated using the constructed LOS error model, and finally the compensated distance d comp = d theo - e comp .
[0074] Finally, the modified ranging data d i ' obtained after compensation by the NLOS / LOS error compensation model is input as observation data into the particle filter algorithm to adjust the particle weight w i .
[0075] Step 3, design a particle filter positioning algorithm, input the error corrected ranging data into the particle filter positioning algorithm, and obtain the final position information of the target object.
[0076] Figure 5This is a flow chart of the particle filter indoor positioning algorithm in an embodiment of the present invention.
[0077] See also Figure 5 ,use particle filter indoor positioning technology to combine the precise time measurement capability of FTM and the nonlinear system processing capability of particle filter algorithm to improve the accuracy and robustness of indoor positioning.
[0078] The probability distribution of the state space is approximated by a series of random samples. Each sample (particle) represents a possible state of the system, including the position coordinates (x i ,y i ), speed v i Etc. Use particles to represent the position (x, y) and velocity v of the person when he moves, and generate the initial particle set (z1, z2, ..., z m ), these particles (z1,z2,...,z m ) According to the initial position (x o ,y o ) and speed v o The prior knowledge of each particle z is randomly generated. i are assigned equal weights w i , represents the probability of its corresponding state. Use the motion model to predict the next state of the particle.
[0079] The motion model uses a constant acceleration motion model, and the new position (x', y') of the particle can be obtained by the current position (x i ,y i ) and speed v i and the time interval Δt.
[0080] The prediction process also takes into account the noise Q in the process, based on the latest observation data d i (distance measured by FTM) to adjust the particle weight w i . Weight w i reflects the particle (z1,z2,...,z m ) state is consistent with the observed data. After the update, the particle weight w i Subject to change to reflect new observational information.
[0081] To avoid the weight w i Degenerate and maintain particle diversity and perform resampling. Resampling is based on the particle weight w i To select a new set of particles, so as to avoid a few particles dominating the entire distribution.
[0082] The particle resampling process adopts the roulette method, which is to resample all particles (z1, z2, ..., z m) to perform weighted averaging to obtain the position estimate (x', y') of the moving target. i Larger particles contribute more to the position estimate coordinates (x',y').
Claims
1. A method of ranging error compensation for indoor positioning precise time measurement, characterized by, The method comprises the following steps: Step 1, collecting a precise time measurement (FTM) ranging data set in a mixed LOS / NLOS environment; Step 2, distinguishing the collected ranging data by LOS signal and NLOS signal identification conditions, If the ranging data is determined to be NLOS, input the ranging data into an NLOS error compensation model for error correction to obtain error-corrected ranging data, If the ranging data is determined to be LOS, input the ranging data into an LOS error compensation model for error correction to obtain error-corrected ranging data; Step 3, designing a particle filtering positioning algorithm, inputting the error-corrected ranging data into the particle filtering positioning algorithm to obtain the position information of the final target object.
2. The method of claim 1, wherein, The step 1 comprises the following sub-steps: Step 1.1, deploying at least 3 or more devices supporting Wi-Fi precise time measurement (FTM) protocol in the corners of the target site, the devices serving as fixed access points (APs) for transmitting and receiving FTM signals, and the target object carrying a device supporting the FTM protocol as a mobile station (STA); Step 1.2, collecting FTM ranging data between the STA and the AP in real time.
3. The method of claim 1, wherein, The step 2 comprises the following sub-steps: Step 2.1, calculating the relative position and relative distance error of the target; Step 2.2, designing an error identification condition in a mixed environment; Step 2.3, designing a nonlinear error compensation method, compensating through an NLOS / LOS error compensation model to obtain corrected ranging data as observation data input into the particle filtering algorithm to adjust the particle weight.
4. The method of claim 3, wherein, In step 2.2, the ranging data d of the current time and the previous two times are integrated i the standard deviation I1 of the standard deviation I2 of the received signal strength indication (RSSI) and the received power P o relative to the transmission power P r the difference |P o - P r the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I3 of the standard deviation I By a large number of measurement data, the weight constants a, b and c corresponding to standard deviations are set, and a discrimination formula of the LOS signal and the NLOS signal is established 5. The method of claim 4, wherein, In step 2.2, the discrimination threshold M is determined dis , the discrimination threshold M is determined dis , whether the ranging data discrimination formula at the current moment is greater than the discrimination threshold M dis , If M > M dis , then the corresponding ranging data d i is determined as a distance when NLOS propagation is judged. The NLOS error compensation model is used to correct the error to obtain more accurate NLOS ranging data for subsequent positioning algorithm operation, If M < M dis , the corresponding ranging data d i is determined as the distance when the LOS propagation is judged and the LOS error compensation is performed by the neural network error compensation model based on PSO-DNN.
6. The method of claim 3, wherein, In step 2.3, when it is detected that the current ranging information of one of the FTM ranging devices is NLOS information, the position information of the previous two moments (x k-2 ,y k-2 )、(x k-1 ,y k-1 ), The Euclidean distance d is calculated using the position coordinates (x k ,y k ) output by the variable-direction constant-velocity prediction model and the device coordinates (x ap ,y ap ) identified as NLOS ranging information The distance d is used to replace the NLOS ranging data d ap , and error correction of the NLOS ranging data is achieved.
7. The method of claim 3, wherein the method further comprises: In the step 2.3, when the current ranging information of the ranging device is detected to be LOS information, the least squares method is used to fit the relationship between the ranging error and the actual distance, and the least squares method is used to fit the collected ranging data to establish an LOS error compensation model.
8. The method of claim 7, wherein, In step 2.3, the ranging error e i is expressed as a function of the actual distance d i where k0, k1,... k n are the fitting coefficients and n is the order of the polynomial. If there are n ranging error data, an error matrix equation can be constructed: By constructing the error matrix K, the distance matrix D and the error vector E, then applying the least square method to solve the coefficient matrix A = (D T D) -1 D T E.
9. The method of claim 7, wherein, The step 2.3, for the new LOS ranging data, first calculate its theoretical distance d theo , then use the constructed LOS error model to calculate the compensated error e comp , and finally the compensated distance d comp = d theo - e comp .
10. The method of claim 1, wherein, In the step 3, particles are used instead of the position and velocity information of the moving target, and a particle filtering algorithm is used for indoor positioning.
Citation Information
Cited By
Non-line-of-sight classification and error compensation method and system based on double convolutional neural networks
CN121093166A