A Phase Error Correction Method for Measuring Rotational Speed by Photoelectric Encoding
By constructing and correcting the rotation angle sequence, detecting and replacing the outliers at the encoded belt joint, the problem of measurement error of the photoelectric sensor is solved, and a high-accurate instantaneous speed correction is achieved.
Patent Information
- Application Number
- CN202310172623.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-23
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2043-02-23
AI Technical Summary
When the photoelectric sensor is attached with a pasted paper-based coded tape for instantaneous speed measurement, a sudden change at the joint of the coded tape leads to measurement errors. The correction effect of existing commercial software is limited, and there are large errors.
By constructing the original rotation angle sequence and the rotation time sequence, the instantaneous rotation speed sequence containing errors is calculated, outlier value detection is performed, the angle value at the joint is replaced, and the actual rotation angle sequence is obtained, and the instantaneous rotation speed sequence is corrected.
Completely eliminate measurement errors caused by sudden changes at the coding belt joints, ensure the accuracy and authenticity of measurement results, reduce the difficulty of phase error positioning recognition, improve the accuracy of correction, and realize automatic identification and batch correction.
Smart Images

Figure CN116449052B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the fields of angle domain digital signal processing and testing technology, and in particular to a phase error correction method for photoelectric encoding rotation speed measurement. Background Art
[0002] At present, there are three main methods for measuring instantaneous speed. Among them, the method of magnetoelectric sensor + inherent gear measurement is only applicable to the case where there is an inherent code disk in the rotating mechanical system. For the case where there is no inherent code disk in the system, two measurement methods have been developed: magnetoelectric sensor + split gear measurement and photoelectric sensor + pasted paper code tape measurement. The former requires the installation of a high-precision gear disk, which is time-consuming, labor-intensive and costly. Due to the presence of seams at the splitting point, the test results are not satisfactory; the latter has the advantages of simplicity, convenience, speed and low cost, especially when there is no fixed code disk. The test system is quick to install and debug, and there is no need to install time-consuming and labor-intensive split gears. Only the paper code tape needs to be pasted to quickly measure the instantaneous speed, which greatly reduces labor intensity and saves time and cost. Therefore, the method of measuring instantaneous speed using photoelectric sensor + pasted paper code tape has developed rapidly. However, due to the mutation at the joint of the paper code tape (see Figure 1 ), resulting in errors in the angle and speed measurement (see Figure 2 ), additional correction processing is required. For the instantaneous speed measurement in this case, the actual correction effect of commercial software is limited, and there is still a large error. For details, see Figure 3 However, smoothing and approximating the data at the joint by averaging and other methods can only eliminate part of the error. The correction result still contains errors caused by data fitting, which is different from the true value. This is very unfavorable for the analysis and processing of signals. Some unnecessary errors will inevitably be introduced into the analysis results, seriously affecting the accuracy of the measurement results. Summary of the invention
[0003] The purpose of the present invention is to solve the problem in the prior art that the error correction effect of the photoelectric sensor with the paper coding tape attached is poor.
[0004] In order to solve the above technical problems, the present invention provides a technical solution: a phase error correction method for photoelectric encoding speed measurement, comprising the following steps:
[0005] S1. Obtain the normal angle value Δθ based on the total number of black and white stripes PPR of the coding tape, the normal black and white stripe width l, and the outer diameter D of the rotating shaft to which the coding tape is pasted. 0 And the joint angle value Δθ 1 ;
[0006] in,
[0007] S2. Obtain the square wave pulse time sequence t(k) through experimental measurement, and obtain the rotation time sequence ΔT(k) according to t(k);
[0008] Where t(k)=[t 1 ,t 2 ,t 3 ,…,t k ,…,t K-2 ,t K-1 ,t K ],
[0009] ΔT k =t k+1 -t k , so ΔT(k)=[ΔT 1 , ΔT 2 , ΔT 3 ,…,ΔT k ,…,ΔT K-2 , ΔT K-1 ];
[0010] S3, construct by Δθ 0 The original rotation angle sequence Δθ 0 (k), Δθ 0 The number of elements in (k) is the same as that in ΔT(k);
[0011] S4, the original rotation angle sequence Δθ 0 The element value of (k) is divided by the element value of the rotation time series ΔT(k) to obtain the instantaneous speed sequence ω containing the error 0 (k);
[0012] Among them, ω 0 (k) = [ω 01 ,ω 02 ,ω 03 ,…,ω 0k ,…,ω 0K-2 ,ω 0K-1 ],
[0013] S5, for the instantaneous speed sequence ω containing errors 0 (k) performing outlier detection to obtain a position index set S of the outlier, where the position index set S of the outlier is an arithmetic progression with the first outlier index position as the first item and the total number of black and white bars PPR of the coding band as the tolerance;
[0014] S6, according to the position index set S of the outliers, the original rotation angle sequence Δθ 0 Δθ at the corresponding position in (k) 0 Replaced by Δθ1 , and then get the actual rotation angle sequence Δθ(k);
[0015] S7. Divide the element values of the actual rotation angle sequence Δθ(k) by the element values of the rotation time sequence ΔT(k) to obtain the actual instantaneous rotation speed sequence ω(k). Thus, the correction of the instantaneous rotation speed is completed.
[0016] According to the above scheme, the outlier detection in S5 is specifically as follows:
[0017] When 0 An element ω in (k) 0k If the following formula is satisfied, then we can judge ω 0k is an outlier,
[0018] |ω 0k -μ|≥3σ
[0019] Among them, μ and σ are respectively 0 (k) The mean and standard deviation of all elements in k.
[0020] A computer comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above-mentioned method for correcting the phase error of the rotation speed measured by photoelectric encoding are implemented.
[0021] A computer-readable storage medium having a computer program stored thereon, characterized in that: when the computer program is executed by a processor, the steps of the phase error correction method for measuring rotation speed by photoelectric encoding as described above are implemented.
[0022] The beneficial effects of the present invention are: 1. The correction method adopted by the present invention is different from other correction methods such as smoothing and approximation. The present invention corrects the phase data from the source, which can completely eliminate the measurement error caused by the mutation at the joint of the coding tape, ensure the accuracy and authenticity of the measurement result, solve the biggest defect of the speed measurement method of the photoelectric sensor plus the paper coding tape, and expand the scope of application of the speed measurement method.
[0023] 2. The present invention can achieve lossless amplification of instantaneous speed error by amplifying a small-scale phase error by an order of magnitude, thereby reducing the difficulty of locating and identifying the phase error and improving the correction accuracy;
[0024] 3. The present invention can automatically identify and locate the position of the data corresponding to the coding belt joint through the method of abnormal value detection, and batch correct the phase and instantaneous speed data, which is time-saving, efficient and low-cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1 It is a schematic diagram of the coding tape connector and its corresponding square wave pulse;
[0026] Figure 2 This is a schematic diagram of data mutation caused when the coding band joint is not corrected;
[0027] Figure 3 It is a comparison chart of the correction effect of the present invention and the correction effect of the existing commercial software;
[0028] Figure 4 The invention discloses a phase error correction method for photoelectric encoding speed measurement according to an embodiment of the present invention. DETAILED DESCRIPTION
[0029] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution of the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings of the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the described embodiments of the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0030] See also Figure 1 , a phase error correction method for photoelectric encoding speed measurement, comprising the following steps,
[0031] S1. Obtain the normal angle value Δθ according to the total number of black and white stripes PPR of the coding tape (PPR=128 in this embodiment), the normal black and white stripe width l (l=10 mm in this embodiment), and the outer diameter D of the rotating shaft to which the coding tape is attached (D=409 mm in this embodiment). 0 And the joint angle value Δθ 1 ;
[0032] in, Δθ 1 =360°-(PPR-1)Δθ 0 =4.177496°;
[0033] S2. Obtain the square wave pulse time sequence t(k) through experimental measurement, and obtain the rotation time sequence ΔT(k) based on t(k); assuming that the number of elements of t(k) is K;
[0034] Where t(k)=[t 1 ,t 2 ,t 3 ,…,t k ,…,t K-2 ,t K-1 ,t K ],
[0035] ΔT k =t k+1 -tk , so ΔT(k)=[ΔT 1 , ΔT 2 , ΔT 3 ,…,ΔT k ,…,ΔT K-2 , ΔT K-1 ]; the number of elements of ΔT(k) is K-1;
[0036] S3, construct by Δθ 0 The original rotation angle sequence Δθ 0 (k), Δθ 0 The number of elements in (k) is the same as that in ΔT(k);
[0037] Δθ 0 (k)
[0038] =[2.801752°,2.801752°,2.801752°,…,2.801752°,…,2.801752°,2.801752°,2.801752°,2.801752°]
[0039] S4, the original rotation angle sequence Δθ 0 The element value of (k) is divided by the element value of the rotation time series ΔT(k) to obtain the instantaneous speed sequence ω containing the error 0 (k);
[0040] Among them, ω 0 (k) = [ω 01 ,ω 02 ,ω 03 ,…,ω 0k ,…,ω 0K-2 ,ω 0K-1 ],
[0041] Since this step uses division and the value of the denominator ΔT(k) is usually much smaller than 1, the original rotation angle sequence Δθ 0 (k) The small-scale phase error is amplified by an order of magnitude and converted into an instantaneous speed sequence containing an error ω 0 (k) Medium-sized large speed error, at this time, the instantaneous speed sequence ω 0 In (k), only the speed data corresponding to the joint has errors, and the rest of the data remains correct;
[0042] S5, for the instantaneous speed sequence ω containing errors 0(k) performing outlier detection to obtain a position index set S of the outlier values, where the position index set S of the outlier values is an arithmetic progression with the first outlier index position as the first item and the total number of black and white bars PPR of the coding band as the tolerance; assuming that the index position of the first outlier value is 7, then S = [7, 135, 263, 391, ...];
[0043] S6, according to the position index set S of the outliers, the original rotation angle sequence Δθ 0 Δθ at the corresponding position in (k) 0 Replaced by Δθ 1 , and then get the actual rotation angle sequence Δθ(k);
[0044] Δθ(k)
[0045] =[2.801752°,2.801752°,2.801752°,2.801752°,2.801752°,2.801752°,4.177496°,2.801752°,…]
[0046] S7. Divide the element values of the actual rotation angle sequence Δθ(k) by the element values of the rotation time sequence ΔT(k) to obtain the actual instantaneous rotation speed sequence ω(k). Thus, the correction of the instantaneous rotation speed is completed.
[0047] Furthermore, the outlier detection in S5 may specifically be:
[0048] When 0 An element ω in (k) 0k If the following formula is satisfied, then we can judge ω 0k is an outlier,
[0049] |ω 0k -μ|≥3σ
[0050] Among them, μ and σ are respectively 0 (k) The mean and standard deviation of all elements in; in other embodiments of the present invention, the outlier detection in S5 can be replaced by other outlier detection methods, which will not be described in detail in this embodiment.
[0051] The above descriptions are merely embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A phase error correction method for photoelectric encoding speed measurement, Features: The following steps are included: S1. Obtain the normal angle value Δθ based on the total number of black and white stripes PPR of the coding tape, the normal black and white stripe width l, and the outer diameter D of the rotating shaft to which the coding tape is pasted. 0 And the joint angle value Δθ 1 ; Among them, Dth 1 =360°-(PPR-1)Δθ 0 ; S2. Obtain the square wave pulse time sequence t(k) through experimental measurement, and obtain the rotation time sequence ΔT(k) according to t(k); Among them, t(k) = [t 1 , t 2 , t 3 , …, t k , …, t K-2 , t K-1 , t K , ΔT k = t k+1 - t k So, there is ΔT(k) = [ΔT 1 , ΔT 2 , ΔT 3 , …, ΔT k , …, ΔT K-2 , ΔT K-1 ; S3, construct by Δθ 0 The original rotation angle sequence Δθ 0 (k), Δθ 0 The number of elements in (k) is the same as that in ΔT(k); S4, the original rotation angle sequence Δθ 0 The element value of (k) is divided by the element value of the rotation time series ΔT(k) to obtain the instantaneous speed sequence ω containing the error 0 (k); Among them, oh 0 (k)=[ω 01 Oh, oh 02 Oh, oh 03 ,…,oh 0k ,…,oh 0K-2 Oh, oh 0K-1 ], S5, for the instantaneous speed sequence ω containing errors 0 (k) performing outlier detection to obtain a position index set S of the outlier, where the position index set S of the outlier is an arithmetic progression with the first outlier index position as the first item and the total number of black and white bars PPR of the coding band as the tolerance; S6, according to the position index set S of the outliers, the original rotation angle sequence Δθ 0 Δθ at the corresponding position in (k) 0 Replaced by Δθ 1 , and then get the actual rotation angle sequence Δθ(k); S7. Divide the element values of the actual rotation angle sequence Δθ(k) by the element values of the rotation time sequence ΔT(k) to obtain the actual instantaneous rotation speed sequence ω(k). Thus, the correction of the instantaneous rotation speed is completed.
2. The phase error correction method for photoelectric encoding speed measurement according to claim 1, Features: The specific outlier detection in S5 is: When 0 An element ω in (k) 0k If the following formula is satisfied, then we can judge ω 0k is an outlier, |oh 0k -μ|≥3σ Among them, μ and σ are respectively 0 (k) The mean and standard deviation of all elements in k.
3. A computer, Features: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the phase error correction method for photoelectric encoding speed measurement according to any one of claims 1 to 2 are implemented.
4. A computer-readable storage medium having a computer program stored thereon, Features: When the computer program is executed by a processor, the steps of the phase error correction method for photoelectric encoding rotation speed measurement according to any one of claims 1 to 2 are implemented.
Citation Information
Patent Citations
Correction method for aiming at reflective code strip torsional oscillation measurement error
CN106908137A
Propeller shaft torsional vibration measuring method
CN111504637A