Method and system for detecting coplanarity of multiple support legs of workpiece

By combining a line laser rangefinder and a line array camera, the peripheral side and internal support legs of the USB socket are scanned and the reference distance difference is calculated, which solves the problem of insufficient coplanarity detection accuracy of the USB socket support legs and achieves higher detection accuracy.

CN116124049BActive Publication Date: 2025-09-30DONGGUAN WANHONG ELECTRONICS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310078090.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-17
Publication Date
2025-09-30
Estimated Expiration
2043-01-17

AI Technical Summary

Technical Problem

In the prior art, the coplanarity detection accuracy of the support legs of the USB socket is not high, especially the inner support legs cannot be scanned by visual inspection equipment, resulting in insufficient detection accuracy.

Method used

A method combining a line laser rangefinder and a line array camera is adopted. The line array camera scans the periphery of the workpiece to generate peripheral contour information. The line laser rangefinder scans the coordinates of the internal support feet, calculates the distance difference between each support foot and the reference plane, and virtualizes the reference plane to determine the coplanarity.

Benefits of technology

The detection accuracy of the coplanarity of the USB socket support legs is improved, the use of transparent glass is avoided, and the accuracy of the detection is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116124049B_ABST
    Figure CN116124049B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and system for detecting the coplanarity of multiple supporting legs of a workpiece. The workpiece includes a base, a plurality of first supporting legs are arranged at the peripheral edge of the base, and a plurality of second supporting legs are arranged on the inner side of the base. The coplanarity detection method includes: providing a controller, a line laser rangefinder and a line array camera; generating peripheral contour information of the workpiece by the line array camera; based on the peripheral contour information, the controller extracts first coordinates of one end of the plurality of first supporting legs away from the base and generates a reference plane; obtains second coordinates of one end of the plurality of second supporting legs away from the base by the line laser rangefinder; respectively calculates the reference distance between each first coordinate and the second coordinate and the reference plane; and calculates the difference between each reference distance. Through the above method, the coplanarity between each supporting leg on the workpiece can be effectively detected, and a reference plane can be virtualized based on the detection data of the line array camera, thereby effectively improving the detection accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of coplanarity detection, and in particular to a method and system for detecting the coplanarity of multiple support legs of a workpiece. Background Art

[0002] Based on the needs of assembly, a plurality of supporting feet are provided on the shell of the USB socket. These supporting feet include outer supporting feet located on the side walls around the shell and inner supporting feet located on the bottom wall inside the shell. During assembly, the outer supporting feet and the inner supporting feet both protrude toward the circuit board. The circuit board is provided with positioning holes that are compatible with the outer supporting feet and the inner supporting feet to achieve the positioning and installation of the USB socket. During the assembly process of the USB socket, if the heights of the various supporting feet are different, so that the ends of the various supporting feet away from the base of the USB socket are not coplanar, or the coplanarity does not meet the requirements, it will cause the USB socket to be installed tilted, or cause some supporting feet to be in a virtual connection state, and the installation stability will not meet the requirements. Therefore, the industry needs to test the coplanarity of the various supporting feet on the USB socket to ensure that the bottom ends of the various supporting feet are basically located in the same plane.

[0003] Currently, when testing the coplanarity of the support legs on a USB socket, because the inner support legs are located inside the housing, visual inspection equipment cannot scan the inner support legs from the outside. Therefore, laser scanning is generally used for inspection. In addition, to measure the distance between the ends of each support leg and a common reference surface, the USB socket under test must be placed on a piece of transparent glass, which serves as a reference surface during inspection. However, due to the refraction effect of the transparent glass on the laser, the coplanarity inspection accuracy is less than ideal. Summary of the Invention

[0004] The object of the present invention is to provide a method and system for detecting the coplanarity of multiple support legs of a workpiece, which can effectively improve the coplanarity detection accuracy.

[0005] To achieve the above-mentioned object, the present invention discloses a method for detecting the coplanarity of multiple support legs of a workpiece, wherein the workpiece includes a base, a plurality of first support legs are provided at the peripheral edge of the base, and a plurality of second support legs are provided on the inner side of the base, with the same protruding direction as the first support legs. The coplanarity detection method comprises:

[0006] Providing a controller and a line laser rangefinder and a line array camera connected to the controller, and calibrating the line laser rangefinder and the line array camera in the controller to associate the reference coordinate systems of the line laser rangefinder and the line array camera;

