摘要 |
A photoelectric encoder includes: a scale having a grating formed with a predetermined period Ps; and a detector head being movable relative to the scale and including a light source and a light receiving unit. In a configuration where light receiving elements in the light receiving unit output N-points light and dark signals (N is an integer of 3 or more), and where phases of the N-points light and dark signals are detected by a least-squares method to fit a sinusoidal function with fixed period to N-points digital signals digitized from the N-points light and dark signals, an N-points light and dark signal period P is set at an integral multiple of a data-point interval w of the N-points digital signals, and an overall length M of the light receiving elements is set at an integral multiple of the N-points light and dark signal period P. Thereby, position detecting errors occurring due to a stain of the scale and/or a defect in the grating can be reduced by simple computing.
|