A distributed virtual-real twin robot posture error online compensation system

Through the distributed virtual-reality twin robot posture error online compensation system, combined with external measurement equipment and model calculation, the robot posture error is acquired and compensated in real time, solving the problems of low efficiency and large errors in the existing technology and achieving high-precision error compensation effect.

CN116834009BActive Publication Date: 2025-09-23HUAZHONG UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310896593.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-19
Publication Date
2025-09-23
Estimated Expiration
2043-07-19

AI Technical Summary

Technical Problem

The existing technology has low efficiency, large error and low reliability in robot posture error compensation, making it difficult to achieve high-precision applications, especially in complex tasks.

Method used

The distributed virtual-real twin robot posture error online compensation system is adopted. Through the combination of virtual CNC interpolation Cartesian axes, virtual posture compensation Cartesian axes and actual joint angle axes, combined with external measurement equipment and model calculation, the robot posture error is acquired and compensated in real time.

Benefits of technology

It achieves high-precision error compensation during robot tasks, improves the efficiency and reliability of compensation, and can compensate errors in real time at the interpolation level, making it suitable for complex tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116834009B_ABST
    Figure CN116834009B_ABST
Patent Text Reader

Abstract

The present invention discloses a distributed virtual-real twin robot posture error online compensation system, comprising: a virtual-real axis group, a first computing medium, a second computing medium, and a driver; the virtual-real axis group comprises a virtual numerical control interpolation Cartesian axis, a virtual posture compensation Cartesian axis, and an actual joint angle axis, wherein the actual joint angle axis is connected to the robot joint motor via a driver; the first computing medium is used to obtain the compensation amount of the virtual posture compensation Cartesian axis; the second computing medium is used to interpolate the G code, superimpose the compensation amount with the theoretical posture of the virtual numerical control interpolation Cartesian axis to obtain the actual posture, perform inverse kinematics calculation on the actual posture to obtain the actual joint angle of the actual joint angle axis, and transmit the actual joint angle to the driver; the driver is used to drive the robot joint motor using the actual joint angle. The present invention can achieve high-precision error compensation with high compensation reliability and high efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of robot error compensation, and more specifically, relates to a distributed virtual-real twin robot posture error online compensation system. Background Art

[0002] Robot posture error is an inevitable problem faced by robot systems, which seriously restricts the high-precision application of robots. Carrying out robot posture error compensation is an important means to improve robot precision and support high-quality application of robots.

[0003] Existing inventions have disclosed numerous methods for posture error compensation, but most of them focus on offline compensation. For example, these methods use various methods to determine the relationship between the robot's state (joint position and spatial position) and the error, and then utilize feedforward compensation to directly modify the target point during offline programming to achieve error compensation. These methods differ significantly in the steps involved in obtaining the relationship between the robot's state and the error. However, these methods are inefficient and difficult to apply to complex robotic tasks.

[0004] Furthermore, offline compensation focuses on macro-position compensation. Its logic is to modify the theoretical point pose corresponding to the G-code during the motion planning phase to improve the robot's operating accuracy. However, since this method only compensates at the macro-position scale and fails to account for the microscopic conditions between adjacent positions, its effectiveness is limited. This compensation method assumes that the errors between adjacent positions satisfy a linear relationship, which is inconsistent with the actual robot's error variations. Consequently, the compensated robot still has large errors, and the compensation reliability is low.

[0005] It can be seen that the existing technology has technical problems of low efficiency, large error and low reliability. Summary of the Invention

[0006] In response to the above defects or improvement needs of the existing technology, the present invention provides a distributed virtual-real twin robot posture error online compensation method and system, thereby solving the technical problems of low efficiency, large error and low reliability in the existing technology.

[0007] To achieve the above-mentioned object, according to one aspect of the present invention, a distributed virtual-real twin robot posture error online compensation system is provided, comprising: a virtual-real axis group, a first computing medium, a second computing medium, and a driver;

[0008] The virtual and real axis group includes a virtual CNC interpolation Cartesian axis, a virtual posture compensation Cartesian axis and an actual joint angle axis, and the actual joint angle axis is connected to the robot joint motor through a driver;

[0009] The first computing medium is used to obtain the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment and transmit it to the second computing medium, and the time difference between two adjacent compensation moments is the compensation period T2;

