Evaluation of Real-Time Kinematic Positioning and Deformation Monitoring Using Xiaomi Mi 8 Smartphone

: Modern low-cost electronic devices can achieve high precision for global navigation satellite systems (GNSSs) and related applications. Recently, the pseudo-range and carrier phase have been directly obtained from a smartphone to establish a professional-level surveying device. Although promising results have been obtained by linking to an external GNSS antenna, the real-time kinematic (RTK) positioning performance requires further improvement when using the embedded smartphone antenna. We ﬁrst investigate the observation quality characteristics of the Xiaomi Mi 8 smartphone. The carrier-to-noise-density ratio of L5/E5a signals is below that of L1/E1 signals, and the cycle slip and loss of lock are severe, especially for L5/E5a signals. Therefore, we use an improved stochastic model and ambiguity-resolution strategies to improve the short-baseline RTK positioning accuracy. Experimental results show that the ambiguity ﬁxing rate can reach approximately 90% in 3 h of observations when using the embedded antenna, while the GPS/Galileo/BDS single-frequency combination is more suitable for smartphones. On the other hand, convergence takes 10–30 min, and the RTK positioning accuracy can reach 1 and 2 cm along the horizontal and vertical directions, respectively, if ambiguity is resolved correctly. Moreover, we verify the feasibility of using a mass-produced smartphone for deformation monitoring. Results from a simulated dynamic deformation experiment indicate that a smartphone can recognise deformations as small as 2 cm.


Introduction
With the development of satellite navigation and positioning technologies, users' demand for global navigation satellite system (GNSS) equipment with accurate positioning has steadily increased. Thus, developing high-precision applications based on low-cost GNSS equipment has become a dominant trend. Smartphones are one of the most used low-cost GNSS devices, accounting for 80% of the total number of GNSS devices available worldwide [1]. Compared with professional GNSS equipment, a smartphone has small size, low cost, and ease of use. However, the main shortcoming of the smartphone GNSS module is its poor positioning accuracy, with the standard single-point positioning precision being typically approximately 10 m on the horizontal plane [2], greatly limiting its use for professional applications.
Research on smartphone GNSS modules has been conducted for many years, but before 2016, users could only obtain position, velocity, time, altitude, azimuth, and other final positioning information from a smartphone [3], thus restricting the development of smartphone GNSS technology. In May 2016, Google opened the GNSS raw measurement application programming interface for smartphones in the Android Nougat (version 7.0) operating system [4]. Since then, users can directly access observations including pseudorange, carrier phase, and Doppler observable from a smartphone. Such data accessibility has greatly contributed to the development of high-precision smartphone GNSS modules toward positioning at the decimetre level or even the centimetre level, thus expanding their adoption in the GNSS market.
Broadcom launched a dual-frequency GNSS chip, and Xiaomi Mi 8 was the world's first smartphone with a dual-frequency GNSS function. Thereafter, smartphones equipped with chips made in China, such as Huawei P40 and Huawei Mate40, have integrated tri-frequency and quad-frequency GNSS functions. Currently, many smartphones are endowed with multi-constellation and multi-frequency capabilities, and their signal volume is comparable to that of survey-grade receivers, likely enabling high-precision positioning.
By leveraging the aforementioned advances, many studies have been conducted on smartphone GNSS raw measurements, aiming to comprehensively analyse the observation quality and positioning performance of various smartphones and implement high-precision applications. However, owing to the embedded low-cost antenna and chip, smartphone GNSS modules present many problems. Typically, the carrier-to-noise-density ratio (C/N0) of a smartphone is approximately 10 dB-Hz lower than that of a geodetic receiver, and it is more sensitive to multipath interference [5]. In addition, the correlation of the observation quality with C/N0 is stronger than that with the elevation [6], and the pseudo-range noise of a smartphone is approximately 10 times larger than that of a geodetic receiver. Moreover, the carrier-phase noise is approximately 3-5 times larger than that of a geodetic receiver [7], and it is sensitive to the duty cycle mechanism [6,8]. Consequently, the carrier phase presents frequent cycle slips and continuous loss of lock. Although these observation problems greatly limit accuracy, high-precision positioning at the centimetre level is still achievable in smartphones [5].
Technologies such as precise point positioning, real-time kinematic (RTK) positioning, and network RTK positioning have been used to develop high-precision applications for smartphones. Realini et al. [9] used GNSS raw measurements from smartphones for positioning tests, achieving decimetre-level accuracy through relative positioning. Dabove et al. [10] equipped both a base station and a rover with smartphones, achieving decimetre-level RTK positioning accuracy and centimetre-level repeatability. Zhang et al. [5] implemented a method for precise point positioning based on the timedifference carrier phase using a Nexus 9 smart device achieving sub-metre-level positioning accuracy. Dabove et al. [11] also studied the performance of a smartphone using network RTK positioning with differential correction observations from the Continuously Operating Reference Stations, achieving centimetre-level precision but only decimetre-level accuracy. They found that to improve decimetre-level accuracy in smartphones, the integer ambiguity should be resolved.
A correct and reliable ambiguity-fixed solution can lead to centimetre-level positioning accuracy [12], even in smartphones. Wanninger et al. [13] conducted experiments on a Huawei P30 smartphone, and the results showed that only the GPS (global positioning system) L1 signal can resolve ambiguity. Geng et al. [14] attached an external survey-grade GNSS antenna to a smartphone, achieving a fixed solution, while Bochkati et al. [15] used a choke-ring to reduce multipath interference, obtaining an ambiguity fixing rate up to 89% and RTK positioning accuracy of 1-2 cm. Gao et al. [16] also used a survey-grade antenna to resolve ambiguity in RTK positioning, achieving 100% fixing rate and millimetre-level positioning accuracy. These methods have demonstrated the ability of GNSS modules in smartphones to achieve high-precision positioning. However, applicability may be reduced by using an external GNSS antenna or a choke-ring on a smartphone because it increases the equipment burden for surveying. In addition, the signal reception of the built-in smartphone antenna should be shielded to prevent interference from the external antenna. Despite the difficulty in achieving high-precision positioning using only the internal smartphone antenna, further optimisation in the underlying algorithms may improve the positioning performance.
Regarding practical applications, Uradziński et al. [17] found that smartphones can achieve centimetre-level accuracy when ambiguity is resolved, enabling geodetic and monitoring applications. Julián et al. [18] used smartphones in forestry surveys, finding that the high sensitivity of smartphones is advantageous for forest sheltered environments, but the positioning accuracy should be further improved. These applications illustrate the importance of high-precision positioning in smartphones. Although the current accuracy has certain bottlenecks, high-performance positioning would be of great significance to many users.