[0007] Scanning each side wall of the workpiece having the first supporting legs by the line array camera to generate peripheral contour information of the workpiece;

[0008] The controller extracts the coordinates of the ends of the plurality of first supporting legs away from the base based on the peripheral contour information to obtain first coordinates, and generates a reference plane corresponding to the ends of the plurality of first supporting legs away from the base;

[0009] Scanning the interior of the workpiece by the line laser rangefinder to obtain the coordinates of the ends of the plurality of second supporting legs away from the base to obtain second coordinates;

[0010] The controller calculates a reference distance between each of the first coordinate and the second coordinate and the reference plane according to a calibration relationship between the line laser rangefinder and the line array camera;

[0011] The difference between the reference distances is calculated.

[0012] Preferably, the method for generating the reference plane includes:

[0013] Extracting two pairs of the first coordinates from the peripheral contour information to serve as reference coordinates, wherein the two pairs of reference coordinates are located on two adjacent sides of the substrate;

[0014] generating two reference lines based on the two pairs of reference coordinates respectively;

[0015] The reference surface is generated based on the two reference lines.

[0016] Preferably, the two reference coordinates for generating the reference line are the two first coordinates farthest from the substrate.

[0017] Preferably, the workpiece is a USB connector.

[0018] The present invention also discloses a multi-support leg coplanarity detection system for a workpiece, wherein the workpiece includes a base, a plurality of first support legs are provided at the peripheral edge of the base, and a plurality of second support legs are provided on the inner side of the base with the same protruding direction as the first support legs. The coplanarity detection system includes a controller and a line laser rangefinder and a line array camera connected to the controller. The controller is provided with a calibration module, an image processing module, a first calculation module, and a second calculation module.

[0019] The calibration module is used to calibrate the line laser rangefinder and the line array camera to associate the reference coordinate systems of the line laser rangefinder and the line array camera;

[0020] The linear array camera is used to scan each side wall of the workpiece having the first supporting legs to generate peripheral contour information of the workpiece;

[0021] The image processing module is configured to process the peripheral contour information to extract first coordinates of ends of the plurality of first supporting legs away from the base, and generate a reference plane corresponding to the ends of the plurality of first supporting legs away from the base;

[0022] The line laser rangefinder is used to scan the interior of the workpiece to obtain second coordinates of one end of the plurality of second supporting legs away from the base;

[0023] The first calculation module is configured to calculate a reference distance between each of the first coordinate and the second coordinate and the reference plane according to a calibration relationship between the line laser rangefinder and the line array camera;

[0024] The second calculation module is used to calculate the difference between the reference distances.

[0025] Preferably, the image processing module includes a reference coordinate extraction module, a reference line generation module and a reference surface generation module, the reference coordinate extraction module is used to extract two pairs of the first coordinates from the peripheral contour information to be used as reference coordinates, and the two pairs of reference coordinates are respectively located on two adjacent sides of the substrate; the reference line generation module is used to generate two reference lines based on the two pairs of reference coordinates; the reference surface generation module is used to generate the reference surface based on the two reference lines.

[0026] Preferably, the two reference coordinates for generating the reference line are the two first coordinates farthest from the substrate.

[0027] Preferably, the workpiece is a USB connector.

[0028] The present invention also discloses a system for detecting the coplanarity of multiple support legs of a workpiece, which comprises:

[0029] one or more processors;

[0030] Memory;

[0031] and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the programs including instructions for executing the multi-support leg coplanarity detection method for a workpiece as described above.

[0032] The present invention also discloses a computer-readable storage medium, which includes a computer program. The computer program can be executed by a processor to implement the multi-support leg coplanarity detection method of a workpiece as described above.

[0033] Compared with the prior art, the above technical solution of the present invention detects the coplanarity of several first supporting feet and several second supporting feet on the workpiece by combining a laser-based line laser rangefinder and a vision-based line array camera. That is, the peripheral side of the workpiece is first scanned by the line array camera to obtain peripheral contour information, and then the controller generates first coordinates of several first supporting feet and a virtual reference plane based on the peripheral contour information. Then, the content of the workpiece is scanned by the line laser rangefinder to obtain the second coordinates of the second supporting feet. Then, the reference distance between each first coordinate and second coordinate and the reference plane is calculated. Finally, the coplanarity between each first supporting foot and second supporting foot on the current workpiece can be determined by calculating the difference between each reference distance. It can be seen that the above technical solution can effectively detect the coplanarity between each supporting foot on the workpiece, and does not require the configuration of a transparent glass piece. Instead, a reference plane is virtualized based on the detection data of the line array camera itself, thereby effectively improving the detection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Figure 1 Flowchart of a method for detecting the coplanarity of multiple supporting legs in an embodiment of the present invention.