[0010] The second computing medium is used to interpolate the G code corresponding to the robot's motion trajectory in Cartesian space to obtain the theoretical position and posture of the virtual CNC interpolated Cartesian axis at each interpolation time t. When aT2≤≤t<(a+1)T2, the compensation amount is the compensation amount at the aT2 compensation time. The compensation amount at the aT2 compensation time is superimposed with the theoretical position and posture of the virtual CNC interpolated Cartesian axis at each interpolation time within aT2≤t<(a+1)T2 to obtain the actual position and posture at each interpolation time within aT2≤t<(a+1)T2. Inverse kinematics calculation is performed on the actual position and posture to obtain the actual joint angle of the actual joint angle axis, and the actual joint angle is transmitted to the driver.

[0011] The driver is used to drive the robot joint motor to move using the actual joint angle;

[0012] Wherein, T2=nT1, n represents the ratio of the compensation period T2 to the interpolation period T1, the time difference between two adjacent interpolation moments is the interpolation period T1, n is an integer ≥1, and t is an integer ≥0.

[0013] The interpolation period in the present invention reflects the speed of interpolation. For example, the interpolation period is 1 ms.

[0014] Furthermore, the first computing medium is used to measure the robot posture using an external measuring device at each compensation moment, and use the difference between the robot posture measured at each compensation moment and the posture recorded by the robot internal controller at the corresponding compensation moment as the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

[0015] The external measurement device is a laser tracker, a binocular camera or a laser displacement sensor. The external measurement device can also be other devices that can measure the position and posture of the robot.

[0016] The laser tracker can measure the absolute position of the reflective object fixed on the robot in space with high precision, and compare it with the theoretical position to obtain the corresponding error. It has high precision and fast error acquisition speed.

[0017] The binocular camera obtains the robot's spatial position by measuring the coded labels posted on the robot, and its accuracy is slightly lower than that of the laser tracker.

[0018] Laser displacement sensors can only measure relative position in one direction and are often used for problems such as cutting depth measurement.

[0019] Furthermore, the first computing medium is used to calculate the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment using the model.

[0020] Furthermore, the first computing medium is used to calculate the robot posture at each compensation moment through forward kinematics using pre-identified robot kinematic parameters, and to use the difference between the robot posture calculated at each compensation moment and the posture recorded by the robot internal controller at the corresponding compensation moment as the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

[0021] Furthermore, the first computing medium is used to measure the external force applied to the robot using a dynamometer at each compensation moment, substitute the external force applied to the robot measured at each compensation moment into the force-induced error model, and obtain the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

[0022] Furthermore, the first computing medium is used to input the theoretical posture of the robot at each compensation moment into the prediction model, and use the prediction result of the prediction model as the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment;

[0023] The prediction model is a trained neural network or deep belief network. The pre-calculated theoretical robot posture and its corresponding posture error measurement value are used as training data. During training, the difference between the predicted error and the posture error measurement value is back-propagated to update the network parameters. The trained neural network or deep belief network is obtained by training until convergence.

[0024] Furthermore, the number of axes in the virtual posture compensation Cartesian axes ranges from 1 to 6.

[0025] Furthermore, the number of the actual joint angle axes is equal to the number of the robot joint motors, and the number of the virtual CNC interpolation Cartesian axes is six.

[0026] Furthermore, n is an integer ≥ T_all / T1;

[0027] Here, time and T_all = time required to obtain a compensation value + time required to transfer the compensation value to the second computing medium + time required to calculate the actual joint angle from the actual posture through inverse kinematics and send it to the driver + safety time. By adjusting the size of the safety time, T_all / T1 can be made into an integer.

[0028] Furthermore, the n is T_all / T1.

[0029] According to another aspect of the present invention, there is provided an electronic device, characterized in that it includes:

[0030] a memory having a computer program stored thereon;

[0031] A processor is used to execute the computer program in the memory to implement the processing steps of a distributed virtual-real twin robot posture error online compensation system.

[0032] In general, the above technical solutions conceived by the present invention can achieve the following beneficial effects compared with the prior art:

[0033] (1) The posture error online compensation system proposed by the present invention focuses on the microscopic state at the interpolation level during the robot's task execution, and designs corresponding distributed virtual-real twin axes to achieve the acquisition and compensation of errors at each moment of the robot task, thereby achieving high-precision error compensation effects and high compensation reliability. In addition, this method does not require any preparatory work before the robot executes the task, and only needs to execute the task directly according to the theoretical G code, so the compensation efficiency is higher. In the process of realizing online compensation, the present invention hopes to compensate for the error in real time at the interpolation cycle level, so a set of virtual-real twin axis groups is designed, including virtual CNC interpolation Cartesian axes, virtual posture compensation Cartesian axes and actual joint angle axes. The design of these axes cleverly associates the theoretical robot task (i.e., the G code corresponding to the robot's motion trajectory in Cartesian space), robot error and actual robot motion in the form of a virtual-real axis group. These axis groups each have their own functions and are used to refine the interpolation time of the robot task trajectory, obtain the compensation amount of the robot compensation cycle, and drive the actual joint movement after superimposing the compensation amount. Through the design of this virtual-real twin axis, the reliability of error compensation and the accurate correspondence of online compensation are fully guaranteed. The present invention proposes a distributed approach. On the one hand, it is the distribution of computing media. The acquisition of compensation amount and G code interpolation, error superposition, and inverse kinematics calculation of the joint angle corresponding to the actual posture are deployed on two media respectively, realizing the shielding of the computing medium and avoiding the time instability caused by the allocation of computing resources. In addition, the distribution is also manifested in the divide-and-conquer of the theoretical G code, compensation amount and actual movement and the unification based on time consistency, realizing the efficient and reliable online compensation of robot errors.

[0034] (2) The present invention proposes a variety of technical means for obtaining compensation, including external measurement and model calculation. External measurement requires the use of external measurement equipment, and the compensation obtained thereby is of high accuracy. According to different models, model calculation is divided into theoretical model calculation and intelligent algorithm prediction. Theoretical model calculation includes kinematic model and force-induced error model, which correspond to the robot's spatial motion and the robot's force-bearing tasks, respectively. Intelligent algorithm prediction can improve the efficiency of obtaining compensation while ensuring accuracy. The present invention has a variety of ways to obtain compensation, which shows that the compensation means of the present invention are flexible.

[0035] (3) In the present invention, the actual axis group not only participates in the calculation but also needs to be bound to the actual physical axis. Therefore, the number of axes in the actual joint angle axis is equal to the number of robot joint motors. The virtual CNC interpolation Cartesian axis and the virtual posture compensation Cartesian axis only participate in the calculation. The axis in the virtual CNC interpolation Cartesian axis is essentially the definition rule for the axis variable in the second operation medium. Because the virtual CNC interpolation Cartesian axis corresponds to the position and posture of the robot in the Cartesian space, the number is constant at six. The virtual posture compensation Cartesian axis is used for compensation. According to the different requirements of posture compensation, 1-6 parameters can be compensated. Therefore, the number of axes in the virtual posture compensation Cartesian axis ranges from 1 to 6. For example, when the number of axes in the virtual posture compensation Cartesian axis is 1, it specifically means that only one error component is compensated. Generally, during the groove processing process, it is necessary to compensate for the error of the robot along the z direction to ensure that the depth of the groove processing meets the preset requirements. At this time, the number of virtual compensation axes is 1. When the number of Cartesian axes for virtual pose compensation is three, only three error components are compensated. This is typically used in position or attitude adjustment tasks, such as robotic laser cutting, where only the position of the laser head in three spatial directions needs to be accurate. Therefore, only three virtual axes are needed to compensate for position errors along the x, y, and z directions to meet practical requirements. When the number of Cartesian axes for virtual pose compensation is six, all six robot error components need to be compensated. This is typically used in robotic surface machining and precision assembly. To ensure accurate tool position and orientation relative to the workpiece coordinate system, or to ensure accurate and collision-free assembly of two parts being assembled, it is necessary to account for all pose errors during robot motion. In this case, six virtual axes are needed to compensate for both position errors along the x, y, and z directions and attitude errors around the x, y, and z axes.

[0036] (4) The present invention further limits the ratio of the compensation period T2 to the interpolation period T1 to an integer ≥ T_all / T1. At this time, the time required to obtain a compensation amount, the time required to transfer the compensation amount to the second operating medium, the time required to calculate the actual joint angle after the actual posture is calculated through inverse kinematics and sent to the driver, and the safety time are fully considered, thereby ensuring the reliability and accuracy of online compensation. When n is T_all / T1, the minimum integer that meets the conditions is used as the compensation period. This provides a safety margin for fluctuations in the system motion time and ensures that the compensation period is strictly equidistant. On the other hand, the minimum integer indirectly ensures that the system is at the highest achievable frequency, ensuring the reliability and efficiency of posture compensation. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] Figure 11 is a schematic structural diagram of a distributed virtual-real twin robot posture error online compensation system provided by an embodiment of the present invention;

