encoder converts the angular position to digital code