| This thesis describes the hole-measuring system on spherical surface, mainly focus on structure of measuring software and the digital image processing theory used in measuring software as well as its realization with visual C++. More than two hundred holes (through holes and blind holes are included ,whose radius vary from 0.28 to 4)lie in the spherical work piece, and it is required to get the exact position of holes determined by the situation of center of hole which is measured by two spatial angles in sphere coordinate system with high precision and efficiency. The hole-measuring system is the special measuring instrument developed for solving such question.In hole-measuring software, we studied the methods of digital image partition for special work piece, including classical edge-find arithmetic such as Roberts, Sobel and threshold partition .The min point threshold partition and contour-trace are used to find edge of through hole, which avert the effect of machining texture on edge-find and have many merits such as simple arithmetic, high efficiency in edge-find and good robustness ; the glistening at the bottom of blind hole, more burrs than through hole at the top of blind hole and disfigurement of edge have badly effect on edge-find, but if we zoomin part of it and select part of edge manually .which increase the repetition ability of measuring, the measuring of blind hole no longer puzzle us ;if the radius of hole is larger than 4, firstly we get image of half of hole, secondly move instrument to get another half, then use two image to construct the image of the whole hole, and this method makes it possible to extend the scope of measuring without change of hardware. If it is equipped with large magnifying lens, more high precision could be produced, which would have more applications in future. Controlling of CG200 image collecting chip is the main task of image collecting module. The auto-measuring of work piece is executed according to a series of measuring sequence.The software of measuring system is programmed by VC++, and it can complete movement control, acquire the reading of raster, control of image card and ring lamp. It also has the function for experiment image processing, and integrates the way of edge detection for through holes and blind holes. The hole-measuring software worked with hardware largely improves efficiency of measuring in term of proper measurement flow; it achieves semi-auto measurement of spatial angle for complex work piece and similar work piece of same kind. This software has good interaction, and it is easy for maintenance, using and upgrading. |