[0038] FIG2( a ) is a schematic diagram showing the positions of a 7-segment S-shaped motion planning algorithm used for theoretical trajectory interpolation according to an embodiment of the present invention;

[0039] FIG2( b ) is a schematic diagram of the speed of the 7-segment S-type motion planning algorithm used in the theoretical trajectory interpolation provided by an embodiment of the present invention;

[0040] FIG2( c ) is a schematic diagram of the 7-segment S-shaped motion planning algorithm used in the theoretical trajectory interpolation provided by an embodiment of the present invention in terms of acceleration;

[0041] Figure 3 This is a schematic diagram of strategies that can be selected during the compensation amount acquisition phase provided by an embodiment of the present invention;

[0042] Figure 4 is a schematic diagram of an error compensation process provided by an embodiment of the present invention;

[0043] Figure 5 This is a schematic diagram of position superposition according to time changes during the actual posture superposition process provided by an embodiment of the present invention;

[0044] Figure 6 Schematic diagram of the corresponding relationship of joint angles in the inverse solution process provided by an embodiment of the present invention;

[0045] Figure 7 Schematic diagram of data transmission and computing medium allocation for a distributed virtual-real twin axis system provided by an embodiment of the present invention;

[0046] Figure 8 This is a schematic diagram of the time required to obtain a compensation value for each interpolation position provided by an embodiment of the present invention;

[0047] Figure 9 It is a trajectory diagram in ISO 9283-1998 that is run during the verification effect phase provided by an embodiment of the present invention;

[0048] Figure 10 (a) shows the error performance before and after the overall position error compensation is performed on the national standard trajectory according to an embodiment of the present invention;

[0049] Figure 10 (b) shows the error performance before and after performing x-axis position error compensation on the national standard trajectory provided by an embodiment of the present invention;

[0050] Figure 10 (c) shows the error performance before and after y-axis position error compensation for the national standard trajectory provided by an embodiment of the present invention;

[0051] Figure 10 (d) shows the error performance before and after z-direction position error compensation for the national standard trajectory provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0052] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely for the purpose of explaining the present invention and are not intended to limit the present invention. In addition, the technical features involved in the various embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.

[0053] like Figure 1 As shown, a distributed virtual-real twin robot posture error online compensation system includes: a virtual-real axis group, a first computing medium, a second computing medium and a driver;

[0054] The virtual and real axis group includes a virtual CNC interpolation Cartesian axis, a virtual posture compensation Cartesian axis and an actual joint angle axis, and the actual joint angle axis is connected to the robot joint motor through a driver;

[0055] The first computing medium is used to obtain the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment and transmit it to the second computing medium, and the time difference between two adjacent compensation moments is the compensation period T2;

[0056] The second computing medium is used to interpolate the G code corresponding to the robot's motion trajectory in Cartesian space to obtain the theoretical position of the virtual CNC interpolated Cartesian axis at each interpolation time t. When aT2≤t<(a+1)T2, the compensation amount is the compensation amount at the aT2 compensation time. The compensation amount at the aT2 compensation time is superimposed with the theoretical position of the virtual CNC interpolated Cartesian axis at each interpolation time within aT2≤t<(a+1)T2 to obtain the actual position at each interpolation time within aT2≤t<(a+1)T2. Inverse kinematics calculation is performed on the actual position to obtain the actual joint angle of the actual joint angle axis, and the actual joint angle is transmitted to the driver.

[0057] The driver is used to drive the robot joint motor to move using the actual joint angle;

[0058] Wherein, T2=nT1, n represents the ratio of the compensation period T2 to the interpolation period T1, the time difference between two adjacent interpolation moments is the interpolation period T1, n is an integer ≥1, and a is an integer ≥0.

[0059] Through the system of the present invention, online compensation of robot posture error is achieved, and the first operating medium provides support for the implementation of different posture error prediction frameworks. It can be widely used in scenarios such as robot milling, laser cutting, grinding, welding, etc. that have high requirements on robot posture accuracy.

[0060] Example 1

[0061] A distributed virtual-real twin robot posture error online compensation system includes: a virtual-real axis group, a first computing medium, a second computing medium and a driver;

