Method for eliminating TDC walking error based on laser ranging system
Data is collected through ADC and Gaussian fitting and normalization are performed using Levenberg-Marquardt algorithm to calculate and correct the walking error of TDC, solving the accuracy reduction problem of laser ranging system in small signals and long-distance scenarios, and achieving more High ranging accuracy.
Patent Information
- Application Number
- CN202411038529.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-11-15
AI Technical Summary
The TDC-based laser ranging system has walking errors in small signals and long-distance scenarios, resulting in a reduction in the ranging accuracy. The existing adaptive adjustment methods cannot completely eliminate the error and affect the accuracy.
ADC is used to collect laser echo data, and Gaussian fitting and normalization are performed through the Levenberg-Marquardt algorithm. The correction amount ΔT of the TDC walking error is calculated, and the optical flight time obtained by TDC is corrected to eliminate the rising edge of the signal of different input amplitudes. Error in reaching a fixed threshold time.
It improves the accuracy of laser ranging, eliminates TDC walking errors, and enhances the accuracy of ranging, especially in small signals and long-distance scenarios.
Smart Images

Figure CN118962643A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of laser distance measurement, and in particular relates to a method for eliminating TDC running errors based on a laser distance measurement system. Background Art
[0002] Laser rangefinders are widely used in topographic mapping, intelligent driving, industrial manufacturing, and environmental monitoring due to their advantages of high precision, fast response, and non-contact measurement. Common methods of laser rangefinders include pulse method, phase method, and triangulation method. Among them, the pulse method is widely used due to its advantages of large ranging range, wide application range, and high ranging accuracy. The pulse method measures the distance to the target by the flight time from the laser emission moment to the laser echo moment. Common methods are divided into the time identification method based on TDC (Time to Digital Converter) and the full waveform sampling method based on ADC (Analog to Digital Converter). The TDC-based moment identification method uses a high-precision time-to-digital conversion chip to measure the time of flight. This method has high measurement accuracy under close distance and large signal conditions, but there is a problem of walking error, especially in small signal and long distance scenarios. The impact of this error is more serious, resulting in reduced ranging accuracy; the ADC-based full waveform acquisition method relies on a high sampling rate ADC chip to obtain narrow pulse echo information and then measure the flight time. This method can obtain the distance information of multiple nearby targets, but the time resolution is low and the requirements for hardware, storage and algorithms are higher.
[0003] After searching, it is found that in the existing algorithms and system research schemes for eliminating TDC walking errors, they are all based on adaptive adjustment of echoes, which realizes that the amplitude characteristics and steep edge rise characteristics of the TDC receiving signal are maintained within a certain range. Therefore, the walking error will still exist in the TDC receiving signal that changes within this range, and the time of the adaptive adjustment itself will also affect the accuracy of TDC to a certain extent.
[0004] In view of the above technical defects, a solution is now proposed. Summary of the invention
[0005] The purpose of the present invention is to design an algorithm to eliminate the walking error of TDC caused by the different time when the rising edge of signals with different input amplitudes reaches a fixed threshold, so as to achieve accurate distance measurement.
[0006] The object of the present invention can be achieved by the following technical solution: A method for eliminating TDC walking error based on a laser ranging system, comprising:
[0007] Step 1: Collect laser echo data based on ADC;
[0008] Step 2: Fitting and normalizing the collected laser echo data;
[0009] Step 3: Calculate the correction amount ΔT of the TDC walking error;
[0010] Step 4: Correct the TOF result obtained by TDC to obtain the final TOF.
[0011] Preferably, the specific process of collecting laser echo data based on ADC is as follows: at the same time when the laser emits the laser, the laser main wave signal is given to the TDC module configured by the programmable gate array FPGA as the starting time of the light flight time TOF, when the laser is emitted to the surface of the object to be measured and reflected back, the photodetector in the reverse bias state receives the laser echo to generate a photocurrent, and the analog front-end circuit performs preprocessing of the current signal to a voltage signal, and the processing results are respectively given to the pre-comparator of the ADC module and the TDC module, when the rising edge of the voltage signal reaches the predetermined threshold voltage of the high-speed comparator, an approximate step signal is output to the TDC module as the flight termination time, the TDC module outputs the laser flight time before correction to the programmable gate array FPGA, and at the same time, the PLL configured by the programmable gate array FPGA outputs a clock signal to the ADC module to perform analog-to-digital conversion on the voltage signal of the analog front-end circuit, and the digital code value corresponding to the waveform is given to the programmable gate array FPGA.
[0012] Preferably, the specific operation process of fitting and normalizing the data in step 2 is:
[0013] 2-1: In the field programmable gate array FPGA, the laser echo data output by the ADC is fitted with a Gaussian model using the Levenberg-Marquardt algorithm to obtain the Gaussian curve G1, which is equivalent to the input signal of the high-speed comparator;
[0014] 2-2: Normalize and reshape the curve G1 under the condition that the coordinates of the peak center remain unchanged to obtain the curve G0.
[0015] Preferably, the specific operation of calculating the correction amount ΔT of the TDC running error in step 3 is:
[0016] Calculate the time T1 and T0 corresponding to the left intersection of curves G1 and G0 with the comparator threshold voltage respectively and make a difference to obtain the correction value ΔT=T0-T1;
[0017] Preferably, the specific operation of step 4: correcting the TOF result obtained by TDC is:
[0018] 4-1: Add ΔT to the pre-corrected laser flight time TC output by TDC to obtain the initial corrected flight time T;
[0019] 4-2: Add the fixed error ΔT0 caused by the normalization process to the preliminary flight time to obtain the final light flight time TOF: TZ=T+ΔT0.
[0020] Preferably, the expression G1(x) for Gaussian fitting of the original echo waveform data collected by the ADC in step 2-1 is:
[0021]
[0022] Among them, a1 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b1 is the center coordinate of the peak of the curve, and c1 represents the width of the Gaussian curve.
[0023] Preferably, in step 2-2, the expression G0(x) obtained by performing Gaussian fitting on the original echo waveform data collected by the ADC and then normalizing it is:
[0024]
[0025] Among them, a0 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b0 is the center coordinate of the peak of the curve, and c0 represents the width of the Gaussian curve.
[0026] Preferably, the Levenberg-Marquardt operation process in step 2-1 is specifically as follows:
[0027] 2-1.1: Get the original data;
[0028] 2-1.2: Remove outliers from the acquired data. According to different actual application scenarios, conduct targeted analysis on possible interference factors in the signal, and use the characteristics of environmental interference factors as the main basis for elimination to ensure the accuracy and reliability of subsequent fitting.
[0029] 2-1.3: Perform variable initialization on the data after outlier removal, use the local maximum value to detect the peak information of each frame of data waveform, and then obtain the peak value A of all echo signals in a single frame. P , peak time τ p and half-peak width p w Correctly setting the initial parameter vector can reduce the number of iterations and ensure the accuracy of waveform decomposition;
[0030] 2-1.4: Calculate the Jacobi matrix for the data after variable initialization;
[0031] 2-1.5: Residual calculation, specifically, where y iis the amplitude of the laser echo at the i-th sampling time;
[0032] 2-1.6: Determine whether the accuracy meets the requirements. If so, the loop ends and the calculated value is output. If not, the data returns to step 2-1.3 for loop calculation.
[0033] The beneficial effects of the present invention are as follows:
[0034] The invention adopts the laser echo data collected by ADC and LM (Levenberg-Marquardt) algorithm to fit the curve, and performs normalization scaling. The normalized and scaled curve is equivalent to inputting the analog signal of the high-speed comparator, and the time difference of the signal before and after the algorithm at the comparator threshold is used to obtain the TDC running error, and the light flight time obtained by TDC is compensated and corrected, thereby improving the accuracy of laser ranging. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] The present invention will be further described below in conjunction with the accompanying drawings;
[0036] Figure 1 is a block diagram of the system on which the present invention is based;
[0037] Figure 2 It is a data flow chart of laser echo in ADC and TDC in the present invention;
[0038] Figure 3 It is a fitted and normalized experimental data graph of the present invention;
[0039] Figure 4 It is the error correction experimental data diagram in the present invention;
[0040] Figure 5 It is a flow chart of the Levenberg-Marquardt algorithm of the present invention. DETAILED DESCRIPTION
[0041] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0042] Example:
[0043] See also Figures 1 to 5 As shown, the present invention is a method for eliminating TDC walking error based on a laser ranging system, comprising:
[0044] Step 1: Collect laser echo data based on ADC;
[0045] Step 2: Fitting and normalizing the collected laser echo data;
[0046] Step 3: Calculate the correction amount ΔT of the TDC walking error;
[0047] Step 4: Correct the TOF result obtained by TDC to obtain the final TOF.
[0048] The specific process of collecting laser echo data based on ADC includes:
[0049] At the same time when the laser emits the laser, the laser main wave signal is given to the TDC module configured by the programmable gate array FPGA as the starting time of the light flight time TOF. When the laser is emitted to the surface of the object to be measured and reflected back, the photodetector in the reverse bias state receives the laser echo to generate photocurrent, and the analog front-end circuit performs preprocessing of the current signal to the voltage signal. The preprocessing is that the transimpedance amplifier converts the input current signal into a voltage signal. The processing results are respectively given to the ADC module and the pre-comparator of the TDC module. When the rising edge of the voltage signal reaches the predetermined threshold voltage of the high-speed comparator, an approximate step signal is output to the TDC module as the flight termination time. The TDC module outputs the laser flight time before correction to the programmable gate array FPGA. At the same time, the PLL output clock signal configured by the programmable gate array FPGA is given to the ADC module to perform analog-to-digital conversion on the voltage signal of the analog front-end circuit, and the digital code value corresponding to the waveform is given to the programmable gate array FPGA. The threshold voltage setting needs to be able to distinguish between background noise and valid signals.
[0050] The specific operation process of fitting and normalizing the data in step 2 is as follows:
[0051] 2-1: In the field programmable gate array FPGA, the laser echo data output by the ADC is fitted with a Gaussian model using the Levenberg-Marquardt algorithm to obtain the Gaussian curve G1, which is equivalent to the input signal of the high-speed comparator. The expression G1(x) for Gaussian fitting of the original echo waveform data collected by the ADC is:
[0052]
[0053] Among them, a1 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b1 is the center coordinate of the peak of the curve, and c1 represents the width of the Gaussian curve;
[0054] 2-2: Normalize and reshape the curve G1 under the condition that the peak center coordinates remain unchanged to obtain the curve G0. Perform Gaussian fitting on the original echo waveform data collected by the ADC and then normalize it to obtain the expression G0(x):
[0055]
[0056] Among them, a0 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b0 is the center coordinate of the peak of the curve, and c0 represents the width of the Gaussian curve.
[0057] The specific operation of calculating the correction amount ΔT of the TDC walking error in step 3 is:
[0058] Calculate the time T1 and T0 corresponding to the left intersection of curves G1 and G0 with the comparator threshold voltage respectively and make a difference to obtain the correction value ΔT=T0-T1;
[0059] Step 4: The specific operation to correct the TOF result obtained by TDC is as follows:
[0060] 4-1: Add ΔT to the pre-corrected laser flight time TC output by TDC to obtain the initial corrected flight time T. Since the comparator input signal equivalent to the normalized G2 curve has exactly the same rising edge in each ranging behavior, theoretically, the walking error caused by the different time when the rising edge of the signal with different input amplitudes reaches the fixed threshold will be eliminated. The only difference between the light flight distance calculated by the initial correction time T and the actual distance is a fixed error caused by the normalization model. This fixed error can be obtained by experiment in the actual measurement of the system. The fixed error is reflected in the algorithm to obtain the final light flight time.
[0061] 4-2: Add the fixed error ΔT0 caused by the normalization process to the preliminary flight time to obtain the final light flight time TOF: TZ=T+ΔT0.
[0062] The specific Levenberg-Marquardt operation process in step 2-1 is:
[0063] 2-1.1: Get the original data;
[0064] 2-1.2: Remove outliers from the acquired data. Specifically, according to different actual application scenarios, conduct targeted analysis on possible interference factors in the signal, and use the characteristics of environmental interference factors as the main basis for elimination to ensure the accuracy and reliability of subsequent fitting;
[0065] 2-1.3: Perform variable initialization on the data after outlier removal, use the local maximum value to detect the peak information of each frame of data waveform, and then obtain the peak value A of all echo signals in a single frame. P , peak time τ p and half-peak width p w Correctly setting the initial parameter vector can reduce the number of iterations and ensure the accuracy of waveform decomposition;
[0066] 2-1.4: Calculate the Jacobi matrix for the data after variable initialization. The calculation formula is as follows:
[0067]
[0068] where r i , (i=0,1,2...) represents the residual;
[0069] 2-1.5: Residual calculation, the specific calculation is where y i is the amplitude of the laser echo at the i-th sampling time;
[0070] 2-1.6: Determine whether the accuracy meets the requirements. The accuracy needs to be set according to the actual application requirements. If the loop ends, the calculated value is output. If not, the data returns to step 2-1.3. The calculation flow chart of the Levenberg-Marquardt algorithm in the present invention is shown in the attached figure. Figure 5 As shown, a Gaussian curve of the following shape is obtained:
[0071]
[0072] in represents the parameter vector of the curve, A p represents the amplitude of the curve, t is the variable in the Gaussian curve expression, that is, the time corresponding to each point on the curve, τ p Indicates the time corresponding to the peak of the curve, p w Indicates the full width at half maximum of the curve, as shown in the attached Figure 3 As shown in FIG. 1 , different echoes obtain different fitting results, and the time Ti (i=1, 2, 3...) corresponding to the left intersection of the corresponding curve and the threshold voltage is calculated. After each fitting result Gi (i=1, 2, 3...) is normalized to the curve G0, the time T0 corresponding to the left intersection of the threshold voltage is calculated, as shown in FIG. Figure 4 As shown, ΔTi=T0-Ti(i=1,2,3...) is calculated and added to the corresponding Ti(i=1,2,3...) to obtain the preliminary corrected flight time. Then the fixed error ΔT0 is obtained from the experiment and added to the preliminary flight time to obtain the final data.
[0073] The above formulas are obtained by collecting a large amount of data for software simulation and selecting a formula that is close to the actual value. The coefficients in the formula are set by technical personnel in this field according to actual conditions. The above is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited to this. Any technical personnel familiar with the technical field within the technical scope disclosed by the present invention, according to the technical solution and the inventive concept of the present invention, make equivalent replacement or change, which should be covered within the protection scope of the present invention.
Claims
1. A method for eliminating TDC running error based on a laser ranging system, characterized in that: include; Step 1: Collect laser echo data based on ADC; Step 2: Fitting and normalizing the collected laser echo data; Step 3: Calculate the correction amount ΔT of the TDC walking error; Step 4: Correct the TOF result obtained by TDC to obtain the final TOF.
2. The method for eliminating TDC running error based on a laser ranging system according to claim 1, characterized in that: The specific process of collecting laser echo data based on ADC includes: At the same time when the laser emits the laser, the laser main wave signal is given to the TDC module configured by the programmable gate array FPGA as the starting time of the light flight time TOF. When the laser hits the surface of the object to be measured and reflects back, the photodetector in the reverse bias state receives the laser echo to generate photocurrent, and the analog front-end circuit pre-processes the current signal into a voltage signal. The processing results are respectively given to the ADC module and the pre-comparator of the TDC module. When the rising edge of the voltage signal reaches the predetermined threshold voltage of the high-speed comparator, an approximate step signal is output to the TDC module as the flight termination time. The TDC module outputs the laser flight time before correction to the programmable gate array FPGA. At the same time, the PLL configured by the programmable gate array FPGA outputs the clock signal to the ADC module to perform analog-to-digital conversion on the voltage signal of the analog front-end circuit, and the digital code value corresponding to the waveform is given to the programmable gate array FPGA.
3. The method for eliminating TDC running error based on a laser ranging system according to claim 2, characterized in that: The specific operation process of fitting and normalizing the data in step 2 is as follows: 2-1: In the field programmable gate array FPGA, the laser echo data output by the ADC is fitted with a Gaussian model using the Levenberg-Marquardt algorithm to obtain the Gaussian curve G1, which is equivalent to the input signal of the high-speed comparator; 2-2: Normalize and reshape the curve G1 under the condition that the coordinates of the peak center remain unchanged to obtain the curve G0.
4. The method for eliminating TDC running error based on a laser ranging system according to claim 3, characterized in that: The specific operation of calculating the correction amount ΔT of the TDC walking error in step 3 is: The times T1 and T0 corresponding to the left intersections of the curves G1 and G0 with the comparator threshold voltage are calculated respectively and the correction value ΔT=T0-T1 is obtained by making a difference.
5. The method for eliminating TDC running error based on a laser ranging system according to claim 4, characterized in that: Step 4: The specific operation to correct the TOF result obtained by TDC is as follows: 4-1: Add ΔT to the pre-corrected laser flight time TC output by TDC to obtain the initial corrected flight time T; 4-2: Add the fixed error ΔT0 caused by the normalization process to the preliminary flight time to obtain the final light flight time TOF: TZ=T+ΔT0.
6. The method for eliminating TDC running error based on a laser ranging system according to claim 3, characterized in that: The expression G1(x) for Gaussian fitting of the original echo waveform data collected by ADC in step 2-1 is: Among them, a1 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b1 is the center coordinate of the peak of the curve, and c1 represents the width of the Gaussian curve.
7. The method for eliminating TDC running error based on a laser ranging system according to claim 3, characterized in that: In step 2-2, the original echo waveform data collected by the ADC is subjected to Gaussian fitting and then normalized to obtain the expression G0(x): Among them, a0 represents the peak-to-peak value of the curve, e is a constant, x is the variable of the expression, here the variable is time, b0 is the center coordinate of the peak of the curve, and c0 represents the width of the Gaussian curve.
8. The method for eliminating TDC running error based on a laser ranging system according to claim 3, characterized in that: The specific Levenberg-Marquardt operation process in step 2-1 is: 2-1.1: Get the original data; 2-1.2: Remove outliers from the acquired data. According to different actual application scenarios, conduct targeted analysis on possible interference factors in the signal, and use the characteristics of environmental interference factors as the main basis for elimination. 2-1.3: Perform variable initialization on the data after outlier removal, specifically using the local maximum value to detect the peak information of each frame of data waveform, so as to obtain the peak value A of all echo signals in a single frame. P , peak time τ p and half-peak width p w ,Properly setting the initial parameter vector can reduce the number of iterations and ensure the accuracy of waveform decomposition; 2-1.4: Calculate the Jacobi matrix for the data after variable initialization; 2-1.5: Residual calculation, specifically where y i is the amplitude of the laser echo at the i-th sampling time; 2-1.6: Determine whether the accuracy meets the requirements. If so, the loop ends and the calculated value is output. If not, the data returns to step 2-1.3 for loop calculation.
