Error measurement and compensation method and apparatus for automated sander

By establishing a linkage coordinate system and kinematic model in an automated grinding machine, and solving for θ1, θ2, s3, θ4, and θ5, compensation for machine tool errors and workpiece installation errors is achieved. This solves the problems of poor interchangeability and readability of automated grinding equipment, and improves programming efficiency and grinding accuracy.

CN116394162BActive Publication Date: 2026-06-12HUAZHONG UNIV OF SCI & TECH +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HUAZHONG UNIV OF SCI & TECH
Filing Date
2023-04-13
Publication Date
2026-06-12

AI Technical Summary

Technical Problem

Existing automated grinding equipment suffers from poor interchangeability, poor readability, and low programming efficiency, making it difficult to reuse G-code across different devices and compensate for errors caused by workpiece installation.

Method used

By establishing the coordinate system of the machine tool structure linkage of the automated grinding machine, selecting control points and vectors, and establishing equations based on the kinematic model, the inverse kinematic solution is obtained to obtain θ1, θ2, s3, θ4, and θ5, thereby compensating for machine tool errors and workpiece installation errors.

🎯Benefits of technology

It improves the readability and programming efficiency of G-code, solves the problem of poor interchangeability, and improves the accuracy and efficiency of the polishing process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116394162B_ABST
    Figure CN116394162B_ABST
Patent Text Reader

Abstract

The application discloses an error measurement and compensation method and device for an automatic grinding machine, and establishes a connecting rod coordinate system of the automatic grinding machine based on a machine tool structure of the automatic grinding machine, and establishes a conversion matrix between the coordinate systems, wherein the machine tool structure of the automatic grinding machine comprises a SCARA robot and a grinding wheel assembly, the grinding wheel assembly comprises a grinding wheel and a main shaft rotating motor; a center of a circle on a circle surface of the grinding wheel far from the main shaft rotating motor is selected as a control point P, and a unit vector perpendicular to the circle surface of the grinding wheel at the control point P is selected as a control vector V; a kinematics model considering machine tool errors is established according to the conversion matrix between the coordinate systems, an equation relationship is established by combining the control point P, the control vector V and the kinematics model; and inverse kinematics is solved based on the equation relationship, so that θ1, θ2, s3, θ4 and θ5 are obtained. The application can not only solve the problems of poor readability and interchangeability, but also improve programming efficiency and calculation accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of grinding and polishing, and more specifically to an error measurement and compensation method and apparatus for automated grinding machines. Background Technology

[0002] The market for casting industrial products has been expanding in recent years, leading to a growing imbalance between labor supply and demand within the industry. Therefore, designing intelligent and automated grinding equipment has become an effective way to solve this problem. Currently, most grinding equipment is programmed using a teach-in method, where workers operate the equipment on-site, recording each action as it is performed, thus generating G-code. This method has the following drawbacks:

[0003] 1. Poor interchangeability, making it difficult to reuse the same G-code across different devices and to compensate for errors caused by workpiece installation on the same device.

[0004] 2. Poor readability: The content recorded in the G code during teaching programming is usually the actual movement position of each motor. However, because the kinematic relationship of industrial robots involves complex trigonometric function calculations, the actual movement position of the motor cannot directly reflect the relative positional relationship between the machining tool and the workpiece.

[0005] 3. Low programming efficiency: On-site teaching programming requires a lot of time for practitioners to complete programming on the industrial processing site, and it is impossible to use high-efficiency CAM software to automatically generate G-code in combination with the process.

[0006] Therefore, it is essential to propose an error measurement and compensation method for automated grinding machines. Summary of the Invention

[0007] In view of the aforementioned technical problems, the purpose of the embodiments of this application is to provide an error measurement and compensation method and apparatus for automated grinding machines, so as to solve the technical problems mentioned in the background section above.

[0008] In a first aspect, the present invention provides an error measurement and compensation method for an automated grinding machine, comprising the following steps:

[0009] S1. Based on the machine tool structure of the automated grinding machine, establish its linkage coordinate system and establish the transformation matrix between each coordinate system. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly. The grinding wheel assembly includes a grinding wheel and a spindle rotary motor.

[0010] S2, select the center of the circle on the side of the grinding wheel away from the spindle rotating motor as the control point P, and select the unit vector at the control point P that is perpendicular to the circle of the grinding wheel as the control vector V;

[0011] S3. Based on the transformation matrix between each coordinate system, establish a kinematic model that considers machine tool errors, and combine the control point P and the control vector V with the kinematic model to establish an equation relationship.

[0012] S4, based on the equality relationship, solve the inverse kinematics to obtain θ1, θ2, s3, θ4, θ5, where θ n s3 is the rotation angle corresponding to the Jn axis rotary motor in the machine tool structure, where n = 1, 2, 4, 5, and s3 is the displacement corresponding to the J3 axis linear motor.

[0013] Preferably, the control point P has three-axis components of x, y, and z in the workpiece coordinate system {OW}, and the control vector V has three-axis components of i, j, and k in the workpiece coordinate system {OW}. The machine tool error includes a first deviation and a second deviation. The first deviation is the deviation between the J5 axis rotation axis corresponding to the J5 axis rotary motor and its ideal installation position. The second deviation is the deviation between the spindle rotation axis corresponding to the spindle rotary motor and its ideal installation position. vec1 is a unit vector coinciding with the J5 axis rotation axis. OB vec1 = [nx1 ny1 nz1 0] T vec2 is a unit vector coinciding with the axis of rotation of the principal axis. OJ5d vec2 = [nx2 ny2 nz2 0] T .

