With the development of industrial automation and intelligence in China,machine vision technology and industrial robots have become a hot topic in research.Machine vision technology has the advantages of non-contact,high sensitivity and high adaptability.It can meet the production needs of different industrial environments.Monocular vision has the advantages of low cost,good stability,simple operation and low power consumption,so it is widely used in defect detection,target recognition,visual guidance,mechanical assembly and so on.This paper is based on the research background that the robot embeds the plastic diaphragm into the mold through visual positioning in the plastic diaphragm injection molding project,and the target recognition and localization of industrial robots are realized by using monocular vision technology and image processing algorithm.Its main research contents are as follows:Firstly,based on the design overview of plastic diaphragm injection molding project,the overall structure of robot target recognition and positioning system is designed.Then,according to the actual needs of the project,it selects the hardware such as robot,camera,lens and light source,and introduces the software such as image processing,data communication and computer programming.Secondly,image processing,target recognition and location algorithms are studied.The principles of camera calibration and hand-eye system calibration are studied.Python is used to calibrate the camera by invoking the Open CV library,using Zhang Zhengyou’s calibration method,by which the internal and external parameters of the camera and distortion coefficients are obtained.According to the project requirements,the hand eye system of the robot is selected and calibrated,and the accuracy is verified.The experimental results show that the calibration accuracy error is within 0.1mm.Aiming at the influence of illumination and noise on the image in the environment,the image processing algorithm is studied.Combined with gray correction and image filtering,an improved Canny edge detection algorithm is proposed.Compared with the traditional Canny algorithm,it retains the edge information of the image on the basis of filtering noise.The template matching method is used for target recognition.According to the advantages of Harris corner detection algorithm in feature extraction method,the SIFT algorithm is improved to improve the accuracy and stability of matching.In order to make the robot insert the plastic film into the mold accurately,the contour of the image is obtained by morphological processing and edge detection algorithm,and then the centroid coordinates and deflection angle of the target object are obtained according to the minimum circumscribed rectangle of the contour.Finally,the overall scheme implementation and system experiment.It realizes the design of human-machine interface,programming control of robot grasping and placement,data communication and program packaging.According to the experimental results of the system,the target recognition can reach 99.7%,and the error of placing plastic sheets by the robot is always kept within 0.1mm,which meets the needs of industrial production. |