Our Contribution
To fully exploit the advantages of smartphone multi-GNSS signals, namely low cost and ease of use, in this paper, we propose the application of smartphones to dynamic deformation monitoring. This would broaden the application field of smartphones and promote the application of low-cost receivers in deformation monitoring. To achieve this goal, we focused on solving the problem of ambiguity, which is difficult to resolve when using the internal smartphone antenna, through data processing. In the first part of the study, the quality characteristics of dual-frequency observations acquired from a Xiaomi Mi 8 smartphone are analysed. Then, we propose an improved dual-frequency stochastic model based on the quality characteristics, combined with a partial ambiguity resolution algorithm [19] to increase the ambiguity fixing rate and positioning accuracy. Subsequently, the ambiguity resolution performance of short-baseline RTK is analysed. Finally, considering fixed ambiguity, the feasibility of using a mass-produced smartphone for deformation monitoring is evaluated.

Smartphone Global Navigation Satellite System (GNSS) Data Collection and Analysis
We collected smartphone GNSS data in a real environment and analysed their quality.

Data Collection
Data collection experiments were conducted on the rooftop of an office building in Central South University, China. We adopted the short-baseline static mode, which is approximately 5 m for the baseline length. The reference station was equipped with a survey-grade antenna (TRM 57971.00) and a geodetic receiver (Trimble Net R9), and the rover station was a Xiaomi Mi 8 smartphone running the Android 9.0 operating system. This smartphone supports five constellations with dual-frequency signals (i.e., GPS L1/L5, GLONASS G1, BDS B1, Galileo E1/E5a, and QZSS L1/L5), and its duty cycle [6], which is a battery-saving mechanism in the smartphone GNSS module, can be turned off. In this study, we disregarded the QZSS constellation. To obtain the smartphone GNSS observation data for analysing and solving the data in post time, we used the Geo++ RINEX Logger (v2.1.3) [20] Android mobile application. During measurement, users only need to turn on the "Dual GPS" positioning function and click start logging to start recording the observation data. The application automatically stores the GNSS data in RINEX format, which is convenient for users to directly process GNSS data. Approximately 5 h of data were collected on 15 November 2020 at a sampling interval of 1 s. The first 3 h was used for analysis, and the results of the last 2 h were consistent with the results of the first 3h, so we do not use the last 2 h to reduce the calculation time. It is considered that the sampling rate of 1 Hz is high enough; hence, 3 h is sufficient to guarantee the required amount of data.
Although mobile phone manufacturers do not publish the location of the smartphone GNSS antenna, Netthonglang et al. [21] estimated the antenna position of Xiaomi Mi 8 through relative positioning with centimetre-level accuracy. The antenna phase centre is on the left side of the front of the phone (Figure 1). To facilitate centring, we used the top centre of the smartphone as the antenna reference point (ARP), whose distance from the phase centre is shown in Figure 1.
The fixed control point (FCP) shown in Figure 2 was used as reference, and its accurate coordinates were obtained using two geodetic receivers through relative positioning. To ensure full GNSS signal reception, we placed the smartphone vertically using a holder. The FCP was taken as the centring point, and the centring accuracy was within 1 cm. We measured the distance between the smartphone ARP and the FCP along three directions (i.e., east, north, and up) and the angle between the orientation perpendicular to the screen and the true north (28.0 • ). Hence, we calculated the offset along the east, north, and up directions to obtain the overall phase centre offset provided in Table 1.

