The grating displacement sensor utilizes the Moir e fringe phenomenon of the measuring grating for displacement measurement. It mainly consists of components such as a light source, a scale grating, an indicator grating, and a photoelectric device. The photoelectric device receives the Moir é fringe intensity signal and processes it through a circuit to obtain the relative displacement of the two gratings. The measurement range is 0.001~10m; The measurement accuracy reaches 0.2~1 μ m/m; The advantages are high measurement accuracy, large range, fast response, digital output, easy implementation of digital measurement and automatic control, high anti-interference ability, and the ability to achieve dynamic measurement; The disadvantages are high environmental requirements, high costs, and the risk of measurement errors when the expansion coefficient of the object being measured is not consistent.