Robot end position rapid detection device and kinematic parameter identification and compensation method

By designing a rapid detection device for the end position of the robot and a kinematic parameter compensation method based on the circular particle swarm algorithm and a fully connected neural network, the problems of insufficient accuracy of error compensation and cumbersome data collection of traditional robots are solved, and high-precision end position measurement and Effective compensation for various errors.

CN115098969BActive Publication Date: 2024-10-15NANJING UNIV OF POSTS & TELECOMM
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210766869.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-30
Publication Date
2024-10-15
Estimated Expiration
2042-06-30

AI Technical Summary

Technical Problem

Traditional robot error compensation methods have insufficient accuracy, cumbersome data collection, expensive equipment, and limited compensation capabilities. Especially under large load conditions, the absolute positioning accuracy is reduced, and they cannot effectively handle errors other than geometric errors, such as manufacturing, assembly, and installation errors.

Method used

Design a rapid detection device for the end position of the robot, including the main body of the robot and four pull-wire sensors. It combines the circular particle swarm algorithm and the fully connected neural network to achieve the real coordinate measurement of the end point of the robot through DH modeling and optimization of geometric kinematic parameters. Rapid identification and compensation of kinematic parameters.

Benefits of technology

It improves the accuracy of the robot's end position, enhances error compensation capabilities, improves absolute positioning accuracy, solves the problem of reduced accuracy under large load conditions, and effectively handles multiple error sources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115098969B_ABST
    Figure CN115098969B_ABST
Patent Text Reader

Abstract

The invention discloses a robot end position rapid detection device and kinematic parameter identification and compensation method, comprising a bracket body and four wire sensors installed on the bracket body; the bracket body comprises a first tripod, a second tripod and three connecting rods, the first tripod is the same as the second tripod, the first tripod and the second tripod are parallel and symmetrical and arranged at intervals; the three corners of the first tripod are respectively connected with the three corners of the second tripod by three connecting rods; the bottom edge of the first tripod is the first supporting edge, and the bottom edge of the second tripod is the second supporting edge; the first supporting edge, the second supporting edge and the two connecting rods connecting the first supporting edge and the second supporting edge form a supporting frame to support the placement surface. The coordinate P of the working end of the robot is calculated by the method. The robot kinematic parameter compensation method of the circular particle swarm algorithm and the robot input error compensation method of the fully connected neural network are used to improve the end position accuracy of the robot.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of robots, and in particular relates to a robot end position rapid detection device and a kinematic parameter identification and compensation method. Background Art

[0002] Industrial robots are an important part of the current manufacturing industry. When faced with working conditions such as heavy loads, their absolute positioning accuracy will be reduced, which will cause excessive grinding forces and obvious surface grinding marks during robot grinding.

[0003] In the traditional robot error compensation method, the external measurement equipment is easily constrained by the environment. At present, the data collection of the measurement equipment on the market is cumbersome. In addition, for big data work, it is impossible to complete the work in a short time.

[0004] In addition, traditional error compensation has the following problems: 1. The robot measurement parameters are relatively complicated and the equipment is expensive; 2. The error compensation method is relatively limited.

[0005] Traditional parameter identification algorithms can improve the absolute positioning accuracy of robots to a certain extent, but the optimization algorithm is more likely to fall into the problem of local optimal solutions, and the improvement in accuracy is not high enough; and the compensation ability for errors other than geometric errors, including manufacturing errors, assembly errors, installation errors, rod deformation, transmission errors, zero point errors, thermal deformation and mechanical clearance, is relatively weak.

[0006] Therefore, a device and method with strong robot error compensation capability is needed. Summary of the invention

[0007] The first object of the present invention is to provide a robot end position rapid detection device and a kinematic parameter identification and compensation method, which can be used for end point position detection of an industrial robot and joint compensation of the robot's kinematic errors.

[0008] A robot end position rapid detection device comprises a bracket body and four pull-wire sensors installed on the bracket body.

[0009] The bracket body includes a first tripod, a second tripod and three connecting rods. The first tripod is the same as the second tripod. The first tripod and the second tripod are parallel, symmetrical and arranged at intervals. The three corners of the first tripod and the three corners of the second tripod are respectively connected together by three connecting rods; the bottom edge of the first tripod is the first supporting edge, and the bottom edge of the second tripod is the second supporting edge; the first supporting edge, the second supporting edge and the two connecting rods connecting the first supporting edge and the second supporting edge form a supporting frame to support the placement surface.

[0010] The first tripod and the second tripod are isosceles straight triangles, a right-angled side of the first tripod and the second tripod is the base, and a first hypotenuse of the first tripod and a second hypotenuse of the second tripod are used to face the robot.

[0011] The first oblique edge, the second oblique edge, and the two connecting rods connecting the first oblique edge and the second oblique edge form an oblique frame facing the robot, and the four pull-wire sensors are installed at four corners of the oblique frame.

[0012] A kinematic parameter identification and compensation method based on a robot end position rapid detection device comprises the following steps.

[0013] Step 1: Determine the actual coordinates p of the robot end point R :Use the robot end position rapid detection device to measure the real coordinates p of the robot’s end point at the current moment R .

[0014] Step 2: Describe the theoretical coordinates p of the robot end point: Using the DH modeling method, the theoretical coordinates p of the robot end point at the current moment are described as:

[0015] p=F(θ i ,d i ,a i ,α i ,q);1≤i≤K