Data Quality Analysis
We analysed the dual-frequency GNSS observations collected in the experiment to obtain a reference for data processing during positioning. The statistical results reported below exclude data with elevations below 10 • .
2.2.1. Dual-Frequency C/N0 Analysis C/N0 is an important data quality indicator for GNSS, and it is related to the receiver hardware and signal path [5]. Figure 3 shows the C/N0 sequence and statistical results of the different types of observations. The maximum C/N0 is below 50 dB-Hz. The L1/G1/B1/E1 signals are mainly concentrated around 40 dB-Hz, but some satellites provide signals below 20 dB-Hz, while the Galileo satellites provide signals above 30 dB-Hz. The GPS L5, Galileo E1/E5a, and BDS GEO satellites were slightly stable during measurement, while other satellites fluctuated greatly. Overall, Galileo satellites provide the highest signal stability and strength, but their number is low. For band L5/E5a, C/N0 is mainly concentrated at 30 dB-Hz, being lower than the mean C/N0 for band L1/G1/B1/E1. The L5/E5a multipath resistance is stronger in smartphones [8,22], and the signal quality is usually better than that in band L1/E1. However, in our results, the C/N0 of band L5/E5a is lower. Therefore, when establishing a stochastic model for multi-frequency observations, the difference in multi-frequency C/N0 should be considered.

Dual-Frequency Cycle Slip Analysis
Cycle slip is an important indicator of carrier-phase quality. Figure 4 shows the time sequence diagram of satellite visibility and its cycle slip for the four constellations, and Figure 5 shows the statistical results of cycle slips. Each cycle slip is marked with a red plus sign, and it is mainly determined by the loss-of-lock indicator, which may also reflect carrier-phase interruption.   Figure 4 shows several satellites observed during the entire period, with reception from 34 satellites overall, including 11 GPS, 9 GLONASS, 5 BDS, and 9 Galileo satellites. In addition, seven GPS satellites deliver L5 signals, and five Galileo satellites deliver E5a signals. The cycle slips or interrupts are frequent, especially for L5/E5a signals. In terms of statistical results, for the first frequency band (L1/G1/B1/E1), the cycle slips of BDS are comparatively more frequent, while almost no slip occurs for the Galileo satellites. However, the cycle slips of GPS L5 and Galileo E5a signals are severe, accounting for more than 5%, which is much higher than the rate for L1/E1 signals. These results show that band L5/E5a is more prone to cycle slip. In addition, the number of satellites delivering signals in this frequency band is low, further reducing the availability of dual-frequency observations in smartphones.
From the statistical results of cycle slips for different C/N0 ranges (Figure 5b), 90.6% of the cycle slips in band L1 are mainly concentrated in the range below 35 dB-Hz, and 99.0% of the cycle slips in band L5 are concentrated in the range below 30 dB-Hz. Overall, the cycle slips are highly severe when C/N0 is lower than 30 dB-Hz. Therefore, the C/N0 threshold should be set to prevent low-quality observations from participating in data processing or ambiguity resolution.

Data Processing and Analysis for Smartphone Real-Time Kinematic (RTK) Positioning
RTK positioning is a widely used high-precision technology in GNSS. As it can eliminate most of the external system errors, RTK positioning can enable high-precision applications in smartphones. In RTK positioning, we apply the double-difference method to both pseudo-range and carrier phase observations to eliminate observation errors. First, single-difference observations are obtained by the difference between observations from rover station r 1 and reference station r 2 . The obtained single-difference observations are differenced by satellites i and j (reference) to calculate the double-difference observations. In short baselines, the double difference can eliminate satellite-orbit and clock errors, receiver-clock errors, ionospheric and tropospheric delays, and other errors, leaving mainly multipath and measurement noise. When the multipath is significant, the observations for low-cost receivers may be correlated. Therefore, in this study, we first minimize the multipath from the source of data collection and then use a C/N0 stochastic model to reduce the impact of multipath. Hence, it is assumed that the remaining error is random. Under this condition, the double-difference observation equation is given by [23]: where the superscript and subscript represent the station difference and satellite difference, respectively, P represents the pseudo-range observations, φ represents the carrier-phase observations, λ is the wavelength of the carrier phase, ρ is the geometric distance calculated by the satellite and receiver coordinates, N is the carrier-phase ambiguity, and ε and η are pseudo-range and carrier-phase measurement noise terms, respectively. A more compact expression is given by: where y represents the observation vector, a represents the coordinate parameter vector, A is its coefficient matrix, b represents the ambiguity parameter vector, B is its coefficient matrix, and ∆ represents the noise vector. In RTK positioning, the Kalman filter [23] is typically used to estimate the unknown floating-point parameters. If high-quality observations P, observation data ϕ, and correctly resolved ambiguity N are obtained, high-precision RTK positioning is achieved. According to the data quality analysis above, we adopt improved data quality control and integer ambiguity resolution for smartphone RTK positioning. In addition, we analyse RTK positioning for different combinations of observations and its convergence time in different periods.