[0062] The virtual and real axis group includes a virtual CNC interpolation Cartesian axis, a virtual posture compensation Cartesian axis and an actual joint angle axis, and the actual joint angle axis is connected to the robot joint motor through a driver;

[0063] In the present invention, the number of virtual CNC interpolation Cartesian axes is six, which are used to interpolate the Cartesian spatial posture. The motion planning adopted for interpolation is a 7-segment S-type planning. The planning in terms of position, velocity and acceleration is shown in Figures 2(a), 2(b) and 2(c). The seven segments specifically refer to the following seven stages: 1. acceleration, 2. uniform acceleration, 3. deceleration, 4. uniform speed, 5. acceleration and deceleration, 6. uniform deceleration and 7. deceleration. Figures 2(a), 2(b) and 2(c) respectively show the curve changes in position, velocity and acceleration of this planning method. This planning method is also the most common planning method in current robot motion planning.

[0064] The number of Cartesian axes in the virtual posture compensation is 3 in Example 1, that is, only the position error is compensated, and the compensation amount is obtained as follows: Figure 3 As shown. One type is measurement, and the other type is calculation. For measurement, it is called external measurement here. This method uses external measuring equipment to measure the error of the robot before the error can be used for subsequent compensation. For calculation, it is called model calculation here. Specifically, according to the different models, it can be subdivided into two categories: theoretical model calculation and intelligent algorithm prediction. For theoretical model calculation, it refers to the kinematic model and the force-induced error model, which correspond to the spatial motion of the robot and the force-bearing task of the robot, respectively. For intelligent algorithm prediction, there are endless methods available. The present invention uses neural networks or deep belief networks.

[0065] In the first embodiment of the present invention, an intelligent algorithm is used for prediction. The theoretical posture of the robot at each compensation moment is input into the prediction model, and the predicted error is used as the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment;

[0066] The prediction model is a trained neural network. The pre-calculated theoretical robot posture and its corresponding posture error measurement value are used as training data. During training, the difference between the predicted error and the posture error measurement value is back-propagated to update the network parameters. The trained neural network is obtained by training until convergence.

[0067] like Figure 4 As shown, the G code corresponds to the program corresponding to the theoretical trajectory that the robot needs to carry out, and the G code is described in Cartesian space, generally in the form of "X__Y__Z__RxRy__Rz__", so it corresponds to the virtual CNC interpolation Cartesian axis of the upper layer. After the data of the virtual numerical interpolation Cartesian axis corresponding to the G code and the data of the virtual posture compensation Cartesian axis corresponding to the compensation amount are superimposed according to the corresponding relationship, the actual Cartesian axis data can be obtained. For the robot, in Example 1, its movement is achieved by the angle change of six joints. Therefore, here, inverse kinematics is used to convert the actual posture in Cartesian space into the angle in joint space, thereby obtaining the data of each actual joint angle axis.

[0068] Figure 5 There are two time axes in the graph, defined as t. The upper one corresponds to theoretical trajectory interpolation, and the lower one corresponds to compensation acquisition. Since the time frequency of theoretical trajectory interpolation is not always equal to the time frequency of compensation acquisition, there is a time difference, and in most cases the time frequency of theoretical trajectory interpolation is much greater than the time frequency of compensation acquisition. This demonstrates that the frequency of compensation acquisition is 1 / 4 of the theoretical trajectory interpolation frequency. Therefore, a new compensation is obtained every four points, and the compensation remains unchanged between adjacent compensation acquisition moments.

[0069] The virtual CNC interpolation Cartesian axis and the virtual posture compensation Cartesian axis are arranged according to Figure 5 After superimposing the corresponding relationships shown, the actual Cartesian axis is obtained, and the robot inverse kinematics is used to obtain the rotation angles of the six axes corresponding to the robot, and the position data of the actual joint angle axis is used to drive the robot movement.

[0070] like Figure 6 As shown in the binary tree structure of the robot joint angle inverse solution, what needs to be solved is the dependency relationship of the solution of each joint angle under the posture X. It can be seen that there will be multiple solutions for the solution of joints 1, 2 and 4, and the calculation of the latter joint angle will depend on the value of the previous joint, so we get Figure 6 Specifically, if the first solution is selected for joint angle 1, then on this basis, two joint angles 2 can be obtained, and under any value, a unique joint angle 3 can be obtained, and so on.