[0014] Preferably, the SCARA robot includes a SCARA robot base, a J1-axis rotary motor, a proximal articulated arm, a J2-axis rotary motor, a distal articulated arm, a J3-axis linear motor, a workpiece clamping tray, and a J4-axis rotary motor. The link coordinate system includes a robot base coordinate system {OB}, a first joint axis static coordinate system {OJ1s}, a first joint axis moving coordinate system {OJ1d}, a second joint axis static coordinate system {OJ2s}, a second joint axis moving coordinate system {OJ2d}, and a third joint axis static coordinate system {OJ3s}. The system comprises the following coordinate systems: the third joint axis moving coordinate system {OJ3d}, the fourth joint axis static coordinate system {OJ4s}, the fourth joint axis moving coordinate system {OJ4d}, the fifth joint axis static coordinate system {OJ5s}, the fifth joint axis moving coordinate system {OJ5d}, the grinding wheel tool ideal coordinate system {OTi}, the grinding wheel tool coordinate system {OT}, and the workpiece coordinate system {OW}. The robot base coordinate system {OB} is located on the SCARA robot base, and its Z-axis coincides with the centerline of the J1 axis rotary motor. The first joint axis static coordinate system { The origin of the first joint axis moving coordinate system {OJ1s} and {OJ1d} is located at the intersection of the centerline of the J1 axis rotary motor and the upper cover of the SCARA robot base; the origin of the second joint axis static coordinate system {OJ2s} and {OJ2d} is located on the centerline of the J2 axis rotary motor, with the height direction the same as {OJ1s}; the origin of the third joint axis static coordinate system {OJ3s} and {OJ3d} is located on the centerline of the J3 axis linear motor, with the height direction {OJ3s}. Same as {OJ1s}; the origins of the fourth joint axis static coordinate system {OJ4s} and the fourth joint axis moving coordinate system {OJ4d} are located on the center line of the J4 axis rotary motor, with the height direction the same as the workpiece mounting table; the origins of the fifth joint axis static coordinate system {OJ5s} and the fifth joint axis moving coordinate system {OJ5d} are located on the center line of the J5 axis rotary motor; the origins of the grinding wheel tool ideal coordinate system {OTi} and the grinding wheel tool coordinate system {OT} are on the grinding wheel spindle axis; the origin of the workpiece coordinate system {OW} is on the workpiece;

[0015] Let the matrix operators be as follows:

[0016]

[0017]

[0018]

[0019] Where trans(a,b,c) is the translation matrix, rotx(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the x-axis, roty(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the y-axis, rotz(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the z-axis, and rotvec(nx,ny,nz,θ) is the rotation matrix of rotating counterclockwise by an angle θ around any unit vector vec=[nx,ny,nz] in space;

[0020] Establish the transformation matrix between the two adjacent coordinate systems in sequence. Based on the machine tool structure and matrix operators, the following calculation formula is obtained:

[0021]

[0022]

[0023]

[0024]

[0025]

[0026]

[0027]

[0028]

[0029]

[0030]

[0031]

[0032]

[0033]

[0034] Where L1 is the height of the SCARA robot base, L2 is the arm length of the proximal articulated arm of the SCARA robot, L3 is the arm length of the distal articulated arm of the SCARA robot, L4 is the height difference between the workpiece clamping pallet and the upper surface of the SCARA robot base, L5, L6, and L7 are the distances in the Y, X, and Z directions between the center of the J5 axis rotation axis end face and the origin of the robot base coordinate system {OB}, respectively; L8 and L9 are the distances in the X and Y directions between the center of the grinding wheel and the center of the J5 axis rotation axis end face, respectively.

[0035] θ1, θ2, θ4, and θ5 are the rotation angles corresponding to the J1-axis rotary motor, J2-axis rotary motor, J4-axis rotary motor, and J5-axis rotary motor, respectively; s3 is the displacement corresponding to the J3-axis linear motor; trans(e x ,e y ,e z )*rotz(e c1 )*rotx(e a )*rotz(e c2 (This refers to the workpiece installation error) The ZXZ expression, e x e y e z , where e represents the translation error in three directions. c1 e a e c2 The rotational error is in three directions.

[0036] in, Inside for OJ5d vec2 = [nx2 ny2 nz2 0] T Compared to the ideal state OJ5d vec2' = [1 0 00] T The included angle can be calculated using the following formula: OJ5d vec v =[nx v ,ny v ,nz v [0] means simultaneously with OJ5d vec2 = [nx2 ny2 nz2 0] T and OJ5d vec2' = [1 0 0 0] T A perpendicular unit vector, defined by its specific direction as perpendicular to... OJ5d vec2× OJ5d vec2' is in the same direction (× is the cross product symbol for vectors), and can be calculated as follows:

[0037] Preferably, step S3 specifically includes:

[0038] Based on the coordinate system transformation relationship, a first route and a second route are established. The first route starts from the robot's base coordinate system {OB} and moves sequentially along each joint of the SCARA system, in the following order: robot base coordinate system {OB}, first joint axis static coordinate system {OJ1s}, first joint axis moving coordinate system {OJ1d}, second joint axis static coordinate system {OJ2s}, second joint axis moving coordinate system {OJ2d}, third joint axis static coordinate system {OJ3s}, and third joint axis moving coordinate system {OJ3}. The first path starts from the robot base coordinate system {OB} and moves along the grinding wheel assembly direction, in the following order: robot base coordinate system {OB}, fifth joint axis static coordinate system {OJ5s}, fifth joint axis dynamic coordinate system {OJ5d}, virtual fifth joint axis static coordinate system {OJ5s}, grinding wheel tool ideal coordinate system {OTi}, and grinding wheel tool coordinate system {OT}.

[0039] The control point P and control vector V are respectively in the workpiece coordinate system {OW} W P = [xyz 1] T , W V = [ijk 0] T In the grinding wheel tool coordinate system {OT}, respectively T P = [0 0 0 1] T , T V = [1 0 0 0] T Control point P and control vector V are transformed to the robot's base coordinate system {OB} via the first and second routes respectively. Since control point P and control vector V coincide in the robot's base coordinate system {OB}, the following equation is established:

[0040]

[0041] Among them, θ1, θ2, s3, θ4, and θ5 are all unknowns to be solved.

[0042] Preferably, step S4 specifically includes:

[0043] By combining the third and fourth terms in equation (1), we can construct an equation regarding... B The equation for V, when expanded, yields a 4x1 vector equation system. The third term in this system is:

[0044]

[0045] Rearranging equation (2) into the form A*sin(θ5)+B*cos(θ5)+C=0, we get:

[0046]

[0047] Compare A*sin(θ5)+B*cos(θ5)+C=0 with sin(θ5) 2 +cos(θ5) 2 =1, solve the system of equations simultaneously to find θ5. Two solutions can be obtained through calculation. Solution 1:

[0048]

[0049] Solution 2:

[0050]

[0051] Based on the actual structure of the machine tool, solution one is discarded, and solution two is retained;

[0052] After obtaining θ5, Since it is a known matrix, and because All are known matrices, and can be obtained from equation (1), etc. and work out B P and B V, represented by symbols: B P = [ B x B y B z 1] T , B V = [ B i B j B k 1] T ;in, B x、 B y、 B z represents the three-axis components of point P in the robot's base coordinate system {OB}. B i、 B j、 B k represents the three-axis components of the V vector in the robot's base coordinate system {OB};

[0053] make Rearranging equation (1) yields:

[0054]

[0055] because Given a matrix, let Calculate J4d P and J4d V, represented by symbols: J4d P = [ J4d x J4d y J4d z 1] T , J4d V = [ J4d iJ4d j J4d k 1] T ;in, J4d x、 J4d y、 J4d z represents the three-axis components of the control point P in the OJ4d coordinate system. J4d i、 J4d j、 J4d k represents the three-axis components of the control vector V in the OJ4d coordinate system;

[0056] Further rearranging equation (6), we get:

[0057]

[0058] Solve Based on the structure and kinematics of the SCARA robot, it can be known that... It is a translation and rotation transformation matrix, and its rotation part can only rotate around the Z-axis, so let's assume... Will B P, B V. J4d P and J4d Substituting the symbolic representation of V into equation (7) and expanding it, and removing the unsigned equations, we obtain the following equation relationship:

[0059]

[0060] First, calculate θ using the fourth and fifth equations in equation (8). OJ4d :

[0061]

[0062] Then θ OJ4d Substitute x into the first, second, and third equations in equation (8) to calculate x. OJ4d y OJ4d z OJ4d :

[0063]

[0064] according to B P OJ4d =[x OJ4d y OJ4d z OJ4d 1] T and θ OJ4d The solution for the unknowns θ1, θ2, s3, and θ4 is given by the following formula:

[0065]

[0066] The value of sin(θ2) is determined to be either a positive or negative solution based on the structure of the grinding wheel assembly and the SCARA robot.

[0067] As a preferred option OB vec1 = [nx1 ny1 nz1 0] T and OJ5d vec2 = [nx2 ny2 nz2 0] T The calculation process is as follows:

[0068] The coordinates of the target ball mounted on the distal articulated arm of the SCARA robot are obtained using a laser tracking measurement device. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0069] The rotation angle of the J1 axis is controlled by the control system, and measured sequentially. Using the least squares method A first circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the first circular surface is denoted as Mvec1 = [mx1 my1 mz1 0]. T ;

[0070] The coordinate position of the target ball mounted on the grinding wheel connecting arm is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0071] The rotation angle of the J5 axis is controlled by the control system, and measured sequentially. Using the least squares method A second circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the second circular surface is denoted as Mvec2 = [mx2 my2 mz2 0]. T ;

[0072] The coordinate position of the target ball mounted on the grinding wheel is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0073] The spindle rotation angle is controlled by the control system, and the following measurements are taken sequentially. Using the least squares method A third circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the third circular surface is denoted as Mvec3 = [mx3 my3 mz3 0]. T ;

[0074] First calculate Mvec1 = [mx1 my1 mz1 0] Tand [0 0 1 0] T The included angle ω1 = arccos(mx1);

[0075] Then calculate Mvec1 = [mx1 my1 mz1 0] T and [0 0 1 0] T The vertical unit vector Mvecper1;

[0076] The specific direction of Mvecper1 is defined as Mvec1 × [0 0 1 0]. T In the same direction, calculations show that:

[0077]

[0078] Create a sequence starting from Mvec1 = [mx1 my1 mz1 0] T To [0 0 1 0] T Transformation matrix:

[0079]

[0080] but:

[0081] First calculate Mvec2 = [mx2 my2 mz2 0] T and [0 1 0 0] T The included angle between them is ω2 = arccos(my2);

[0082] Then calculate Mvec2 = [mx2 my2 mz2 0] T and [0 1 0 0] T The vertical unit vector Mvecper2;

[0083] The specific direction of Mvecper2 is defined as Mvec2 × [0 1 0 0]. T In the same direction, calculations show that:

[0084]

[0085] Create a sequence starting from Mvec2 = [mx2 my2 mz2 0] T To [0 1 0 0] T Transformation matrix:

[0086]

[0087] but:

[0088] As a preferred option The calculation process is as follows:

[0089] After the workpiece is clamped and installed, adjust the positions of each motor so that the center of the grinding wheel touches the marked point on the workpiece. W P, and establish an equation relationship:

[0090]

[0091] In this context, θ1, θ2, θ4, θ5, and s3 are all known quantities during the contact process. T P, W P are all known quantities and can be calculated.

[0092] Rearranging equation (12) yields:

[0093]

[0094] in,

[0095] Repeat the above steps to select four non-coplanar marker points on the workpiece. W P1, W P2, W P3 and W P4 establishes four equations, which can be solved simultaneously as follows:

[0096]

[0097] remember W P n =[ W x n , W y n , W z n ,1] T , J4d P n =[ J4d x n , J4d y n , J4d z n ,1] T , Substituting into equation (14), discarding the unsigned equation, and rearranging, we get:

[0098]

[0099] Equation (15) consists of 12 linearly independent equations and 12 unknowns t. 11 t 12 t 13 t 14 t21 t 22 t 23 t 24 t 31 t 32 t 33 and t 34 Equation (15) can be solved using Gaussian elimination, and the result can be obtained using t. nn Expressed

[0100] Secondly, the present invention provides an error measurement and compensation device for an automated grinding machine, comprising:

[0101] The coordinate establishment module is configured to establish the linkage coordinate system based on the machine tool structure of the automated grinding machine, and to establish the transformation matrix between the coordinate systems. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly, which includes a grinding wheel and a spindle rotary motor.

[0102] The variable definition module is configured to select the center of the circle on the side of the grinding wheel away from the spindle rotary motor as the control point P, and select the unit vector of the circle at control point P that is perpendicular to the grinding wheel as the control vector V.

[0103] The equation establishment module is configured to establish a kinematic model considering machine tool errors based on the transformation matrix between each coordinate system, and to establish an equation relationship by combining the control point P and the control vector V with the kinematic model.

[0104] The solver module is configured to solve the inverse kinematics based on the equation relationship, obtaining θ1, θ2, s3, θ4, and θ5, where θ n s3 is the rotation angle corresponding to the Jn axis rotary motor in the machine tool structure, where n = 1, 2, 4, 5, and s3 is the displacement corresponding to the J3 axis linear motor.

[0105] Thirdly, the present invention provides an electronic device including one or more processors; and a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any implementation of the first aspect.

[0106] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method as described in any of the implementations of the first aspect.

[0107] Compared with the prior art, the present invention has the following beneficial effects:

[0108] (1) The present invention defines G-code rules that meet the requirements of casting grinding process and are easy to read and understand, which can solve the problem of poor readability and at the same time provide the possibility of CAM software application and improve programming efficiency.

[0109] (2) This invention establishes a kinematic model containing error parameters, including machine tool error and workpiece installation error, and derives an inverse solution method to compensate for machine tool error and workpiece loading error when the error parameters are known, thereby improving accuracy.

[0110] (3) The present invention designs a detection process to obtain machine tool error and workpiece installation error, which can solve the problem of poor interchangeability. Attached Figure Description

[0111] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0112] Figure 1 This is a flowchart illustrating an error measurement and compensation method for an automated grinding machine according to an embodiment of this application.

[0113] Figure 2 The following are simplified mechanical structure diagrams and dimensional diagrams of the automated equipment to which the error measurement and compensation method for an automated grinding machine is applicable, as described in the embodiments of this application.

[0114] Figure 3 This is a schematic diagram illustrating the meaning of G-codes in the definition of an error measurement and compensation method for an automated grinding machine according to an embodiment of this application.

[0115] Figure 4 This is a schematic diagram of the coordinate system transformation relationship in the derivation inverse solution process of the error measurement and compensation method for an automated grinding machine according to an embodiment of this application;

[0116] Figure 5 This is a schematic diagram of a machine tool error measurement method for an automated grinding machine, as described in an embodiment of this application.

[0117] Figure 6 This is a schematic diagram of a workpiece installation error measurement method for an automated grinding machine, as described in an embodiment of this application.

[0118] Figure 7 This is a schematic diagram of an error measurement and compensation device for an automated grinding machine, according to an embodiment of this application.

[0119] Reference numerals: 1. Equipment mounting base; 2. SCARA robot base; 3. J1 axis rotary motor; 4. Proximal articulated arm; 5. J2 axis rotary motor; 6. Distal articulated arm; 7. J3 axis linear motor; 8. Workpiece clamping tray; 9. J4 axis rotary motor; 10. Workpiece to be processed; 11. Spindle rotary motor; 12. Grinding wheel; 13. Grinding wheel connecting arm; 14. J5 axis rotary motor; 15. Grinding wheel mounting base; 16. Laser tracking measuring instrument; 17. Target ball. Detailed Implementation

[0120] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0121] Figure 1 An embodiment of this application illustrates an error measurement and compensation method for an automated grinding machine, comprising the following steps:

[0122] S1. Based on the machine tool structure of the automated grinding machine, establish its linkage coordinate system and establish the transformation matrix between each coordinate system. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly. The grinding wheel assembly includes a grinding wheel and a spindle rotary motor.

[0123] In a specific embodiment, refer to Figure 2 The automated grinding machine includes a mounting base 1 and a machine tool structure. The SCARA robot includes a SCARA robot base 2, a J1-axis rotary motor 3, a proximal articulated arm 4, a J2-axis rotary motor 5, a distal articulated arm 6, a J3-axis linear motor 7, a workpiece clamping tray 8, and a J4-axis rotary motor 9. The J1-axis rotary motor 3 is mounted on the SCARA robot base 2. The proximal articulated arm 4 is mounted between the J1-axis and J2-axis rotary motors 4. The distal articulated arm 6 is mounted between the J2-axis and J3-axis linear motors 7. The J4-axis rotary motor 9 controls the rotation of the workpiece clamping tray 8, and the workpiece 10 to be processed is placed on the workpiece clamping tray 8. The grinding wheel assembly includes a grinding wheel mounting base 15, a grinding wheel, a J5-axis rotary motor 14, a grinding wheel connecting arm 13, a grinding wheel 12, and a spindle rotary motor 11. The grinding wheel connecting arm 13 is positioned between the J5-axis and spindle rotary motors 14 and 11. The spindle rotary motor 11 controls the rotation of the grinding wheel disc 12. The structure of the automated grinding machine to which this invention is applicable includes, but is not limited to, the following: Figure 2 The present invention applies to any "4-axis + 1-axis" structure that includes a SCARA robot and a grinding wheel revolution axis.