[0035] Figure 2 FIG. 1 is a three-dimensional structural diagram of a USB socket in an embodiment of the present invention from one viewing angle.

[0036] Figure 3 This is a three-dimensional structural diagram of the USB socket in another perspective according to an embodiment of the present invention.

[0037] Figure 4 This is a schematic diagram of the principle structure of a multi-support leg coplanarity detection system in an embodiment of the present invention. DETAILED DESCRIPTION

[0038] In order to explain the technical content, structural features, achieved objectives and effects of the present invention in detail, the following is a detailed description in conjunction with the embodiments and the accompanying drawings.

[0039] This embodiment discloses a method for detecting the coplanarity of multiple support legs of a workpiece, which is used to detect the coplanarity of multiple support legs on a workpiece. Figure 2 and Figure 3In this embodiment, the workpiece is a USB socket U as an example (but not limited thereto). The USB socket U includes a base 1, on which a plurality of supporting legs are provided. Specifically, a plurality of first supporting legs U1 are provided at the peripheral edge of the base 1, and a plurality of second supporting legs U2 are provided on the inner side of the base 1, extending in the same direction as the first supporting legs U1. In this embodiment, the base 1 includes a bottom wall 13 and side walls located around the bottom wall 13. The side walls include a first side wall 10, a second side wall 11, and a third side wall 12 located between the first side wall 10 and the second side wall 11. The first side wall 10 and the second side wall 11 each have three first supporting legs U1, the third side wall 12 has a fourth first supporting leg U1, and the bottom wall 13 has nine second supporting legs U2.

[0040] Please refer to Figures 1 to 3 The coplanarity detection method in this embodiment includes the following steps:

[0041] S1: Provide a controller, a line laser rangefinder, and a line scan camera connected to the controller. Calibrate the line laser rangefinder and the line scan camera in the controller to associate their reference coordinate systems. The line laser rangefinder in this embodiment is preferably a Keyence line laser profiler.

[0042] S2: Scan each side wall having the first support leg U1 on the peripheral side of the USB socket U using a line scan camera, that is, scan the first side wall 10, the second side wall 11, and the third side wall 12 to generate peripheral contour information of the USB socket U;

[0043] S3: The controller uses image processing software to extract the coordinates of the ends of the plurality of first supporting legs U1 away from the base 1 based on the peripheral contour information to obtain first coordinates, and generates a reference plane corresponding to the ends of the plurality of first supporting legs U1 away from the base 1;

[0044] S4: Scanning the interior of the USB socket U, that is, scanning the bottom wall 13 of the USB socket U, by using a line laser rangefinder to obtain the coordinates of the ends of the second supporting legs U2 away from the base 1 to obtain second coordinates;

[0045] S5: The controller calculates a reference distance between each first coordinate and the second coordinate and the reference plane according to a calibration relationship between the line laser rangefinder and the line array camera;

[0046] S6: Calculate the difference between each reference distance. Specifically, if the difference between any two reference distances is greater than a preset value, it indicates that the coplanarity between the supporting legs on the current USB socket U does not meet the standard. Conversely, if the difference between all reference distances is not greater than the preset value, it indicates that the coplanarity between the supporting legs on the current USB socket U meets the standard. It should also be noted that the distance from the first coordinate used as the reference coordinate to the reference plane is zero.

[0047] Furthermore, the method for generating the reference plane includes:

[0048] Extracting two pairs of first coordinates from the peripheral contour information to serve as reference coordinates, the two pairs of reference coordinates being located on adjacent sides of the substrate 1 , for example, the two reference coordinates of one pair are derived from the two first coordinates on the first side wall 10 , and the two reference coordinates of the other pair are derived from the two first coordinates on the third side wall 12 ;

[0049] Based on the principle of two points forming a line, two reference lines are generated based on two pairs of reference coordinates;

[0050] Since the two reference lines are located on the adjacent two side walls, the two reference lines are not parallel. Therefore, based on the principle of two lines forming a surface, a reference surface is generated based on the two reference lines.

[0051] Furthermore, the two reference coordinates for generating the reference line are the two first coordinates farthest from the base 1 , so that the generated reference surface is equivalent to the supporting surface of the USB socket U.

