# Quadrature Incremental Encoder A&B phase

It’s been two days that I’m searching to understand how an incremental encoder’s precision is quadratured.

I found out that we must be counting the state changes of the two channels A and B,

where A is the signal produced by a photodiode that is lighted by a LED in a square waveform, due to the alternances of opaque and hollow parts of the rotating disque,

and B is the same signal as A but out of phase with 90 degrees, (as far as I comprehended, this shouldn’t mean that receiving photodiodes should be at an angle of 90degrees) it means that between A and B there is a quarter period of the wave spoken about earlier.

How could be this attained ? How can we separate photodiodes A and B in a such way that we have a quarter period of phase, knowing that the frequency of the rotating disque could vary and hence this phase difference between A and B will change too.

Another question, would the speed (frequency of lights) have an impact on the number of bits needed to save the elapsed distance, knowing that the distance is the same at each speed?

• The "phase" is not a "distance", but a "distance" relative to the period duration. Apr 2 '19 at 18:17
• I rephrased it to sound clearer. Apr 2 '19 at 18:21
• hence this phase difference between A and B will change too - So no, it won't. Apr 2 '19 at 18:22
• I can’t see how it doesn’t change. Do we set it from the beginning of the manufacturing to have a quadrature phase? How could this be achievable Apr 2 '19 at 18:24
• Think that your encoder is "open" half of the revolution and closed half of it. So each diode will give 1 half of the period and 0 half of it. If we place these with 90 degree difference, one of these will always give 1 quarter period before the other one. Apr 2 '19 at 18:28

You can read about the encoder basics on the net, plenty of information.

As you can see on the picture, the A and B slots are shifted. No matter where you place the sensor A and B the signals will be unaffected, as long they are at exact distance of N slots.

A precision encoder is somehow different in construction. It may have tens of thousands increments. The physical size of each slot is much smaller than size of photo detector, so a trick is needed. This trick is called a Moire pattern.

The light from LED goes through glass rotor disc with slots, then it passes through a fringe before reaching the photo detector. On four pictures you can see a movement of a single slot. See the light and dark areas shifting. The A and B photo detectors are placed where this minima and maxima occurs, the signals are sinewaves that are passed trough schmitt triggers to get quadrature signals.

• Love the more comprehensive view offered here. +1. In mice, I've also seen cheaper arrangements, commonly, with a pair of offset LED-pairs used to "get the effect" from a single set of slots.
– jonk
Apr 2 '19 at 21:13
• Wow that’s way beyond what i neede! Nice info 👍🏻 Apr 2 '19 at 21:21