[0124] Based on the above structure, a link coordinate system is constructed, which includes the robot base coordinate system {OB}, the first joint axis static coordinate system {OJ1s}, the first joint axis moving coordinate system {OJ1d}, the second joint axis static coordinate system {OJ2s}, the second joint axis moving coordinate system {OJ2d}, the third joint axis static coordinate system {OJ3s}, the third joint axis moving coordinate system {OJ3d}, the fourth joint axis static coordinate system {OJ4s}, and the fourth joint axis moving coordinate system {OJ4d}. The system comprises the following coordinate systems: the fifth joint axis static coordinate system {OJ5s}, the fifth joint axis moving coordinate system {OJ5d}, the grinding wheel tool ideal coordinate system {OTi}, the grinding wheel tool coordinate system {OT}, and the workpiece coordinate system {OW}. The robot base coordinate system {OB} is located on the SCARA robot base, and its Z-axis coincides with the centerline of the J1 axis rotary motor. The origins of the first joint axis static coordinate system {OJ1s} and the first joint axis moving coordinate system {OJ1d} are located at the intersection of the centerline of the J1 axis rotary motor and the upper cover of the SCARA robot base. The origins of the second joint axis static coordinate system {OJ2s} and the second joint axis moving coordinate system {OJ2d} are located on the centerline of the J2 axis rotary motor, with the same height direction as {OJ1s}. The origins of the third joint axis static coordinate system {OJ3s} and the third joint axis moving coordinate system {OJ3d} are located on the centerline of the J3 axis linear motor, with the same height direction as {OJ1s}. The fourth joint axis... The origins of the static coordinate system {OJ4s} and the fourth joint axis moving coordinate system {OJ4d} are located on the centerline of the J4 axis rotary motor, with their height direction aligned with the workpiece mounting table; the origins of the fifth joint axis static coordinate system {OJ5s} and the fifth joint axis moving coordinate system {OJ5d} are located on the centerline of the J5 axis rotary motor; the origins of the grinding wheel tool ideal coordinate system {OTi} and the grinding wheel tool coordinate system {OT} are located on the grinding wheel spindle axis; the origin of the workpiece coordinate system {OW} is located on the workpiece.

[0125] S2, select the center of the circle on the side of the grinding wheel away from the spindle rotating motor as the control point P, and select the unit vector of the circle at control point P that is perpendicular to the grinding wheel as the control vector V.

[0126] Specifically, define the meaning of each variable in the G-code during the grinding process. For example... Figure 3 As shown, the center of the circle on the side of the grinding wheel furthest from the spindle rotary motor is selected as the control point P = [xyz 1]. T We select the unit vector perpendicular to the grinding wheel's circular surface at control point P as the control vector V = [ijk 0]. T The control point P has three axis components of x, y, and z in the workpiece coordinate system {OW}, and the control vector V has three axis components of i, j, and k in the workpiece coordinate system {OW}.

[0127] S3. Based on the transformation matrix between the coordinate systems, establish a kinematic model that considers machine tool errors, and combine the control point P and the control vector V with the kinematic model to establish an equation relationship.

[0128] In a specific embodiment, the machine tool error includes a first deviation and a second deviation. The first deviation is the deviation between the J5 axis rotation axis corresponding to the J5 axis rotary motor and its ideal installation position. The second deviation is the deviation between the spindle rotation axis corresponding to the main spindle rotary motor and its ideal installation position. vec1 is a unit vector coinciding with the J5 axis rotation axis. OB vec1 = [nx1 ny1 nz1 0] T vec2 is a unit vector coinciding with the axis of rotation of the principal axis. OJ5d vec2 = [nx2 ny2nz2 0] T .

[0129] Specifically, machine tool error refers to the deviation between the J5 axis rotation axis and the spindle rotation axis and their ideal installation position after the automated grinding machine has been assembled. Figure 2 As shown, vec1 is a unit vector coinciding with the rotation axis of J5, ideally within the robot's base coordinate system {OB}. OB vec1' = [0 1 0 0] T However, after the equipment was assembled, OB vec1 cannot perfectly match the ideal state, therefore let OB vec1 = [nx1 ny1 nz1 0] T Similarly, vec2 is a unit vector coinciding with the axis of rotation of the main axis, ideally within the fifth joint axis moving coordinate system {OJ5d}. OJ5d vec2' = [1 0 0 0] T In reality OJ5d vec2 also cannot coincide with its ideal state, therefore let OJ5d vec2 = [nx2 ny2 nz2 0] T .

[0130] Based on the transformation matrices of the above coordinate systems, let the matrix operators be as follows:

[0131]

[0132]

[0133]