[0052] In summary, the above-mentioned coplanarity detection method detects the coplanarity of several first supporting feet U1 and several second supporting feet U2 on the workpiece by combining a laser-based line laser rangefinder and a vision-based line array camera. That is, the peripheral side of the workpiece is first scanned by the line array camera to obtain peripheral contour information, and then the controller generates the first coordinates of several first supporting feet U1 and a virtual reference plane based on the peripheral contour information. The content of the workpiece is then scanned by the line laser rangefinder to obtain the second coordinates of the second supporting feet U2. Then, the reference distance between each first coordinate and second coordinate and the reference plane is calculated. Finally, the coplanarity between each first supporting foot U1 and second supporting foot U2 on the current workpiece can be determined by calculating the difference between each reference distance. The above-mentioned coplanarity detection method can not only effectively detect the coplanarity between each supporting foot on the workpiece, but also does not require the configuration of a transparent glass piece. Instead, a reference plane is virtualized based on the feedback of the line array camera, thereby effectively improving the detection accuracy.

[0053] In another preferred embodiment of the present invention, a system for detecting the coplanarity of multiple support legs of a workpiece is also disclosed. Figures 2 to 4The workpiece includes a base 1, a plurality of first supporting feet U1 are provided at the peripheral edge of the base 1, and a plurality of second supporting feet U2 with the same protruding direction as the first supporting feet U1 are provided on the inner side of the base 1. The coplanarity detection system includes a controller and a line laser rangefinder and a line array camera connected to the controller. The controller is provided with a calibration module, an image processing module, a first calculation module and a second calculation module.

[0054] The calibration module is used to calibrate the line laser rangefinder and the line array camera to associate the reference coordinate systems of the line laser rangefinder and the line array camera.

[0055] The line array camera is used to scan each side wall having the first supporting foot U1 on the peripheral side of the workpiece to generate peripheral contour information of the workpiece.

[0056] The image processing module is used to process the peripheral contour information to extract the first coordinates of the ends of the first supporting legs U1 away from the base 1 and generate a reference plane corresponding to the ends of the first supporting legs U1 away from the base 1.

[0057] The line laser rangefinder is used to scan the interior of the workpiece to obtain the second coordinates of the ends of the plurality of second supporting legs U2 away from the base 1 .

[0058] The first calculation module is used to calculate the reference distance between each first coordinate and the second coordinate and the reference plane according to the calibration relationship between the line laser rangefinder and the line array camera.

[0059] The second calculation module is used to calculate the difference between each reference distance.

[0060] Furthermore, the image processing module includes a reference coordinate extraction module, a reference line generation module and a reference surface generation module. The reference coordinate extraction module is used to extract two pairs of first coordinates from the peripheral contour information to be used as reference coordinates, and the two pairs of reference coordinates are respectively located on the adjacent two sides of the substrate 1; the reference line generation module is used to generate two reference lines based on the two pairs of reference coordinates; and the reference surface generation module is used to generate a reference surface based on the two reference lines.

[0061] Furthermore, the two reference coordinates for generating the reference line are the two first coordinates farthest from the substrate 1 .

[0062] The working principle and working mode of the multi-support leg coplanarity detection system in this embodiment are detailed in the multi-support leg coplanarity detection method in the above embodiment, and will not be repeated here.

[0063] The present invention also discloses another multi-support leg coplanarity detection system, which includes one or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the programs include instructions for executing the multi-support leg coplanarity detection method as described above. The processor can be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for executing relevant programs to implement the functions required to be executed by the modules in the multi-support leg coplanarity detection system of the embodiment of the present application, or to execute the multi-support leg coplanarity detection method of the method embodiment of the present application.

[0064] The present invention also discloses a computer-readable storage medium, which includes a computer program, and the computer program can be executed by a processor to complete the multi-support leg coplanarity detection method as described above. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media. The available medium can be a read-only memory (ROM), or a random access memory (RAM), or a magnetic medium, such as a floppy disk, a hard disk, a tape, a magnetic disk, or an optical medium, such as a digital versatile disc (DVD), or a semiconductor medium, such as a solid state disk (SSD).

[0065] The present application also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the above-described method for detecting coplanarity of multiple support legs.

[0066] The above disclosure is only a preferred embodiment of the present invention, which certainly cannot be used to limit the scope of rights of the present invention. Therefore, equivalent changes made according to the scope of the patent application of the present invention are still within the scope covered by the present invention.

Claims

