Measuring Angular Velocity (Encoder)
- Updated2025-12-03
- 1 minute(s) read
On devices that support it, you can use the counters to perform velocity measurements with encoders. An encoder is a device that converts linear or rotary displacement into digital or pulse signals. Angular velocity can be measured with X1, X2, and X4 quadrature encoders. You can choose to do either single-point (on-demand) velocity measurement or buffered (sample clock) velocity measurement.
The counter measures the velocity of the encoder using the A and B signals, which are offset by 90°. The velocity is calculated using the A and B input signal transitions and the amount of time that elapses between the changes in the encoder count value.
The decoding type attribute/property specifies how to count and interpret the pulses the encoder generates on signal A and signal B.