An encoder is a sensor which turns a position into an electronic signal.
There are two forms: The position may be measured as either linear or angular position