[0134] Where trans(a,b,c) is the translation matrix, rotx(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the x-axis, roty(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the y-axis, rotz(θ) is the rotation matrix of rotating counterclockwise by an angle θ around the z-axis, and rotvec(nx,ny,nz,θ) is the rotation matrix of rotating counterclockwise by an angle θ around any unit vector vec=[nx,ny,nz] in space.

[0135] Establish the transformation matrix between the two adjacent coordinate systems in sequence. This represents the transformation matrix, specifically the transformation matrix from the superscript coordinate system to the subscript coordinate system. Based on the machine tool structure and matrix operators, the following calculation formula is obtained:

[0136]

[0137]

[0138]

[0139]

[0140]

[0141]

[0142]

[0143]

[0144]

[0145]

[0146]

[0147]

[0148]

[0149] Where L1 is the height of the SCARA robot base, L2 is the arm length of the proximal articulated arm of the SCARA robot, L3 is the arm length of the distal articulated arm of the SCARA robot, L4 is the height difference between the workpiece clamping pallet and the upper surface of the SCARA robot base, L5, L6, and L7 are the distances in the Y, X, and Z directions between the center of the J5 axis rotation axis end face and the origin {OB}, respectively; L8 and L9 are the distances in the X and Y directions between the center of the grinding wheel and the center of the J5 axis rotation axis end face.

[0150] θ1, θ2, θ4, and θ5 are the rotation angles corresponding to the J1-axis rotary motor, J2-axis rotary motor, J4-axis rotary motor, and J5-axis rotary motor, respectively; s3 is the displacement corresponding to the J3-axis linear motor; trans(e x ,e y ,e z )*rotz(e c1 )*rotx(e a )*rotz(e c2 (This refers to the workpiece installation error) The ZXZ expression, e x e y e z , where e represents the translation error in three directions. c1 e a e c2 The rotational error is in three directions.

[0151] in, Inside Compared to the ideal state OJ5d vec2' =

[1000] T The included angle can be calculated using the following formula: OJ5d vec v =[nx v ,ny v ,nz v [0] means simultaneously with OJ5d vec2 = [nx2 ny2 nz2 0] T and OJ5d vec2' =

[1000] T A perpendicular unit vector, defined by its specific direction as perpendicular to... OJ5d vec2× OJ5d vec2' is in the same direction (× is the cross product symbol for vectors), and can be calculated as follows:

[0152] Specifically, the embodiments of this application establish and The transformation matrix used is a transformation matrix that rotates in any direction in space. This method introduces the true direction vectors of the J5 axis rotation axis and the spindle rotation axis into the kinematic model, thereby achieving machine tool error compensation. In establishing... To avoid loss of generality, a combination of translation and Z×Z rotation matrices is used to represent this. This method can represent the transformation relationship between any two coordinate systems, meaning that the workpiece installation error can occur in any direction (3 translations plus 3 rotations). By introducing the workpiece installation error into the kinematic model in this way, the workpiece installation error can be compensated.

[0153] In a specific embodiment, step S3 specifically includes:

[0154] Based on the coordinate system transformation relationship, a first route and a second route are established. The first route starts from the robot's base coordinate system {OB} and moves sequentially along each joint of the SCARA system, in the following order: robot base coordinate system {OB}, first joint axis static coordinate system {OJ1s}, first joint axis moving coordinate system {OJ1d}, second joint axis static coordinate system {OJ2s}, second joint axis moving coordinate system {OJ2d}, third joint axis static coordinate system {OJ3s}, and third joint axis moving coordinate system {OJ3}. The first path starts from the robot base coordinate system {OB} and moves along the grinding wheel assembly direction, in the following order: robot base coordinate system {OB}, fifth joint axis static coordinate system {OJ5s}, fifth joint axis dynamic coordinate system {OJ5d}, virtual fifth joint axis static coordinate system {OJ5s}, grinding wheel tool ideal coordinate system {OTi}, and grinding wheel tool coordinate system {OT}.

[0155] The control point P and control vector V are respectively in the workpiece coordinate system {OW} W P = [xyz 1] T , W V = [ijk 0] T In the grinding wheel tool coordinate system {OT}, respectively T P = [0 0 0 1] T , T V = [1 0 0 0] T Control point P and control vector V are transformed to the robot's base coordinate system {OB} via the first and second routes respectively. Since control point P and control vector V coincide in the robot's base coordinate system {OB}, the following equation is established:

[0156]

[0157] Among them, θ1, θ2, s3, θ4, and θ5 are all unknowns to be solved.

[0158] Specifically, such as Figure 4As shown, there are two routes for coordinate system transformation. The first route starts from the robot base coordinate system {OB} and moves sequentially along each joint of the SCARA system, in the following order: ① Robot base coordinate system {OB}, ② First joint axis static coordinate system {OJ1s}, ③ First joint axis moving coordinate system {OJ1d}, ④ Second joint axis static coordinate system {OJ2s}, ⑤ Second joint axis moving coordinate system {OJ2d}, ⑥ Third joint axis static coordinate system {OJ3s}, ⑦ Third joint axis moving coordinate system {OJ3d}, ⑧ Fourth joint axis static coordinate system {OJ4s}, ⑨ Fourth joint axis moving coordinate system {OJ4d}, ⑩ Workpiece coordinate system {OW}. The second step also starts from the robot's base coordinate system {OB} and moves along the grinding wheel assembly direction, in the following order: ① Robot base coordinate system {OB}, ② Fifth joint axis static coordinate system {OJ5s}, ③ Fifth joint axis moving coordinate system {OJ5d}, ④ Virtual fifth joint axis static coordinate system {OJ5s}, ⑤ Grinding wheel tool ideal coordinate system {OTi}, ⑥ Grinding wheel tool coordinate system {OT}. According to step S2, the control point P and control vector V in the workpiece coordinate system {OW} are respectively... W P = [xyz 1] T , W V = [ijk 0] T In the grinding wheel tool coordinate system {OT}, respectively T P = [0 0 0 1] T , T V = [1 0 0 0] T The control point P and the control vector V are transformed into the robot base coordinate system {OB} through two transformation paths. Since the control point P and the control vector V coincide in the robot base coordinate system {OB}, equation (1) can be established.

[0159] S4, based on the equality relationship, solve the inverse kinematics to obtain θ1, θ2, s3, θ4, θ5, where θ n s3 is the rotation angle corresponding to the Jn axis rotary motor in the machine tool structure, where n = 1, 2, 4, 5, and s3 is the displacement corresponding to the J3 axis linear motor.

[0160] Specifically, the process of solving for the five unknowns θ1, θ2, θ4, θ5, and s3 using equations is called inversion. In the process of inversion, all other parameters are known quantities.

[0161] In a specific embodiment, step S4 specifically includes:

[0162] By combining the third and fourth terms in equation (1), we can construct an equation regarding... B The equation for V, when expanded, yields a 4x1 vector equation system. The third term in this system is:

[0163]

[0164] Rearranging equation (2) into the form A*sin(θ5)+B*cos(θ5)+C=0, we get:

[0165]

[0166] Compare A*sin(θ5)+B*cos(θ5)+C=0 with sin(θ5) 2 +cos(θ5) 2 =1, solve the system of equations simultaneously to find θ5. Two solutions can be obtained through calculation. Solution 1:

[0167]

[0168] Solution 2:

[0169]

[0170] Based on the actual structure of the machine tool, solution one is discarded, and solution two is retained;

[0171] After obtaining θ5, Since it is a known matrix, and because All are known matrices, and can be obtained from equation (1), etc. and work out B P and B V, represented by symbols: B P = [ B x B y B z 1] T , B V = [ B i B j B k 1] T ;in, B x、 B y、 B z represents the three-axis components of point P in the robot's base coordinate system {OB}. B i、 B j、 B k represents the three-axis components of the V vector in the robot's base coordinate system {OB};

[0172] make Rearranging equation (1) yields:

[0173]

[0174] because Given a matrix, let Calculate J4d P andJ4d V, represented by symbols: J4d P = [ J4d x J4d y J4d z 1] T , J4d V = [ J4d i J4d j J4d k 1] T ;in, J4d x、 J4d y、 J4d z represents the three-axis components of the control point P in the OJ4d coordinate system. J4d i、 J4d j、 J4d k represents the three-axis components of the control vector V in the OJ4d coordinate system;

[0175] Further rearranging equation (6), we get:

[0176]

[0177] Solve Based on the structure and kinematics of the SCARA robot, it can be known that... It is a translation and rotation transformation matrix, and its rotation part can only rotate around the Z-axis, so let's assume... Will B P, B V. J4d P and J4d Substituting the symbolic representation of V into equation (7) and expanding it, and removing the unsigned equations, we obtain the following equation relationship:

[0178]

[0179] First, calculate θ using the fourth and fifth equations in equation (8). OJ4d :

[0180]

[0181] Then θ OJ4d Substitute x into the first, second, and third equations in equation (8) to calculate x. OJ4d y OJ4d z OJ4d :

[0182]

[0183] according to B P OJ4d =[x OJ4d y OJ4d z OJ4d 1] Tand θ OJ4d The solution for the unknowns θ1, θ2, s3, and θ4 is given by the following formula:

[0184]

[0185] The value of sin(θ2) is determined to be either a positive or negative solution based on the structure of the grinding wheel assembly and the SCARA robot.

[0186] Specifically, according to B P OJ4d =[x OJ4d y OJ4d z OJ4d 1] T and θ OJ4d The part about finding the solutions for the unknowns θ1, θ2, s3, and θ4 is the classic inverse formula for SCARA robots, and the specific solution process will not be elaborated here. In equation (11), two sets of solutions can be obtained based on the sign of sin(θ2). One of these solutions can be fixed according to the structure of the grinding wheel assembly and the robot. Figure 2 For example, if the grinding wheel is located in the negative X-axis and positive Y-axis directions of the SCARA robot base, and the distal articulated arm of the SCARA robot rotates counterclockwise relative to the proximal articulated arm, then sin(θ2) should be solved using a positive solution.

[0187] After solving for the unknowns θ1, θ2, s3, θ4 and θ5 according to the above steps, the control system can send position commands to each axis motor. After the motors complete the execution, the workpiece can reach the specified position and posture that meets the processing code.

[0188] In the above solution process, OB vec1 = [nx1 ny1 nz1 0] T and OJ5d vec2 = [nx2 ny2 nz2 0] T It is considered a known quantity, which can be obtained by measuring the actual machine tool and calculating. OB vec1 = [nx1 ny1 nz1 0] T and OB vec2 = [nx2ny2nz20] T The measurement requires a laser tracking measuring instrument 16 and a target ball 17, such as... Figure 5As shown, a laser tracking measuring instrument 16 is installed next to the automated grinding machine and fixed with a tripod. After fixing, a measurement coordinate system {OC} is established on the laser tracking measuring instrument 16. The measurement coordinate system {OC} is fixedly connected to the laser tracking measuring instrument 16, and the coordinate values ​​output by the laser tracking measuring instrument 16 are all described based on the measurement coordinate system {OC}. Target balls 17 are respectively installed on the distal articulated arm, grinding wheel connecting arm, and grinding wheel of the SCARA robot.

[0189] In a specific embodiment, OB vec1 = [nx1 ny1 nz1 0] T and OJ5d vec2 = [nx2 ny2 nz2 0] T The calculation process is as follows:

[0190] The coordinates of the target ball mounted on the distal articulated arm of the SCARA robot are obtained using a laser tracking measurement device. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0191] The rotation angle of the J1 axis is controlled by the control system, and measured sequentially. Using the least squares method A first circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the first circular surface is denoted as Mvec1 = [mx1 my1 mz1 0]. T ;

[0192] The coordinate position of the target ball mounted on the grinding wheel connecting arm is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0193] The rotation angle of the J5 axis is controlled by the control system, and measured sequentially. Using the least squares method A second circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the second circular surface is denoted as Mvec2 = [mx2 my2 mz2 0]. T ;

[0194] The coordinate position of the target ball mounted on the grinding wheel is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument;

[0195] The spindle rotation angle is controlled by the control system, and the following measurements are taken sequentially. Using the least squares method A third circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the third circular surface is denoted as Mvec3 = [mx3 my3 mz3 0]. T ;

[0196] First calculate Mvec1 = [mx1 my1 mz1 0] T and [0 0 1 0] T The included angle ω1 = arccos(mx1);

[0197] Then calculate Mvec1 = [mx1 my1 mz1 0] T and [0 0 1 0] T The vertical unit vector Mvecper1;

[0198] The specific direction of Mvecper1 is defined as Mvec1 × [0 0 1 0]. T In the same direction, calculations show that:

[0199]

[0200] Create a sequence starting from Mvec1 = [mx1 my1 mz1 0] T To [0 0 1 0] T Transformation matrix:

[0201]

[0202] but:

[0203] First calculate Mvec2 = [mx2 my2 mz2 0] T and [0 1 0 0] T The included angle between them is ω2 = arccos(my2);

[0204] Then calculate Mvec2 = [mx2 my2 mz2 0] T and [0 1 0 0] T The vertical unit vector Mvecper2;

[0205] The specific direction of Mvecper2 is defined as Mvec2 × [0 1 0 0]. T In the same direction, calculations show that:

[0206]

[0207] Create a sequence starting from Mvec2 = [mx2 my2 mz2 0] T To [0 1 0 0] T Transformation matrix:

[0208]

[0209] but:

[0210] In the above solution process, It is considered a known matrix, but in practical applications, it needs to be measured to obtain its specific values.

[0211] In a specific embodiment, The calculation process is as follows:

[0212] After the workpiece is clamped and installed, adjust the positions of each motor so that the center of the grinding wheel touches the marked point on the workpiece. W P, and establish an equation relationship:

[0213]

[0214] In this context, θ1, θ2, θ4, θ5, and s3 are all known quantities during the contact process. T P, W P are all known quantities and can be calculated.

[0215] Rearranging equation (12) yields:

[0216]

[0217] in,

[0218] Repeat the above steps to select four non-coplanar marker points on the workpiece. W P1, W P2, W P3 and W P4 establishes four equations, which can be solved simultaneously as follows:

[0219]

[0220] remember W P n =[ W x n , W y n , W z n ,1] T , J4d P n =[ J4d x n , J4d y n , J4d zn ,1] T , Substituting into equation (14), discarding the unsigned equation, and rearranging, we get:

[0221]

[0222] Equation (15) consists of 12 linearly independent equations and 12 unknowns t. 11 t 12 t 13 t 14 t 21 t 22 t 23 t 24 t 31 t 32 t 33 and t 34 Equation (15) can be solved using Gaussian elimination, and the result can be obtained using t. nn Expressed

[0223] Specifically, after the workpiece is installed, calculations and data are obtained via point-to-point contact. like Figure 6 As shown, after completing the workpiece clamping and installation, a system can be established. Adjust the positions of each motor so that the center of the grinding wheel touches the marked point on the workpiece. W P, completing the touch means they coincide in the robot's base coordinate system {OB}, therefore the equation (12) can be established. Finally, t nn Expressed Convert to This form of expression is acceptable. During the conversion process, the least squares method can be used to control the conversion error.

[0224] Further reference Figure 7 As an implementation of the methods shown in the above figures, this application provides an embodiment of an error measurement and compensation device for an automated grinding machine, which is similar to... Figure 1 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.

[0225] This application provides an error measurement and compensation device for an automated grinding machine, comprising:

[0226] The coordinate establishment module 1 is configured to establish the linkage coordinate system based on the machine tool structure of the automated grinding machine, and to establish the transformation matrix between the coordinate systems. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly, and the grinding wheel assembly includes a grinding wheel and a spindle rotary motor.

[0227] Variable definition module 2 is configured to select the center of the circle on the side of the grinding wheel away from the spindle rotary motor as the control point P, and select the unit vector of the circle at control point P that is perpendicular to the grinding wheel as the control vector V;

[0228] Equation Establishment Module 3 is configured to establish a kinematic model considering machine tool errors based on the transformation matrix between each coordinate system, and to establish an equation relationship by combining the control point P and the control vector V with the kinematic model.

[0229] Solver module 4 is configured to solve the inverse kinematics based on equality relationships, obtaining θ1, θ2, s3, θ4, and θ5, where θ n s3 is the rotation angle corresponding to the Jn axis rotary motor in the machine tool structure, where n = 1, 2, 4, 5, and s3 is the displacement corresponding to the J3 axis linear motor.

[0230] The above description is merely a preferred embodiment of this application and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described inventive concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features with similar functions disclosed in this application.

Claims

1. A method for error measurement and compensation in an automated grinding machine, characterized in that, Includes the following steps: S1. Based on the machine tool structure of the automated grinding machine, establish its linkage coordinate system and establish the transformation matrix between each coordinate system. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly. The SCARA robot includes a SCARA robot base, a J1 axis rotary motor, a proximal articulated arm, a J2 axis rotary motor, a distal articulated arm, a J3 axis linear motor, a workpiece clamping tray, and a J4 axis rotary motor. The grinding wheel assembly includes a grinding wheel, a grinding wheel connecting arm, a J5 axis rotary motor, and a spindle rotary motor. The grinding wheel connecting arm is located between the J5 axis rotary motor and the spindle rotary motor. S2, Select the center of the circle on the side of the grinding wheel away from the spindle rotary motor as the control point. Select the control point The unit vector perpendicular to the circular surface of the grinding wheel is the control vector. ; S3, establish a kinematic model considering machine tool errors based on the transformation matrix between the coordinate systems, and then define the control points. and control vector Establish equations based on the aforementioned kinematic model; S4, based on the aforementioned equation, solve for the inverse kinematics to obtain... , , , , ,in, The rotation angle corresponding to the Jg axis rotary motor in the machine tool structure is given by g = 1, 2, 4, 5. The displacement corresponding to the J3 axis linear motor is shown. The J1 axis rotary motor is mounted on the SCARA robot base. The proximal articulated arm is mounted between the J1 axis rotary motor and the J2 axis rotary motor. The distal articulated arm is mounted between the J2 axis rotary motor and the J3 axis linear motor. The J4 axis rotary motor controls the rotation of the workpiece clamping tray.

2. The error measurement and compensation method for an automated grinding machine according to claim 1, characterized in that, The control point In the workpiece coordinate system {OW}, the three axis components are x, y, and z, respectively, and the control vector... In the workpiece coordinate system {OW}, the three-axis components are i, j, and k, respectively. The machine tool error includes a first deviation and a second deviation. The first deviation is the deviation between the J5 axis rotation axis corresponding to the J5 axis rotary motor and its ideal installation position. The second deviation is the deviation between the spindle rotation axis corresponding to the spindle rotary motor and its ideal installation position. vec1 is a unit vector coinciding with the J5 axis rotation axis. Let... vec2 is a unit vector coinciding with the axis of rotation of the principal axis. .

3. The error measurement and compensation method for an automated grinding machine according to claim 2, characterized in that, The SCARA robot includes a SCARA robot base, a J1-axis rotary motor, a proximal articulated arm, a J2-axis rotary motor, a distal articulated arm, a J3-axis linear motor, a workpiece clamping tray, and a J4-axis rotary motor. The linkage coordinate system includes the robot base coordinate system {OB}, the first joint axis static coordinate system {OJ1s}, the first joint axis moving coordinate system {OJ1d}, the second joint axis static coordinate system {OJ2s}, the second joint axis moving coordinate system {OJ2d}, the third joint axis static coordinate system {OJ3s}, and the third joint axis... The system comprises the following coordinate systems: joint axis moving coordinate system {OJ3d}, fourth joint axis static coordinate system {OJ4s}, fourth joint axis moving coordinate system {OJ4d}, fifth joint axis static coordinate system {OJ5s}, fifth joint axis moving coordinate system {OJ5d}, grinding wheel tool ideal coordinate system {OTi}, grinding wheel tool coordinate system {OT}, and workpiece coordinate system {OW}. The robot base coordinate system {OB} is located on the SCARA robot base, and its Z-axis coincides with the centerline of the J1 axis rotary motor. The first joint axis static coordinate system {OJ1s}... The origin of the first joint axis moving coordinate system {OJ1d} is located at the intersection of the centerline of the J1 axis rotary motor and the upper cover of the SCARA robot base; the origin of the second joint axis static coordinate system {OJ2s} and the second joint axis moving coordinate system {OJ2d} is located on the centerline of the J2 axis rotary motor, with the height direction the same as {OJ1s}; the origin of the third joint axis static coordinate system {OJ3s} and the third joint axis moving coordinate system {OJ3d} is located on the centerline of the J3 axis linear motor, with the height direction {OJ3s}. Same as {OJ1s}; the origins of the fourth joint axis static coordinate system {OJ4s} and the fourth joint axis moving coordinate system {OJ4d} are located on the center line of the J4 axis rotary motor, with the height direction the same as the workpiece mounting table; the origins of the fifth joint axis static coordinate system {OJ5s} and the fifth joint axis moving coordinate system {OJ5d} are on the center line of the J5 axis rotary motor; the origins of the grinding wheel tool ideal coordinate system {OTi} and the grinding wheel tool coordinate system {OT} are on the grinding wheel spindle axis; the origin of the workpiece coordinate system {OW} is on the workpiece; Let the matrix operators be as follows: ; ; ; ; ; in, It is a translation matrix. Rotation counterclockwise around the x-axis The rotation matrix of the angle. To rotate counterclockwise around the y-axis The rotation matrix of the angle. Rotation counterclockwise around the z-axis The rotation matrix of the angle. Let be any unit vector in space Rotate counterclockwise The rotation matrix of the angle; Establish the transformation matrix between the two adjacent coordinate systems in sequence. , , , , , , , , , , , , Based on the machine tool structure and matrix operators, the following calculation formula is obtained: ; ; ; ; ; ; ; ; ; ; ; ; ; in, The height of the SCARA robot base. This refers to the arm length of the proximal articulated arm of the SCARA robot. This refers to the arm length of the distal articulated arm of the SCARA robot. The height difference between the workpiece clamping pallet and the upper surface of the SCARA robot base. , , These represent the distances in the Y, X, and Z directions between the center of the end face of the J5 axis rotation axis and the origin of the robot's base coordinate system {OB}. , These are the distances in the X and Y directions from the center of the grinding wheel to the center of the end face of the J5 axis rotating shaft. , , , These represent the rotation angles corresponding to the J1-axis rotary motor, J2-axis rotary motor, J4-axis rotary motor, and J5-axis rotary motor, respectively. This represents the displacement corresponding to the J3 axis linear motor. For workpiece installation error The ZXZ Euler angle representation, in which , , These represent the translational errors of the workpiece in the X, Y, and Z directions, respectively. , , These represent the rotational errors around the Z-axis, X-axis, and Z-axis, respectively. in, Inside for Compared to the ideal state The included angle can be calculated using the following formula: ; To be simultaneously with and A perpendicular unit vector, defined by its specific direction as perpendicular to... In the same direction, calculations show that: .

4. The error measurement and compensation method for an automated grinding machine according to claim 3, characterized in that, Step S3 specifically includes: Based on the coordinate system transformation relationship, a first route and a second route are established. The first route starts from the robot base coordinate system {OB} and moves sequentially along each joint of the SCARA, in the following order: robot base coordinate system {OB}, first joint axis static coordinate system {OJ1s}, first joint axis moving coordinate system {OJ1d}, second joint axis static coordinate system {OJ2s}, second joint axis moving coordinate system {OJ2d}, third joint axis static coordinate system {OJ3s}, third joint axis moving coordinate system {OJ3d}, fourth joint axis static coordinate system {OJ4s}, fourth joint axis moving coordinate system {OJ4d}, and workpiece coordinate system {OW}. The second route starts from the robot base coordinate system {OB} and moves along the grinding wheel assembly direction, in the following order: robot base coordinate system {OB}, fifth joint axis static coordinate system {OJ5s}, fifth joint axis moving coordinate system {OJ5d}, grinding wheel tool ideal coordinate system {OTi}, and grinding wheel tool coordinate system {OT}. The control point and control vector In the workpiece coordinate system {OW}, respectively , In the grinding wheel tool coordinate system {OT}, respectively , The control point and control vector After transforming to the robot's base coordinate system {OB} via the first and second routes respectively, the control points are used... and control vector Under the robot's base coordinate system {OB}, their coordinates coincide, and the following equations are established: (1) in, , , , , All of these are unknowns to be solved.

5. The error measurement and compensation method for an automated grinding machine according to claim 4, characterized in that, Step S4 specifically includes: By combining the third and fourth terms in equation (1), we can construct an equation about... The equation, when expanded, yields a 4 The third term in the system of vector equations is: Rearrange equation (2) as follows From the form, we can obtain: Will and Solve the simultaneous equations. Two solutions can be obtained through calculation. Solution 1: Solution 2: Based on the actual structure of the machine tool, solution one is discarded, and solution two is retained; get back, Since it is a known matrix, and because , , All are known matrices, and can be obtained from equation (1), etc. and work out and Expressed using symbols: , ;in, , , for The three-axis components of the point in the robot's base coordinate system {OB} , , for The three-axis components of a vector in the robot's base coordinate system {OB}; make Rearranging equation (1) yields: because Given a matrix, let , Calculate and Expressed using symbols: , ;in, , , Control points The three-axis components in the fourth joint axis moving coordinate system {OJ4d} , , For control vector The three-axis components in the fourth joint axis moving coordinate system {OJ4d}; Further rearranging equation (6), we get: Solve Based on the structure and kinematic relationship of the SCARA robot, it can be known that... It is the translation and rotation transformation matrix from the fourth joint axis moving coordinate system {OJ4d} to the robot base coordinate system {OB}, and its rotating part can only rotate around the Z-axis, so let's assume... ,Will , , , and Substituting the symbolic representation into equation (7) and expanding it, and removing the unsigned equations, we obtain the following equation relationship: First, use the fourth and fifth equations in equation (8) to calculate : Then Substitute into the first, second, and third equations of equation (8) to calculate , , : according to and Find the unknown quantity , , , The solution, the formula is as follows: in, The solution is determined as positive or negative based on the structure of the grinding wheel assembly and the SCARA robot.

6. The error measurement and compensation method for an automated grinding machine according to claim 5, characterized in that, The and The calculation process is as follows: The coordinates of the target ball mounted on the distal articulated arm of the SCARA robot are obtained using a laser tracking measurement device. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument; The rotation angle of the J1 axis is controlled by the control system, and measured sequentially. , ... Use the least squares method to , , ... A first circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the first circular surface is denoted as . ; The coordinate position of the target ball mounted on the grinding wheel connecting arm is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument; The rotation angle of the J5 axis is controlled by the control system, and measured sequentially. , ... Use the least squares method to , , ... A second circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the second circular surface is denoted as . ; The coordinate position of the target ball mounted on the grinding wheel is obtained using a laser tracking measuring instrument. The coordinate position of the target ball is obtained based on the measurement coordinate system {OC} established on the laser tracking measuring instrument; The spindle rotation angle is controlled by the control system, and the following measurements are taken sequentially. , ... Use the least squares method to , , ... A third circular surface is fitted in the measurement coordinate system {OC}, and the unit normal vector of the third circular surface is denoted as . ; First calculate and The angle between ; Recalculation and and Vertical unit vector ; Regulation The specific direction is with In the same direction, calculations show that: ; Establish from arrive Transformation matrix: ; but: ; First calculate and The angle between ; Recalculation and and Vertical unit vector ; Regulation The specific direction is with In the same direction, calculations show that: ; Establish from arrive Transformation matrix: ; but: .

7. The error measurement and compensation method for an automated grinding machine according to claim 5, characterized in that, The The calculation process is as follows: After the workpiece is clamped and installed, adjust the positions of each motor so that the center of the grinding wheel touches the marked point on the workpiece. And establish an equation relationship: During the touch , , , , All are known quantities, therefore , , , , , , , , , , , , , All are known quantities and can be calculated. , ; Rearranging equation (12) yields: in, ; Repeat the above steps to select four non-coplanar marker points on the workpiece. , , and A total of four equations are established, which are solved simultaneously as follows: remember , , Substituting into equation (14), discarding the unsigned equation, and rearranging, we get: Equation (15) consists of 12 linearly independent equations and 12 unknowns. , , , , , , , , , , and Equation (15) can be solved using Gaussian elimination to obtain the result. Expressed .

8. An error measurement and compensation device for an automated grinding machine, characterized in that, include: The coordinate establishment module is configured to establish the linkage coordinate system based on the machine tool structure of the automated grinding machine, and to establish the transformation matrix between the coordinate systems. The machine tool structure of the automated grinding machine includes a SCARA robot and a grinding wheel assembly. The SCARA robot includes a SCARA robot base, a J1 axis rotary motor, a proximal articulated arm, a J2 axis rotary motor, a distal articulated arm, a J3 axis linear motor, a workpiece clamping tray, and a J4 axis rotary motor. The grinding wheel assembly includes a grinding wheel, a grinding wheel connecting arm, a J5 axis rotary motor, and a spindle rotary motor. The grinding wheel connecting arm is located between the J5 axis rotary motor and the spindle rotary motor. The variable definition module is configured to select the center of a circle on the side of the grinding wheel furthest from the spindle rotary motor as the control point. Select the control point The unit vector perpendicular to the circular surface of the grinding wheel is the control vector. ; The equation establishment module is configured to establish a kinematic model considering machine tool errors based on the transformation matrix between the coordinate systems, and to establish the control points. and control vector Establish equations based on the aforementioned kinematic model; The solution module is configured to solve for the inverse kinematics based on the aforementioned equation, and obtain... , , , , ,in, The rotation angle corresponding to the Jg axis rotary motor in the machine tool structure is given by g = 1, 2, 4, 5. The displacement corresponding to the J3 axis linear motor is shown. The J1 axis rotary motor is mounted on the SCARA robot base. The proximal articulated arm is mounted between the J1 axis rotary motor and the J2 axis rotary motor. The distal articulated arm is mounted between the J2 axis rotary motor and the J3 axis linear motor. The J4 axis rotary motor controls the rotation of the workpiece clamping tray.

9. An electronic device, comprising: One or more processors; Storage device for storing one or more programs. When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1-7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-7.