Method, device, storage medium and terminal for constructing robot workpiece coordinate system

By setting positioning holes on the workpiece and using detection probes to collect data and calculate the theoretical circle center coordinates, the problem of inaccurate workpiece coordinate systems is solved and the processing accuracy and efficiency of industrial robots are improved.

CN114670179BActive Publication Date: 2024-08-23JIANGXI RUIXIANG INTELLIGENT EQUIP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210255553.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-16
Publication Date
2024-08-23
Estimated Expiration
2042-03-16

AI Technical Summary

Technical Problem

When establishing a workpiece coordinate system for industrial robots, it is difficult to accurately collect coordinate data of feature points of the workpiece with the existing technology, resulting in an inaccurate coordinate system and affecting the X/Y/Z axis manipulation accuracy of the robot on the workpiece.

Method used

By setting positioning holes on the workpiece, using detection probes to collect touch detection data, calculating the theoretical center coordinates of the positioning holes, and establishing the workpiece coordinate system based on these coordinates, optimizing the acquisition method and using Renishaw probes to improve accuracy.

Benefits of technology

The rapid and accurate construction of the workpiece coordinate system is achieved, and the processing accuracy and efficiency are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114670179B
    Figure CN114670179B
Patent Text Reader

Abstract

The present invention relates to the field of intelligent processing, and in particular to a method, device, storage medium and terminal for constructing a robot workpiece coordinate system. The method includes the following steps: at least three positioning holes are set on the workpiece to be processed, and the detection probe is controlled to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and the contact detection data corresponding to each positioning hole is collected; the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system are calculated according to the contact detection data; and the workpiece coordinate system of the workpiece to be processed is established according to the theoretical center coordinates of all positioning holes. The present invention uses an optimized coordinate point acquisition method and a precise detection probe such as a Renishaw probe to quickly and accurately obtain multiple coordinate data of at least three positioning holes on a workpiece object, thereby calculating and generating the center coordinates of the positioning holes according to these coordinate data, and establishing the workpiece coordinate system of the workpiece object according to the center coordinates, thereby achieving a significant improvement in processing accuracy and processing efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of intelligent processing, and in particular to a method, device, storage medium and terminal for constructing a robot workpiece coordinate system. Background Art

[0002] With the continuous advancement of the industrialization process, the development of industrial robots in various fields is getting faster and faster. In the application of industrial robots in the field of mechanical processing, the operation of the robot is aimed at a certain workpiece, so it is necessary to establish a fixed workpiece coordinate system on the workpiece, so that most of the robot's operating tasks are defined in the workpiece coordinate system. When the workpiece is displaced, only the workpiece coordinates need to be updated. The existing technology usually collects the coordinates of at least three feature points on the workpiece object to establish the workpiece coordinate system. Since it is difficult to accurately collect the coordinate data of these feature points on the actual workpiece, the established workpiece coordinate system is inaccurate, which makes it difficult for the industrial robot to manipulate the X / Y / Z axis on the workpiece object, affecting the processing accuracy of the workpiece. Summary of the invention

[0003] The present invention provides a method, device, storage medium and terminal for constructing a robot workpiece coordinate system, which solve the above-mentioned technical problems.

[0004] The technical solution of the present invention to solve the above technical problems is as follows: A method for constructing a robot workpiece coordinate system, based on a detection probe arranged at the end of a robot flange tool, comprises the following steps:

[0005] Step 1, setting at least three positioning holes on the workpiece to be processed, controlling the detection probe to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and collecting the contact detection data corresponding to each positioning hole during the movement of the detection probe;

[0006] Step 2, calculating the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the contact detection data of each positioning hole;

[0007] Step 3: establishing a workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes.

[0008] In a preferred embodiment, the at least three positioning holes are actual circular holes formed on the workpiece to be processed, or an auxiliary structure is provided at the edge of the workpiece to be processed, and at least three positioning holes are formed on the auxiliary structure.

[0009] In a preferred embodiment, the detection probe is a Renishaw probe, and generating the touch detection data by the detection probe comprises the following steps:

[0010] S001, during the movement of the detection probe, when the probe of the detection probe touches the inner wall of the positioning hole, a probe touch feedback signal is generated and sent to the digital signal board of the detection probe;

[0011] S002, generating an interrupt instruction corresponding to the stylus touch feedback signal through the digital signal board, and sending the interrupt instruction to the controller of the robot;