[0071] The way to establish the forward and inverse kinematics models of the robot is:

[0072] Taking the six-degree-of-freedom Stäubli robot TX2-90L as an example, the construction rules of forward kinematics are introduced. The odd-order transformation matrix of adjacent links is:

[0073]

[0074] Then the forward kinematics can be expressed as

[0075]

[0076] where θ = [θ1 L θ6] T , a i d i , α i ,θ i are the kinematic parameters of the i-th link, [·] * It is a motion operator used to transform the odd transformation matrix into X = [xyz α β γ] T The parameters of the links of the studied robot are shown in Table 1.

[0077] Table 1

[0078] Link <![CDATA[a i (mm)]]> <![CDATA[d i (mm)]]> <![CDATA[α i (°)]]> <![CDATA[θ i (°)]]> 1 50 0 -90 0 2 500 0 0 -90 3 0 50 90 90 4 0 550 -90 0 5 0 0 90 0 6 0 100 0 0

[0079] For the convenience of subsequent calculations, the original Split into

[0080]

[0081] Redefine the spatial position that the robot expects to reach X = [xyz α β γ] T The odd transformation matrix is:

[0082]

[0083] Solving for θ1:

[0084] Transforming the forward kinematics, we get the following formula:

[0085]

[0086] Among them are:

[0087]

[0088] Solving the above equation yields:

[0089]

[0090]

[0091] φ=atan2(p y -100z2,p x -100z1)

[0092] Solving for θ2:

[0093] Further transformation of the positive kinematics can be obtained as follows:

[0094]

[0095] Among them are:

[0096]

[0097] Solving the above formula we can get:

[0098]

[0099]

[0100] stA=((p x -100z1)cos(θ1)-50+(p y -100z2)sin(θ1))

[0101] B=(-100z3+p z )

[0102] Solving for θ3:

[0103] From the above solutions for θ1 and θ2, θ3 can be directly calculated, which is expressed as:

[0104] θ3=arctan(A cos(θ2)-B sin(θ2),A sin(θ2)+B cos(θ2)-500)

[0105] where A and B are consistent with those in the above calculation of θ2.

[0106] Solving for θ4:

[0107] Further transformation of the positive kinematics can be obtained as follows:

[0108]

[0109] Among them are:

[0110]

[0111] Solving the above formula we can get:

[0112] θ 4,1 =arctan(C, D),θ 4,2=arctan(-C, -D)

[0113] stC=cos(θ1)z2-sin(θ1)z1

[0114] D=((cos(θ1)z1+sin(θ1)z2)cos(θ3)-sin(θ3)z3)cos(θ2)-sin(θ2)(z3cos(θ3)+sin(θ3)(cos(θ1)z1+sin(θ1)z2))

[0115] Solving for θ5:

[0116] Further transformation of the positive kinematics can be obtained as follows:

[0117]

[0118] Among them are:

[0119]

[0120] Solving the above formula we can get:

[0121] θ5=arctan(E,F)

[0122] stE=(z1(-sin(θ2)sin(θ3)+cos(θ2)cos(θ3))cos(θ1)+(cos(θ3)sin(θ1)z2-sin(θ3)z3)co s(θ2)-sin(θ2)(sin(θ1)sin(θ3)z2+z3cos(θ3)))cos(θ4)-sin(θ4)(sin(θ1)z1-cos(θ1)z2)

[0123] F=cos(θ1)z2-sin(θ1)z1

[0124] Solving for θ6:

[0125] Further transformation of the positive kinematics can be obtained as follows:

[0126]

[0127] Among them are:

[0128]

[0129] Solving the above formula we can get:

[0130] θ6=arctan(G,H)

[0131]

[0132] H=(cos(θ4)((cos(θ1)x1+sin(θ1)x2)cos(θ3)-sin(θ3)x3)cos(θ2)-cos(θ4)s in(θ2)cos(θ3)x3-sin(θ2)sin(θ3)(cos(θ1)x1+sin(θ1)x2)cos(θ4)-sin(θ4)( sin(θ1)x1-cos(θ1)x2))cos(θ5)-sin(θ5)((x3cos(θ3)+sin(θ3)(cos(θ1)x1+ sin(θ1)x2))cos(θ2)+sin(θ2)((cos(θ1)x1+sin(θ1)x2)cos(θ3)-sin(θ3)x3))