Stochastic Model and Cycle-Slip Detection
Satellite elevation is conventionally used to determine stochastic models in GNSS data processing. However, Liu et al. [6] found that the accuracy of GNSS observations in smartphones is more correlated with C/N0 than with elevation. Thus, it is more reasonable to use C/N0 to determine the stochastic model. The conventional elevation model and C/N0 model SIGMA-ε [24] are, respectively, formulated as follows: where σ 2 g is the observation variance for the elevation model, el is the satellite elevation, a 0 , b 0 and C i are model coefficients, σ 2 S is the observation variance for the C/N0 model, and CN0 is the C/N0 value.
Considering the differences in C/N0 ranges for different frequencies in the smartphone signals, if the C/N0 model is used directly, the L5/E5a frequency weight may be lower than the L1/E1 frequency weight, being contrary to the smaller noise of L5/E5a observations. Therefore, based on the C/N0 stochastic model proposed in [25], we set different thresholds for different frequencies in the model to reduce the impact of differences in dual-frequency C/N0. As the reference station is a geodetic receiver, it uses an elevation model. According to the law of error propagation, the variance of the single-difference observation should be the sum of the variances of the two stations: where σ 2 S L is the observation variance of the smartphone signals, L denotes the frequency band, σ L 2 is the variance of the single-difference observation, and CN0 MAX is the maximum C/N0 in the corresponding band. For comparison, we set two types of CN0 MAX values for the two frequencies: unified CN0 MAX and individual CN0 MAX . We call the corresponding models unified-CNM model and individual-CNM model. For the unified-CNM model, CN0 MAX is set to 40 dB-Hz for all frequencies. For the individual-CNM model, CN0 MAX is set to 45 dB-Hz for band L1/G1/B1/E1 and 35 dB-Hz for band L5/E5a according to the statistical values reported above.
The positioning performance of the elevation model and the C/N0 models, namely, SIGMA-ε, unified-CNM, and individual-CNM, are evaluated in Section 3.2. Here, we briefly analyse the feasibility of the three C/N0 models. Taking G26 as an example, the variance ratios of bands L1 and L5 (i.e., σ 2 S L1 /σ 2 S L5 ) for the three C/N0 models are shown in Figure 6. For the SIGMA-ε model, the observation variance in band L1 is lower than that in band L5 (factor of 0-0.4). On the other hand, the observation noise in band L1 is higher than that in band L5 for the Xiaomi Mi 8 measurements [8,22]. Therefore, the SIGMA-ε model may set counterproductive weights when using bands L1 and L5 simultaneously. For the unified-CNM model, most ratios are lower than 1, while few are higher than 1, which may not lead to optimality. For the individual-CNM model, approximately 67.2% of the ratios are higher or equal to 1, being more promising for optimisation. For cycle-slip detection in data processing, we mainly use the loss-of-lock indicator, Doppler, and code-phase combination methods for joint detection. In addition, we adopt a geometry-free method for dual-frequency observations. The code-phase combination method is greatly affected by the pseudo-range noise. Thus, a larger cycle-slip threshold should be set (15 m in this study) to detect pseudo-range gross errors simultaneously. Moreover, we set the C/N0 threshold and elevation cut-off value to eliminate the observations which are severely affected by multipath interference and cycle slip. The specifications for RTK positioning are listed in Table 2.