[0012] S003, executing the interrupt instruction through the controller to control the robot's mechanical arm to stop moving, and calling the preset CRobt instruction to generate the point coordinates corresponding to the contact point on the positioning hole to form contact detection data, and then storing it in the preset array gjpos{3}.

[0013] In a preferred embodiment, the data processing step is also included, specifically:

[0014] It is determined whether the fluctuation range of the touch detection data exceeds a preset threshold, and if so, the touch detection data is collected again.

[0015] In a preferred embodiment, the contact detection data includes first contact detection data generated when the detection probe is at at least two detection heights inside the positioning hole and moves along the inner wall of the positioning hole, and second contact detection data generated when the detection probe is at the top surface of the positioning hole and moves along the inner wall of the positioning hole;

[0016] The theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system are calculated according to the first contact detection data and the second contact detection data, specifically:

[0017] S201, fitting circular paths corresponding to different detection heights according to the first touch detection data, calculating the center coordinates of at least two of the circular paths, and fitting corresponding space straight line equations according to the center coordinates;

[0018] S202, generating a spatial plane equation corresponding to the top surface of the fixture by fitting according to the second contact detection data;

[0019] S203, jointly solving the spatial straight line equation and the spatial plane equation, generating the intersection coordinates of the corresponding spatial straight line and the corresponding spatial plane, and using them as the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system;

[0020] S204, repeating the above steps S201-S203 to generate the theoretical center coordinates of each positioning hole in the workpiece coordinate system.

[0021] In a preferred embodiment, the first touch detection data is collected by the detection probe, specifically:

[0022] S101a, controlling the detection probe to move to above one of the positioning holes;

[0023] S102a, controlling the detection probe to move to a preset detection height according to the initial walking path and perform a first circular motion, wherein the detection probe touches the inner wall of the positioning hole at least three times during the motion, and collecting the first point coordinates corresponding to each contact point;

[0024] S103a, changing the detection height of the detection probe at the positioning hole, controlling the detection probe to perform a second circular motion according to the initial walking path, and collecting second point coordinates corresponding to at least three contact points during the motion;

[0025] S104a, controlling the detection probe to move to above the next positioning hole, and repeating the above steps S101a-S103a, until the first point coordinates and the second point coordinates corresponding to each positioning hole are obtained, forming the first touch detection data of the positioning hole, so as to fit the corresponding spatial straight line equation according to the first touch detection data.

[0026] In a preferred embodiment, the first touch detection data is collected by the detection probe and the corresponding space straight line equation is fitted, specifically:

[0027] S101b, controlling the detection probe to move above one of the positioning holes, and moving to the bottom surface of the positioning hole according to a first incremental contact path, to obtain point position data of the bottom surface;

[0028] S102b, lifting the detection probe from the bottom surface of the positioning hole to a preset detection height according to the bottom surface point data, and controlling the detection probe to perform a third circular motion in the positioning hole according to the initial walking path, and generating a third center coordinate of the motion trajectory corresponding to the third circular motion;

[0029] S103b, correcting the initial walking path according to the third circle center coordinates to generate a corresponding optimized walking path, wherein the optimized walking path includes an empty walking path and a second incremental contact path;

[0030] S104b, controlling the detection probe to move to the inner wall of the corresponding positioning hole according to the idle walking path, and performing a fourth circular motion in the corresponding positioning hole according to the second incremental contact path, and generating fourth center coordinates of the motion trajectory corresponding to the fourth circular motion;

[0031] S105b, performing a second correction on the initial walking path according to the fourth circle center coordinates to generate a target optimized path, and controlling the detection probe to perform a fifth circular motion in the corresponding positioning hole according to the target optimized path to generate a fifth circle center coordinate of a motion trajectory corresponding to the fifth circular motion;

[0032] S106b, fitting the spatial straight line equation corresponding to the positioning hole according to the fourth circle center coordinates and the fifth circle center coordinates;

[0033] S107b, controlling the detection probe to move to above the next positioning hole, and repeating the above steps S101b-S106b until the corresponding spatial straight line equation is fitted and generated for each positioning hole.

[0034] A second aspect of an embodiment of the present invention provides a computer-readable storage medium storing a computer program, and when the computer program is executed by a processor, the method for constructing a robot workpiece coordinate system described above is implemented.

