Through MATLAB simulation, the uniqueness of the helical gear side profile shape is verified, the helical gear rotation direction is obtained by counting the number of structural elements, and the helical gear side edge is extracted by using Canny operator combined with homomorphic filtering; Then the improved hit miss transformation algorithm is used to screen the edges, and the edges of the tooth lines are obtained; Finally, the spiral angle is obtained by curve fitting.

The results show that:
(1) the measurement system of the proposed algorithm combines with the on-line measurement system of the helical gear end face, and is improved on the basis of it. It can measure the helical angle and direction of the helical gear while measuring the number of teeth, the diameter of the addendum circle, the diameter of the graduation circle and other parameters of the helical gear, which is suitable for the industrial production environment;
(2) compared with previous studies, the method proposed in this paper has higher detection accuracy, faster detection speed, and the measurement accuracy is close to the universal angle ruler method. The proposed image processing algorithm can effectively improve the adverse effects of illumination and tooth surface defects on helical gear edge extraction. Moreover, most of the previous studies can not achieve online measurement, but this method can achieve online measurement better;
(3) the method in this paper can not completely replace the traditional contact measurement method in accuracy, but it has great advantages over the traditional method in speed, and can be applied to the preliminary accuracy measurement and automatic sorting in the manufacturing and assembly process of helical gears.
In the follow-up research, we plan to reduce the dependence of the edge extraction algorithm on the light source, and strive to achieve a good edge extraction effect under a single light source; Optimize the fitting algorithm to reduce the influence of outliers; Use C language to rewrite the program or rewrite the loop into the form of matrix operation to improve the running speed.