Partial Ambiguity Resolution
Parameter estimation allows the coordinates (i.e., baseline vector), the ambiguity floating-point solution, and its covariance matrix to be obtained. Then, the integer value of the float ambiguity must be determined to obtain the fixed-coordinate solution with resolved ambiguity. Correct ambiguity resolution is the basis for centimetre-level positioning accuracy [12]. However, the carrier phase acquired by a smartphone is noisy and sensitive to cycle slips, and the float ambiguity shows a poor integer solution [26]. When using the conventional method to fix all the float ambiguities, it may be difficult to pass the ratio test, resulting in the failure of ambiguity resolution. Hence, we only select the part of float ambiguities that have higher accuracy for resolution to improve both the fixing rate and positioning accuracy. This algorithm is called partial ambiguity resolution [19] and is described below.
First, we use the least-squares method or a Kalman filter to obtain float baselineâ and ambiguity solutionsb, resulting in the following variance-covariance matrix: where Qâ is the variance matrix ofâ, Qb is the variance matrix ofb, and Qâb and Qbâ are the covariance matrices ofâ andb. Then, let all the ambiguity vectors be given byb = [b 1 , b 2 , · · · , b n ] and the partial fixedambiguity vector beb p = [b 1 , b 2 , · · · , b ns ], whose variance matrix is Qb p . The remaining unfixed-ambiguity vector isb f = [b n−ns , b n−ns+1 , · · · , b n ].
Next, the integer values ofb p are searched using least-squares ambiguity decorrelation adjustment (LAMBDA) [27] to obtain fixed solutions b p . The baseline solutions can be directly updated according to the correlation between the float baseline vector and fixed ambiguities (i.e., Qâb p ): unfixed ambiguityb f can be omitted from the update [19]. Finally, the fixed solutions are obtained.
The key to the aforementioned algorithm is to select candidate ambiguity subsets. Therefore, we use the original ambiguity variance and C/N0, that is, LAMBDA is first applied to fix all the float ambiguities whose C/N0 values are greater than a threshold. Then, if the ratio test is passed, the fixed solutions are directly obtained. Otherwise, the ambiguity with the largest variance is excluded, and the remaining ambiguities are fixed again following the procedure above. Next, iterative calculations are performed until the ratio test passes or the number of remaining ambiguities is less than four.
We modify the abovementioned algorithm on the RTKLIB open-source GNSS software (v2.4.3) [28], and the smartphone GNSS observations in integer time periods are used for RTK positioning. The main positioning specifications are listed in Table 2, and the other parameters use the default values in RTKLIB.

Evaluation of Data Processing
First, a combination of GPS and Galileo observations were used in RTK positioning to verify the effectiveness of the data processing strategies, and real-time differential analysis was also used to verify the stochastic models. Except for the stochastic model and ambiguity-resolution strategy, the other specifications are listed in Table 2. We consider RTK positioning convergence when the errors along the north and east directions are below 0.1 m. In addition, the fixing rate is the number of fixed epochs divided by the total number of epochs, while the error-fixing rate is the proportion of positioning error greater than 0.1 m at fixed ambiguity. Table 3 lists the real-time differential root-mean-square (RMS) errors of different stochastic models using GPS L1/L5 + Galileo E1/E5a observations for the parameters of the unified-CNM and individual-CNM models described in Section 3.1.1. The RMS values along the three directions for the individual-CNM model are the smallest, followed by those for the elevation model. However, the results of the SIGMA-ε and unified-CNM models are all worse than those of the elevation model in the real-time differential analysis. Thus, the proposed individual-CNM model provides optimal results. Next, we used RTK positioning to evaluate the stochastic models. Table 4 lists the RTK positioning solutions of different stochastic models using GPS L1/L5 + Galileo E1/E5a observations. The positioning accuracy of every C/N0 model is better than that of the elevation model. However, in the C/N0 model, the SIGMA-ε and unified-CNM models take longer to converge. On the other hand, the accuracy of the individual-CNM model is the highest, and its convergence time is similar to that of the elevation model. Therefore, the individual-CNM model achieves the highest positioning performance. Table 4. Real-time differential RMS errors of different stochastic models for positioning. For ambiguity resolution, Figures 7 and 8 show the fully fixed ambiguity and partially fixed ambiguity solutions for GPS L1 + Galileo E1 observations, respectively. Considering the results after 1500 s (around 9:30), most unfixed ambiguities can be fixed when using the partial resolution, effectively improving RTK positioning. A comparison of the fixed and float-only solutions is shown in Figure 9. Ambiguity resolution can substantially improve the positioning accuracy.    Table 5 lists the statistical results of the float-only, full, and partial resolution. Overall, the accuracy of fixed solutions is higher than that of float-only solutions, and partial resolution can considerably improve the fixing rate, positioning accuracy, and convergence speed. However, there are also some error-fixed solutions. In the parameter settings, five epochs (i.e., minimum lock) should converge before participating in ambiguity resolution when a cycle slip occurs, aiming to mitigate the influence of cycle slips. To further weaken the influence of cycle sips, the fix-and-hold mode [29] is used to impose a tight constraint on fixed ambiguities. This mode uses the fixed ambiguity solutions as virtual observations and performs secondary filtering to improve the filtering covariance matrix, aiming to reduce the influence of state initialisation on the covariance.

East (m) North (m) Up (m)
Only when the ratio reaches 10.0 or higher do we use the fix-and-hold mode for ambiguity resolution to ensure the reliability of fixed solutions. The corresponding solutions are shown in Figure 10. Compared with Figure 8, the positioning results are smoother after using the fix-and-hold mode. The fixing rate increases to 90.8% and up to 100% after convergence. Therefore, when the fixing rate is not low in the continuous mode, we also apply the fix-and-hold mode to improve the fixing rate.