[0035] A third aspect of an embodiment of the present invention provides a robot workpiece coordinate system construction terminal, comprising the computer-readable storage medium and a processor, wherein the processor implements the steps of the above-mentioned robot workpiece coordinate system construction method when executing the computer program on the computer-readable storage medium.

[0036] A fourth aspect of the embodiments of the present invention provides a device for constructing a robot workpiece coordinate system, using the above-mentioned method for constructing a robot workpiece coordinate system, including a collection module, a calculation module and a coordinate system construction module.

[0037] The acquisition module is used to control the detection probe to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and to collect the touch detection data corresponding to each positioning hole during the movement of the detection probe;

[0038] The calculation module is used to calculate the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the contact detection data of each positioning hole;

[0039] The coordinate system building module is used to establish the workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes.

[0040] The present invention provides a method, device, storage medium and terminal for constructing a robot workpiece coordinate system. Through an optimized coordinate point acquisition method and a precise detection probe such as a Renishaw probe, multiple coordinate data of at least three positioning holes on a workpiece object are quickly and accurately acquired, so that the center coordinates of the positioning holes are calculated and generated according to these coordinate data, and the workpiece coordinate system of the workpiece object is established according to the center coordinates, thereby achieving a significant improvement in machining accuracy and machining efficiency.

[0041] In order to make the above-mentioned objects, features and advantages of the invention more obvious and easy to understand, the preferred embodiments of the present invention are specifically cited below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.

[0043] Figure 1 is a schematic flow chart of a method for constructing a robot workpiece coordinate system provided in Example 1;

[0044] Figure 2 is a schematic structural diagram of a device for constructing a robot workpiece coordinate system provided in Example 2;

[0045] Figure 3 It is a structural schematic diagram of the construction terminal of the robot workpiece coordinate system provided in Example 3. DETAILED DESCRIPTION

[0046] In order to make the purpose, technical solution and beneficial technical effect of the present invention clearer, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods. It should be understood that the specific implementation methods described in this specification are only for explaining the present invention, not for limiting the present invention.

[0047] Figure 1 is a flow chart of a method for constructing a robot workpiece coordinate system provided in Example 1. The method for constructing a robot workpiece coordinate system is based on a detection probe disposed at the end of a robot flange tool, such as Figure 1 As shown, the specific steps include:

[0048] Step 1: at least three positioning holes are set on the workpiece to be processed, the detection probe is controlled to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and the contact detection data corresponding to each positioning hole during the movement of the detection probe is collected.

[0049] Here, the positioning hole can be an actual circular hole set on the workpiece to be processed. When the workpiece does not have a positioning hole, an auxiliary structure can also be set at the edge of the workpiece to be processed, and a positioning hole can be set on the auxiliary structure, so as to establish a workpiece coordinate system according to the coordinate data of the positioning hole. In a specific embodiment, an auxiliary structure can be set, and at least three positioning holes can be set on the auxiliary structure, or multiple auxiliary structures with the same top surface height can be set, and positioning holes can be set on each auxiliary structure.

[0050] In a preferred embodiment, in order to improve the acquisition accuracy of the coordinate data in the positioning hole, a Renishaw probe can be selected as the detection probe. The Renishaw probe is a machine tool online measurement product launched by Renishaw. It consists of a probe and a receiver, which are optically transmitted by infrared. The probe is a high-precision sensor. The movement of the probe is controlled by a macro program. When the probe of the probe touches a specific point on the workpiece, the receiver receives the touch signal of the probe and feeds the signal back to the CNC system. The macro program obtains the actual coordinate value of the touch point in the CNC system. In a specific embodiment, the above touch detection data generated by the Renishaw detection probe is specifically:

[0051] S001, during the movement of the detection probe, when the probe of the detection probe touches the inner wall of the positioning hole, a probe touch feedback signal is generated and sent to the digital signal board of the detection probe;

[0052] S002, generating an interrupt instruction corresponding to the stylus touch feedback signal through the digital signal board, and sending the interrupt instruction to the controller of the robot;

