The optical encoders detected movement by "quadrature". Each encoder had a wheel with stripes which would interrupt the light passing between an LED and a light-detecting photodiode, producing electrical pulses with mouse movement. Both the X and the Y encoders were turned by frictional contact with the mouse ball. Two pairs of emitters and detectors were used on each encoder. A first set of pulses is enough to detect the rate of rotation without indicating the direction of rotation, and a second set of synchronized but 90° out of phase pulses provides the direction of rotation. Therefore, two emitter-detector pairs were used for X and Y each.