The present disclosure relates generally to an angle measuring device and specifically to a device known as an angular encoder (or rotary encoder).
The angular encoder may be constructed in different ways. One type of angular encoder comprises a glass disk, one or more read heads, and processing electronics. The one or more read heads send light to the disk. This light is either transmitted through or reflected off the disk to optical detectors, which are also a part of the read heads. The glass disk contains a pattern, which may be as simple as a collection of lines directed radially outward from the disk center. As the disk rotates, the pattern of light changes on the read head. This changing light pattern is evaluated by the processing electronics to find the angle of rotation of the glass disk relative to the read heads. In most cases, the glass disk is attached to the rotating member, which might be an axle, and the read heads are attached to the frame within which the axle rotates.
A second type of angular encoder places the pattern on a ring rather than a disk. The one or more read heads send light to the ring, where it strikes the pattern reflecting back to the detectors in the read head. The changing pattern of light on the detector is evaluated by the processing electronics to find the angle of rotation of the ring relative to the read heads. In most cases, the ring is attached to the rotating member, which might be an axle, and the read heads are attached to the frame within which the axle rotates.
The disk and rings described above may be generally classified as patterned elements in that each holds a pattern, which may be a pattern of marks, for example, that are read by read heads, as described below. The patterned elements are designed to cooperate with read heads, described below, and the cooperation may involve optical, magnetic, mechanical, or other types of interaction between the patterned element and the read heads.
The read head is a device that reads a signal reflected by or transmitted through an encoder disk, ring, or similar structure. The most common types of read heads generate and respond to optical signals. A read head is constructed in such a way as to be able to distinguish between two directions of rotation of the disk or ring (for example, forward and backward). The most common method of providing the sense of direction is to obtain quadrature electrical signals, which are signals separated in phase by ninety degrees, from the obtained signal. Quadrature signals are also useful because they improve the accuracy of the encoder readings. There may be several read heads for each encoder disk or ring, and each of these read heads may produce quadrature electrical signals.
An angular encoder may be absolute or incremental. An absolute encoder provides the information to determine the present angle in an absolute sense—that is, without having a history of previous angle measurements. An incremental encoder, on the other hand, requires knowledge of previous encoder readings to determine the present reading. Ordinarily an incremental encoder contains a structure on the disk or ring that produces an optical signal that is transformed by the read head into an index pulse. The index pulse serves to provide a reference position, ordinarily accurate to within one line on the encoder disk or ring. At the start of a measurement session, an instrument containing an incremental encoder may begin by carrying out a procedure to determine the location of the index pulse. Generally the read head determines the position of the index pulse to a fraction of the spacing between two lines on the encoder disk or ring. Thereafter, a read head may count the number of lines that have passed it in either the forward and backward directions. From knowledge of the angle between encoder disk lines, it determines the present angle.
The accuracy with which angular encoders can measure varies widely. For inexpensive encoders, the angles may be measured in fractions of a degree. In contrast, other encoders are accurate to a fraction of an arc second. Highly accurate encoders are important to the class of devices that includes laser trackers, total stations, laser scanners, and theodolites. Accuracies required for such devices are often on the order of one microradian, or 0.2 arc seconds.
In most cases, the largest errors associated with angular encoders repeat for every 360 degree rotation of the encoder disk or ring. Additional errors, ordinarily smaller, may be associated with rotation of the bearings upon which the encoder disk or ring rotates. Such bearing errors typically repeat every 720 degrees, as is known in the art.
In this document, the dominant errors affecting the angular encoders are assumed to have a period of 360 degrees, although the method described herein can be easily extended without a reformulation of the mathematics to apply to the encoder-bearing system having a periodicity of 720 degrees or any multiple of 360 degrees. For the remainder of this document, it will be assumed that the errors have a period of 360 degrees so that they may be decomposed into spectral (Fourier) components having periods equal to 360°/n, where n=1, 2, 3, . . . In the case of an angular encoder using a glass disk and a single read head, the largest error is usually the first order (n=1) error that occurs once every 360 degrees. The main cause of this error is miscentering of the laser disk. An effective way to remove this first-order error is to use two read heads spaced 180 degrees apart rather than a single read head. By averaging the readings of the two read heads, the first-order angular error is eliminated. In fact, averaging the readings of two read heads eliminates errors of order 1, 3, 5, . . . (all orders except for those that are multiples of two).
For the case of an encoder that contains a glass disk, second order errors may be caused by tilt of the encoder disk relative to the read heads or by ellipticity (non-circularity) of the pattern of marks on the disk. These errors can be removed by using three or more symmetrically placed read heads. The readings from each of the read heads are averaged to find the encoder angle. In general, some number m of read heads can remove all Fourier error modes except for m and its harmonics. So two read heads cannot remove errors of orders n=2, 4, 6, . . . . Three read heads cannot remove errors of orders n=3, 6, 9, . . . .
To get the highest accuracy from reasonably priced encoders, some manufacturers who incorporate encoders in their products carry out a procedure called compensation (sometimes referred to as “calibration”) in which parameters or maps are found that enable correction of errors in software or firmware. The most common type of compensation involves placing a highly accurate reference encoder on one end of the axle. Readings are taken at the same time for the reference encoder and the encoder under test. The difference in the recorded values of these two encoders is used to create a map or a function to correct encoder errors.
However, mapping has limitations. First, there are inevitably errors in coupling two encoder systems together and even a very accurate reference encoder will lose accuracy when temporarily coupled to an external axle. Second, as explained above, static mapping parameters cannot correct for changes caused by temperature shifts or mechanical shocks. Third, because mapping is not model based, there is no mechanism for removing any errors that arise in the mapping process itself. In addition, mapping is a time-consuming procedure that adds cost to the manufacturer's product and reduces profit.
Another potential problem faced by encoder users is degradation in encoder performance, either as a result of changing environmental conditions or as a result of damage to the encoder assembly itself. It would be highly advantageous to be able to (1) detect degradation in encoder performance and (2) correct degradation in encoder performance without returning the instrument to the factory for re-compensation.
A method for self compensation of angular encoders is described in U.S. Pat. No. 7,825,367 ('367) to Nakamura et al. The method involves using a linear array, such as a CCD sensor, to read the lines on an encoder disk at two locations. The disk is rotated through a number of angular steps over 360 degrees. By analyzing the difference in the readings at the two encoder positions, errors in the encoder assembly may be determined. However, a serious deficiency with this method is encountered in devices that must work in industrial environments that may have wide temperature swings. Large temperature variations (for example, from −15 to +50 degrees Celsius) may cause large errors in an angular encoder containing a single read head or, as in the '367 patent, a single linear array. Such variations occur, for example, as a result of the differential thermal expansion of materials such as epoxy applied non-uniformly in bonding the encoder disk to the mechanical shaft on which it rotates. Such large errors may be automatically removed by placing two read heads 180 degrees apart and then averaging the readings of the read heads. The method of patent '367 is unable to provide the very important automatic correction of encoder errors with changes in temperature. Further discussion of the effect of temperature is given hereinafter with respect to
There is a need for an encoder apparatus and a compensation procedure that (1) enables higher accuracy than previously possible, (2) provides this high accuracy without mapping with an external reference encoder, (3) detects degradation in encoder performance during field use, (4) improves encoder performance in the field by carrying out a self-compensation procedure, and (5) provides automatic correction of low order encoder errors over temperature. In addition, in some cases, it may also be desirable to make use of data obtained from mapping to an external reference encoder if this mapping data is processed in a special way to improve encoder accuracy even further.
According to one aspect of the present invention, a method for self-compensating an angular encoder system, the angular encoder system including a structure, a patterned element configured to rotate by a first angle relative to the structure, the rotation performed about an axis, and read heads including one reference read head and a number m of measure read heads, the number m being greater than or equal to two, the read heads fixedly disposed on the structure and substantially located on a plane and positioned about a central point at the intersection of the axis and the plane, each read head disposed on the structure at a second angle about the central point; the measure read heads arranged in such a way that separation between the second angles of adjacent measure read heads is substantially equal to 360 degrees divided by the number m, the reference read head arranged in such a way that separation between the second angle of the reference read head and the second angle of any of the m measure read heads is not equal to zero. The method includes the steps of rotating the patterned element relative to the read heads, the rotation about the axis to a plurality of first angles covering a range of at least 360 degrees; obtaining, at each of the plurality of first angles, first angular readings for the m measure read heads and for the reference read head; calculating a first array for each of the m measure read heads, each first array including, for each of the plurality of first angles, a difference in the first angular readings of the measure read head and the first angular reading of the reference read head; calculating, for each of the m measure read heads, at least one first spectral component based at least in part on the first array; calculating, for each of the m measure read heads, at least one second spectral component, the second spectral component based, at least in part, on the at least one first spectral component and on estimates of the second angles of the m measure read heads; and recording, for each of the m measure read heads, the at least one second spectral component.
Referring now to the drawings, wherein like elements are numbered alike in the several FIGURES:
Encoder assembly 40 comprises encoder disk assembly 50 and read head assembly 60. Encoder disk assembly comprises encoder disk 52 and flange 54. Encoder disk 52 is rigidly attached through flange 54 to axle 20. Read head assembly 60 comprises mounting plate 62, read heads 64, and circuit board with processing electronics 66. Read heads 64 are securely attached to mounting plate 62 on their front side and are soldered to circuit board 66 on their back side. Read heads 64 send a laser beam to encoder disk. The laser beam bounces back and strikes optical detectors within read heads 64.
Electrical signals are transmitted through communication system 70 to one or more additional processors 80. Communication system 70 may be a device bus that transmits packets of information, for example. Optional one or more additional processor 80 alters the electrical signals from processing electronics to obtain the angle of rotation of axle 20. An example of additional processing that may be required by one or more additional processor 80 is adding or subtracting a constant to place the measured angle within the reference frame of the axle.
In a general sense, one or more read heads are attached to a structure. In the example shown in
As explained in the introduction, some manufacturers map angular encoders internal to their instruments by attaching a reference encoder to one end of the axle to which their encoder is attached. The readings of the internal and reference encoders are then compared. A map, generated from the difference in readings, is used to correct the readings of the instrument's encoder. An example of such a map for an encoder with three read heads 120A, 120B, and 120C spaced 120 degrees apart is shown in
As explained in the introduction, angular encoders have a period of 360 degrees, and encoder errors (neglecting 720 degree bearing errors, as described hereinabove) therefore repeat with the same 360 degree period. These errors may be decomposed into spectral (Fourier) components having periods equal to 360°/n, where n=1, 2, 3, . . . . Spectral components 510 of curve 410 (STANDARD MAP) in
One way to obtain the readings in step 710 is to use motors to step the encoder disk relative to the read heads by a desired angular step size over the required number of steps, N. Another way to obtain a number of evenly spaced steps is to rotate the disk continuously, rather than stepwise, with a motor and reading the read-head values at regular intervals. Another possibility is to rotate the encoder disk by hand. In the latter two cases, the data points may not be evenly spaced from 1 to N for a fixed time between readings. It is possible, however, to interpolate the collected data points to get N evenly spaced points. It is also possible to use N points that are not evenly spaced.
In an embodiment, the angles of the reads heads are set to zero when a reference mark passes by a reference position on the structure that holds the read heads. For example, the angle for the reference read head and each of the measure read heads may be set equal to zero when the index mark on the disk or ring passes the reference read head. At this instant, the angle of rotation of the disk or ring is said to be α=0, and the angle read by each of the m measure read heads is said to be αk(α=0)=0, where k=1, . . . , m. (For the arrangement shown in
It is possible to use a reference mark different than an index mark. For example, any arbitrary mark or position on the disk or ring could be used as a reference for establishing the zero angle. Furthermore, the reference mark could be set to zero when it satisfies some condition other than passing the reference read head. For example, it could be set to zero when it passed one of the measure read heads or some other device capable of synchronizing the angle of the disk or ring to a signal. Such possible variations will be obvious to one of ordinary skill in the art.
Step 720 is to calculate the differences in the angular readings between each of the m measure read heads and the reference read head. This difference is taken for each read head and for each of the plurality of first angles. The difference values are formed into m arrays−one array for each measure read head:
d
k={αk(α1)−αref(α1), αk(α2)−αref(α2), αk(α3)−αref(α3), . . . , αk(αN)−αref(αN)} (1)
Step 730 is to find first spectral components of the m arrays of Eq. (1). One way to do this is to perform a discrete Fourier transform (DFT) on each of the m arrays, as shown in Eq. (2):
F
k=DFT(dk). (2)
Each of the arrays Fk (k=1, . . . , m) has N elements but, because the elements dk are real numbers, the elements in Fk have a two-fold symmetry, enabling the Fk to be unambiguously represented by N/2 values for each k, as is known in the art. Another way to find the spectral components is to perform a best fit of the array of Eq. (1) to a series of sine and cosine terms (or amplitude and phase terms) having the appropriate frequencies with coefficients left as parameters to be found. Such a best fit may be obtained, for example, by minimizing the sum of squared residual errors. This method would be suitable, for example, for finding the coefficients when the collected data points are not evenly spaced. Of course variations of discrete Fourier transforms, such as fast Fourier transforms (FFTs) can also be used. The spectral components Fk resulting from Eq. (2) are called first spectral components to distinguish them from different spectral components obtained hereinbelow.
By spectral components, it will be understood by one of ordinary skill in the art that each spectral component contains two elements. The two elements may include an amplitude and a phase. In this case, the amplitude is a real number and the phase may be an extra term added to the argument of a sine or cosine function. Alternatively, the two elements may be a cosine coefficient and a sine coefficient. In this case, the cosine and sine terms may be written without the addition of a phase term. Another possibility is for the two elements to be real and imaginary parts of a complex number. Other ways of representing spectral components are also possible.
If the first spectral components Fk are written as complex values, they may be converted into cosine and sine coefficients, C′k and S′k, respectively, by taking real and imaginary parts:
C′
k
=Re(Fk), (3)
S′
k
=Im(Fk). (4)
Since Fk is an array of values, each of C′k, S′k is also an array of values. In general, it is not necessary to obtain the entire set of N/2 values for C′k and S′k. Instead, we may select the desired number M of first spectral components. The method for selecting an optimum number of first spectral components M is discussed hereinbelow.
The cosine and sine coefficients of Eqs. (3)-(4) are first spectral components. They represent the spectrum of the difference in readings between the measure and reference read heads. Step 740 is to calculate second spectral components, which represent the spectrum of errors for the overall encoder system as seen by each read head k. The errors of the overall encoder system are partly due to imperfections in the encoder disk and partly due to imperfections in the mounting of the encoder disk (or other patterned structure) in relation to the read heads. In the method described herein, the read heads are assumed to be identical and not to contribute to the error. The limits of validity of this assumption are discussed hereinbelow.
It can be shown that, for identical read heads, the first spectral components are related to second spectral coefficients Skj, Ckj by
S
kj
=[−S′
kj
+C′
kj cot(jβk/2)]/2, (5)
C
kj
=−[C′
kj
+S′
kj cot(jβk/2)]/2. (6)
Here k={1, . . . , m} is the read head index and j is the mode index. The function cot is the cotangent and βk is defined as the angular position of measure read head k relative to the reference read head 130. The values of βk for each k={1, . . . , m} may be initially selected based on nominal values for the positions of the read heads, obtained for example from mechanical drawings. The integer j, which represents the order of the spectral component, has a value between 1 and M, where M≦N/2 is the desired number of spectral components. The values βk are called the second angles.
The number of spectral components M in Eqs. (3)-(6) is at least one. To understand this, refer to
The Eqs. (5) and (6) can be rewritten in a variety of ways to obtain the second spectral components, which are the spectral components for the overall encoder system as seen by read head k. For example, Eqs. (5), (6) could be written to give amplitude and phase values for each spectral component rather than a cosine coefficient and a sine coefficient.
Step 750 is to record the second spectral components. The second spectral components may be stored, for example, in computer memory, or they may be stored on paper or another medium. There are two ways that the second spectral components can be used. They can be used directly in a formula to correct the overall encoder reading based on the present reading of the m read heads. Alternatively, they may be used to construct an error map, whose corrections can be applied by interpolating the read head readings relative to the map. These two ways of using the second spectral components are now discussed.
Consider first the case in which the read heads each read a third angle γ, which is a specific value of the first angle—in other words, a specific angle of rotation of the patterned element relative to the read heads. The error Ek of the kth read head, evaluated at the position of the pth read head, for the third angle γ is calculated using the results of Eqs. (5) and (6):
E
k(γ+βp)=Σj[Skj sin(j(γ+βp))+Ckj cos(j(γ+βp))], k=1, . . . , m, p=1, . . . , m. (7)
This error is referred to as the first error. The summation is carried out over the selected j, of which there are M values. However, the j values do not necessarily start with j=1. For example, for an encoder with three read heads, the number M might be selected as six, with the specific values of j selected to be j=3, 6, 9, 12, 15, 18. The read heads will read slightly different values as a result of read-head errors. For a system having three measure read heads, as shown in
The first errors as seen by the different read heads would ideally be identical but actually differ slightly. Accuracy can be improved by averaging the first errors over the measure read heads:
E
avg(γ+βp)=(1/m)(E1(γ+βp)+E2(γ+βp)+ . . . +Em(γ+βp)), p=1, . . . , m. (8)
The quantity Eavg is also considered a type of first error. Examples of first average quantities taken over a range of angles are shown in
The term averaging as used in this document refers not only to a simple “mean” but to any kind of operation that produces a smoothing action. Such an operation might include, for example, low-pass filtering, rejection of outliers, or other mathematical operations. Although Eq. (8) and other equations below are included in the preferred embodiment described herein, it will be understood by one of ordinary skill in the art that other averaging methods are possible.
The first error, calculated in Eq. (8), is associated with the encoder disk as it is mounted on the structure. In an actual encoder of the sort discussed herein, the measure read heads are symmetrically spaced, which results in significant cancellation of errors, as shown in the following equation:
εavg(γ)=(1/m)(Eavg(γ+β1)+Eavg(γ+β2)+ . . . +Eavg(γ+βm)). (9)
This error is called the second error.
The correction value of Eq. (12) was obtained by putting spectral components into Eq. (7). An alternative approach is to calculate correction factors for a variety of angles and then to put these into a table (map) that can be used with an interpolation method to obtain the correction for a particular measured angle. In this case, the first error Eq. (7) would be written in terms of a collection of first angles:
E
k(δi+βp)=Σj[Skj sin(j(δi+βp))+Ckj cos(j(δi+βp))], k=1, . . . , m, p=1, . . . , m. (10)
The first errors as seen by the different read heads would ideally be identical but actually differ slightly. Accuracy can be improved by averaging the first errors:
E
avg(δi+βp)=(1/m)(E1(δi+βp)+E2(δi+βp)+ . . . +Em(δi+βp)), i=1, 2, . . . , N. (11)
For this case, the second error of Eq. (12) is revised as
εavg(δi)=(1/m)(Eavg(αi+β1)+Eavg(δi+β2)+ . . . +Eavg(δi+βm)). (12)
The error values εavg(δi) may be put into a table as a function of δi. Here δi may represent any angle whatsoever and is not necessarily restricted to the first angles; that is, those angles measured to find the arrays of difference values.
The second angles βk may estimated based on mechanical drawings. They may be found more accurately by performing an optimization procedure. To do this, the residual errors are calculated:
R
ki
=E
k(αi)−Eavg(αi). (13)
Residual errors are used to compute the merit function Q of Eq. (9),
Q(β1,β2,β3)=Σi=1 . . . NΣkRki2, (14)
and then to minimize the merit function in an optimization routine to find the best-fit angles β1, β2, . . . , βm.
For a system having three measure read heads, as shown in
The basic assumption behind the mathematical method described here and depicted in the flow chart of
The mathematical treatment represented by the flow chart in
By observing the differences in the readings of the three measure read heads relative to the reference read head, it is possible to detect problems in particular read heads or in the placement of the read heads on mounting plate 62. If these differences are detected at the factory, the read heads may be checked for alignment, or one of the read heads may be replaced. If these differences are detected in field operation, it may indicate that one of the read heads has moved and may suggest that the encoder assembly needs to be recompensated or repaired.
The encoder assembly described above contains one asymmetrically placed reference read head and a plurality of symmetrically placed measure read heads. One might ask why it is necessary for the reference read head to be placed asymmetrically. Why is it not possible to simply compare the symmetrically placed read heads to one another? The answer can be seen in Eqs. 5 and 6. Each equation contains the term cot(jβk/2), where βk is the angle of the measure encoder relative to the reference encoder and j is an integer between 1 and N, where N is the number of comparison angles. If there are m symmetrically placed read heads, then the angular spacing between read heads is 2 it/m radians, and the spacing between any two read heads is 2πq/m radians, where q is another integer. If we use one of symmetrically placed read heads as the reference read head, then hk=2πq/m, and the argument of the cotangent function is jπq/m. The cotangent function goes to plus or minus infinity whenever its argument goes to πp/2, where p is an odd integer. This happens whenever jπq/m=πp/2, which is when j=0.5 m p/q. For symmetrically spaced read heads, there will in general be many values of j for which the cotangent argument goes to infinity.
By carefully selecting the position of an asymmetrically placed reference read head, this problem can be avoided.
A summary is now given for the embodiment described hereinabove. With a traditional mapping method, an external encoder is placed on a shaft and the readings of that encoder are compared to an encoder under test, also located on the shaft. This mapping method can improve the accuracy of an encoder but may introduce errors, as is apparent in
In another embodiment, the method described hereinabove is supplemented by values obtained using an external reference encoder—that is, a reference encoder attached to the end of a shaft that also holds the encoder under test. In some cases, this may be desirable because there is some maximum number of spectral components that can be obtained using the mathematical method of
In deciding how many spectral components to include from the external map, it is a good idea to look at the amount of noise in the external map. An idea of the amount of noise can be obtained by looking at the size of the spectral components that are multiples of three compared to the other components, which should be nearly zero. In this case, noise is reasonable to order 36, but it may not be a good idea to extend the spectral components form the external map much higher than this for the particular example considered here.
In evaluating the procedure described above, it is worthwhile to evaluate the potential errors. Errors may be caused by the following: (1) the read heads do not read exactly the same values for equivalent positions of the encoder disk; (2) the mathematical method cannot extract more than a certain number of spectral components because the cotangent factor gets too large; (3) there is a slight error in the calculated angular positions of the read heads. In addition, if additional components are extracted from an external map to supplement the spectral components from the self-compensation procedure, there will be noise associated with these.
For the errors of types (1) and (2) above, we can see from
In summary, the methods described hereinabove involves a placement of read heads that enable a mathematical procedure to more accurately compensate encoder errors than would be possible using traditional encoder mapping methods. In most cases, the procedure is carried out without the need of the external mapping procedure, thereby saving time and money. In addition, because the mapping procedure can be carried out in the field, it can be applied quickly (in less than a minute) whenever it is needed.
The self compensation procedure is a great advantage in overcoming increased errors that occur with changes in environmental conditions and especially temperature. Changes in temperature are known to produce changes in the encoder map. The encoder self-compensation procedure can be run in less than a minute. Consequently, it can be performed whenever temperature has changed significantly, thereby providing a high accuracy result at all temperatures.
The encoder design and compensation procedure also have advantages for detecting problems in manufacturing or in the field. For example, if the read heads are not seated properly or if one of the read heads is defective, that will show up in a comparison of the readings of the three read heads, as in
As mentioned hereinabove, an important consideration in at least two or three symmetrically spaced read heads, in addition to an asymmetrical reference read head, is illustrated in
The apparatus and method described herein may be advantageously used with a variety of devices. In the metrology field, an angular encoder having the properties described may be usefully employed in laser trackers, laser scanners, total stations, articulated arms, rotary stages, indexing tables, and other devices that make require high accuracy angular measurements. In the manufacturing field, an angular encoder having the properties described may be usefully employed in lathes, milling machines, robot mechanisms, and indexing heads. In the scientific and defense fields, an angular encoder having the properties described hereinabove may be usefully employed in telescope pointing systems, gimbal pointing structures, and the like. There are many other applications to which this technology may be usefully directed.
In the discussion above, examples have been given in which a Fourier transform (for example, a discrete Fourier transform) is used to extract spectral components. It should be understood, however, that other methods (for example, best fit methods) may be used to find spectral components. In general, the term Fourier component should be interpreted to mean a spectral component obtained by whatever means.
While preferred embodiments have been shown and described, various modifications and substitutions may be made thereto without departing from the spirit and scope of the invention. Accordingly, it is to be understood that the present invention has been described by way of illustrations and not limitation.
The presently disclosed embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims, rather than the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein.
Number | Date | Country | |
---|---|---|---|
61345198 | May 2010 | US |