[0053] S003, the controller executes the interrupt instruction to control the robot's mechanical arm to stop moving, and calls the preset CRobt instruction to generate the point coordinates corresponding to the contact point on the positioning hole to form the contact detection data, and then stores it in the preset array gjpos{3}. Specifically, each time the controller executes the interrupt instruction, it will stop the robot from moving and turn off the interrupt in time to avoid the interrupt stack overflowing the memory (loop interrupt), so as to prevent the robot from collecting inaccurate data due to inertia under delayed waiting, and finally use the CRobt instruction to obtain the point coordinates and then store them in the array gjpos{3}.

[0054] In an optional embodiment, the detection probe is controlled to move along the inner wall of each positioning hole at different detection heights, and touch detection data corresponding to each positioning hole is generated. The touch detection data here include first touch detection data and second touch detection data with different functions and detection heights. Specifically, the first touch detection data is detected by the detection probe during the movement of the positioning hole at at least two detection heights inside the positioning hole along the inner wall of the positioning hole, and is used to fit the circular path corresponding to the different detection heights, so as to calculate the coordinates of the center of the circle corresponding to the circular path at different heights, so as to fit the spatial straight line equation; and the second detection data is detected by the detection probe during the movement of the positioning hole on the top surface of the positioning hole and along the inner wall of the positioning hole, and is used to fit the spatial plane equation corresponding to the top surface of the fixture.

[0055] In one embodiment, collecting the first touch detection data by using the detection probe specifically includes the following steps:

[0056] S101a, controlling the detection probe to move above one of the positioning holes.

[0057] S102a, control the detection probe to move to the preset detection height in the positioning hole according to the initial walking path and perform the first circular motion, during which the detection probe touches the inner wall of the positioning hole at least three times, and collects the first point coordinates corresponding to each touch point. In a preferred embodiment, the initial walking path here can be a combination of an empty walking path and an incremental touch path, wherein the preset empty walking path and the preset incremental touch path can both use trigonometric functions, and the empty walking path allows the detection probe to quickly move to the inner wall of the positioning hole to be touched, for example, first move to the inner wall of the positioning hole according to the moving distance of radius*0.8, and then perform the touch test at a speed of 0.2mm / s during the remaining touch test process; or move to the inner wall of the positioning hole according to the moving distance of radius*0.9 or radius*0.95, and then perform the touch test at a speed of 0.1mm / s or 0.05mm / s, that is, a speed close to the critical value. Not only can the touch test efficiency be improved by the empty walking path, but walking in the incremental touch path can ensure that the robot touches the inner wall of the positioning hole at a steady speed, avoiding the robot from causing errors in the touch test data due to inertia.

[0058] Then, S103a is executed to change the detection height of the detection probe at the positioning hole, control the detection probe to perform a second circular motion according to the initial walking path, and collect second point coordinates corresponding to at least three contact points during the motion.

[0059] S104a, controlling the detection probe to move to above the next positioning hole, and repeating the above steps S101a-S103a, until the first point coordinates and the second point coordinates corresponding to each positioning hole are obtained, that is, the first contact detection data of the positioning hole is formed.

[0060] Then, step 2 is performed to calculate the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the touch detection data of each positioning hole, that is, the first touch detection data and the second touch detection data. In one embodiment, the steps specifically include:

[0061] S201, fitting circular paths corresponding to different detection heights according to the first touch detection data of any positioning hole, calculating the center coordinates of at least two of the circular paths, and fitting corresponding space straight line equations according to the center coordinates;

[0062] S202, generating a spatial plane equation corresponding to the top surface of the fixture by fitting according to the second contact detection data of the positioning hole;

[0063] S203, jointly solving the spatial straight line equation and the spatial plane equation, generating the intersection coordinates of the corresponding spatial straight line and the corresponding spatial plane, and using them as the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system;

[0064] S204, repeating the above steps S201-S203 to generate the theoretical center coordinates of each positioning hole in the workpiece coordinate system.

[0065] In a specific embodiment, the spatial straight line equation of the two center coordinates can approximate the central axis of the positioning hole, and the different equidistant center coordinates are also related to the diameter of the ball at the end of the probe. For example, in one embodiment, a ball with a diameter of 1mm is used, and the equidistant center coordinates are generated by different side impact planes with equidistant intervals of 0.5mm. The first center coordinate side impact plane is 0.7mm away from the hole surface, so that the probe will not move outside the hole or press the measuring rod during the side impact.

[0066] Finally, step 3 is executed to establish the workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes. The specific method is recorded in relevant literature and will not be described in detail here.

