Method for determining damping coefficient of robot, method for determining interpolation joint angle of robot, electronic device and robot
By determining the robot's damping coefficient and combining it with singular threshold optimization for interpolation joint angle calculation, the randomness problem of the damping coefficient is solved, the calculation accuracy is improved, and singular points are avoided, thus achieving efficient and precise control of the robot's pose.
Patent Information
- Application Number
- CN202411503769.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2044-10-25
AI Technical Summary
In existing technologies, the determination of the damping coefficient of robots is highly random, resulting in low accuracy in joint angle and pose calculations, and failing to effectively avoid wrist singularities.
By obtaining the target interpolation pose error, and combining the correlation between the damping coefficient threshold and the singular threshold, the damping coefficient is determined using a network model or Gaussian distribution function. The singular threshold is then introduced into the inverse kinematics solution to optimize the calculation of the interpolation joint angle.
It reduces the randomness of the damping coefficient, improves the accuracy of interpolation joint angles, and can simultaneously avoid wrist singularities, thereby improving computational efficiency and accuracy.
Smart Images

Figure CN119427425B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of robotics, and more specifically, to a method for determining the damping coefficient of a robot, a method for determining the interpolation joint angle of a robot, electronic equipment, and a robot. Background Technology
[0002] Currently, robots in industrial production primarily perform tasks such as parts handling, product processing and assembly, welding between parts, and surface polishing and painting. With the increasing demand for personalized and customized production, traditional industrial robots suffer from poor adaptability and insufficient flexibility on flexible product lines. Therefore, multi-axis redundant robots, due to their operational flexibility and redundancy, can utilize their redundancy characteristics to achieve tasks such as interference avoidance, circular welding, and high-density placement, and have gradually gained recognition and use in industrial production processes.
[0003] In multi-axis redundant robots, accurately determining the damping coefficient and solving the robot's inverse kinematics are crucial for determining the robot's pose. However, existing methods often result in damping coefficients with a high degree of randomness. Summary of the Invention
[0004] This application provides a method for determining the damping coefficient of a robot, a method for determining the interpolation joint angle of a robot, an electronic device, and a robot, to at least solve the technical problem of the strong randomness of the damping coefficient in the prior art, thereby reducing the fluctuation of robot-related parameters (e.g., joint angles, poses, etc.) determined based on the damping coefficient and improving accuracy.
[0005] According to a first aspect of the embodiments of this application, a method for determining the damping coefficient of a robot having a wrist singularity is provided, the method comprising:
[0006] Obtain the target interpolation pose error;
[0007] Based on the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold, the damping coefficient threshold and singular threshold corresponding to the target interpolation position error are determined.
[0008] The damping coefficient is determined based on the damping coefficient threshold and singular threshold corresponding to the target interpolation position error.
[0009] According to a second aspect of the embodiments of this application, a method for determining the interpolation joint angle of a robot having a wrist singularity is provided, the method comprising:
[0010] The method described in the second aspect of the embodiments of this application is used to determine the damping coefficient of the robot;
[0011] Obtain the joint angular velocity of the robot and the pose difference velocity between the current interpolation point and the previous interpolation point on the motion trajectory;
[0012] The interpolation joint angle of the current interpolation point is determined based on the first correlation between the joint angular velocity, the pose differential velocity, and the base Jacobian matrix of the robot, and the second correlation between the damping coefficient and the base Jacobian matrix.
[0013] According to a fourth aspect of the embodiments of this application, an electronic device is provided, the electronic device comprising:
[0014] Memory, used to store one or more computer instructions;
[0015] A processor is configured to implement the method described in the first or second aspect of the embodiments of this application according to the computer instructions.
[0016] According to a third aspect of the embodiments of this application, a robot is provided, the robot having a wrist singularity, the robot employing the method described in the first or second aspect of the embodiments of this application, or having the electronic device described in the fourth aspect of the embodiments of this application.
[0017] By adopting the embodiments of this application, on the one hand, the randomness of the damping coefficient determined by the prior art can be reduced, and a damping coefficient that is conducive to improving the efficiency of subsequent calculations can be determined; on the other hand, the accuracy of the interpolated joint angle calculated subsequently can be improved; furthermore, by introducing a singular threshold in the calculation of the damping coefficient, wrist singularity avoidance and inverse kinematics solution can be performed simultaneously during the calculation of the interpolated joint angle. Attached Figure Description
[0018] Figure 1 This is a flowchart illustrating a method for determining the damping coefficient of a robot according to an embodiment of this application;
[0019] Figure 2 This is a flowchart illustrating a method for determining the interpolation joint angle of a robot according to an embodiment of this application;
[0020] Figure 3 This is a flowchart illustrating a method for determining the interpolation joint angle of a robot according to an embodiment of this application;
[0021] Figure 4 This is a flowchart illustrating a real-time inverse kinematics solution and accuracy compensation method for a seven-axis robotic arm according to an embodiment of this application.
[0022] Figure 5 This is a link coordinate system for a seven-axis robotic arm according to an embodiment of this application;
[0023] Figure 6 This is a DH parameter table according to an embodiment of this application;
[0024] Figure 7 This is a schematic diagram of a theoretically planned Cartesian space straight-line trajectory according to an embodiment of this application;
[0025] Figure 8A This is a spatial trajectory curve of joints 1-3 of a seven-axis robotic arm according to an embodiment of this application;
[0026] Figure 8B This is a spatial trajectory curve of joints 4 to 7 of a seven-axis robotic arm according to an embodiment of this application;
[0027] Figure 9 This is a schematic diagram illustrating an actual interpolation method according to an embodiment of this application;
[0028] Figure 10A This is a schematic diagram of an interpolation point position error according to an embodiment of this application;
[0029] Figure 10B This is a schematic diagram of an interpolation point attitude error according to an embodiment of this application;
[0030] Figure 11 This is a system schematic diagram of an electronic device according to an embodiment of this application. Detailed Implementation
[0031] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0032] It should be understood that "multiple" as mentioned herein refers to two or more. In the description of the embodiments of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Furthermore, to facilitate a clear description of the technical solutions of the embodiments of this application, the terms "first," "second," etc., are used in the embodiments of this application to distinguish identical or similar items with essentially the same function and effect. Those skilled in the art will understand that the terms "first," "second," etc., do not limit the quantity or execution order, and the terms "first," "second," etc., do not necessarily imply differentness.
[0033] Furthermore, the terms “comprising” and “having”, and any variations thereof, are intended to cover non-exclusive inclusion, such that a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those steps or units that are explicitly listed, but may include other steps or units that are not explicitly listed or that are inherent to such process, method, product, or apparatus.
[0034] First, the terminology used in the embodiments of this application will be introduced.
[0035] Multi-axis redundant robots refer to robots or robot systems with more degrees of freedom than required for a specific task. For example, for a task with a specified end-effector position and orientation, six degrees of freedom is the minimum number of degrees of freedom required for the task. Therefore, robots with seven or more axes, six-axis robots with guide rails or positioners, and multi-robot coordinated operation systems can all be called redundant robots in a broad sense.
[0036] The pose of a robotic arm / robot typically includes two parts: position and orientation. Position describes the coordinates of the robotic arm's end effector in three-dimensional space, while orientation describes the orientation of the end effector relative to a reference coordinate system. These two parts together constitute a complete pose description of the robotic arm.
[0037] Pose interpolation refers to the process in motion planning for a robotic arm where a series of intermediate poses are calculated using a specific algorithm based on the initial and target poses, enabling the robotic arm to smoothly transition from the initial pose to the target pose. This process requires consideration of factors such as the robotic arm's kinematic constraints, dynamic characteristics, and task requirements. There are various methods for robotic arm pose interpolation, some of the most common being:
[0038] Linear interpolation: In Cartesian space, the position of the robotic arm's end effector is directly interpolated linearly while maintaining the orientation or performing simple orientation interpolation. This method is simple and intuitive, but may not meet complex motion requirements.
[0039] Circular interpolation: A circular arc is planned along the movement path of the robotic arm, causing the robotic arm to move along the arc trajectory. This method can smoothly change the posture of the robotic arm while reducing shock and vibration during movement.
[0040] Spline interpolation: This method uses spline curves (such as B-splines and NURBS curves) to plan the motion trajectory of the robotic arm, achieving a smoother and more natural motion effect. While this method requires higher computational complexity, it provides more precise and flexible motion control.
[0041] Joint space interpolation: In joint space, the angles of each joint of the robotic arm are directly interpolated, and the corresponding Cartesian space pose is obtained through inverse kinematics. This method can make full use of the joint performance of the robotic arm, but it may have certain difficulties in handling complex motion trajectories.
[0042] Taking linear interpolation as an example, the implementation steps are roughly as follows:
[0043] Determine the initial and target poses: Based on the task requirements, determine the initial and target poses of the robotic arm. Calculate position interpolation: Perform linear interpolation on the initial and target positions in Cartesian space to obtain an intermediate position sequence. Attitude interpolation (optional): If the attitude needs to be changed, methods such as equivalent axis-angle coordinate system representation can be used for attitude interpolation. Inverse kinematics solution: Using the interpolated intermediate poses (including position and attitude) as input, obtain the corresponding joint angle sequence through inverse kinematics solution. Control the robotic arm motion: Based on the obtained joint angle sequence, control the robotic arm to move according to the planned motion trajectory.
[0044] Wrist singularity: This is a special situation encountered by robots during movement. It occurs under specific joint configurations, leading to a reduction in the robot's degrees of freedom or abrupt changes in joint velocity caused by minute end-effector movements. Wrist singularity is a type of singularity in industrial robots, primarily occurring when the robot's wrist joints (usually the 4th and 6th axes) are in specific positions, causing abnormal kinematic performance. Conditions for occurrence: Wrist singularity typically occurs when the 4th and 6th axes are parallel, i.e., when the angle of the 5th axis (usually the wrist rotation axis) is 0° or close to 0°. In this case, forward rotation of the 4th axis can be compensated for by reverse rotation of the 6th axis, resulting in an infinite number of solutions for the pose of a point in space.
[0045] Solving joint angles using the damped least squares method is a crucial step in interpolation pose estimation. The selection of the damping coefficient significantly impacts the algorithm's computational efficiency and accuracy. Traditionally, damping coefficients are chosen based on fixed expressions or empirical formulas, which introduces considerable randomness, leading to significant fluctuations in the accuracy of the calculated joint angles.
[0046] In response, this application provides a method for determining the damping coefficient of a robot, wherein the robot has a wrist singularity, such as... Figure 1 As shown, the method includes the following processes.
[0047] S100: Obtain the target interpolation pose error.
[0048] Here, the target interpolation pose error can be understood as the maximum allowable interpolation pose error.
[0049] The maximum interpolation pose error includes: the robot's TCP (Tool Center Point) end-effector position error and the attitude error. Position error refers to the deviation vector between the robot's actual interpolation position and the theoretically planned position, typically composed of three components along the X, Y, and Z axes.
[0050] S102: Based on the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold, determine the damping coefficient threshold and singular threshold corresponding to the target interpolation position error.
[0051] In this embodiment, the correlation between the target interpolation pose error and the damping coefficient threshold and the singular threshold is determined in advance, or a tool (e.g., a network model) that can determine or reflect the correlation between the target interpolation pose error and the damping coefficient threshold and the singular threshold is designed in advance.
[0052] S104: Determine the damping coefficient based on the damping coefficient threshold and singular threshold corresponding to the target interpolation position error.
[0053] The method provided in this embodiment determines the damping coefficient threshold and singular threshold corresponding to the target interpolation position error based on the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold. Furthermore, it determines the damping coefficient based on these thresholds. Therefore, compared to existing technologies that select the damping coefficient value based on fixed expressions or empirical formulas, this method not only reduces the randomness of the damping coefficient to a certain extent but also considers the robot's singularity problem simultaneously by introducing singular thresholds. This results in more accurate inverse kinematics solutions based on the damping coefficient.
[0054] Optionally, in one implementation of this embodiment, S102 is implemented as follows: the target interpolation pose error is input into a network model that takes the target interpolation pose error as input and outputs a damping coefficient threshold and a singular threshold, thereby obtaining the damping coefficient threshold and singular threshold corresponding to the target interpolation position error. Using this implementation, the trained network model reflects or determines the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold, which helps to more accurately determine the preferred damping coefficient, thereby improving the accuracy and efficiency of inverse kinematics solution.
[0055] The network model can be a backpropagation (BP) network model or a convolutional neural network model. The input data used during network model training includes the interpolation pose error, and the output data used during training includes the damping coefficient threshold and singular threshold corresponding to the interpolation pose error.
[0056] For example, the training data can be randomized. For instance, the maximum value of the damping coefficient (i.e., the damping coefficient threshold) and the singular threshold can be randomly input. Based on these two parameters, the inverse kinematics of the robot can be solved using the damped least squares method. Then, a compensation algorithm is used to compensate for the results, obtaining the corresponding joint angles (the actually solved joint angles). The error between the pose corresponding to this joint angle and the theoretically given position is the interpolation pose error in the training model data. Thus, the input data used for training—the interpolation pose error—and the output data used for training—the maximum value of the damping coefficient and the singular threshold—are obtained.
[0057] For example, the training process can adopt the conventional model training process, which will not be described in detail in the embodiments of this application.
[0058] Optionally, in one implementation of this embodiment, S104 can be implemented in the following way: the damping coefficient is determined according to the Gaussian distribution law of the damping coefficient threshold and the singular threshold corresponding to the target interpolation position error.
[0059] Specifically, the damping coefficient is determined based on the following Gaussian distribution function:
[0060] Where λ represents the damping coefficient, λ max ε represents the damping coefficient threshold corresponding to the target interpolation position error, k represents the singular threshold corresponding to the target interpolation position error, and k represents the condition number in the Gaussian distribution function. The Gaussian distribution function is continuous and smooth, which means that it is defined and has a derivative at all points. Therefore, it is more convenient to use the Gaussian distribution function for mathematical operations in the scenario applied in this embodiment, especially when performing differentiation and integration.
[0061] Figure 2 This application describes a method for determining the interpolation joint angles of a robot having a wrist singularity, according to one embodiment of the present application. The method includes the following processes.
[0062] S200: Obtain the robot's damping coefficient. For details, please refer to... Figure 1 The illustrated embodiment obtains the damping coefficient of the robot.
[0063] S202: Obtain the pose difference velocity between the current interpolation point and the previous interpolation point on the robot's motion trajectory. "Obtain" includes various methods such as calculation and direct acquisition from known information.
[0064] S204: Determine the joint angular velocity of the current interpolation point based on the conversion relationship between the joint angular velocity of the current interpolation point and the pose differential velocity, wherein the conversion relationship includes the damping coefficient.
[0065] S206: Determine the interpolation joint angle of the current interpolation point based on the joint angular velocity of the current interpolation point.
[0066] The method provided in this embodiment determines, on the one hand, the damping coefficient of the robot, which is beneficial to improving the efficiency of subsequent calculations, using the method for determining the damping coefficient of the robot provided above; on the other hand, the joint angular velocity of the current interpolation point is calculated based on the conversion relationship between the joint angular velocity of the current interpolation point and the pose difference velocity (the damping coefficient is introduced in the conversion relationship), and then the interpolation joint angle of the current interpolation point is calculated, thereby improving the accuracy of the calculated interpolation joint angle; furthermore, since a singular threshold is introduced in the calculation of the damping coefficient, wrist singularity avoidance and inverse kinematics solution can be performed simultaneously during the calculation of the interpolation joint angle.
[0067] Taking a seven-axis robot as an example, there are two configurations: SRS and non-SRS. SRS configuration refers to the robot arm's axes 1, 2, and 3 being collinear, and axes 5, 6, and 7 being collinear. Non-SRS configuration refers to the robot arm's axes 1, 2, and 3 not being collinear, or axes 5, 6, and 7 not being collinear. For solving the inverse kinematics problem for these two configurations, inverse kinematics solution methods can be divided into two categories: closed-form solutions (geometric methods) and numerical solutions (iterative methods, transpose methods, and pseudo-inverse methods). Closed-form solutions are fast, efficient, and easy to control in real time, but are generally limited to SRS configuration robots. Numerical solutions are more versatile and can solve inverse kinematics problems for both SRS and non-SRS configuration robots, but require solving a system of nonlinear equations, and the results are not unique. Furthermore, it cannot guarantee that all solutions or the accuracy of the solved pose can be guaranteed.
[0068] Some existing techniques exist, such as using the standard DH parameter method to establish a DH parameter model of a 7-axis robot, obtaining the expression for the transformation matrix from the base coordinate system to the flange coordinate system based on the robot's forward motion algorithm. Then, an iterative algorithm is used to solve the above equations to obtain the inverse kinematics joint angles of the 7-axis robot, thus realizing the inverse kinematics of the 7-axis robot. However, this inverse kinematics method lacks versatility and is difficult to apply to singularity avoidance.
[0069] For example, by constructing a virtual six-axis robot that satisfies the Pieper criterion (an important criterion in robotics that provides crucial guidance for solving robot inverse kinematics; following the Pieper criterion allows for more efficient solutions to robot inverse kinematics problems, thereby improving robot performance and stability), and using the inverse kinematics solution of the virtual six-axis robot combined with a probe-fit method, the real-time inverse kinematics calculation problem for the biased seven-axis robot was solved. However, this inverse kinematics method does not consider the robot's singularity problem and lacks versatility.
[0070] Compared to existing technologies, the method provided in this embodiment has strong versatility in inverse kinematics solution and can perform singularity avoidance and inverse kinematics solution for both SRS and non-SRS seven-axis robots.
[0071] Optionally, in one implementation of this embodiment, the transformation relationship satisfies:
[0072]
[0073] Where vel_joint represents the joint angular velocity of the current interpolation point, σ1,σ2,...,σ m Let represent the singular values of the base Jacobian matrix, λ represent the damping coefficient, and Ui and Vi represent the left and right singular vectors of the base Jacobian matrix, respectively. The position differential velocity is represented by m, which is a positive integer.
[0074] By adopting this implementation method, the introduction of a damping coefficient into the transformation relationship can not only avoid the transformation relationship being unsolvable due to the denominator being 0, but also calculate a more accurate joint angular velocity.
[0075] The following method can be used to obtain Ui and Vi. First, obtain the joint angle of the previous interpolation point; then, determine the transfer matrix between the links of the robot based on the joint angle of the previous interpolation point; then, determine the base Jacobian matrix based on the calculation relationship between the transfer matrix, the relative Jacobian matrix, and the base Jacobian matrix; finally, perform SVD decomposition on the base Jacobian matrix to obtain Ui and Vi. A detailed explanation of this process is provided below.
[0076] Optionally, in one implementation of this embodiment, such as Figure 3 As shown, the method also includes the following processing.
[0077] S300: Determine the pose of the current interpolation point based on the interpolation joint angle of the current interpolation point.
[0078] S302: Determine whether the error between the pose of the current interpolation point and the theoretically planned pose is less than a set threshold. If it is less, execute S304; otherwise, execute S306.
[0079] S304: The interpolation joint angle of the current interpolation point is valid. In other words, the interpolation joint angle of the current interpolation point is set to the actual interpolation angle.
[0080] S306: After adjusting the pose difference velocity based on the error between the current interpolation point's pose and the theoretically planned pose, the interpolation joint angle of the current interpolation point is re-determined based on the adjusted pose difference velocity.
[0081] In this embodiment, by repeatedly executing S300-S306, an effective interpolation joint angle can be obtained.
[0082] Optionally, in S306, the pose differential speed can be adjusted based on the error between the pose of the current interpolation point and the theoretically planned pose in the following manner:
[0083] First, the pose difference velocity error is determined based on the error between the pose of the current interpolation point and the theoretically planned position; then, returning to step S202, the positions of the current interpolation point and the previous interpolation point are compared.
[0084] The pose difference velocity is subtracted from the position difference velocity error to obtain the new pose difference velocity. Subsequent processing steps S204 and beyond are then performed based on this new pose difference velocity.
[0085] The method provided in this embodiment can perform accuracy compensation when the error between the pose of the current interpolation point and the theoretically planned pose is not less than a set threshold, thereby more efficiently determining the interpolation joint angle that meets the requirements.
[0086] Figure 4 This is a flowchart illustrating a real-time inverse kinematics solution and accuracy compensation method for a seven-axis robotic arm according to an embodiment of this application. (Refer to...) Figure 4 The method, taking linear interpolation as an example, includes the following processing.
[0087] Step 1: Train the network model. Specifically, a large amount of data between the maximum value of the damping coefficient, the singular threshold, and the interpolation pose error is obtained using empirical formulas. Then, a neural network is used to train the preceding network model, where the interpolation pose error is the network input, and the maximum value of the damping coefficient and the singular threshold are the network outputs.
[0088] Step 2: Determine the damping coefficient. Specifically, based on the given maximum interpolation pose error (i.e., the target interpolation pose error) and the preceding network model, the corresponding damping coefficient is obtained.
[0089] Step 3: Given the planned pose of the current interpolation point on the straight trajectory, the actual pose of the previous interpolation point, and the actual joint angle of the previous interpolation point;
[0090] Step 4: Calculate the TCP differential velocity. Specifically, calculate the pose differential velocity vel_pos between the current interpolation point and the previous interpolation point.
[0091] Pose differential velocity describes the rate of change of a robot or robotic arm end effector (such as a gripper or tool) in pose space. Pose typically consists of two parts: position and orientation. Position refers to the coordinates of the end effector in space, while orientation describes its orientation or direction. Pose differential velocity can be decomposed into linear velocity and angular velocity.
[0092] Linear velocity: describes the linear motion velocity of the end effector in space, that is, the velocity vector along a certain direction. This velocity vector usually has three components, corresponding to the velocities on the X, Y, and Z coordinate axes respectively.
[0093] Angular velocity: describes the rotational speed of an end effector about its center of mass or a fixed point. It is usually represented by a vector whose direction is the direction of the rotation axis and whose magnitude is the angular velocity of rotation (in radians per second).
[0094] Step 5: Calculate the transfer matrix between links. Specifically, the joint angles of the previous interpolation point in Step 3 are introduced into the forward kinematics module to obtain the transfer matrix between links. The forward kinematics module, also known as the forward kinematics model, refers to the relationship between the position and orientation of the robot's end effector and the robot's joint angles. In other words, given the robot's joint angles, the forward kinematics module can calculate the exact position and orientation of the robot's end effector. This model is one of the most fundamental models in the field of robot control and is crucial for tasks such as robot posture control, target position calculation, and simulation.
[0095] Step 6: Calculate the relative Jacobian matrix T J. Specifically, the relative Jacobian matrix is calculated based on the transfer matrix between the links.
[0096] Step 7: Calculate the base Jacobian matrix J. Specifically, the base Jacobian matrix J can be calculated based on the transformation relationship between the relative Jacobian matrix and the base Jacobian matrix.
[0097] Step 8: SVD decomposition of the base Jacobian matrix J. Specifically, the base Jacobian matrix is decomposed using SVD to obtain matrices U, S, and V. Here, U is the identity matrix composed of eigenvectors, S is the diagonal matrix composed of eigenvalues, and V is the identity matrix composed of eigenvectors. The formula is as follows:
[0098] J = U * S * V T (1)
[0099] Step 9: Introduce the general formula for the relation:
[0100] Specifically, we introduce a general formula relating the joint angular velocity vel_joint and the pose difference velocity vel_pos, and then substitute the vel_pos calculated in step 4 and the J obtained in step 8 into the above general formula (2) to obtain the general formula:
[0101] Step 10: Introduce the damping coefficient and calculate the joint angular velocity vel_joint at the current interpolation point. Specifically, if the denominator σ i If the denominator is 0, the calculation result will be infinite. To avoid the denominator being 0, the damping coefficient λ is introduced into the general formula (3) in step 9, which yields:
[0102]
[0103] Where vel_joint represents the joint angular velocity;
[0104] σ1,σ2...,σ m : Singular values of J;
[0105] λ: Damping coefficient;
[0106] Ui, Vi: The left and right singular vectors of the Jacobian matrix;
[0107] TCP differential speed.
[0108] Furthermore, the joint angular velocity vel_joint of the current interpolation point can be calculated.
[0109] Step 11: Calculate the joint angle corresponding to the current interpolation point;
[0110] Step 12: Introduce the positive kinematics module to obtain the actual pose corresponding to the current interpolation point;
[0111] Step 13: Determine whether the error between the actual pose and the theoretically planned pose corresponding to the current interpolation point is less than the pose accuracy threshold (i.e., set the threshold).
[0112] More specifically, in step 13, the actual pose corresponding to the current interpolation point is subtracted from the theoretically planned pose, and the error between the poses is calculated to obtain the joint angular velocity to be compensated.
[0113] Step 14: If the angle is less than the pose accuracy threshold, set the calculated joint angle as the actual interpolation angle and end the process. If the angle is greater than the pose accuracy threshold, calculate the pose error of the current interpolation point and feed it back to Step 4, repeating the subsequent steps until the process ends.
[0114] More specifically, Figure 1In the illustrated embodiment, the main cause of the maximum interpolation pose error, besides the inherent error of the robot's mechanical structure, is the additional introduction of a damping coefficient λ into the original mathematical model (i.e., Equation 4). This is intended to ensure that the Jacobian matrix is invertible at singular points, which also introduces errors.
[0115] Similarly, the attitude error is also a deviation vector caused by the introduction of the damping coefficient λ. When the Euler angles are described using the ZYX method, the attitude error consists of three components: the alphy Euler angle, the beta Euler angle, and the gamma Euler angle. Since λ is artificially introduced in formula (4), the calculation result will have errors. Therefore, when the pose error is greater than the pose accuracy threshold, the TCP differential velocity in step 4 needs to be compensated using the joint angular velocity to be compensated corresponding to the pose error, and then step 5 and subsequent processing are performed based on the compensated TCP differential velocity.
[0116] The method provided in this embodiment uses a seven-axis industrial robot as the experimental object, but it is not limited to seven-axis industrial robots. It can be applied to all multi-axis robots with wrists.
[0117] The method provided in this embodiment uses an improved damped least squares method combined with a feedforward accuracy compensation algorithm to solve the inverse kinematics problem of a seven-axis robotic arm. The training of the damping coefficient is not limited to using a neural network algorithm; other machine learning algorithms such as deep learning and reinforcement learning can also be used to train the damping coefficient and optimize it using genetic algorithms or ant colony algorithms. Furthermore, the pose error is not limited to being fed back into the original damped least squares formula; it can also be fed back into other accuracy compensation algorithms, and this application does not impose any restrictions on this.
[0118] The method provided in this embodiment offers a high-precision inverse kinematics solution for multi-axis robots. Taking a seven-axis industrial robot as an example, this method is applicable to both SRS and non-SRS seven-axis robots for singularity avoidance and inverse kinematics solution, significantly improving the accuracy of the solution. Specifically, on one hand, the optimized damping coefficient and damped least squares method are used to find the optimal inverse solution. The damping coefficient affects the solution accuracy and efficiency; therefore, a BP neural network is used to pre-train a model of the maximum interpolation position error and damping coefficient for this robot model. Based on the required maximum interpolation error, the damping coefficient is determined, enabling dynamic adjustment of the optimal damping coefficient, thereby greatly improving the accuracy of the solution. On the other hand, the pose error caused by the damping coefficient is compensated for using a feedforward method until the pose accuracy threshold is met, improving the accuracy of the final result.
[0119] In one specific implementation of this embodiment, a real-time inverse kinematics solution and accuracy compensation method for a seven-axis robotic arm includes the following processing steps.
[0120] Step 1: Obtain a large amount of data on the relationship between the maximum value of the damping coefficient, the singular threshold, and the interpolation pose error using empirical formulas. Then, train a pre-processed network model using a neural network, where the interpolation pose error is the network input and the maximum value of the damping coefficient and the singular threshold are the network outputs.
[0121] Step 2: Given the required maximum interpolation pose errors of 0.1 mm and 0.1°, and based on the network model, obtain the corresponding maximum damping coefficient λ. max The value is 1.8, the singular domain value ε is 300, and the damping coefficient λ is determined based on the Gaussian distribution function.
[0122]
[0123] In the formula, λ max — Maximum damping factor; ε — Singular threshold; k — Condition number.
[0124] Step 3: Establish the robot link coordinate system, such as... Figure 5 As shown; determine the robot's DH parameters, such as... Figure 6 As shown in the table below.
[0125] in, Figure 5 The diagram illustrates the mapping relationship between robot joint angles and end effector TCP pose determined using the DH modeling method. The DH modeling method establishes a fixed coordinate system on each link of the robot according to certain rules. It then determines the length, rotation parameters, offsets, and joint angle parameters of each link by analyzing the positional relationships between adjacent coordinate systems. Finally, by substituting these parameters into the coordinate system transformation formula between adjacent links, the position and orientation of the end effector relative to the robot base can be calculated. This is a conventional method. Figure 5 The coordinate systems shown are all determined based on joint rotation and the right-hand rule, which is a conventional method.
[0126] exist Figure 6 In the table, the DH parameters include the length a of the link. i , Linkage angle α i Offset d between adjacent links i and joint angle θ i The link parameter is defined as: the length a of the link. i For along X i Axis, from Z i Move to Z i+1 Distance; Linkage angle α i For X i Axis, from Z i Rotate to Z i+1 Angle; Linkage offset d i For along Z iAxis, from X i-1 Move to X i Distance; joint angle θ i For along Z i Axis, from X i-1 Rotate to X i The angle.
[0127] Specifically, in step 3, Cartesian space trajectory planning can be performed using a straight-line trajectory planning method. For example, given the planned pose of the current interpolation point of the straight-line trajectory as P[127.3,47.7,1029.8,24.6,-10.2,-176.4], the actual pose of the starting point as P0[127,47.4,1029.9,24.4,-10.1,-176.5], the joint angle of the starting point as J0[10,10,10,10,15,10,10], and the joint angle of the ending point as J1[20,20,20,20,20,20,50].
[0128] Step 4: Calculate the pose difference velocity vel_pos between the current interpolation point and the previous interpolation point. The position velocity is obtained through position transformation, and the attitude velocity is obtained through quaternion transformation.
[0129] Step 5: Introduce the joint angle of the previous interpolation point in Step 3 into the forward kinematics module to obtain the transfer matrix between the links.
[0130] Step 6: Calculate the relative Jacobian matrix T J;
[0131]
[0132] Step 7: Based on the transformation relationship between the relative Jacobian matrix and the base Jacobian matrix, the base Jacobian matrix J can be calculated.
[0133]
[0134] Step 8: Perform SVD decomposition on the base Jacobian matrix to obtain matrices U, S, and V. Here, U is the identity matrix composed of eigenvectors, S is the diagonal matrix composed of eigenvalues, and V is the identity matrix composed of eigenvectors.
[0135] J = U * S * V T
[0136] Step 9: Introduce the general formula relating the joint angular velocity vel_joint and the end effector pose velocity vel_pos, and then substitute the vel_pos calculated in Step 4 and the J obtained in Step 8 into the following general formula:
[0137]
[0138] Step 10: Introducing the damping coefficient λ yields the following;
[0139]
[0140] Step 11: Calculate the joint velocity vel_joint at the current interpolation point.
[0141] Step 12: Calculate the joint angle corresponding to the current interpolation point. For example, the joint angle corresponding to the current interpolation point can be determined based on vel_joint, the controller's interpolation period (e.g., 0.004s), and the joint angle of the previous pose.
[0142] Step 13: Introduce the forward kinematics module to obtain the actual pose corresponding to the current interpolation point.
[0143] Step 14: Determine whether the error between the actual pose and the theoretically planned pose corresponding to the current interpolation point is less than the pose accuracy threshold.
[0144] Step 15: If the angle is less than the pose accuracy threshold, set the calculated joint angle as the actual interpolation angle and end the process; if the angle is not less than the pose accuracy threshold, calculate the pose error of the current interpolation point and feed it back to Step 4, and repeat the subsequent steps until the end.
[0145] Step 16: Given the planned straight-line trajectory at the end, such as... Figure 7 As shown. Following the steps described above, the inverse solution corresponding to the linear interpolation pose is obtained, resulting in the joint trajectory graph, as shown. Figure 8A and Figure 8B As shown. Then, substituting the obtained joint trajectories into the forward kinematics yields the actual interpolation pose, as shown. Figure 9 As shown, and compared with the theoretical pose, the following results were obtained: Figure 10A and 10B The pose interpolation error diagram is shown. Combined with, for example... Figure 8A And the joint trajectory corresponding to the path shown in 8B ( Figure 8A and Figure 8B As can be seen from the actual interpolated joint spatial trajectory, ① the damping coefficient combined with the damping least squares method combined with the accuracy compensation algorithm used in this application embodiment can correctly calculate the inverse solution of the seven-axis robot arm; ② its corresponding joint trajectory is smooth and meets the requirements of continuous speed, acceleration and agility; ③ it is synchronously imported into the no-load for verification and meets the real-time requirements.
[0146] This application also provides an electronic device, including a memory and a processor. The memory stores computer instructions, and the processor is used to invoke the computer instructions to implement the method provided in this application, for example, to implement... Figures 1-4 The method provided in any of the embodiments.
[0147] Specifically, such as Figure 11 As shown, the electronic device includes a processor 100, at least one communication bus 200, a user interface 300, at least one external communication interface 400, and a memory 500. The communication bus 200 is configured to enable communication between these components. The user interface 300 may include a display screen, and the external communication interface 400 may include standard wired and wireless interfaces.
[0148] This application also provides a computer program product that, when executed, implements the method provided in this application embodiment, for example, implementing... Figures 1-4 The method provided in any of the embodiments.
[0149] This application also provides a computer-readable storage medium storing a computer program product, which, when executed, implements the method provided in this application embodiment, for example, implementing... Figures 1-4 The method provided in any of the embodiments.
[0150] The descriptions of the above computer program products, computer-readable storage media, and electronic devices are similar to those of the above method embodiments, and have similar beneficial effects. For any technical details not disclosed in the computer program products, computer-readable storage media, and electronic devices of this application, please refer to the descriptions of the method embodiments of this application for understanding.
[0151] This application also provides a robot, which is a multi-axis robot and has a unique wrist. This robot employs the methods provided in this application, for example, using... Figures 1-10B The method in the relevant embodiments, or the robot having Figure 11 The electronic device shown.
[0152] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0153] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0154] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0155] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer, or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital versatile disc (DVD)), or a semiconductor medium (e.g., solid state disk (SSD)). It is worth noting that the computer-readable storage medium mentioned in the embodiments of this application can be a non-volatile storage medium; in other words, it can be a non-transient storage medium.
[0156] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, displayed data, etc.), and signals involved in the embodiments of this application are all authorized by the user or fully authorized by all parties, and the collection, use, and processing of related data must comply with the relevant laws, regulations, and standards of the relevant countries and regions. For example, the scene data of the current frame in the 3D virtual scene involved in the embodiments of this application, the client's device information, and the scene interaction information are all obtained with full authorization.
[0157] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A method for determining the damping coefficient of a robot, the robot having a wrist singularity, characterized in that, The method includes: Obtain the target interpolation pose error; Based on the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold, the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error are determined. The damping coefficient is determined based on the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error.
2. The method according to claim 1, characterized in that, The step of determining the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error based on the correlation between the target interpolation pose error and the damping coefficient threshold and singular threshold includes: By inputting the target interpolation pose error into a network model that takes the target interpolation pose error as input and the damping coefficient threshold and singular threshold as output, the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error are obtained.
3. The method according to claim 2, characterized in that, The input data used by the network model during training includes: interpolation pose error; the output data used by the network model during training includes: damping coefficient threshold and singular threshold corresponding to the interpolation pose error; and / or, The network model is a BP neural network model or a convolutional neural network model.
4. The method according to claim 1, characterized in that, The step of determining the damping coefficient based on the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error includes: The damping coefficient is determined based on the Gaussian distribution of the damping coefficient threshold and the singular threshold corresponding to the target interpolation pose error.
5. The method according to claim 4, characterized in that, The step of determining the damping coefficient based on the Gaussian distribution of the damping coefficient threshold and singular threshold corresponding to the target interpolation pose error includes: The damping coefficient is determined based on the following Gaussian distribution function: ; in, This represents the damping coefficient. This represents the damping coefficient threshold corresponding to the target interpolation pose error. The target interpolation pose error corresponds to the singular threshold, and k represents the condition number in the Gaussian distribution function.
6. A method for determining the interpolation joint angle of a robot, the robot having a wrist singularity, characterized in that, The method includes: The damping coefficient of the robot is determined using the method described in any one of claims 1-5; Obtain the pose difference velocity between the current interpolation point and the previous interpolation point on the robot's motion trajectory; The joint angular velocity of the current interpolation point is determined based on the conversion relationship between the joint angular velocity of the current interpolation point and the pose differential velocity, wherein the conversion relationship includes the damping coefficient; The interpolation joint angle of the current interpolation point is determined based on the joint angular velocity of the current interpolation point.
7. The method according to claim 6, characterized in that, The transformation relationship satisfies: in; vel_joint This represents the joint angular velocity of the current interpolation point. The singular values of the base Jacobian matrix are represented. This represents the damping coefficient. Ui and Vi Let represent the left and right singular vectors of the base Jacobian matrix, respectively. This represents the pose differential velocity. m Is a positive integer.
8. The method according to claim 7, characterized in that, The method further includes: Obtain the joint angle of the previous interpolation point; The transfer matrix between the links of the robot is determined based on the joint angle of the previous interpolation point; The base Jacobian matrix is determined based on the computational relationship between the transfer matrix, the relative Jacobian matrix, and the base Jacobian matrix. The base Jacobian matrix is obtained by performing SVD decomposition. Ui and Vi .
9. The method according to claim 6, characterized in that, The method further includes: The pose of the current interpolation point is determined based on the interpolation joint angle of the current interpolation point. Determine whether the error between the pose of the current interpolation point and the theoretically planned pose is less than a set threshold. If it is less than the set threshold, then the interpolation joint angle of the current interpolation point is valid, or... If the value is not less than a set threshold, the pose difference velocity is adjusted according to the error between the pose of the current interpolation point and the theoretically planned pose, and then the interpolation joint angle of the current interpolation point is re-determined according to the adjusted pose difference velocity.
10. An electronic device, characterized in that, The electronic device includes: Memory, used to store one or more computer instructions; A processor configured to implement the method as described in any one of claims 1-9 according to the computer instructions.
11. A robot having a peculiar wrist, characterized in that, The robot employs the method as described in any one of claims 1-9, or has the electronic equipment as described in claim 10.
Citation Information
Patent Citations
Joint singular point treatment method, device, equipment and storage medium
CN109571481A
Inverse solution method and device for seven-joint redundant degree-of-freedom robot
CN114714335A