Encoder is a device that converts angular displacement or linear displacement into electrical signals. The former becomes a code wheel and the latter is called a yardstick. Encoders can be divided into contact type and non-contact type according to the read mode.