Evaluation of Ambiguity Resolution for Different Observation Combinations
Next, we evaluated the actual fixing rate and fixed-solution accuracy of different observation combinations to improve observation selection. The positioning parameters are as listed in Table 2. The solutions for single-frequency observations are listed in Table 6.  Table 6 shows that when using single-constellation and single-frequency observations, the mean number of satellites is approximately six, and thus the fixing rates are low and cannot converge. When using the G/C combination, which nearly doubles the number of satellites, the fixing rate increases to 55.6%, but it remains low and has a slow convergence. On the other hand, the fixing rate of the G/E combination can reach 90.8% and converges after 25.1 min, indicating substantial improvement in both the fixing rate and convergence time.
When using combinations G/E/C and G/R/E/C, the number of satellites greatly increases, but the fixing rate decreases drastically, possibly due to anomalies in the BDS and GLONASS observations acquired by the smartphone. After analysis, we found that for combination G/C or G/E/C, after excluding the BDS GEO and GLONASS satellite observations, the fixing rate increases to 80.3% and 85.7%, respectively, and the convergence speed also increases. This is mainly attributable to the GEO satellite observations in smartphones, which have a half-cycle jump, and the GEO satellite itself has a very poor orbit accuracy [30]. Figure 11 shows that in the observations from the two BDS GEO satellites, C01 and C03, the carrier-phase residuals of the float solutions in many epochs are close to 0.5, likely corresponding to half-cycle jumps. However, the half-cycle jumps are very difficult to detect. Such jumps should be identified by the loss-of-lock indicator in the RINEX file or in field AccumulatedDeltaRangeState [4] of the GNSS raw measurements. In addition, in the combination of G/E/C, when excluding the BDS GEO satellite observations and not fixing the BDS ambiguities, the fixing rate increases again to 88.5%. The main reason is that the cycle slips of BDS are more frequent than those of other constellations ( Figure 5). As frequent cycle slips severely undermine positioning, it is better not to fix the BDS ambiguity. In contrast, although GLONASS observations have fewer cycle slips, the fixing rate of combination G/R/E/C is also lower than that of combination G/E/C, mainly because the noise of GLONASS observations in smartphones is higher than that of observations from other constellations [6]. Therefore, for a suitable number of satellites, the cycle-slip satellites should be controlled to participate in positioning, and observations from the BDS GEO and GLONASS satellites should be avoided. Further analysis of the combinations that include dual-frequency observations and other satellites with single-frequency data was also performed. The corresponding solutions are listed in Table 7. The fixing rate of the GPS dual-frequency observations is only 22.4%, which is lower than the single-frequency result, and the fixing rate of G/E single-frequency observations is relatively high, but the dual-frequency fixing rate is only 10.6%, being lower than that of the single-GPS constellation. The positioning accuracy also fails to converge within 0.1 m. If band L5 or E5a is not fixed, the fixing rate increases to 59.1% and 88.0%, respectively, mainly because the cycle slips in bands GPS L5 and Galileo E5a are extremely frequent, with those of band Galileo E5a being more frequent. The cycle-slip ratios in bands GPS L5 and Galileo E5a are 5.2% and 8.2%, respectively. When a cycle slip occurs in RTK positioning, the ambiguity parameters should be reinitialised, and frequent initialisation reduces the ambiguity fixing rate.
In Table 7, the number of satellites with simultaneous dual-frequency observations is low, and their cycle slips are frequent, further reducing the availability of dual-frequency observations. Therefore, these observations are limited for use in long-baseline RTK positioning or precise point positioning and other multi-frequency combination positioning strategies. In the results reported above, the accuracy of fixed solutions using different observation combinations is consistent, and an accuracy of approximately 1 and 2 cm can be achieved along the horizontal and vertical directions, respectively. However, owing to the excessive noise in smartphone observations, even for a fixing rate above 90%, it is still difficult to obtain millimetre-level accuracy. For several combinations with a fixing rate higher than 88%, we compared the accuracy of the fixed solutions and their corresponding float solutions simultaneously after the fixed solutions converged, obtaining the results shown in Figure 12. After fixing the ambiguity, the accuracy along the three directions improves. The east direction shows the highest improvement, reaching approximately 80%, and the other two directions show improvements by more than 30%. Hence, ambiguity resolution is important for high-precision positioning in smartphones, and future work should pursue further improvements in the fixing rate while shortening the convergence time. The above analysis shows that the large difference in fixed rates for the different combinations is mainly due to the impact of the number of satellites, cycle slips, and observation accuracy. By considering the results above, the correct fixing rate, and a reasonable convergence time, we recommend using combination G/E/C (no GEO/float C) for poisoning based on smartphone observations when the number of satellites is sufficient.