[0067] In a preferred embodiment, after fitting the circular trajectory and obtaining the center coordinates, the diameter of the fitted circle can be calculated, and the diameter can be compared with the preset diameter threshold of the corresponding positioning hole. Based on the comparison result, it can be determined whether the calculation of the center coordinates is correct and the collision detection data can be recollected, thereby further optimizing the accuracy of the workpiece coordinate system.

[0068] In another preferred embodiment, in order to improve the accuracy of the coordinate point position in the positioning hole, the method for collecting the first touch detection data is optimized, which specifically includes the following steps:

[0069] S101b, controlling the detection probe to move to above one of the positioning holes, and moving to the bottom surface of the positioning hole according to a first incremental contact path, such as 1 mm, to obtain point position data of the bottom surface.

[0070] S102b, lift the detection probe from the bottom surface of the positioning hole to a preset detection height according to the bottom surface point data, ensure that the center of the probe of the detection probe is in the positioning hole, and control the detection probe to perform a third circular motion in the positioning hole according to the initial walking path, and generate the third center coordinates of the motion trajectory corresponding to the third circular motion.

[0071] S103b, correcting the points of the initial walking path according to the third circle center coordinates to generate a corresponding optimized walking path, wherein the optimized walking path includes an empty walking path and a second incremental contact path.

[0072] S104b, controlling the detection probe to move to the inner wall of the corresponding positioning hole according to the idle walking path, for example, first moving to the inner wall of the positioning hole according to the moving distance of radius*0.9, and performing the fourth circular motion in the corresponding positioning hole according to the second incremental touch path, that is, performing the touch detection along the inner wall of the positioning hole at a speed of 0.1mm / s during the remaining touch detection process, and generating the fourth center coordinate of the motion trajectory corresponding to the fourth circular motion.

[0073] S105b, perform a second correction on the points of the initial walking path according to the fourth circle center coordinates, generate a target optimized path, and control the detection probe to perform a fifth circular motion in the corresponding positioning hole according to the target optimized path, and generate the fifth circle center coordinates of the motion trajectory corresponding to the fifth circular motion. Here, the fifth circle center coordinates are a correction of the third circle center coordinates, so as to obtain effective and equidistant fourth circle center coordinate data and fifth circle center coordinate data, thereby ensuring the accuracy of the data.

[0074] S106b, fitting the spatial straight line equation corresponding to the positioning hole according to the fourth circle center coordinates and the fifth circle center coordinates.

[0075] S107b, control the detection probe to move to the top of the next positioning hole, and repeat the above steps S101b-S106b until the corresponding spatial straight line equation is fitted and generated for each positioning hole, thereby achieving accurate calculation of the theoretical center of each positioning hole, and then establishing a more suitable workpiece coordinate system for the workpiece object.

[0076] In another preferred embodiment, after the first touch detection data and the second touch detection data are collected, a data processing step may be performed, specifically:

[0077] Determine whether the fluctuation range of the touch detection data exceeds a preset threshold. If so, re-collect the touch detection data, thereby filtering out data with large deviations in the touch detection data, and further improving the accuracy of workpiece processing. In a specific embodiment, the distance between each touch point and the corresponding center of the circle during each touch process can be calculated based on the touch detection data, and then the deviation of the distance can be evaluated by the variance and standard deviation, so as to filter out the touch points whose deviations exceed the preset threshold, as well as the touch detection data of the touch points. Here, the variance and standard deviation are the most important and most commonly used indicators for measuring discrete trends. Variance is the average of the squares of the deviations of each variable value from its mean, and it is the most important method for measuring the degree of discreteness of numerical data. The standard deviation is the arithmetic square of the variance, and the standard deviation can be used as a measure of uncertainty.

[0078] The above embodiment provides a method for constructing a robot workpiece coordinate system, which quickly and accurately obtains multiple coordinate data of at least three positioning holes on the workpiece object through an optimized coordinate point acquisition method and a precise detection probe such as a Renishaw probe, thereby calculating and generating the center coordinates of the positioning holes based on these coordinate data, and establishing the workpiece coordinate system of the workpiece object based on the center coordinates, thereby achieving a significant improvement in workpiece processing accuracy and processing efficiency.

[0079] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0080] An embodiment of the present invention further provides a computer-readable storage medium storing a computer program, and when the computer program is executed by a processor, the method for constructing a robot workpiece coordinate system described above is implemented.

