This rotation sensor or incremental encoder (unlike potentiometer) has no limit for number of counting. It can also detect clockwise and counter clockwise rotation and that’s why it has 2 pins (SIA and SIB) for detecting rotation.
Basically, it translates the rotary motion into a sequence of pulse signals. By comparing the square wave generated from each of the two pins you can determine the direction of rotation (as shown in Figure below) and by counting the number of pulses you can determine both the rotation angle and the RPM of the rotating shaft. A reset button is provided to reset the counter to zero state when needed to restart counting.
Features
PIN Definition