Analysis of RTK-Positioning Convergence Time by Segment
To verify the consistency of the convergence time in different periods, we solved the entire observation data in segments, that is, we reinitialised the coordinates and ambiguity parameters in a segments once every 1 h, and then solved the segments separately. As reported above, the combination G/E/C of single-frequency observations provides the best convergence overall. Thus, we used it for data processing without resolving the BDS ambiguity. The other calculation parameters were set as listed in Table 2. Considering slow convergence, we started to fix the ambiguity after 3 min of observations.
In addition to the data from 15 November 2020, which were used above, we used two additional datasets collected in recent days, at the same location and with a similar setup. The data collected on 11 November 2020 are approximately of 3 h, and the data collected on 14 November 2020 are approximately of 5 h. Here, we used the last 3 h of the 5 h data for analysis, owing to the clock jump in the previous data, and it will not affect the results of the segmented solution. These two datasets mainly aim to increase the amount of data for convergence time analysis and do not consider the impact of geomagnetic storm conditions on different days. Figure 13 shows the segmented solutions for 1 h intervals. Table 8 lists the convergence time of each session, the mean number of satellites in combination G/E (as BDS is not fixed, the number of BDS satellites is not considered), and the mean number of candidate ambiguities that meet the fixed conditions (e.g., C/N0 threshold, cycle slip). The convergence time differs across segments, mostly being 10-20 min and exceeding 30 min for few segments. In addition, the ambiguity can hardly be resolved for two segments mainly because the number of candidate ambiguities is very small. The corresponding segment with a long convergence time usually has few candidate ambiguities. For example, for segment 1 of dataset 2, the number of candidates is the largest, achieving the fastest convergence, whereas for segment 3 of dataset 2 and segment 1 of dataset 3, the number of candidates is lower than 1 (0.4 and 0.2, respectively), and the ambiguity cannot be fixed. Even if the total number of satellites is large, when a satellite elevation and C/N0 are very low or a cycle slip occurs, the corresponding ambiguity does not meet the fixed conditions and cannot be used for ambiguity resolution, resulting in few candidate ambiguities. On the other hand, the results in Section 3.3 show that simply including the number of observations from other constellations or frequencies in ambiguity resolution is not conducive to a higher fixing rate.   Table 8 shows that the cycle-slip rate may not determine the number of candidates directly because it is also related to other factors, but a large number of candidates must correspond to a low cycle-slip rate. The pseudo-range residuals are approximately 5 m, and there is no obvious correlation with the fixing rate. However, the pseudo-range accuracy is the main factor influencing the main convergence speed [31], but it can be superseded by other factors such as the cycle slips. The effect of the cycle-slip rate and pseudo-range accuracy on convergence is reported in Section 5. Nevertheless, we can conclude that higher-quality GPS and Galileo observations increase the number of candidate ambiguities, accelerate convergence, and increase the fixing rate.

Evaluation of Dynamic Deformation Monitoring Using Smartphone
The results reported above show that the RTK positioning accuracy of a smartphone can reach 1 cm, suggesting its potential for surveying and mapping applications. Hou et al. [32] studied the feasibility of a low-cost u-blox receiver for dynamic deformation monitoring in high-rise buildings, and Uradziński et al. [17] evaluated the static solution accuracy of smartphones in geodetic applications. Similarly, we explored the feasibility of using mass-produced smartphones as deformation monitoring devices through an experiment using simulated deformation equipment.
As shown in Figure 14, the simulated deformation equipment can move along the east, north, and up directions and register the displacement. Before conducting the experiment, we calibrated the true north using a compass. A Xiaomi Mi 8 smartphone was then fixed on the simulation platform and its body was kept upright to ensure adequate signal reception. During the experiment, the equipment was displaced once every 30 min to simulate the dynamic deformation of the monitored body. Considering the low accuracy of smartphone GNSS dynamic positioning, the horizontal displacement was set to 2 cm per movement. The schedule of the simulated deformation is listed in Table 9. For this experiment, we used GPS L1 observations to obtain the solutions, as there were few Galileo and BDS satellites in common view with the base station during the measurements. In addition, the ambiguity resolution mode was fix-and-hold. In the experiment, the average fixed solutions before the smartphone displaced in 1 h were used as the initial reference coordinates. The experimental results are shown in Figure 15. Centimetre-level accuracy is achieved as well as a fixing rate of 96.2%. In 9:00-9:30 and 9:30-10:00, the solutions suitably agree with the simulated deformation, and the deformation can be clearly seen at 9:00, 9:30, and 10:00. In the second half of the period 10:00-10:30 and the first half of the period 10:30-11:00, the solutions shift due to cycle slips, but they return to normal after some periods. The experimental results show that the deformation trend can be determined by using a smartphone, but owing to its high observation noise, deformation monitoring at the millimetre level cannot be achieved. In addition, a smartphone is extremely susceptible to interference from the environment and its own components during measurement. Consequently, it may not be applicable to actual monitoring scenarios at this stage of development. Improving the GNSS hardware quality in smartphones may enable monitoring applications in mass-produced smartphones.