[0081] Figure 2 Schematic diagram of the structure of the robot workpiece coordinate system construction device provided in Example 2, such as Figure 2 As shown, it includes a collection module 100, a calculation module 200 and a coordinate system construction module 300.

[0082] The acquisition module 100 is used to control the detection probe to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and to collect the touch detection data corresponding to each positioning hole during the movement of the detection probe;

[0083] The calculation module 200 is used to calculate the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the contact detection data of each positioning hole;

[0084] The coordinate system building module 300 is used to establish the workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes.

[0085] In a preferred embodiment, the at least three positioning holes are actual circular holes formed on the workpiece to be processed, or an auxiliary structure is provided at the edge of the workpiece to be processed, and at least three positioning holes are formed on the auxiliary structure.

[0086] In a preferred embodiment, it further comprises a data processing module 400, wherein the data processing module 400 is used to determine whether the fluctuation range of the touch detection data exceeds a preset threshold, and if so, re-collect the touch detection data.

[0087] In a preferred embodiment, the touch detection data includes first touch detection data generated when the detection probe is at at least two detection heights inside the positioning hole and moves along the inner wall of the positioning hole, and second touch detection data generated when the detection probe is on the top surface of the positioning hole and moves along the inner wall of the positioning hole.

[0088] In a preferred embodiment, the calculation module 200 specifically includes:

[0089] A first fitting unit 201 is used to fit circular paths corresponding to different detection heights according to the first touch detection data, calculate the center coordinates of at least two of the circular paths, and fit the corresponding space straight line equation according to the center coordinates;

[0090] A second fitting unit 202, configured to fit and generate a spatial plane equation corresponding to the top surface of the fixture according to the second contact detection data;

[0091] The calculation unit 203 is used to solve the spatial straight line equation and the spatial plane equation together to generate the intersection coordinates of the corresponding spatial straight line and the corresponding spatial plane, and use them as the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system.

[0092] In a preferred embodiment, the acquisition module 100 specifically includes:

[0093] A first control unit 101 is used to control the detection probe to move to above one of the positioning holes;

[0094] The first acquisition unit 102 is used to control the detection probe to move to a preset detection height according to the initial walking path and perform a first circular motion. During the motion, the detection probe touches the inner wall of the positioning hole at least three times, and the first point coordinates corresponding to each contact point are collected;

[0095] The second acquisition unit 103 is used to change the detection height of the detection probe in the positioning hole, control the detection probe to perform a second circular motion according to the initial walking path, and collect the second point coordinates corresponding to at least three contact points during the movement to form the first contact detection data of the positioning hole, so as to fit the corresponding spatial straight line equation according to the first contact detection data.

[0096] In another embodiment, the acquisition module 100 includes:

[0097] The second control unit 1001 is used to control the detection probe to move to the top of one of the positioning holes, and move to the bottom surface of the positioning hole according to the first incremental contact path to obtain point position data of the bottom surface;

[0098] The first generating unit 1002 is used to lift the detection probe from the bottom surface of the positioning hole to a preset detection height according to the bottom surface point data, and control the detection probe to perform a third circular motion in the positioning hole according to the initial walking path, and generate a third center coordinate of the motion trajectory corresponding to the third circular motion;

[0099] An optimization unit 1003 is used to modify the initial walking path according to the third circle center coordinates to generate a corresponding optimized walking path, wherein the optimized walking path includes an empty walking path and a second incremental contact path;

[0100] The second generating unit 1004 is used to control the detection probe to move to the inner wall of the corresponding positioning hole according to the idle walking path, and to perform a fourth circular motion in the corresponding positioning hole according to the second incremental contact path, and to generate fourth center coordinates of the motion trajectory corresponding to the fourth circular motion;

[0101] The third control unit 1005 is used to perform a second correction on the initial walking path according to the fourth center coordinates, generate a target optimized path, and control the detection probe to perform a fifth circular motion in the corresponding positioning hole according to the target optimized path, generate the fifth center coordinates of the motion trajectory corresponding to the fifth circular motion, so as to fit the spatial straight line equation corresponding to the positioning hole according to the fourth center coordinates and the fifth center coordinates.

