CN110274615B - Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder - Google Patents
Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder Download PDFInfo
- Publication number
- CN110274615B CN110274615B CN201910730249.0A CN201910730249A CN110274615B CN 110274615 B CN110274615 B CN 110274615B CN 201910730249 A CN201910730249 A CN 201910730249A CN 110274615 B CN110274615 B CN 110274615B
- Authority
- CN
- China
- Prior art keywords
- signal
- angle
- unit
- magnet
- phase
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 33
- 238000006243 chemical reaction Methods 0.000 claims abstract description 38
- 238000005070 sampling Methods 0.000 claims description 72
- 238000012935 Averaging Methods 0.000 claims description 9
- 230000000630 rising effect Effects 0.000 claims description 6
- 238000012545 processing Methods 0.000 claims description 5
- 238000001514 detection method Methods 0.000 claims description 3
- 230000008569 process Effects 0.000 claims description 3
- 238000005259 measurement Methods 0.000 description 6
- 238000010586 diagram Methods 0.000 description 5
- 238000004364 calculation method Methods 0.000 description 2
- 238000013461 design Methods 0.000 description 2
- 238000006073 displacement reaction Methods 0.000 description 2
- 230000001133 acceleration Effects 0.000 description 1
- 238000013459 approach Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000005260 corrosion Methods 0.000 description 1
- 230000007797 corrosion Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01D—MEASURING NOT SPECIALLY ADAPTED FOR A SPECIFIC VARIABLE; ARRANGEMENTS FOR MEASURING TWO OR MORE VARIABLES NOT COVERED IN A SINGLE OTHER SUBCLASS; TARIFF METERING APPARATUS; MEASURING OR TESTING NOT OTHERWISE PROVIDED FOR
- G01D3/00—Indicating or recording apparatus with provision for the special purposes referred to in the subgroups
- G01D3/028—Indicating or recording apparatus with provision for the special purposes referred to in the subgroups mitigating undesired influences, e.g. temperature, pressure
- G01D3/032—Indicating or recording apparatus with provision for the special purposes referred to in the subgroups mitigating undesired influences, e.g. temperature, pressure affecting incoming signal, e.g. by averaging; gating undesired signals
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01D—MEASURING NOT SPECIALLY ADAPTED FOR A SPECIFIC VARIABLE; ARRANGEMENTS FOR MEASURING TWO OR MORE VARIABLES NOT COVERED IN A SINGLE OTHER SUBCLASS; TARIFF METERING APPARATUS; MEASURING OR TESTING NOT OTHERWISE PROVIDED FOR
- G01D5/00—Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable
- G01D5/12—Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means
- G01D5/243—Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means influencing the phase or frequency of AC
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Transmission And Conversion Of Sensor Element Output (AREA)
Abstract
The invention discloses a circuit and a method for improving the output precision of increment coding ABZ in a magnetic angle encoder, wherein the circuit for improving the output precision of increment coding ABZ in the magnetic angle encoder comprises an A/D conversion unit, a phase detector, an advance phase estimation unit, an A/B signal edge jump estimation unit and a high frequency digital clock unit, wherein the input end of the A/D conversion unit is connected with an analog magnetic field intensity signal when a magnet rotates, the output end of the A/D conversion unit is connected with the phase detector, the phase detector is connected with the advance phase estimation unit and the A/B signal edge jump estimation unit, the advance phase estimation unit is connected with the A/B signal edge jump estimation unit, and the A/B signal edge jump estimation unit outputs an A/B signal; the circuit combines advanced phase estimation and A/B signal edge jump threshold judgment on the basis of the conventional magnetic angle encoder increment A/B signal output principle, further improves the accuracy of the A/B signal, reduces A/B signal jitter caused by high-speed movement of the magnet, and has better performance in variable-speed movement of the magnet.
Description
Technical Field
The invention relates to the technical field of motor control circuits, in particular to a circuit and a method for improving the output precision of increment coding ABZ in a magnetic angle encoder.
Background
In the aspects of speed measurement, counting, angular displacement measurement, linear displacement and the like in the current industrial application, the magnetic angle encoder has the advantages of small volume, convenient assembly, corrosion resistance, pollution resistance, reliable performance and the like, and is gradually replaced with the photoelectric encoder to be applied to more and more occasions. However, in the case of high-speed motion measurement, the photoelectric encoder can maintain stable output accuracy because the porous turntable can be used. The magnetic angle encoder is limited by the a/D sampling frequency and the time delay of the digital processing section, which results in a large amplitude jitter and deviation of the output ABZ signal relative to the slow motion measurement.
The existing ABZ signal output principle of the magnetic angle encoder is shown in fig. 1, and the graph shows that as the rotating speed of the magnet increases, the range of angle errors and the frequency of errors are increased, and the performance of the whole magnetic angle encoder can be influenced in actual use.
Disclosure of Invention
The technical problems to be solved by the invention are as follows: under the condition of high-speed motion measurement, the magnetic angle encoder is limited by the A/D sampling frequency and the time delay of the digital processing part can lead to larger amplitude jitter and deviation of the output A/B signal relative to the measurement result of slow motion, and the range of angle errors and the frequency of errors can be increased along with the increase of the rotating speed of the magnet, so that the performance problem of the whole magnetic angle encoder can be influenced in actual use.
The invention is realized by the following technical scheme:
A circuit for improving the output precision of increment coding ABZ in a magnetic angle encoder comprises an A/D conversion unit, a phase detector, a lead phase estimation unit, an A/B signal edge jump estimation unit and a high frequency digital clock unit. The input end of the A/D conversion unit is connected with an analog magnetic field intensity signal when the magnet rotates, the output end of the A/D conversion unit is connected with a phase detector, the phase detector is connected with a lead phase estimation unit and an A/B signal edge jump estimation unit, the lead phase estimation unit is connected with the A/B signal edge jump estimation unit, and the A/B signal edge jump estimation unit outputs an A/B signal; wherein:
The A/D conversion unit is used for converting the analog magnetic field intensity into digital signals in the horizontal and vertical directions at a fixed sampling frequency and transmitting the digital signals to the phase detector;
The phase detector is used for processing the input magnetic field intensity in the horizontal and vertical directions to obtain the current rotating angle value of the magnet;
The advanced phase estimation unit is used for estimating the next phase according to the angle result detected by the multi-time historical phase detector and transmitting the next phase to the A/B signal edge jump estimation unit for edge jump phase estimation;
The A/B signal edge jump estimation unit is used for estimating the rising/falling edge position of the quadrature A/B signal, reducing the amplitude of A/B signal jitter caused by burst noise and high rotating speed and outputting an A/B signal;
The high frequency digital clock unit is used as a reference clock of the A/B signal edge jump estimation unit.
The invention mainly relates to generation of an A/B signal in an ABZ signal of a motor control system, wherein the generation principle and mechanism of the A/B signal are consistent, and only the phase difference exists.
The working principle is as follows: the invention relates to a circuit for improving the output precision of increment coding ABZ in a magnetic angle encoder, which comprises an A/D conversion unit, a phase detector and a magnetic angle encoder, wherein the A/D conversion unit converts the analog magnetic field intensity when a magnet rotates into digital signals in horizontal and vertical directions at a fixed sampling frequency and transmits the digital signals to the phase detector; secondly, detecting and obtaining the angle value of the current magnet rotation by a phase detector, obtaining the angle delta theta of the magnet rotation between two A/D sampling moments according to the angle values detected by the front and rear phase detectors, transmitting the delta theta into a super front phase estimating unit, and estimating the angle delta theta' of the magnet rotation when the next A/D sampling moment arrives; finally, the advance phases delta theta' and delta theta are transmitted to an A/B signal jump edge position estimation unit to carry out jump edge position estimation of the A/B signal. The circuit is added with an advanced phase estimation unit and an A/B signal edge jump estimation unit based on the conventional magnetic angle encoder increment A/B signal output, and is used for advanced phase estimation and A/B signal edge jump threshold judgment in combination, so that the accuracy of the A/B signal is further improved, the A/B signal jitter caused by high-speed movement of a magnet is reduced, and the circuit has better performance in the magnet variable-speed movement; the circuit has the advantages of small scale, low power consumption and simple control, and is convenient for practical application.
Further, the high frequency digital clock unit is in phase with the sampling frequency of the A/D conversion unit, the frequency is 2 N times of the sampling frequency of the A/D conversion unit, and the value range of N is 3-6, so that the accuracy of the A/B signal is compensated.
Further, the system also comprises a source clock unit and a frequency divider, wherein the source clock unit is connected with the frequency divider, the frequency divider is connected with the high-frequency digital clock unit and the A/D conversion unit, the source clock unit generates a clock and a digital domain clock required by sampling of the A/D conversion unit through frequency division of the frequency divider, the digital domain clock frequency is 2 N times of the sampling rate of the A/D conversion unit, the value range of N is 3-6, and N is used for compensating the precision of the A/B signal.
Further, a PLL phase-locked loop is included for phase-locking the high frequency digital clock unit.
Further, the a/D conversion unit converts the analog magnetic field strength into digital signals in horizontal and vertical directions at a fixed sampling frequency and transmits the digital signals to the phase detector, wherein the digital signals include digital horizontal magnetic field components and digital vertical magnetic field components.
A method for improving the accuracy of incremental encoded ABZ output in a magnetic angle encoder, the method comprising the steps of:
S1: converting the analog magnetic field intensity when the magnet rotates into digital signals in the horizontal and vertical directions at a fixed sampling frequency, and transmitting the digital signals to a phase detector;
s2: according to the horizontal and vertical magnetic field intensity digital signals input in the step S1, the phase detector adopts a CORDIC algorithm to calculate and analyze to obtain the current magnet rotation angle value;
s3: according to step S2, subtraction operation is carried out on the angle values detected by the front phase detector and the rear phase detector, so as to obtain the angle delta theta of the magnet rotating between the two A/D sampling moments;
s4: transmitting the delta theta into a super-front phase estimation unit according to the delta theta obtained in the step S3, and estimating the angle delta theta' rotated by the magnet when the next A/D sampling time arrives;
s5: according to steps S3 and S4, the advance phases delta theta' and delta theta are transmitted to an A/B signal jump edge position estimation unit to carry out jump edge position estimation of the A/B signal.
Further, the method of estimating the angle Δθ' through which the magnet rotates when the next a/D sampling time comes may be any one of a sliding window averaging method and a weighted averaging method, where: the sliding window average method formula adoptsThe formula averages the angles of rotation of the magnet in n A/D sampling periods which are continuously measured; n is the length of the sliding window; Δθ j is the angle through which the magnet rotates in each A/D sampling period; the weighted average formula uses Δθ ' k=Δθk*α+Δθ′k-1 (1- α), where Δθ ' k is the estimated angle through which the magnet rotates in the kth a/D sampling period, Δθ ' k-1 is the estimated angle through which the magnet rotates in the kth-1 a/D sampling period, Δθ k is the currently measured angle through which the magnet rotates in the kth a/D sampling period, and α is a weighting factor less than 1.
Further, in step S5, the advance phases Δθ' and Δθ are transmitted to the a/B signal jump edge position estimation unit, and the jump edge position estimation of the a/B signal is performed, which specifically includes the following steps:
S51: when it is detected that the following condition is satisfied at the p-th Δθ, the high frequency digital clock unit counts clear 0 and restarts counting, using the following formula:
Wherein T is 1/4 of each A/B signal period, delta theta is the currently measured angle of magnet rotation in 1A/D sampling period, and the formula indicates the triggering condition when the difference between T and the total angle of magnet rotation is smaller than the estimated angle of magnet rotation in the next A/D sampling period in the continuous P A/D sampling times;
S52: the delta theta 'p is divided equally into 2 M parts, each of which has an angular dimension delta theta' aver=Δθ′p/2M, where 2 M is related to a multiple of 2 N of the high frequency digital clock unit relative to the a/D sampling frequency in step S51 as follows: n > =m; m adaptively configures a numerical value according to the size of the current delta theta' k;
S53: order the When DEG is greater than or equal to m [ delta ] theta' averm*Δθ′aver, recording the value of m; wherein DEG represents the angle required to be compensated for in the detection of the A/B signal edge to generate the next A/B signal edge; m represents the number of high frequency clock cycles that need to pass for this compensation;
S54: when the number of the high frequency digital clock units is recorded to m, rising/falling edges of the A/B signals are generated;
S55: the Δθ -DEG is calculated as Δθ 0 in the next step S51 when the next Δθ arrives, and p in step S51 is cleared to 0, and then the process goes back to step S51.
The invention has the following advantages and beneficial effects:
1. According to the circuit for improving the output precision of the increment coding ABZ in the magnetic angle encoder, in the principle of outputting the increment A/B signal of the conventional magnetic angle encoder, the circuit is combined with advanced phase estimation and the judgment of the A/B signal along the jump threshold, so that the precision of the A/B signal is further improved, the A/B signal jitter caused by high-speed movement of a magnet is reduced, and the circuit has better performance in the variable-speed movement of the magnet;
2. the circuit for improving the output precision of the increment coding ABZ signal in the magnetic angle encoder has the advantages of small scale, low power consumption and simple control, and is convenient for practical application;
3. The method for improving the output precision of the increment coding ABZ signal in the magnetic angle encoder improves the precision of the increment A/B signal and reduces the A/B signal jitter caused by high-speed movement of a magnet or burst noise.
Drawings
The accompanying drawings, which are included to provide a further understanding of embodiments of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the principles of the application. In the drawings:
FIG. 1 is a schematic diagram of the ABZ signal output of a conventional magnetic angle encoder according to the present invention.
FIG. 2 is a circuit diagram of an improved output accuracy of an incremental encoded A/B signal in a magnetic angle encoder according to the present invention.
FIG. 3 is a schematic diagram illustrating the estimation of the position of the entire A/B signal edge in a method for improving the output accuracy of an incremental encoded A/B signal in a magnetic angle encoder according to the present invention.
FIG. 4 is a schematic diagram of the output of A/B signals during accelerated rotation of a magnet in a method for improving the accuracy of the output of delta coded A/B signals in a magnetic angle encoder according to the present invention.
In the drawings, the reference numerals and corresponding part names:
The device comprises a 1-A/D conversion unit, a 2-phase detector, a 3-advanced phase estimation unit, a 4-A/B signal edge jump estimation unit, a 5-high frequency digital clock unit, a 6-source clock unit and a 7-frequency divider.
Detailed Description
For the purpose of making apparent the objects, technical solutions and advantages of the present invention, the present invention will be further described in detail with reference to the following examples and the accompanying drawings, wherein the exemplary embodiments of the present invention and the descriptions thereof are for illustrating the present invention only and are not to be construed as limiting the present invention.
Example 1
As shown in fig. 1 to 2, a circuit for improving output precision of incremental coding ABZ in a magnetic angle encoder comprises an a/D conversion unit 1, a phase detector 2, a leading phase estimation unit 3, an a/B signal edge jump estimation unit 4 and a high frequency digital clock unit 5, wherein an input end of the a/D conversion unit 1 is connected with an analog magnetic field intensity signal when a magnet rotates, an output end of the a/D conversion unit is connected with the phase detector 2, the phase detector 2 is connected with the leading phase estimation unit 3 and the a/B signal edge jump estimation unit 4, the leading phase estimation unit 3 is connected with the a/B signal edge jump estimation unit 4, and the a/B signal edge jump estimation unit 4 outputs an a/B signal; wherein:
The a/D conversion unit 1 is configured to convert the analog magnetic field strength into a digital signal in the horizontal and vertical directions at a fixed sampling frequency and transmit the digital signal to the phase detector 2, wherein the digital signal includes a digital horizontal magnetic field component and a digital vertical magnetic field component; and the higher the conversion precision of the A/D conversion unit 1 is, the higher the sampling frequency is, the higher the precision of the sampled data is, which is helpful for improving the precision of the A/B output signal;
the phase detector 2 is used for processing the input magnetic field intensity in the horizontal and vertical directions to obtain the current rotating angle value of the magnet;
The advance phase estimation unit 3 is configured to estimate a next phase according to the angle result detected by the multiple historical phase detector 2, and transmit the next phase to the a/B signal edge jump estimation unit 4 for edge jump phase estimation;
the a/B signal edge jump estimation unit 4 is configured to estimate a rising/falling edge position of an orthogonal a/B signal, reduce an amplitude of a/B signal jitter caused by burst noise and a high rotation speed, and output an a/B signal;
The high-frequency digital clock unit 5 is used as a reference clock of the A/B signal edge jump estimation unit 4, the high-frequency digital clock unit 5 is in phase with the sampling frequency of the A/D conversion unit 1, the frequency is 2 N times of the sampling frequency of the A/D conversion unit 1, and the value range of N is 3-6 and is used for compensating the accuracy of the A/B signal. This may be achieved by dividing the source clock unit 6 by a divider 7, wherein: the source clock unit 6 is connected with the frequency divider 7, the frequency divider 7 is connected with the high-frequency digital clock unit 5 and the A/D conversion unit 1, the source clock unit 6 generates a clock and a digital domain clock required by sampling of the A/D conversion unit 1 through frequency division of the frequency divider 7, the digital domain clock frequency is 2 N times of the sampling rate of the A/D conversion unit 1, the value range of N is 3-6, and N is used for compensating the precision of the A/B signal.
Under the condition that the magnet rotates at a high speed, in order to improve the output precision, the PLL phase-locked loop is also considered to lock the high frequency digital clock unit 5 so as to improve the sampling and calculation precision of the digital domain signal.
The working principle is as follows: the invention relates to a circuit for improving the output precision of increment coding ABZ in a magnetic angle encoder, which comprises the following steps that firstly, an A/D conversion unit 1 converts the intensity of an analog magnetic field when a magnet rotates into a digital signal in the horizontal and vertical directions at a fixed sampling frequency, and the digital signal is transmitted to a phase detector 2; secondly, the phase detector 2 detects and obtains the angle value of the current magnet rotation, and the angle delta theta of the magnet rotation between two A/D sampling moments is obtained according to the angle values detected by the front and back phase detectors 2, and is transmitted into the super-front phase estimating unit 3 to estimate the angle delta theta' of the magnet rotation when the next A/D sampling moment arrives; finally, the advance phases delta theta' and delta theta are transmitted to an A/B signal jump edge position estimation unit to carry out jump edge position estimation of the A/B signal. The circuit is added with the advanced phase estimation unit 3 and the A/B signal edge jump estimation unit 4 on the basis of the conventional magnetic angle encoder increment ABZ signal output, and is used for advanced phase estimation and A/B signal edge jump threshold judgment in combination, so that the accuracy of the A/B signal is further improved, the A/B signal jitter caused by the high-speed movement of the magnet is reduced, and the circuit has better performance in the magnet variable-speed movement; the circuit has the advantages of small scale, low power consumption and simple control, and is convenient for practical application.
Example 2
As shown in fig. 1 to 4, the present embodiment is different from embodiment 1 in a method for improving the output accuracy of incremental encoding ABZ in a magnetic angle encoder, the method comprising the steps of:
The period of the A/B signal can be determined by the line number configured by a user, and the angle T corresponding to one period is 360/line number;
S1: converting the analog magnetic field intensity when the magnet rotates into digital signals in the horizontal and vertical directions at a fixed sampling frequency, and transmitting the digital signals to the phase detector 2; the sampling frequency is the clock and digital domain clock required by the source clock unit 6 to generate A/D sampling through the frequency divider 7, the digital domain clock frequency is 2 N times of the A/D sampling rate, N can be set according to specific requirements, and the value can be 3-6;
S2: according to the horizontal and vertical magnetic field intensity digital signals input in the step S1, the phase detector 2 adopts a CORDIC algorithm to calculate and analyze to obtain the current magnet rotation angle value;
S3: according to step S2, subtraction is performed on the angle values detected by the front and rear phase detectors 2 to obtain the angle Δθ through which the magnet rotates between the two a/D sampling moments;
S4: transmitting the delta theta into the super-front phase estimation unit 3 according to the delta theta obtained in the step S3, and estimating the angle delta theta' through which the magnet rotates when the next A/D sampling time comes; the advance phase estimating unit 3 estimates the rotation angle of the magnet in an A/D sampling period by using a sliding window averaging method or a weighted iterative averaging method.
Wherein: the mode of estimating the angle delta theta' through which the magnet rotates when the next A/D sampling moment comes adopts any one of a sliding window averaging method and a weighted averaging method;
(1) Sliding window averaging method, formula using The formula averages the angles of rotation of the magnet in n A/D sampling periods which are continuously measured; n is the length of the sliding window; Δθ j is the angle through which the magnet rotates in each A/D sampling period;
(2) The weighted average method adopts the formula of delta theta ' k=Δθk*α+Δθ′k-1 (1-alpha), wherein delta theta ' k is the estimated angle of magnet rotation in the Kth A/D sampling period, delta theta ' k-1 is the estimated angle of magnet rotation in the Kth-1A/D sampling period, delta theta k is the currently measured angle of magnet rotation in the Kth A/D sampling period, and alpha is a weighting coefficient smaller than 1.
S5: according to steps S3 and S4, the advance estimated phases delta theta' and delta theta are transmitted to an A/B signal jump edge position estimation unit to carry out jump edge position estimation of the A/B signal.
Specifically:
In step S5, the advance phases Δθ' and Δθ are transmitted to the a/B signal jump edge position estimation unit, and the jump edge position estimation of the a/B signal is performed, which specifically includes the following steps:
s51: when it is detected that the following condition is satisfied at the p-th Δθ, the high frequency digital clock unit 5 counts clear 0 and restarts the count (counts the number of clocks), the following formula is adopted:
Where T is 1/4 of each A/B signal period and Δθ is the angle currently measured by the magnet rotating during 1A/D sampling period. The method is characterized in that the trigger condition is shown when the difference between T and the total angle rotated by the magnet is smaller than the estimated angle rotated by the magnet in the next A/D sampling time in the continuous P A/D sampling times;
S52: the delta theta 'p is divided equally into 2 M parts, each of which has an angular dimension delta theta' aver=Δθ′p/2M, where 2 M is related to a multiple of 2 N of the high frequency digital clock unit relative to the a/D sampling frequency in step S51 as follows: n > =m; m adaptively configures a numerical value according to the size of the current delta theta' k;
S53: order the When DEG is greater than or equal to m [ delta ] theta' aver, recording the value of m; wherein DEG represents the angle required to be compensated for in the detection of the A/B signal edge to generate the next A/B signal edge; m represents the number of high frequency clock cycles that need to pass for this compensation;
S54: when the number of the high frequency digital clock units is recorded to m, rising/falling edges of the A/B signals are generated;
S55: the Δθ -DEG is calculated as Δθ 0 in the next step S51 when the next Δθ arrives, and p in step S51 is cleared to 0, and then the process goes back to step S51.
The whole A/B signal edge position estimation schematic diagram is shown in fig. 3, and the A/B signal output after edge estimation is more close to an ideal A/B signal.
Under the above-described design, the accuracy of the a/B signal in the magnet acceleration/deceleration motion state can also be improved by configuring in the estimated approach direction, as shown in fig. 4.
When the magnet rotates in an accelerating way, a decision threshold point closest to the left side of the edge position is configured and selected, so that an edge signal is output in advance in an accelerating state, and phase errors between the magnet and an ideal state are reduced. Similarly, when the magnet performs deceleration motion, a decision threshold point closest to the right side of the edge position needs to be configured and selected.
In addition, the design of the invention has the following characteristics:
1, the advance phase estimation unit 3 may select the mask within a range where the magnet may be reversed (i.e., a period of time when the speed is gradually changed from the forward direction to the reverse direction) to reduce the probability of misjudgment of the direction.
2, In the advance phase estimating unit 3, each advance phase estimation can be compared with the actual a/D sampling value at the corresponding position to obtain the estimation error ERR of the current advance phase Δθ' k and the actual phase Δθ k, and then the ERR is brought into the operation of the next advance phase estimation, which is helpful to improve the accuracy of the advance phase estimation, namely:
ERR=Δθ′k-Δθk
Δθ′real,k+1=Δθ′k+1+ERR
Wherein ERR is an estimated error between a current advance phase Δθ ' k and a phase Δθ k of an actual magnet rotated in an a/D sampling time, Δθ ' k+1 is a next estimated advance phase, and Δθ ' real,k+1 is a corrected next estimated advance phase;
Subsequent substituting Δθ 'real,k+1 for Δθ' k+1 to carry out the calculations from step S51 to step S55 can further improve the output accuracy of the a/B signal.
3, The whole A/B signal edge jump estimating unit 4 and the advanced phase estimating unit 3 can be configured to be in a bypass state by an external instruction so as to reduce the power consumption in a specific occasion.
The foregoing description of the embodiments has been provided for the purpose of illustrating the general principles of the invention, and is not meant to limit the scope of the invention, but to limit the invention to the particular embodiments, and any modifications, equivalents, improvements, etc. that fall within the spirit and principles of the invention are intended to be included within the scope of the invention.
Claims (7)
1. A method for improving output precision of an incremental coded ABZ signal in a magnetic angle encoder, the method comprising the steps of:
S1: converting the analog magnetic field intensity when the magnet rotates into digital signals in the horizontal and vertical directions at a fixed sampling frequency, and transmitting the digital signals to a phase detector;
s2: according to the horizontal and vertical magnetic field intensity digital signals input in the step S1, the phase detector adopts a CORDIC algorithm to calculate and analyze to obtain the current magnet rotation angle value;
s3: according to step S2, subtraction operation is carried out on the angle values detected by the front phase detector and the rear phase detector, so as to obtain the angle delta theta of the magnet rotating between the two A/D sampling moments;
s4: transmitting the delta theta into a super-front phase estimation unit according to the delta theta obtained in the step S3, and estimating the angle delta theta' rotated by the magnet when the next A/D sampling time arrives;
S5: s3 and S4, transmitting the advanced estimated phases delta theta' and delta theta to an A/B signal jump edge position estimation unit to perform jump edge position estimation of the A/B signal;
In step S5, the advance estimated phases Δθ' and Δθ are transmitted to the a/B signal jump edge position estimation unit, and the jump edge position estimation of the a/B signal is performed, which specifically includes the following steps:
S51: when it is detected that the following condition is satisfied at the p-th Δθ, the high frequency digital clock unit counts clear 0 and restarts counting, using the following formula:
Wherein T is 1/4 of each A/B signal period, delta theta is the currently measured angle of magnet rotation in 1A/D sampling period, and the formula indicates the triggering condition when the difference between T and the total angle of magnet rotation is smaller than the estimated angle of magnet rotation in the next A/D sampling period in the continuous P A/D sampling times;
S52: the delta theta 'p is divided equally into 2 M parts, each of which has an angular dimension delta theta' aver=Δθ′p/2M, where 2 M is related to a multiple of 2 N of the high frequency digital clock unit relative to the a/D sampling frequency in step S51 as follows: n > =m; m adaptively configures a numerical value according to the size of the current delta theta' k;
S53: order the When DEG is greater than or equal to m [ delta ] theta' averm*Δθ′aver, recording the value of m; wherein DEG represents the angle required to be compensated for in the detection of the A/B signal edge to generate the next A/B signal edge; m represents the number of high frequency clock cycles that need to pass for this compensation;
S54: when the number of the high frequency digital clock units is recorded to m, rising/falling edges of the A/B signals are generated;
S55: the Δθ -DEG is calculated as Δθ 0 in the next step S51 when the next Δθ arrives, and p in step S51 is cleared to 0, and then the process goes back to step S51.
2. The method for improving output precision of an incremental coded ABZ signal in a magnetic angle encoder according to claim 1, wherein the method for estimating the angle Δθ' rotated by the magnet when the next a/D sampling time arrives is any one of a sliding window averaging method and a weighted averaging method, wherein: the sliding window average method formula adoptsThe formula averages the angles of rotation of the magnet in n A/D sampling periods which are continuously measured; n is the length of the sliding window; Δθ j is the angle through which the magnet rotates in each A/D sampling period; the weighted average formula uses Δθ ' k=Δθk*α+Δθ'k-1 (1- α), where Δθ ' k is the estimated angle through which the magnet rotates in the kth a/D sampling period, Δθ ' k-1 is the estimated angle through which the magnet rotates in the kth-1 a/D sampling period, Δθ k is the currently measured angle through which the magnet rotates in the kth a/D sampling period, and α is a weighting factor less than 1.
3. The circuit realized based on the method for improving the output precision of the increment coding ABZ signal in the magnetic angle encoder according to any one of claims 1 to 2 is characterized by comprising an A/D conversion unit (1), a phase detector (2), an advance phase estimation unit (3), an A/B signal edge jump estimation unit (4) and a high frequency digital clock unit (5), wherein the input end of the A/D conversion unit (1) is connected with an analog magnetic field intensity signal when a magnet rotates, the output end of the A/D conversion unit is connected with the phase detector (2), the phase detector (2) is connected with the advance phase estimation unit (3) and the A/B signal edge jump estimation unit (4), the advance phase estimation unit (3) is connected with the A/B signal edge jump estimation unit (4), and the A/B signal edge jump estimation unit (4) outputs the A/B signal; wherein:
the A/D conversion unit (1) is used for converting the analog magnetic field intensity into digital signals in the horizontal and vertical directions at a fixed sampling frequency and transmitting the digital signals to the phase detector;
the phase detector (2) is used for processing the input magnetic field intensity in the horizontal and vertical directions to obtain the current rotating angle value of the magnet;
The advanced phase estimation unit (3) is used for estimating the next phase according to the angle result detected by the multi-time historical phase detector (2) and transmitting the next phase to the A/B signal edge jump estimation unit (4) for edge jump phase estimation;
The A/B signal edge jump estimation unit (4) is used for estimating the rising/falling edge positions of the orthogonal A/B signals and outputting the A/B signals;
the high frequency digital clock unit (5) is used as a reference clock of the A/B signal edge jump estimation unit (4).
4. A circuit according to claim 3, characterized in that the high frequency digital clock unit (5) is in phase with the sampling of the a/D conversion unit (1) and has a frequency of 2 N times the sampling frequency of the a/D conversion unit (1), N has a value in the range of 3 to 6, N is used to compensate for the accuracy of the a/B signal.
5. A circuit according to claim 3, further comprising a source clock unit (6) and a frequency divider (7), wherein the source clock unit (6) is connected to the frequency divider (7), the frequency divider (7) is connected to both the high frequency digital clock unit (5) and the a/D conversion unit (1), the source clock unit (6) generates the clock and the digital domain clock required for sampling by the a/D conversion unit (1) by frequency division of the frequency divider (7), the digital domain clock frequency is 2 N times the sampling rate of the a/D conversion unit (1), the value of N ranges from 3 to 6, and N is used for compensating the accuracy of the a/B signal.
6. A circuit as claimed in claim 3, characterized by further comprising a PLL phase locked loop for phase locking the high frequency digital clock unit (5).
7. A circuit according to claim 3, characterized in that the a/D conversion unit (1) converts the analog magnetic field strength into a digital signal in horizontal and vertical directions at a fixed sampling frequency, which digital signal comprises a digital horizontal magnetic field component, a digital vertical magnetic field component, to the phase detector.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910730249.0A CN110274615B (en) | 2019-08-08 | 2019-08-08 | Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910730249.0A CN110274615B (en) | 2019-08-08 | 2019-08-08 | Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110274615A CN110274615A (en) | 2019-09-24 |
CN110274615B true CN110274615B (en) | 2024-05-10 |
Family
ID=67965896
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910730249.0A Active CN110274615B (en) | 2019-08-08 | 2019-08-08 | Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110274615B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112362089B (en) * | 2020-10-30 | 2022-05-27 | 哈尔滨理工大学 | A multi-pair magnetoelectric encoder and its high-resolution and high-reliability angle calculation method |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US4827225A (en) * | 1988-06-13 | 1989-05-02 | Unisys Corporation | Fast locking phase-locked loop utilizing frequency estimation |
US6078614A (en) * | 1996-09-24 | 2000-06-20 | Hewlett-Packard Company | Data processing apparatus and methods |
JP2007085942A (en) * | 2005-09-22 | 2007-04-05 | Yaskawa Electric Corp | Magnetic encoder device, angle of rotation calculation method and position detection method |
CN108375384A (en) * | 2017-01-31 | 2018-08-07 | 亚德诺半导体集团 | Magnetic sensor position measurement with phase compensation |
JP2018132357A (en) * | 2017-02-14 | 2018-08-23 | 日本電産サンキョー株式会社 | Rotary encoder |
CN108959183A (en) * | 2018-06-05 | 2018-12-07 | 上海麦歌恩微电子股份有限公司 | The forward interpolation method of angular transducer and rotary encoder |
CN109506680A (en) * | 2018-11-23 | 2019-03-22 | 成都芯进电子有限公司 | A kind of absolute type magnetic angle encoder Digital Implementation framework |
CN110081913A (en) * | 2018-01-25 | 2019-08-02 | 迈来芯电子科技有限公司 | Position sensor device |
CN210036761U (en) * | 2019-08-08 | 2020-02-07 | 成都芯进电子有限公司 | Circuit for improving output precision of incremental coding ABZ in magnetic angle encoder |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7839178B2 (en) * | 2002-08-20 | 2010-11-23 | Seagate Technology Llc | High speed digital phase/frequency comparator for phase locked loops |
US8355239B2 (en) * | 2008-01-29 | 2013-01-15 | Infineon Technologies Ag | Predictive phase locked loop system |
-
2019
- 2019-08-08 CN CN201910730249.0A patent/CN110274615B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US4827225A (en) * | 1988-06-13 | 1989-05-02 | Unisys Corporation | Fast locking phase-locked loop utilizing frequency estimation |
US6078614A (en) * | 1996-09-24 | 2000-06-20 | Hewlett-Packard Company | Data processing apparatus and methods |
JP2007085942A (en) * | 2005-09-22 | 2007-04-05 | Yaskawa Electric Corp | Magnetic encoder device, angle of rotation calculation method and position detection method |
CN108375384A (en) * | 2017-01-31 | 2018-08-07 | 亚德诺半导体集团 | Magnetic sensor position measurement with phase compensation |
JP2018132357A (en) * | 2017-02-14 | 2018-08-23 | 日本電産サンキョー株式会社 | Rotary encoder |
CN110081913A (en) * | 2018-01-25 | 2019-08-02 | 迈来芯电子科技有限公司 | Position sensor device |
CN108959183A (en) * | 2018-06-05 | 2018-12-07 | 上海麦歌恩微电子股份有限公司 | The forward interpolation method of angular transducer and rotary encoder |
CN109506680A (en) * | 2018-11-23 | 2019-03-22 | 成都芯进电子有限公司 | A kind of absolute type magnetic angle encoder Digital Implementation framework |
CN210036761U (en) * | 2019-08-08 | 2020-02-07 | 成都芯进电子有限公司 | Circuit for improving output precision of incremental coding ABZ in magnetic angle encoder |
Non-Patent Citations (2)
Title |
---|
一种基于数据跳变检测的高动态环境GPS信号参数估计方法;李小民, 刘晖, 郑利龙, 张其善;航空学报;19990525(第05期);全文 * |
高可靠性增量式光电编码器接口电路设计;蒋晶;蒋东方;高航;;测控技术;20090218(第02期);全文 * |
Also Published As
Publication number | Publication date |
---|---|
CN110274615A (en) | 2019-09-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8384570B2 (en) | Encoder interpolator with enhanced precision | |
US6064199A (en) | Magnetic field change detection circuitry having threshold establishing circuitry | |
US7859344B2 (en) | PLL circuit with improved phase difference detection | |
US6384752B1 (en) | Absolute encoder | |
US5999060A (en) | Digital frequency synthesizer system and method | |
US7688242B2 (en) | Analog-to-digital (AD) converter and analog-to-digital conversion method | |
EP3701631B1 (en) | Digital-to-time converter (dtc) assisted all digital phase locked loop (adpll) circuit | |
JP3072833B2 (en) | Digital PLL circuit | |
JP3015747B2 (en) | Encoder interpolation circuit | |
CN106844253B (en) | A kind of serial communication clock data recovery system of low sampling rate | |
CN110274615B (en) | Circuit and method for improving output precision of incremental coding ABZ in magnetic angle encoder | |
CN210036761U (en) | Circuit for improving output precision of incremental coding ABZ in magnetic angle encoder | |
CN113446925A (en) | Digital phase tracking filter for position sensing | |
US5079549A (en) | Digital resolver with a synchronous multiple count generation | |
JP2012049660A (en) | Phase-locked loop circuit | |
US7859313B2 (en) | Edge-missing detector structure | |
US8472561B2 (en) | Receiver circuit | |
CN102933970B (en) | Comprise the speed pickup of Costas loop | |
Kim et al. | Ultra precise position estimation of servomotor using analog quadrature encoders | |
JP5326759B2 (en) | FSK receiving apparatus, FSK receiving method, and program | |
US7535382B2 (en) | High speed quadrature counter | |
JP2003130686A (en) | Device for detecting position | |
US9118451B2 (en) | Receiver circuit and receiving method | |
US9252785B2 (en) | Clock recovery for a data receiving unit | |
CN110595514B (en) | Phase adaptive circuit in rotary-to-digital converter and control method thereof |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CP03 | Change of name, title or address |
Address after: Room 401, unit 2, building 3, No. 88, Tianchen Road, high tech Zone (West District), Chengdu, Sichuan 610000 Patentee after: Chengdu Xinjin Electronics Co.,Ltd. Country or region after: China Address before: Room 401, unit 2, building 3, No. 88, Tianchen Road, high tech Zone (West District), Chengdu, Sichuan 610000 Patentee before: Chengdu Xinjin Electronics Co.,Ltd. Country or region before: China |
|
CP03 | Change of name, title or address |