[0016] In the formula, θ i ,d i ,a i ,α i is the geometric kinematic parameter of the robot’s i-th degree of freedom; where θ i is the rotation angle of the i-th joint; d i represents the z-direction distance of the i-th joint; let the rod connecting the i-th joint and the i+1-th joint be the i-th rod, then a i represents the length of the i-th member; α i represents the torsion angle of the i-th rod; q is the robot joint variable; K is the total number of degrees of freedom of the robot.

[0017] Step 3: Compensation of theoretical coordinates p: The current robot joint variable q and the current robot end point real coordinates p R As input, the optimized geometric kinematic parameters are taken as output. Based on the ring particle swarm algorithm, the optimal geometric kinematic parameters θ are obtained. i +△θ i ,d i +△d i ,a i +△ai ,α i +△α i ; Among them, △θ i , △d i , △a i and △α i They are θ i ,d i 、a i and α i The optimal compensation value; after one compensation, the theoretical coordinates of the robot end point at the current moment are p C1 Described as:

[0018] p C1 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ,q)

[0019] Step 4: Secondary compensation of theoretical coordinates p: The optimal geometric kinematic parameters after the primary compensation in step 3, the robot joint variables q and the real coordinates p of the robot end point are used. R As a sample data set, the robot joint variables are used as input and the optimized robot joint variables are used as output to build a fully connected neural network, and then the optimized value of the robot joint variable q at the current moment is obtained as q+△q; where △q is the compensation value of the robot joint variable q at the current moment; after secondary compensation, the theoretical coordinates of the robot end point at the current moment are p C2 Described as:

[0020] p C2 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ,q+△q).

[0021] In step 1, the actual coordinates of the robot end point p R The specific determination method includes the following steps:

[0022] Step 1A, deploying the robot end position rapid detection device: the robot includes a frame and a movable part movably mounted on the frame; the robot end position rapid detection device is placed on the periphery of the robot's movable part, and the wire ends of four wire sensors in the robot end position rapid detection device are fixed at the end area of ​​the movable part.

[0023] Step 1B, establish the robot coordinate system: select a fixed point on the frame as the base point O of the coordinate system, define the downward direction of the frame as the y direction, the direction in which the active part extends toward the robot end position rapid detection device as the x direction, and the direction perpendicular to x and y as the z direction, thereby establishing the robot coordinate system O-xyz; at this time, the coordinates of the end point P of the robot's active part in the robot coordinate system are set to (x, y, z), which are values ​​to be determined.

[0024] Step 1C, solve the coordinate value of the end point P of the movable part: the four wire sensors are wire sensor A, wire sensor B, wire sensor C and wire sensor D; for wire sensor A, wire sensor B and wire sensor C, according to the principle that the wire lengths obtained in different ways are equal, establish the following set of equations:

[0025]

[0026] In the formula, (x Ae ,y Ae , z Ae ) is the deviation from the end of the wire of the wire sensor A to the end point P of the robot's active part in the robot coordinate system, set value.

[0027] (x Be ,y Be , z Be ) is the deviation from the end of the wire of the wire sensor B to the end point P of the robot's active part in the robot coordinate system, set value.

[0028] (x Ce ,y Ce , z Ce ) is the deviation from the end of the wire of the wire sensor C to the end point P of the robot's active part in the robot coordinate system, set value.

[0029] (x A ,y A , z A ) is the coordinate value of the wire sensor A in the robot coordinate system, a known value.

[0030] (x B ,y B , z B ) is the coordinate value of the wire sensor B in the robot coordinate system, a known value.

[0031] (x C ,y C , z C ) is the coordinate value of the wire sensor C in the robot coordinate system, a known value.

[0032] d A ,dB and d C They are the wire length values ​​of wire sensor A, wire sensor B and wire sensor C obtained through measurement, and all are known values.

[0033] By solving the equations, we can get the end point P(x, y, z) of the active part. The result is the real coordinate p of the end point of the robot. R .

[0034] Step 1D: Calculate the wire length d of the wire sensor D l :Substitute P(x, y, z) obtained in step 1C into the following formula to calculate d l .

[0035]

[0036] In the formula, (x De ,y De , z De ) is the deviation from the end of the wire of the wire sensor D to the end point P of the robot's active part in the robot coordinate system, set value.

[0037] (x D ,y D , z D ) is the coordinate value of the wire sensor D in the robot coordinate system, a known value.

[0038] Step 1E, setting the wire length error △l: according to the actual installation situation of the wire sensor D, set the allowable error of the wire length in the wire sensor.

[0039] Step 1F, verify the coordinates of the end point P of the active part: Substitute P(x, y, z) obtained in step 1C into the following formula for verification.

[0040] d D -△l <d l <d D +△l (3)

[0041] Where, d D is the length of the wire of the wire sensor D obtained by measurement, and is a known value

[0042] When the coordinates of point P (x, y, z) satisfy the formula, then P (x, y, z) is the real coordinates p of the robot end point R .

[0043] When the coordinates of point P (x, y, z) do not satisfy the formula, delete the P (x, y, z) obtained by the current data collection or correct the error in step 1E, and repeat steps 1E and 1F until the real coordinates of the robot end point p are obtained. R.

[0044] In step 3, the method for solving the optimal geometric kinematic parameters based on the circular particle swarm algorithm includes the following steps:

[0045] Step 31: Establish the objective function L, the specific expression is:

[0046] min L=||p R -p|| 2

[0047] Step 32: Solve for the optimal geometric kinematic parameters: The actual coordinates p of the robot end point determined in step 1 are R , the robot joint variable q at the current moment is taken as input. When the objective function L tends to the minimum value, the corresponding geometric kinematic parameters are the optimal geometric kinematic parameters.