[0133] From the above calculations, it can be seen that there are multiple solutions for θ1, θ2, and θ4 during the calculation process. This is related to the axis configuration of the robot. The dependency relationship of the axis solutions is as follows: Figure 6 In actual motion, the selection is made based on the principle of minimizing the overall rotation.

[0134] In Example 1, the distributed computing medium allocation method is as follows: Figure 7 As shown. In this figure, the robot and the robot driver are connected by a cable, the robot driver communicates with the external controller, and the external controller communicates with the industrial computer. The specific data flow can be described as follows: on the second computing medium (external controller), the G code corresponding to the robot motion trajectory is interpolated and sent to the first computing medium (industrial computer). On the second computing medium, TwinCAT3 sends the theoretical pose data corresponding to the obtained G code to the ONNX intelligent reasoning framework, which stores a pre-trained position error prediction model to obtain a compensation value. The compensation value is sent back to the second computing medium (external controller) through TwinCAT3. On this computing medium, superposition and inverse kinematics are completed, and the actual joint angle calculated by inverse kinematics is sent to the robot driver to drive the robot to perform movement according to the actual joint angle.

[0135] The setting of the compensation period in Example 1 is well considered. There are actually many means of obtaining error values ​​here. The time required to obtain a compensation amount is recorded as Time_1, and the time required to transfer the obtained compensation amount to the second operating medium is recorded as Time_2. The actual posture after superposition is calculated by inverse kinematics to obtain the actual joint angle and send it to the driver. The time required is Time_3. In order to set a reliable compensation period, a safety time needs to be given, which is defined as Time_Safe. Time_1+Time_2+Time_3+Time_Safe=T_all. By adjusting the size of the safety time, T_all / T1 is an integer. When n is T_all / T1, the minimum integer that meets the conditions is used as the compensation period.

[0136] Figure 8 What is recorded is the time required to obtain a compensation value for each interpolation position. It can be seen that the average time is 0.998ms and the maximum time is 1.299ms. The time corresponding to transmitting the obtained error to the second medium is the communication time. After testing, it is constant to Time_2=2ms. The actual posture is calculated and sent to the actual joint angle axis at the time Time_3=0.600ms. Here, taking the maximum time as an example, the safety time is set to Time_Safe=0.101ms, T_all=4ms, and the interpolation period is T1=1ms. Therefore, the minimum integer is determined to be 4, that is, n is 4.

[0137] The robot inverse kinematics described in Example 1 is performed according to theoretical kinematic parameters. Therefore, the problem of the inverse solution not having a closed-form solution due to kinematic parameter errors causing the actual robot configuration to fail the Piper criterion arises. Furthermore, a minimum compensation period is provided, providing a safety margin for fluctuations in the system's motion time and ensuring strictly equidistant compensation periods. Furthermore, the minimum integer indirectly ensures that the system operates at the highest achievable frequency, ensuring reliable and efficient error compensation.

[0138] Example 2

[0139] Compensate for the posture error of the standard trajectory in the range of 800mm×800mm in the national standard ISO 9283-1998. Figure 9 shown.

[0140] The frequency of online compensation is 250Hz (T2=4ms). The overall position error before and after compensation and the position error in each direction are shown in the figure below. Figure 10 The specific comparison is shown in Table 2 below.

[0141] Table 2

[0142]

[0143] Figure 10 (a) shows the error performance before and after the overall position error compensation for the national standard trajectory. Figure 10 (b) shows the error performance before and after the x-axis position error compensation is performed on the national standard trajectory. Figure 10 (c) shows the error performance before and after the Y-axis position error compensation is performed on the national standard trajectory. Figure 10 (d) shows the error performance before and after z-axis position error compensation for the national standard trajectory; the blue curve is the result before compensation, the orange curve is the curve after compensation, and the plotted graph shows the error change over time. It can be seen that the position error is significantly reduced after online compensation. In terms of average value, it is reduced from 0.965mm before compensation to 0.077mm after compensation, a reduction of about 92.02%. This shows that the online posture error compensation method proposed in this invention focuses on the microscopic state at the interpolation level during the robot's task execution, and designs corresponding distributed virtual and real twin axes to achieve the acquisition and compensation of the robot's errors at each moment of the task. Therefore, it can achieve high-precision error compensation and high compensation reliability.

