Recommended · for some experience
Rotary encoder - sensor arrangement
Why people recommend it
Recommended as a clear account of how rotary encoders work, with enough detail to build one yourself; the ideas carry over to linear encoders and other boards.
Watch for: Uses Arduino, though the concept applies elsewhere
In their words
And here is a video series on how to make DIY encoder whith explanations on how it works -
AlStorm Prime on electronics.stackexchange.com, Jul 2018. CC BY-SA.