[0102] An embodiment of the present invention also provides a robot workpiece coordinate system construction terminal, comprising the computer-readable storage medium and a processor, wherein the processor implements the steps of the above-mentioned robot workpiece coordinate system construction method when executing the computer program on the computer-readable storage medium. Figure 3 is a schematic diagram of the structure of a construction terminal of a robot workpiece coordinate system provided in Embodiment 3 of the present invention, such as Figure 3 As shown, the robot workpiece coordinate system construction terminal 8 of this embodiment includes: a processor 80, a readable storage medium 81, and a computer program 82 stored in the readable storage medium 81 and executable on the processor 80. When the processor 80 executes the computer program 82, the steps in the above-mentioned various method embodiments are implemented, such as Figure 1 Alternatively, when the processor 80 executes the computer program 82, the functions of each module in the above-mentioned device embodiments are realized, for example Figure 2 The functions of modules 100 to 300 are shown.

[0103] Exemplarily, the computer program 82 may be divided into one or more modules, which are stored in the readable storage medium 81 and executed by the processor 80 to implement the present invention. The one or more modules may be a series of computer program instruction segments capable of implementing specific functions, which are used to describe the execution process of the computer program 82 in the construction terminal 8 of the robot workpiece coordinate system.

[0104] The construction terminal 8 of the robot workpiece coordinate system may include, but is not limited to, a processor 80 and a readable storage medium 81. Those skilled in the art will understand that Figure 3 It is only an example of the construction terminal 8 of the robot workpiece coordinate system and does not constitute a limitation on the construction terminal 8 of the robot workpiece coordinate system. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the construction terminal of the robot workpiece coordinate system may also include a power management module, an operation processing module, input and output devices, a network access device, a bus, etc.

[0105] The processor 80 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0106] The readable storage medium 81 may be an internal storage unit of the construction terminal 8 of the robot workpiece coordinate system, such as a hard disk or memory of the construction terminal 8 of the robot workpiece coordinate system. The readable storage medium 81 may also be an external storage device of the construction terminal 8 of the robot workpiece coordinate system, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the construction terminal 8 of the robot workpiece coordinate system. Further, the readable storage medium 81 may also include both an internal storage unit and an external storage device of the construction terminal 8 of the robot workpiece coordinate system. The readable storage medium 81 is used to store the computer program and other programs and data required by the construction terminal of the robot workpiece coordinate system. The readable storage medium 81 may also be used to temporarily store data that has been output or is to be output.

[0107] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0108] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0109] Those of ordinary skill in the art will appreciate that the units and method steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0110] In the embodiments provided by the present invention, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0111] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0112] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0113] The present invention is not limited to what is described in the specification and implementation modes, and therefore additional advantages and modifications can be easily realized by those skilled in the art. Therefore, without departing from the spirit and scope of the general concept defined by the claims and their equivalents, the present invention is not limited to the specific details, representative devices, and illustrative examples shown and described herein.

Claims