[0144] It will be easily understood by those skilled in the art that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A distributed virtual-real twin robot posture error online compensation system, characterized by: include: A virtual and real axis group, a first operating medium, a second operating medium and a driver; The virtual and real axis group includes a virtual CNC interpolation Cartesian axis, a virtual posture compensation Cartesian axis and an actual joint angle axis, and the actual joint angle axis is connected to the robot joint motor through a driver; The first computing medium is used to obtain the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment and transmit it to the second computing medium, and the time difference between two adjacent compensation moments is the compensation period T2; The second computing medium is used to interpolate the G code corresponding to the robot's motion trajectory in Cartesian space to obtain the theoretical position of the virtual CNC interpolated Cartesian axis at each interpolation time t. When aT2≤t<(a+1)T2, the compensation amount is the compensation amount at the aT2 compensation time. The compensation amount at the aT2 compensation time is superimposed with the theoretical position of the virtual CNC interpolated Cartesian axis at each interpolation time within aT2≤t<(a+1)T2 to obtain the actual position at each interpolation time within aT2≤t<(a+1)T2. Inverse kinematics calculation is performed on the actual position to obtain the actual joint angle of the actual joint angle axis, and the actual joint angle is transmitted to the driver. The driver is used to drive the robot joint motor to move using the actual joint angle; Wherein, T2=nT1, n represents the ratio of the compensation period T2 to the interpolation period T1, the time difference between two adjacent interpolation moments is the interpolation period T1, n is an integer ≥1, and a is an integer ≥0.

2. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 1, characterized in that: The first computing medium is used to measure the robot posture using an external measuring device at each compensation moment, and use the difference between the robot posture measured at each compensation moment and the posture recorded by the robot internal controller at the corresponding compensation moment as the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

3. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 1, characterized in that: The first computing medium is used to calculate the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment using the model.

4. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 3, characterized in that: The first computing medium is used to calculate the robot posture at each compensation moment through forward kinematics using pre-identified robot kinematic parameters, and to use the difference between the robot posture calculated at each compensation moment and the posture recorded by the robot internal controller at the corresponding compensation moment as the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

5. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 3, characterized in that: The first operating medium is used to measure the external force applied to the robot using a dynamometer at each compensation moment, substitute the external force applied to the robot measured at each compensation moment into the force-induced error model, and obtain the compensation amount of the virtual posture compensation Cartesian axis at each compensation moment.

6. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 3, characterized in that: The first computing medium is used to input the theoretical posture of the robot at each compensation moment into the prediction model, and use the prediction result of the prediction model as the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment; The prediction model is a trained neural network. The pre-calculated theoretical robot posture and its corresponding posture error measurement value are used as training data. During training, the difference between the predicted error and the posture error measurement value is back-propagated to update the network parameters. The trained neural network is obtained by training until convergence.

7. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 3, characterized in that: The first computing medium is used to input the theoretical posture of the robot at each compensation moment into the prediction model, and use the prediction result of the prediction model as the compensation amount of the Cartesian axis of the virtual posture compensation at each compensation moment; The prediction model is a trained deep belief network. The pre-calculated theoretical robot pose and its corresponding pose error measurement value are used as training data. During training, the difference between the predicted error and the pose error measurement value is back-propagated to update the network parameters. The trained deep belief network is obtained by training until convergence.

8. A distributed virtual-real twin robot posture error online compensation system according to any one of claims 1 to 7, characterized in that: The number of the actual joint angle axis axes is equal to the number of robot joint motors, the number of virtual CNC interpolation Cartesian axis axes is six, and the number of virtual posture compensation Cartesian axis axes ranges from 1 to 6.

9. A distributed virtual-real twin robot posture error online compensation system according to any one of claims 1 to 7, characterized in that: Said n is an integer ≥ T_all / T1; Here, time and T_all = time required to obtain a compensation value + time required to transfer the compensation value to the second computing medium + time required to calculate the actual joint angle from the actual posture through inverse kinematics and send it to the driver + safety time. By adjusting the size of the safety time, T_all / T1 can be made into an integer.

10. A distributed virtual-real twin robot posture error online compensation system as claimed in claim 9, characterized in that: The n is T_all / T1.

11. An electronic device, characterized in that: include: a memory having a computer program stored thereon; A processor for executing the computer program in the memory to implement the processing steps of a distributed virtual-real twin robot posture error online compensation system according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Simulation method and device of digital twin system of industrial robot

    CN108724190A

  • Industrial robot digital twin real-time job control, monitoring and precision compensation method

    CN109571476A