[0048] In step 32, the objective function L is solved using the following formula:

[0049]

[0050] in:

[0051]

[0052]

[0053] Where N is the total number of samples, and N>3.

[0054] is the global optimal fitness value of particle k; g k is the global optimal position of particle k;

[0055] are the local optimal fitness values ​​of particle 1, particle k, and particle N, respectively; where 1≤k≤N.

[0056] are the individual optimal fitness values ​​of particle 1, particle N, particle k-1, particle k, particle k+1 and particle N respectively.

[0057] and are the individual optimal fitness values ​​of particle k after the 1st iteration and the tth iteration, respectively.

[0058] When the number of iterations t meets the maximum number of iterations, the global optimal position g k These are the optimal geometric kinematic parameters obtained by solving.

[0059] In step 32, during the iteration process, the velocity update formula of particle k is:

[0060] V ks (t+1)=wV ks (t)+a 1 b 1 (t)(p ks (t)-x ks (t))+a 2 b 2 (t)(j ks (t)-x ks (t)) (4-3)

[0061] Where t represents the number of iterations, w represents the inertia weight, s represents the s-th dimension vector of each particle, 1≤s≤4K, and is one of the 4K geometric kinematic parameters; a 1 、a 2 Represents the acceleration factor, and its value range is [0,2].

[0062] b 1 (t), b 2 (t) represents the random number at the tth iteration, and its value range is [0,1].

[0063] V ks (t+1) and V ks (t) are the iteration speeds of the s-th dimension vector in particle k at the t+1th and tth iterations, respectively.

[0064] p ks (t) is the individual optimal position of the s-th dimension vector in particle k at the t-th iteration.

[0065] j ks (t) is the local optimal position of the s-th dimension vector in particle k at the t-th iteration.

[0066] x ks (t) is the current position of the s-th dimension vector in particle k at the t-th iteration.

[0067] During the iteration process, the position update formula of particle k is:

[0068] x ks (t+1)=x ks (t)+V ks (t+1) (4-4)

[0069] In the formula, x ks (t) is the current position of the s-th dimension vector in particle k at the t+1th iteration.

[0070] The fully connected neural network has four layers. The first layer is the input layer, the second layer is the dual-channel fully connected layer, the third layer is the dual-channel weight allocation layer, and the fourth layer is the output layer. In the third layer, the attention mechanism is used to determine the cumulative weights of the dual channel outputs.

[0071] The beneficial effects of the present invention are: a robot end position rapid detection device is set up, the robot end position is calculated by a robot end position rapid detection method, and a robot kinematic parameter compensation method of a circular particle swarm algorithm and a robot input error compensation method of a fully connected neural network are performed based on the robot end position rapid detection device, and the compensation ability is strong to improve the robot end position accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0072] Figure 1 It is a structural diagram of a robot end position rapid detection device according to an embodiment of the present invention.

[0073] Figure 2 It is a connection relationship diagram between the robot end position rapid detection device and the robot according to an embodiment of the present invention.

[0074] Figure 3 It is a compensation simulation diagram after the first error compensation of the embodiment of the present invention.

[0075] Figure 4 It is a compensation simulation diagram after the second error compensation of the embodiment of the present invention.

[0076] Figure 5 It is a flow chart of the compensation method according to an embodiment of the present invention.

[0077] Figure 6 It is a flow chart of a fully connected neural network according to an embodiment of the present invention.

[0078] Figure 7 It is a schematic flow chart of a robot kinematic parameter identification and compensation method according to an embodiment of the present invention.

[0079] Figure 8 It is the data acquisition interface of the robot end position rapid detection device of the present invention. DETAILED DESCRIPTION

[0080] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. It should also be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.

[0081] like Figure 1As shown, this embodiment discloses a robot end position rapid detection device 100. The robot end position rapid detection device 100 includes a bracket body and four pull-wire sensors 40 installed on the bracket body; the bracket body includes a first tripod and a second tripod and three connecting rods 30, the first tripod is the same as the second tripod, the first tripod and the second tripod are parallel and symmetrical and arranged at intervals; the three corners of the first tripod are connected to the three corners of the second tripod through three connecting rods 30 respectively; the bottom side of the first tripod is the first supporting side 11, and the bottom side of the second tripod is the second supporting side 21; the first supporting side 11, the second supporting side 21 and the two connecting rods 30 connecting the first supporting side 11 and the second supporting side 21 form a supporting frame to support the placement surface. The supporting frame is a parallelogram frame.

[0082] As a preferred solution, the first tripod and the second tripod are isosceles straight triangles, one right-angled side of the first tripod and the second tripod is the base, and the first hypotenuse 13 of the first tripod and the second hypotenuse 23 of the second tripod are used to face the robot. The other right-angled sides of the first tripod and the second tripod are perpendicular to the placement surface, and are the first vertical side 12 and the second vertical side 22 respectively. The first tripod and the second tripod of this embodiment are isosceles straight triangles, which makes the structure of the entire bracket body relatively stable, thereby ensuring the detection accuracy. In addition, it can also enable the robot end position rapid detection device 100 to give the robot a larger activity space to avoid collision with the robot.

[0083] As a preferred solution, the first bevel 13 and the second bevel 23 and two connecting rods 30 connecting the first bevel 13 and the second bevel 23 form a bevel frame facing the robot, and four pull-wire sensors 40 are installed at four corners of the bevel frame. The bevel frame is a parallelogram frame.