1. A method for detecting the coplanarity of multiple support legs of a workpiece, characterized in that: The workpiece includes a base, a plurality of first supporting legs are provided at the peripheral edge of the base, and a plurality of second supporting legs are provided on the inner side of the base with the same protruding direction as the first supporting legs. The coplanarity detection method includes: Providing a controller and a line laser rangefinder and a line array camera connected to the controller, and calibrating the line laser rangefinder and the line array camera in the controller to associate the reference coordinate systems of the line laser rangefinder and the line array camera; Scanning each side wall of the workpiece having the first supporting legs by the line array camera to generate peripheral contour information of the workpiece; The controller extracts the coordinates of the ends of the plurality of first supporting legs away from the base based on the peripheral contour information to obtain first coordinates, and generates a reference plane corresponding to the ends of the plurality of first supporting legs away from the base; Scanning the interior of the workpiece by the line laser rangefinder to obtain the coordinates of the ends of the plurality of second supporting legs away from the base to obtain second coordinates; The controller calculates a reference distance between each of the first coordinate and the second coordinate and the reference plane according to a calibration relationship between the line laser rangefinder and the line array camera; The difference between the reference distances is calculated.

2. The method for detecting the coplanarity of multiple support legs of a workpiece according to claim 1, characterized in that: The method for generating the reference plane includes: Extracting two pairs of the first coordinates from the peripheral contour information to serve as reference coordinates, wherein the two pairs of reference coordinates are located on two adjacent sides of the substrate; generating two reference lines based on the two pairs of reference coordinates respectively; The reference plane is generated based on the two reference lines.

3. The method for detecting the coplanarity of multiple support legs of a workpiece according to claim 2, wherein: The two reference coordinates for generating the reference line are the two first coordinates farthest from the base.

4. The method for detecting the coplanarity of multiple support legs of a workpiece according to claim 1, wherein: The workpiece is a USB connector.

5. A system for detecting the coplanarity of multiple support legs of a workpiece, characterized in that: The workpiece includes a base, a plurality of first supporting legs are provided at the peripheral edge of the base, and a plurality of second supporting legs are provided on the inner side of the base, extending in the same direction as the first supporting legs. The coplanarity detection system includes a controller, a line laser rangefinder and a line array camera connected to the controller, and the controller is provided with a calibration module, an image processing module, a first computing module, and a second computing module. The calibration module is used to calibrate the line laser rangefinder and the line array camera to associate the reference coordinate systems of the line laser rangefinder and the line array camera; The linear array camera is used to scan each side wall of the workpiece having the first supporting legs to generate peripheral contour information of the workpiece; The image processing module is configured to process the peripheral contour information to extract first coordinates of ends of the plurality of first supporting legs away from the base, and generate a reference plane corresponding to the ends of the plurality of first supporting legs away from the base; The line laser rangefinder is used to scan the interior of the workpiece to obtain second coordinates of one end of the plurality of second supporting legs away from the base; The first calculation module is configured to calculate a reference distance between each of the first coordinate and the second coordinate and the reference plane according to a calibration relationship between the line laser rangefinder and the line array camera; The second calculation module is used to calculate the difference between the reference distances.

6. The multi-support leg coplanarity detection system for a workpiece according to claim 5, characterized in that: The image processing module includes a reference coordinate extraction module, a reference line generation module, and a reference surface generation module. The reference coordinate extraction module is used to extract two pairs of the first coordinates from the peripheral contour information to serve as reference coordinates. The two pairs of reference coordinates are respectively located on two adjacent sides of the substrate. The reference line generation module is used to generate two reference lines based on the two pairs of reference coordinates respectively; the reference plane generation module is used to generate the reference plane based on the two reference lines.

7. The multi-support leg coplanarity detection system for a workpiece according to claim 6, characterized in that: The two reference coordinates for generating the reference line are the two first coordinates farthest from the base.

8. The multi-support leg coplanarity detection system for a workpiece according to claim 5, characterized in that: The workpiece is a USB connector.

9. A system for detecting the coplanarity of multiple support legs of a workpiece, characterized in that: include: one or more processors; Memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the programs including instructions for executing the multi-support leg coplanarity detection method for a workpiece according to any one of claims 1 to 4.

10. A computer-readable storage medium, characterized in that The method comprises a computer program, which can be executed by a processor to implement the method for detecting the coplanarity of multiple support legs of a workpiece according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Stereo vision sensor integrates line array camera and area array camera and calibration method

    CN106289106A

  • Coplanarity detection method

    CN114894093A