Inspection method of inclination of an IC
This is a continuation of application Ser. No. 08/405,405, filed on Mar. 15, 1995, which was abandoned upon the filing hereof, which is a continuation of application Ser. No. 08/082,421 filed Jun. 28, 1993 now abandoned. 
    
    
     FIELD OF THE INVENTION 
     The present invention relates to a method of measuring the inclination of an IC to fix its position for mounting on a circuit board. 
     BACKGROUND OF THE INVENTION 
     To mount an integrated circuit (&#34;IC &#34;) on a predetermined position on a circuit board, it is necessary to set an exact position of the IC. In order to measure the exact position of the IC, it is necessary to locate the center of the IC and measure its angle of inclination. In the case extracting information regarding the center of the IC and its angle of the inclination using image processing methods, the extraction process is applied to a binarized image in order to make the processing speed high. However, the binarized image is easily damaged by a change in the degree of brightness of lights illuminating the IC, and such methods have trouble measuring exact position . 
     SUMMARY OF THE INVENTION 
     The present invention solves the above conventional problems, and it has a purpose to provide an inspection method of inclination of an IC in order to fix a position of IC speedily and precisely without the image information of binarized images. 
     An inspection method of inclination of an IC according to this invention defines a inspection area including open ends of IC pins on each side of IC package, extracts longitudinal edges and open ends of each IC pin from a density projection of each checking area, calculates a representative point of each checking area on a line along the open ends and calculates an inclination of an IC according to a difference of coordinates of a representative point of the checking area positioning on the opposite side. 
    
    
     BRIEF DESCRIPTION OF DRAWINGS 
     FIG. 1 is a flow chart showing an embodiment of the present invention. 
     FIG. 2 is a conceptual diagram showing a setting of a checking area. 
     FIG. 3 is a conceptual diagram showing a density projection, a primary differential and each pin of a checking area. 
     FIG. 4 is a diagram for explaining a position of an edge of a subpixel unit. 
     FIG. 5 is a conceptual diagram showing a center of an IC. 
    
    
     PREFERRED EMBODIMENT OF THE PRESENT INVENTION 
     Hereinafter, an embodiment of method of measuring the inclination of an IC of the present invention is described with reference to the attached drawings. FIG. 1 is a flow chart showing an embodiment of the present invention. Reference will be made to other drawings as they relate to steps of FIG. 1. 
     First, an image of an IC with pins on 4 sides of QFT type etc. is taken on step 1. The darkness of the background differs from that of the pins. 
     In step 2, checking regions are set around predetermined positions in the image of the IC. Checking regions are designated as CR1 to CR4 (FIG. 2). One checking region is positioned on each side of the IC and includes open ends of the IC pins. 
     Density projections are generated along directions of the X-axis and the Y-axis of each checking regions in step 3. FIG. 3 shows a density projection of a checking regions CR1 as an example. The density projection is calculated by integrating gray level values (darkness) of an image. The density projection has highly reliable information compared with a binarized image which has lost information during information compression (i.e., lost during binarization). 
     In step 4, the primary differential (rate of change of the density projection) is determined . FIG. 3 shows the differential as a thick line. As the result, each longitudinal edge of the IC pins is emphasized as a peak in the differential along the direction of the X-axis. A line along the open ends of the IC pins is emphasized as a peak in the differential along the direction of the Y-axis. 
     In step 5, a position of an edge is measured by detecting a peak in the differential using a subpixel unit, where a coordinate exists between subpixels. FIG. 4 shows a part of the edge by a pixel unit of an image in a direction of Y-axis. It is usual that there are uneven in an image as FIG. 4. In order to calculate more accurate position of the edge, that is Y-coordinates from such an image data, subpixels must be considered. As a result, it is possible to obtain a more exact and precise Y-coordinates (FIG. 4 shows a line of X-axis of the coordinates.) than the method obtaining coordinates by a pixel unit with the maximum value of a primary differential. The coordinates of a direction of X-axis is also calculated by a subpixel unit. 
     In order to extract a part of an edge, the predetermined value calculated in experience is set as a threshold value, and a location is accepted as an edge when the primary differential value is over the threshold value. In order to standardize the threshold value, it is better to perform normalization after determining the primary differential. 
     In step 6, a point corresponding to each IC pin is selected. The point is illustrated in FIG. 3 at each intersection of a broken line (showing a central position of longitudinal edges of each pin) and a thick line (showing a median position of open edges of each pin). The cross points are labeled as P1 to Pn in the figure. 
     In step 7 , a mean location of X-coordinates of points from P1 to Pn is calculated and the mean location is selected as a representative point RP1 for checking region CR1. 
     A representative point is selected in all checking regions as described above. They are shown by RP1 to RP4 in FIG. 5. 
     In step 8, lines connecting representative points in opposite sides of the IC are calculated and defined as L1 and L2. Then, a crossing point of the lines is selected as a central point of the IC. An inclined angle can be calculated according to ΔYΔX when a difference of X-coordinates of RP1 and RP3 is defined as ΔX and a difference of a Y-coordinates of RP2 and RP4 is defined as ΔY. 
     It is possible to calculate an inclined angle quickly by the present invention because the checking regions are small and the necessary time for the processings is short. 
     The IC is rotated by the amount of the measured inclined angle and its inclination is thereby corrected . 
     The present invention mentioned above can exactly measure the inclination of an IC precisely in high speed without the information of a binarized image, and correct the inclination after the measurement.