[0084] The material of the bracket body of this embodiment can be industrial profiles. The bracket body of this embodiment has a simple structure and low cost.

[0085] like Figure 2 As shown, the robot end position rapid detection device 100 is set outside the robot's workspace. Then, the host computer collects, displays and saves data in real time, and the position of the end point of the robot's active end can be detected in real time during the movement of the robot's active end. In this embodiment, the pull-wire sensor 40 is directed toward the robot's flange, and the ends of the pull-wires of the four pull-wire sensors 40 are fixed at the end center point of the flange. In this embodiment, the end center point of the flange is considered to be the end point of the robot's active end, that is, the end point of the active end. During the movement of the robot, the length of the pull wire changes continuously. In this embodiment, the distance from the end center point of the flange to the four pull-wire sensors 40 can be obtained.

[0086] Specifically, a NI6210 data acquisition card is used as an acquisition device, and a C#-based data acquisition platform is developed. The length of the wire of the wire sensor 40 is acquired through the data acquisition card, and the coordinates of the end center point of the robot's flange are obtained through a coordinate conversion algorithm.

[0087] This embodiment also discloses a method for quickly detecting the position of a robot end, which is based on the device 100 for quickly detecting the position of a robot end.

[0088] like Figure 5 and Figure 7 As shown, a kinematic parameter identification and compensation method based on a robot end position rapid detection device includes the following steps.

[0089] Step 1: Determine the actual coordinates p of the robot end point R :Use the robot end position rapid detection device to measure the real coordinates p of the robot’s end point at the current moment R .

[0090] The actual coordinates p of the robot end point are R The specific determination method preferably includes the following steps:

[0091] Step 1A, deploying the robot end position rapid detection device: the robot includes a frame and a movable part movably mounted on the frame; the robot end position rapid detection device is placed on the periphery of the robot's movable part, and the wire ends of four wire sensors in the robot end position rapid detection device are fixed at the end area of ​​the movable part.

[0092] like Figure 2 and Figure 7 As shown, the robot includes a robot frame and a movable part installed on the robot frame.

[0093] This embodiment is described in detail by taking a five-degree-of-freedom joint robot as an example. Therefore, the movable part of the robot has joint 1, joint 2, joint 3, joint 4, joint 5 and a flange arranged at the end of joint 5. The flange has the end center point of the flange plate.

[0094] The coordinates P of the end center point of the robot flange in this embodiment are considered to be the coordinates of the end of the robot's active part, that is, the coordinates of the working end or end of the robot. In other embodiments, the end of the robot's active part can also be another component located at the end, that is, the present application does not limit the flange to the end component of the robot's active part, and the principle of calculating the coordinates of the end point of the robot's active part is the same as the above principle.

[0095] Step 1B, establish the robot coordinate system: select a fixed point on the frame as the base point O of the coordinate system, define the downward direction of the frame as the y direction, the direction in which the active part extends toward the robot end position rapid detection device as the x direction, and the direction perpendicular to x and y as the z direction, thereby establishing the robot coordinate system O-xyz; at this time, the coordinates of the end point P of the robot's active part in the robot coordinate system are set to (x, y, z), which are values ​​to be determined.

[0096] Step 1C, solve the coordinate value of the end point P of the movable part: the four wire sensors are wire sensor A, wire sensor B, wire sensor C and wire sensor D; for wire sensor A, wire sensor B and wire sensor C, according to the principle that the wire lengths obtained in different ways are equal, establish the following set of equations:

[0097]

[0098] In the formula, (x Ae ,y Ae , z Ae ) is the deviation from the end of the wire of the wire sensor A to the end point P of the robot's active part in the robot coordinate system, set value.

[0099] (x Be ,y Be , z Be ) is the deviation from the end of the wire of the wire sensor B to the end point P of the robot's active part in the robot coordinate system, set value.

[0100] (x Ce ,y Ce , z Ce ) is the deviation from the end of the wire of the wire sensor C to the end point P of the robot's active part in the robot coordinate system, set value.

[0101] (x A ,y A , z A ) is the coordinate value of the wire sensor A in the robot coordinate system, a known value.

[0102] (x B ,y B , z B ) is the coordinate value of the wire sensor B in the robot coordinate system, a known value.

[0103] (x C ,y C , z C ) is the coordinate value of the wire sensor C in the robot coordinate system, a known value.

[0104] d A ,d B and dC The lengths of the wires of the wire sensors A, B and C are obtained by measurement, and are all known values. In this embodiment, the NI6210 data acquisition card is preferably used as the acquisition device. A data acquisition platform based on C# is developed to acquire the lengths of the wires of the sensors. The acquisition interface is as shown in FIG. Figure 8 shown.

[0105] By solving the equations, we can get the end point P(x, y, z) of the active part. The result is the real coordinate p of the end point of the robot. R .

[0106] Step 1D: Calculate the wire length d of the wire sensor D l :Substitute P(x, y, z) obtained in step 1C into the following formula to calculate d l .

[0107]

[0108] In the formula, (x De ,y De , z De ) is the deviation from the end of the wire of the wire sensor D to the end point P of the robot's active part in the robot coordinate system, set value.

[0109] (x D ,y D , z D ) is the coordinate value of the wire sensor D in the robot coordinate system, a known value.

[0110] Step 1E, setting the wire length error △l: according to the actual installation situation of the wire sensor D, set the allowable error of the wire length in the wire sensor.

[0111] Step 1F, verify the coordinates of the end point P of the active part: Substitute P(x, y, z) obtained in step 1C into the following formula for verification.