1. A method for constructing a robot workpiece coordinate system, based on a detection probe arranged at the end of a robot flange tool, characterized in that: The following steps are involved: Step 1, setting at least three positioning holes on the workpiece to be processed, controlling the detection probe to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and collecting the contact detection data corresponding to each positioning hole during the movement of the detection probe; Step 2, calculating the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the contact detection data of each positioning hole; Step 3, establishing a workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes; The at least three positioning holes are actual circular holes formed on the workpiece to be processed, or an auxiliary structure is provided at the edge of the workpiece to be processed, and at least three positioning holes are formed on the auxiliary structure; The detection probe is a Renishaw probe, and generating the touch detection data by the detection probe includes the following steps: S001, during the movement of the detection probe, when the probe of the detection probe touches the inner wall of the positioning hole, a probe touch feedback signal is generated and sent to the digital signal board of the detection probe; S002, generating an interrupt instruction corresponding to the stylus touch feedback signal through the digital signal board, and sending the interrupt instruction to the controller of the robot; S003, executing the interrupt instruction through the controller to control the robot arm to stop moving, and calling the preset CRobt instruction to generate the point coordinates corresponding to the contact point on the positioning hole to form contact detection data, and then storing it in the preset array gjpos{3}; It also includes data processing steps, specifically: Determine whether the fluctuation range of the touch detection data exceeds a preset threshold, and if so, re-collect the touch detection data; The contact detection data includes first contact detection data generated when the detection probe is at least two detection heights inside the positioning hole and moves along the inner wall of the positioning hole, and second contact detection data generated when the detection probe is at the top surface of the positioning hole and moves along the inner wall of the positioning hole; The theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system are calculated according to the first contact detection data and the second contact detection data, specifically: S201, fitting circular paths corresponding to different detection heights according to the first touch detection data, calculating the center coordinates of at least two of the circular paths, and fitting corresponding space straight line equations according to the center coordinates; S202, generating a spatial plane equation corresponding to the top surface of the fixture by fitting according to the second contact detection data; S203, jointly solving the spatial straight line equation and the spatial plane equation, generating the intersection coordinates of the corresponding spatial straight line and the corresponding spatial plane, and using them as the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system; S204, repeating the above steps S201-S203 to generate the theoretical center coordinates of each positioning hole in the workpiece coordinate system; The first touch detection data is collected by the detection probe and the corresponding spatial straight line equation is fitted, which is specifically: S101a, controlling the detection probe to move to above one of the positioning holes; S102a, controlling the detection probe to move to a preset detection height according to the initial walking path and perform a first circular motion, wherein the detection probe touches the inner wall of the positioning hole at least three times during the motion, and collecting the first point coordinates corresponding to each contact point; S103a, changing the detection height of the detection probe at the positioning hole, controlling the detection probe to perform a second circular motion according to the initial walking path, and collecting second point coordinates corresponding to at least three contact points during the motion; S104a, controlling the detection probe to move to above the next positioning hole, and repeating the above steps S101a-S103a, until the first point coordinates and the second point coordinates corresponding to each positioning hole are obtained, forming the first touch detection data of the positioning hole, so as to fit the corresponding space straight line equation according to the first touch detection data; The first touch detection data is collected by the detection probe and the corresponding spatial straight line equation is fitted, which is specifically: S101b, controlling the detection probe to move above one of the positioning holes, and moving to the bottom surface of the positioning hole according to a first incremental contact path, to obtain point position data of the bottom surface; S102b, lifting the detection probe from the bottom surface of the positioning hole to a preset detection height according to the bottom surface point data, and controlling the detection probe to perform a third circular motion in the positioning hole according to the initial walking path, and generating a third center coordinate of the motion trajectory corresponding to the third circular motion; S103b, correcting the initial walking path according to the third circle center coordinates to generate a corresponding optimized walking path, wherein the optimized walking path includes an empty walking path and a second incremental contact path; S104b, controlling the detection probe to move to the inner wall of the corresponding positioning hole according to the idle walking path, and performing a fourth circular motion in the corresponding positioning hole according to the second incremental contact path, and generating fourth center coordinates of the motion trajectory corresponding to the fourth circular motion; S105b, performing a second correction on the initial walking path according to the fourth circle center coordinates to generate a target optimized path, and controlling the detection probe to perform a fifth circular motion in the corresponding positioning hole according to the target optimized path to generate a fifth circle center coordinate of a motion trajectory corresponding to the fifth circular motion; S106b, fitting the spatial straight line equation corresponding to the positioning hole according to the fourth circle center coordinates and the fifth circle center coordinates; S107b, controlling the detection probe to move to above the next positioning hole, and repeating the above steps S101b-S106b until the corresponding spatial straight line equation is fitted and generated for each positioning hole.

2. A device for constructing a robot workpiece coordinate system, using the method for constructing a robot workpiece coordinate system according to claim 1, characterized in that: Including acquisition module, calculation module and coordinate system construction module, The acquisition module is used to control the detection probe to move along the inner wall of each positioning hole at different detection heights of each positioning hole, and to collect the touch detection data corresponding to each positioning hole during the movement of the detection probe; The calculation module is used to calculate the theoretical center coordinates of the corresponding positioning hole in the workpiece coordinate system according to the contact detection data of each positioning hole; The coordinate system building module is used to establish the workpiece coordinate system of the workpiece to be processed according to the theoretical center coordinates of all positioning holes.

3. A computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the method for constructing a robot workpiece coordinate system according to claim 1 is implemented.

4. A calibration terminal for a robot workpiece coordinate system, comprising a computer-readable storage medium and a processor, wherein the processor implements the steps of the method for constructing the robot workpiece coordinate system of claim 1 when executing a computer program on the computer-readable storage medium.