Discussion
In this study, we mainly evaluated the RTK positioning accuracy and ambiguity resolution using the built-in antenna of a smartphone for GNSS observations. The results show that cycle slips are very frequent in smartphones, considerably undermining high-precision positioning. In addition to accurate cycle-slip detection, the frequency of cycle slips in smartphones should be mitigated. Although adopting appropriate strategies can increase the fixing rate, it remains low, and correct fixation takes a long time initially. Moreover, the highest accuracy can reach 1 cm, even if the ambiguity is fixed correctly. Observation noise and changes in the antenna phase centre may hinder additional improvements in the positioning performance through data processing.
The low fixing rate and low positioning accuracy can be explained by the use of lowcost antennas that have low gain and low multipath resistance, resulting in low-accuracy pseudo-range and carrier-phase observations. Improving the antenna design is essential to improve the fixing-rate reliability and reduce the convergence time. To illustrate this concept, we used a choke coil for the geodetic antenna in auxiliary experiments. The smartphone was placed upright on the choke coil to reduce the effect of multipath signals, as shown in Figure 16. Approximately 1.5 h of data were collected from 1:50 to 3:25 (GPS Time). Since the data were sufficiently long, we partitioned the data into two subsets. Similar to the previous analysis, the first subset (before 2:45) was utilized to examine the long-term stability of fixed solutions, while the second subset (after 2:45) was used for convergence time analysis in tiny segments. The observation selection and calculation parameter settings were the same as those in Section 3.4. The results of long-term RTK positioning using the choke coil are shown in Figure 17, with a 92.4% fixing rate. It can be observed that the error is less than 2 m in the initial stage, which is better than when the choke coil is not used. Moreover, the solution can remain fixed for about 10 min after the start, and the error remains stable. Following that, we analyzed the segmented RTK positioning in detail. Because the ambiguity can be resolved within 10 min in the initial stage, the calculation segment interval was likewise set to 10 min. The results are shown in Figure 18 and Table 10. It can be seen that the time to fix ambiguity was shortened to less than 5 min, with the fastest fixation taking only 1.5 min. Even though it took nearly 10 min to be fixed in the initial stage, it was much shorter than the time when using the built-in smartphone antenna. In addition, the positioning accuracy after convergence was higher than when the choke coil was not used. In segment 4, the RMS errors along the east, north, and up directions were 0.003, 0.004, and 0.007 m, respectively, showing millimetre-level accuracy. After using the choke coil, the mean number of candidate ambiguities was relatively large, and there were almost no cycle slips. In addition, the pseudo-range accuracy was approximately 2 m, representing an increase of more than 50%.  The choke coil experiment confirms that the antenna design is essential to improve the fixing rate, convergence speed, and positioning accuracy because it increases the observation quality. Although external antennas and choke coils are also used to improve the positioning performance of smartphones, they may not be the best choice for practical applications. We expect that manufacturers will continuously improve the quality of GNSS modules in smartphones, while we continue to study optimisation algorithms for positioning. In future research, we can make full use of the advantages of smartphones equipped with multiple sensors, in order to make up for the shortcomings of a single GNSS through integration of GNSS/IMU and other sensors. As they do not cause changes in coordinates during deformation monitoring that are too large, coordinate or baseline constraints may be used to improve the positioning effect.

Conclusions
We comparatively analysed the quality of multi-frequency GNSS observations in the Xiaomi Mi 8 smartphone. The analysis results allowed us to use improved algorithms including a stochastic model and ambiguity resolution for short-baseline RTK positioning. The ambiguity fixing rate, positioning performance, and convergence time using only the embedded smartphone GNSS antenna were then determined. The feasibility of using a smartphone for dynamic deformation monitoring was also verified. The cycle slips in the smartphone were severe, especially when C/N0 was below 30 dB-Hz. In addition, C/N0 of band L5/E5a was lower than that of band L1/E1, and its cycle-slip ratio was higher than that of band L1/E1, limiting the use of the second frequency in smartphones. In future work, we will explore the effective use of the second frequency for GNSS observations.
Using an improved C/N0 stochastic model and partial ambiguity resolution combined with other solving strategies can improve the positioning accuracy and ambiguity fixing rate. The ambiguity fixing rate varies greatly with different combinations of observations, and it is mainly affected by the number of satellites and cycle slips. It can reach 80-90% or above. The solution using GPS + Galileo + BDS single-frequency combination while keeping the BDS float ambiguity is the best, and its ambiguity fixing rate can reach approximately 90% in 3 h observations. However, it still takes a long time (usually 10-30 min) for a fixed solution to converge within 0.1 m. The accuracy of the fixed solutions for different band combinations can reach 1 and 2 cm along the horizontal and vertical directions, respectively.
By simulating dynamic deformation monitoring, the smartphone can recognise 2 cm deformation trends, being insufficient for actual monitoring applications. Nevertheless, a smartphone may be applied for high-precision measurements in applications such as vibration monitoring.
After using a choke coil around the smartphone, the fixing rate, convergence speed, and positioning accuracy improve, demonstrating the importance of antenna design on the positioning performance. With the advancement of hardware development, improved GNSS modules may lead to fast centimetre-or millimetre-level positioning accuracy in smartphones.