[0112] d D -△l <d l <d D +△l (3)

[0113] Where, d D is the length of the wire of the wire sensor D obtained by measurement, and is a known value

[0114] When the coordinates of point P (x, y, z) satisfy the formula, then P (x, y, z) is the real coordinates p of the robot end point R .

[0115] When the coordinates of point P (x, y, z) do not satisfy the formula, delete the P (x, y, z) obtained by the current data collection or correct the error in step 1E, and repeat steps 1E and 1F until the real coordinates of the robot end point p are obtained. R .

[0116] Step 2: Describe the theoretical coordinates p of the robot end point: Using the DH modeling method, the theoretical coordinates p of the robot end point at the current moment are described as:

[0117] p=F(θ i ,d i ,a i ,α i ,q);1≤i≤K

[0118] In the formula, θ i ,d i ,a i ,α i is the geometric kinematic parameter of the robot’s i-th degree of freedom; where θ i is the rotation angle of the i-th joint; d i represents the z-direction distance of the i-th joint; let the rod connecting the i-th joint and the i+1-th joint be the i-th rod, then a i represents the length of the i-th member; α i represents the torsion angle of the i-th rod; q is the robot joint variable; K is the total number of degrees of freedom of the robot. In this embodiment, K=5 is preferred, so there are 20 geometric kinematic parameters.

[0119] Step 3: Compensation of theoretical coordinates p: The current robot joint variable q and the current robot end point real coordinates p R As input, the optimized geometric kinematic parameters are taken as output. Based on the ring particle swarm algorithm, the optimal geometric kinematic parameters θ are obtained. i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ; Among them, △θ i , △d i , △a i and △α i They are θ i ,d i 、a i and α i The optimal compensation value; after one compensation, the theoretical coordinates of the robot end point at the current moment are p C1 Described as:

[0120] pC1 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ,q)

[0121] The method for solving the optimal geometric kinematic parameters based on the circular particle swarm algorithm preferably includes the following steps:

[0122] Step 31: Establish the objective function L, the specific expression is:

[0123] min L=||p R -p|| 2

[0124] Step 32: Solve for the optimal geometric kinematic parameters: The actual coordinates p of the robot end point determined in step 1 are R , the robot joint variable q at the current moment is taken as input. When the objective function L tends to the minimum value, the corresponding geometric kinematic parameters are the optimal geometric kinematic parameters.

[0125] The above objective function L is preferably solved using the following formula:

[0126]

[0127] in:

[0128]

[0129]

[0130] Where N is the total number of samples, and N>3.

[0131] is the global optimal fitness value of particle k; g k is the global optimal position of particle k;

[0132] are the local optimal fitness values ​​of particle 1, particle k, and particle N, respectively; where 1≤k≤N.

[0133] are the individual optimal fitness values ​​of particle 1, particle N, particle k-1, particle k, particle k+1 and particle N respectively.

[0134] and are the individual optimal fitness values ​​of particle k after the 1st iteration and the tth iteration, respectively.

[0135] When the number of iterations t meets the maximum number of iterations, the global optimal position g k These are the optimal geometric kinematic parameters obtained by solving.

[0136] During the iteration process, the velocity update formula of the above particle k is:

[0137] V ks (t+1)=wV ks (t)+a 1 b 1 (t)(p ks (t)-x ks (t))+a 2 b 2 (t)(j ks (t)-x ks (t)) (4-3)

[0138] Where t represents the number of iterations, w represents the inertia weight, s represents the s-th dimension vector of each particle, 1≤s≤4K, and is one of the 4K geometric kinematic parameters; a 1 、a 2 Represents the acceleration factor, and its value range is [0,2].

[0139] b 1 (t), b 2 (t) represents the random number at the tth iteration, and its value range is [0,1].

[0140] V ks (t+1) and V ks (t) are the iteration speeds of the s-th dimension vector in particle k at the t+1th and tth iterations, respectively.

[0141] p ks (t) is the individual optimal position of the s-th dimension vector in particle k at the t-th iteration.

[0142] j ks (t) is the local optimal position of the s-th dimension vector in particle k at the t-th iteration.

[0143] x ks (t) is the current position of the s-th dimension vector in particle k at the t-th iteration.

[0144] During the iteration process, the position update formula of particle k is:

[0145] x ks (t+1)=x ks (t)+V ks (t+1) (4-4)

[0146] In the formula, xks (t) is the current position of the s-th dimension vector in particle k at the t+1th iteration.

[0147] Above and The fitness value of the above formula can be obtained by using a known adaptive function. In this embodiment, the expression of the fitness function is preferably:

[0148]

[0149] Among them, (x 1 ,y 1 ,z 1 ) is the measured real robot coordinate p R ,(x 2 ,y 2 ,z 2 ) is the kinematic analysis coordinate after fitting.

[0150] After the first compensation, the robot has a residual error E 1 =p R -p C1 ; The second compensation is performed through the robot input error compensation method of fully connected neural network.

[0151] Step 4: Secondary compensation of theoretical coordinate p

[0152] The optimal geometric kinematic parameters after one compensation in step 3, the robot joint variables q and the real coordinates p of the robot end point R As a sample data set. Among them, the robot joint variable q is used as the input of the sample data set, and the real coordinates of the robot end point p R The corresponding robot joint variables are used as the optimized robot joint variables.

[0153] Then, take the robot joint variables as input and the optimized robot joint variables as output, and build Figure 6 The fully connected neural network shown in the figure further obtains the optimized value of the robot joint variable q at the current moment as q+△q; wherein △q is the compensation value of the robot joint variable q at the current moment.

[0154] After secondary compensation, the theoretical coordinates of the robot end point at the current moment are p C2 Described as:

[0155] p C2 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,α i+△α i , q + △q).

[0156] In the present invention, a method for compensating the error of robot joint variables based on a fully connected neural network specifically includes the following steps.

[0157] Step 41: Randomly select M groups of data from N groups of data sample sets as the training subset, where M < N; the remaining N - M groups of data are used as the test subset.

[0158] Step 42: Using the robot joint variable q as the input and the optimized robot joint variable q + △q as the output, the network structure diagram is as Figure 6 shown.

[0159] In Figure 6 , the circled X, Y, Z, A, and B are respectively the input joint variable values corresponding to the five joints of the five-degree-of-freedom robot in this embodiment; the circled X1, Y1, Z1, A1, and B1 are respectively the output joint variable values corresponding to the five joints of the five-degree-of-freedom robot in this embodiment.

[0160] The first layer (input layer). Normalize the data set to achieve the effect of generalization and solve the problem of difficult learning caused by data distribution. The normalized data u of the input q 1 is:

[0161] u 1 = Batch_norm(q)

[0162] The second layer (fully connected layer).

[0163] In the present invention, by building a two-channel feedforward fully connected neural network, the problem of joint variable compensation can be specifically solved.

[0164] Using the normalized data u 1 as the network input and Relu as the activation function, the output values u 2 and u 3 of the two channels in the second layer are respectively:

[0165] u 2 = Relu(w 1 u 1 + b 1 )

[0166] u 3 = Relu(w' 1 u 1 + b' 1 )

[0167] In the above formula, w 1 and w' 1are the connection weights corresponding to the neurons in the two channels of the second layer; b 1 and b′ 1 They are the bias values ​​corresponding to the neurons in the two channels of the second layer.

[0168] The third layer (weight distribution layer).

[0169] The third layer is still dual-channel, and the outputs of the two channels of the second layer are used as the inputs of the third layer. In order to avoid the noise accumulation problem caused by the channel, the attention mechanism is used, and the neural network determines the cumulative weight of the outputs of the two channels. The output value u of the two channels of the third layer 4 and u 5 They are:

[0170] u 4 =α(w 2 u 2 +b 2 )

[0171] u 5 =(1-α)×(w′ 2 u 3 +b′ 2 )

[0172] In the above formula, w 2 and w′ 2 are the connection weights corresponding to the neurons in the two channels of the third layer; b 2 and b′ 2 are the bias values ​​corresponding to the neurons in the two channels of the third layer respectively; α and 1-α are the accumulated weights of the outputs of the two channels of the third layer respectively.

[0173] The fourth layer (feedforward connection layer). Add the compensation amount to the robot joint variables to obtain the optimized robot joint variables:

[0174] u 6 =w 3 (u 5 +u 4 )+b 3 +q

[0175] In the above formula, w 3 is the connection weight of neurons in the fourth layer; b 3 is the bias value of the neurons in the fourth layer.

[0176] The fifth layer (output layer).

[0177] Output compensation △q, where △q=w 3 (u 5 +u 4 )+b 3 .

[0178] According to the neural network output q+△q, the robot terminal coordinate p after network optimization is calculated C2 :

[0179] p C2 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ,q+△q)

[0180] Among them, p C2 It can be expressed as (x 3 ,y 3 ,z 3 ).

[0181] In order to better train the neural network, according to the data obtained in step 1 and the measured real coordinates p R And the coordinates obtained from kinematic analysis are used to establish the Loss function:

[0182]

[0183] Among them, (x 1 ,y 1 ,z 1 ) is the measured real robot coordinate p R ,(x 3 ,y 3 ,z 3 ) is the kinematic analysis coordinates for predicting robot joint variables, and the robot compensation model is obtained based on the fully connected neural network training.

[0184] Step 43: Train the DFNN. Randomly select 64 samples from each batch and enter the network. Train for 50 epochs in total. Use the Adam optimizer to iteratively update the network parameters. The initial learning rate is set to 0.01 and the weight decay is 0.001.

[0185] Test DFNN, input the current robot kinematic parameters and real-time data of robot joint variables into the compensation model, calculate the compensation amount △q required to reach the corresponding robot end coordinates, and calculate the network prediction value △q to jointly optimize the robot coordinates p C2 , calculate the robot error after compensation and compare it with the error after kinematic parameter compensation.

[0186] The present invention uses a fully connected neural network to perform error compensation for robot joint variables. Its advantages are: in low-dimensional data and small sample sets, the fully connected neural network has training advantages and avoids the situation where the conversion dimension affects the model training. According to the output form of the joint variable plus the compensation amount we need; building a dual-channel feedforward fully connected neural network can solve the problem of joint variable compensation in a targeted manner.

[0187] A single-layer neural network may overfit the existing data. Using a double-layer and attention mechanism can increase the robustness of the model and balance the weights of network parameters.

[0188] exist Figure 3 In the figure, the robot kinematic parameter compensation simulation based on the circular particle swarm algorithm is shown. The horizontal axis represents the number of samples N, and the vertical axis represents the error distance. The dark line is the robot error distance e before optimization, and the light line is the robot error E after one compensation. 1 From the results, we can see that the dark line is the initial error, and the average initial error is 1.069mm; the light line is the error after the ring particle swarm algorithm optimization, and the average error after optimization is 0.249mm. From the overall trend, the average error decreases by 0.82mm, and the downward trend is stable. The absolute positioning accuracy is improved by 76.7%.

[0189] exist Figure 4 The figure shows the robot quadratic error compensation based on a fully connected neural network of the present invention. The horizontal axis represents the data sample N, the vertical axis represents the Euclidean error distance, and the dark line is the robot error E after kinematic compensation. 1 , the light-colored line is the robot error E after secondary compensation 2 . As can be seen from the figure, the light-colored line is below the dark-colored line. After the robot neural network prediction compensation, the average error is 0.043mm, the maximum error is 0.073mm, the average error decreases by 0.206mm, and the downward trend is stable. The absolute positioning accuracy is improved by 95.98%. On the basis of kinematic parameter compensation, the absolute positioning accuracy is improved by 19.28%. The correctness of the robot kinematic error joint compensation method is basically verified. The present invention can solve the problems such as the reduction of absolute positioning accuracy caused by working conditions such as large loads, and the obvious surface grinding marks caused by excessive grinding forces during robot grinding.

[0190] In addition, the robot's kinematic parameters will change according to the robot's movement and working status. The specific changes depend on the situation. When the robot error exceeds 2mm, parameter identification and error compensation need to be re-performed.

[0191] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, various obvious changes, readjustments and substitutions can be made without departing from the protection scope of the present invention. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.

Claims

1. A robot end position rapid detection device, It is characterized in that It comprises a support body and four pull-wire sensors (40) mounted on the support body; The support body comprises a first tripod, a second tripod and three connecting rods (30); the first tripod is identical to the second tripod, the first tripod and the second tripod are parallel, symmetrical and spaced apart; the three corners of the first tripod and the three corners of the second tripod are respectively connected together by three connecting rods (30); the bottom edge of the first tripod is a first supporting edge (11), and the bottom edge of the second tripod is a second supporting edge (21); the first supporting edge (11), the second supporting edge (21) and the two connecting rods (30) connecting the first supporting edge (11) and the second supporting edge (21) form a supporting frame for supporting on a placement surface.

2. The robot end position rapid detection device according to claim 1, Features: The first tripod and the second tripod are isosceles straight triangles, a right-angled side of the first tripod and the second tripod is the base, and a first hypotenuse (13) of the first tripod and a second hypotenuse (23) of the second tripod are used to face the robot.

3. The robot end position rapid detection device according to claim 2, Features: The first oblique edge (13), the second oblique edge (23), and the two connecting rods (30) connecting the first oblique edge (13) and the second oblique edge (23) form an oblique frame facing the robot, and the four pull-wire sensors (40) are installed at the four corners of the oblique frame.

4. A kinematic parameter identification and compensation method based on the robot end position rapid detection device according to any one of claims 1 to 3, Features: The steps include: Step 1: Determine the actual coordinates p of the robot end point R :Use the robot end position rapid detection device to measure the real coordinates p of the robot’s end point at the current moment R ; Step 2: Describe the theoretical coordinates p of the robot end point: Using the DH modeling method, the theoretical coordinates p of the robot end point at the current moment are described as: p=F(θ i ,d i ,a i ,a i ,q);1≤i≤K In the formula, θ i ,d i ,a i ,α i is the geometric kinematic parameter of the robot’s i-th degree of freedom; where θ i is the rotation angle of the i-th joint; d i represents the z-direction distance of the i-th joint; let the rod connecting the i-th joint and the i+1-th joint be the i-th rod, then a i represents the length of the i-th member; α i represents the torsion angle of the i-th rod; q is the robot joint variable; K is the total number of degrees of freedom of the robot; Step 3: Compensation of theoretical coordinates p: The current robot joint variable q and the current robot end point real coordinates p R As input, the optimized geometric kinematic parameters are taken as output. Based on the ring particle swarm algorithm, the optimal geometric kinematic parameters θ are obtained. i +△θ i ,d i +△d i ,a i +△a i ,α i +△α i ; Among them, △θ i , △d i , △a i and △α i They are θ i ,d i 、a i and α i The optimal compensation value; after one compensation, the theoretical coordinates of the robot end point at the current moment are p C1 Described as: p C1 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,a i +△α i ,q) Step 4: Secondary compensation of theoretical coordinates p: The optimal geometric kinematic parameters after the primary compensation in step 3, the robot joint variables q and the real coordinates p of the robot end point are used. R As a sample data set, the robot joint variables are used as input and the optimized robot joint variables are used as output to build a fully connected neural network, and then the optimized value of the robot joint variable q at the current moment is obtained as q+△q; where △q is the compensation value of the robot joint variable q at the current moment; after secondary compensation, the theoretical coordinates of the robot end point at the current moment are p C2 Described as: p C2 =F(θ i +△θ i ,d i +△d i ,a i +△a i ,a i +△α i ,q+△q).

5. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 4, Features: In step 1, the actual coordinates of the robot end point p R The specific determination method includes the following steps: Step 1A, arranging a robot end position rapid detection device: the robot comprises a frame and a movable part movably mounted on the frame; the robot end position rapid detection device is placed on the periphery of the movable part of the robot, and the ends of the pull wires of four pull wire sensors in the robot end position rapid detection device are fixed at the end area of ​​the movable part; Step 1B, establish the robot coordinate system: select a fixed point on the frame as the base point O of the coordinate system, define the downward direction of the frame as the y direction, the direction in which the active part extends toward the robot end position rapid detection device as the x direction, and the direction perpendicular to x and y as the z direction, thereby establishing the robot coordinate system O-xyz; at this time, the coordinates of the end point P of the robot active part in the robot coordinate system are set to (x, y, z), which are the values ​​to be determined; Step 1C, solve the coordinate value of the end point P of the movable part: the four wire sensors are wire sensor A, wire sensor B, wire sensor C and wire sensor D; for wire sensor A, wire sensor B and wire sensor C, according to the principle that the wire lengths obtained in different ways are equal, establish the following set of equations: In the formula, (x Ae ,y Ae , z Ae ) is the deviation from the end of the cable of the cable sensor A to the end point P of the robot's active part in the robot coordinate system, set value; (x Be ,y Be , z Be ) is the deviation from the end of the cable of the cable sensor B to the end point P of the robot's active part in the robot coordinate system, set value; (x Ce ,y Ce , z Ce ) is the deviation from the end of the cable of the cable sensor C to the end point P of the robot's active part in the robot coordinate system, set value; (x A ,y A , z A ) is the coordinate value of the wire sensor A in the robot coordinate system, a known value; (x B ,y B , z B ) is the coordinate value of the wire sensor B in the robot coordinate system, a known value; (x C ,y C , z C ) is the coordinate value of the wire sensor C in the robot coordinate system, a known value; d A d B and d C are the wire length values ​​of the wire sensor A, the wire sensor B and the wire sensor C obtained through measurement, all of which are known values; By solving equation group (1), we can obtain the end point P (x, y, z) of the active part. The result is the real coordinate p of the end point of the robot. R .

6. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 5, Features: The following steps are also included: Step 1D: Calculate the wire length d of the wire sensor D l :Substitute P(x, y, z) obtained in step 1C into the following formula (2) to calculate d l ; In the formula, (x De ,y De , z De ) is the deviation from the end of the wire of the wire sensor D to the end point P of the robot's active part in the robot coordinate system, set value; (x D ,y D , z D ) is the coordinate value of the wire sensor D in the robot coordinate system, a known value; Step 1E, setting the wire length error △l: according to the actual installation situation of the wire sensor D, setting the allowable error of the wire length in the wire sensor; Step 1F, coordinate verification of the end point P of the active part: Substitute P(x, y, z) obtained in step 1C into the following formula (3) for verification; d D -△l<d l <d D +△l (3) Where, d D is the length of the wire of the wire sensor D obtained by measurement, which is a known value When the coordinates of point P (x, y, z) satisfy formula (3), then P (x, y, z) is the real coordinates of the robot end point p R ; When the coordinates of point P (x, y, z) do not satisfy formula (3), delete P (x, y, z) obtained by current data collection or correct the error in step 1E, and repeat steps 1E and 1F until the true coordinates of the robot end point p are obtained. R .

7. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 4, Features: In step 3, the method for solving the optimal geometric kinematic parameters based on the circular particle swarm algorithm includes the following steps: Step 31: Establish the objective function L, the specific expression is: my L=||p R -p|| 2 Step 32: Solve for the optimal geometric kinematic parameters: The actual coordinates p of the robot end point determined in step 1 are R , the robot joint variable q at the current moment is taken as input. When the objective function L tends to the minimum value, the corresponding geometric kinematic parameters are the optimal geometric kinematic parameters.

8. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 7, Features: In step 32, the objective function L is solved using the following formula (4): in: Where N is the total number of samples, and N>3; is the global optimal fitness value of particle k; g k is the global optimal position of particle k; are the local optimal fitness values ​​of particle 1, particle k, and particle N, respectively; where 1≤k≤N; are the individual optimal fitness values ​​of particle 1, particle N, particle k-1, particle k, particle k+1 and particle N respectively; and are the individual optimal fitness values ​​of particle k after the 1st iteration and the tth iteration respectively; When the number of iterations t meets the maximum number of iterations, the global optimal position g k These are the optimal geometric kinematic parameters obtained by solving.

9. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 8, Features: In step 32, during the iteration process, the velocity update formula of particle k is: V ks (t+1)=wV ks (t)+a 1 b 1 (t)(p ks (t)-x ks (t))+a 2 b 2 (t)(j ks (t)-x ks (t)) (4-3) Where t represents the number of iterations, w represents the inertia weight, s represents the s-th dimension vector of each particle, 1≤s≤4K, and is one of the 4K geometric kinematic parameters; a 1 、a 2 Represents the acceleration factor, the value range is [0,2]; b 1 (t), b 2 (t) represents the random number at the tth iteration, and its value range is [0,1]; V ks (t+1) and V ks (t) are the iteration speeds of the s-th dimension vector in particle k at the t+1th and tth iterations respectively; p ks (t) is the individual optimal position of the s-th dimension vector in particle k at the t-th iteration; j ks (t) is the local optimal position of the s-th dimension vector in particle k at the t-th iteration; x ks (t) is the current position of the s-th dimension vector in particle k at the t-th iteration; During the iteration process, the position update formula of particle k is: x ks (t+1)=x ks (t)+V ks (t+1) (4-4) In the formula, x ks (t) is the current position of the s-th dimension vector in particle k at the t+1th iteration.

10. The kinematic parameter identification and compensation method based on the robot end position rapid detection device according to claim 4, Features: The fully connected neural network has four layers. The first layer is the input layer, the second layer is the dual-channel fully connected layer, the third layer is the dual-channel weight allocation layer, and the fourth layer is the output layer. In the third layer, the attention mechanism is used to determine the cumulative weights of the dual channel outputs.