[1]
[1]
A quadrature/incremental encoder is
quadrature: 90°/right angle separation or math process to calculate area
[2] Timers can be used to interface with quadrature encoders and derive crucial movement information (speed, direction, position) at anytime. Decoding these quadrature impulses involves feeding these signals into microcontrollers to measure signal info (period, frequency). Some devices use a special timer module specifically for interfacing with quadrature encoders. Depending on the device, such modules could be called quadrature encoder pulses/quadrature encoder interfaces. Other devices may also use a generic timer module to interface with incremental encoders. These quadrature encoders are used in various applications, such as sensor-based motor control and robotics.
[2] Decoding signals into relevant informations The encoder uses a timer module attached to a position counter.
3 quadrature signals, Channel A and B signals, and the quadrature index signal, serve as inputs of the timer module, which must be configured in capture mode (records the exact timestamp a signal occuring) to capture rising, falling edges. (Fig. 4)
The timer modules decodes the quadrature signals into waveforms into directions and clock signals that are fed into the position counter keeping track of the encoder's incremental position (Fig. 5).
[2]
[2] Fig. 4
[2] Fig. 5
[2] The quadrature encoder index signal (or zero position/quadrature point) can have a quadrature index, an additional row with a single fixed slot location, denoting the disk's zero position (Fig. 3), which has the following purposes:
when to start monitoring the position
signals to the device for each full rotation
aids in position verification in case of glitch signals
[2]
[2] Fig. 3
An optical quadrature encoder is made of a disk with a pattern of opaque/transparent slots along its periphery. The number of transparent slots on the encoder is known as the encoder resolution.
[2]
[2] The more slots an encoder it has, the more precise the encoder position.
[2]
[2] Turning the encoder to its side, an optical quadrature encoder also consists of a light source on one of its side and a pair of photosensors on the other side. The sensors are responsible for producing the encoded pulse signals and are offset by 90 electrical degrees from each other with respect to the light sensor, causing a phase difference in the generated pulse signals. Physically, both sensors are physically placed slightly apart. As the slotted disk rotates between the light and the sensors, each sensor outputs a high signal if light passes through a transparent slot and a low signal when blocked by an opaque slot.
Inside the encoder, a disk features a series of alternating transparent (open) and opaque (blocked) slots along its perimeter.
Light Source & Sensors: A light source (like an LED) shines onto one side of the disk, while two photodetectors (Sensors A and B) are placed on the opposite side to read the light passing through the slots.
[2]
The light source can emit light through the encoder disk and is obstructed by the disk' opaque parts.
obstructed: blocked, hindered for movement/sight/progress stopped or resisted
[2]
[2] Like regular encoder disks, as the encoder's shaft rotates, the photosensors detect a series of darkness and light, consisting of low and high signals, a waveform waveform pattern known as the quadrature signals, which encode the rotational the quadrature encoder's info.
Quadrature signals consist of a pair of channels, E.g., channel A and B are offset by 90°, which refer to the digital electrical signals generated by a pair of internal photosensors.
[2] Depending on the device, the channels may also be referred to as phase (QEP) inputs. The frequency and relative phase of these waveforms with respect to each other can be decoded into position, direction, and speed information when input into a microcontroller.
[2] As the encoder spins CW at a constant velocity, channel A is leading channel B.
If the encoder stops, the quadrature signals pause at their current state.
[2] The encoder spinning in CW.
[2] As the encoder turns CCW, Channel B is now leading channel A.
[2] The encoder spinning in CCW.
Channel A "leads" Channel B if its voltage waveform transitions to a high state prior Channel B does as the disk turns in a direction: