Industrial robot work trajectory optimization method

By identifying and reselecting key neighborhoods in the trajectory of industrial robots, optimizing the tool's rotation angle around the axis and inverse kinematic posture branches, the risks of wrist flipping, elbow reversal, and limit in the robot trajectory are solved, generating continuous target operation trajectories and improving the stability and safety of robot operation.

CN123149980APending Publication Date: 2026-11-24SHANDONG YUANXING NETWORK TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611340986.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-01
Publication Date
2026-11-24

AI Technical Summary

Technical Problem

Existing industrial robot trajectory optimization technologies fail to effectively identify and address risks such as wrist flipping, elbow reversal, or joint limitation caused by tool rotation around the axis, inverse kinematic posture branches, and joint angle sequences in local areas of the work trajectory. This results in problems such as joint jumps, unstable inverse kinematic branch switching, or insufficient mechanical limit margins in critical work areas.

Method used

By acquiring the end position of the work trajectory point, the tool axis direction, the tool rotation angle around the axis, the inverse kinematic posture branch, and the joint angle sequence, the wrist joint flipping neighborhood, the elbow joint reversal neighborhood, or the limiting neighborhood are identified. The tool rotation angle around the axis or the inverse kinematic posture branch is reselected to keep the end position and the tool axis direction unchanged within the trajectory area, and the posture change is transferred to the non-work contact trajectory segment for execution, generating a target work trajectory with continuous joint posture.

Benefits of technology

While maintaining the stability of the end-effector operation, optimize the robot trajectory to avoid risks such as wrist flipping, elbow reversal, and joint limitation, ensure the continuity of joint posture, reduce the risks of mechanical limitation approach and inverse branch switching, and improve the quality of operation and equipment safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123149980A_ABST
    Figure CN123149980A_ABST
Patent Text Reader

Abstract

This invention relates to a method for optimizing the working trajectory of an industrial robot, belonging to the field of industrial robot trajectory planning and motion control technology. The method includes: acquiring the end position, tool axis direction, tool rotation angle around the axis, inverse kinematic posture branch, and joint angle sequence of each working trajectory point in the industrial robot's working trajectory; extracting the trajectory regions where the wrist joint falls into a preset flip neighborhood, the elbow joint falls into a preset reversal neighborhood, or any joint falls into a preset limit neighborhood according to the execution order; and using the joints falling into the preset limit neighborhood as limit approach joints; while keeping the end position and tool axis direction unchanged within the trajectory region, reselecting the tool rotation angle around the axis or the inverse kinematic posture branch; when there are no results satisfying the reselection constraints within the trajectory region, transferring the rotation angle change or posture branch switching to the preceding or following posture adjustment trajectory segment for execution, generating a target working trajectory with continuous joint posture.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of industrial robot trajectory planning and motion control technology, specifically to a method for optimizing the working trajectory of industrial robots. Background Technology

[0002] Existing industrial robot trajectory optimization technologies typically focus on path points, velocity distribution, acceleration profiles, or operation time, aiming to ensure the robot's end effector moves smoothly, quickly, or stably along a preset path. Publication CN121105038A discloses a control method for industrial robot trajectory optimization based on intelligent algorithms. This method collects joint position information, tool center point coordinates, and motion time sequences, stores the data in a trajectory database, cleans and filters it, extracts path point sequences, velocity distributions, and acceleration profiles, and outputs an optimized motion trajectory sequence through an intelligent optimization algorithm model with a neural network structure, thereby generating control commands to drive the robot's movement. This approach can improve trajectory rationality and motion stability, but its optimization focus is mainly on historical trajectory data, path point lists, and velocity curves. It does not address how to handle the relationship between the tool's rotation angle around the axis and the inverse kinematic posture branch without changing the end effector's working position and tool axis direction when the industrial robot experiences wrist rotation, elbow reversal, or local joints approaching mechanical limits during continuous operation trajectories.

[0003] Public document CN118636162B discloses a method for optimizing the joint spatial trajectory of a robotic arm for assembly operations. This method designs the physical spatial motion trajectory of the robotic arm based on the assembly operation accuracy, determines critical path points and constraints, determines the joint poses at critical points using inverse kinematics, and then performs full-path joint pose interpolation using a hybrid fifth-order and seventh-order polynomial. Finally, it searches for robotic arm operating parameters with the shortest operation time as a constraint to reduce joint impact during assembly operations and improve the positioning accuracy of the end effector. While this approach is significant for reducing start-stop impact and shortening operation time, in actual welding, gluing, grinding, and spraying operations, the trajectory points often need to maintain both the tool axis direction and the operational contact state. If the joint spatial trajectory is processed solely through full-path interpolation or operating parameter search, it can easily lead to problems such as abrupt changes in inverse kinematics posture branches, continuous approximation of the wrist joint to the flip position, or insufficient margin for the limiting approach joint in local areas.

[0004] Therefore, existing industrial robot trajectory optimization technologies still have the following shortcomings: First, they typically focus on overall trajectory smoothness, operational efficiency, or impact suppression, failing to identify local trajectory regions with risks of flipping, reversing, or limiting from the end position of the work trajectory point, tool axis direction, tool rotation angle around the axis, inverse kinematic posture branches, and joint angle sequences. Second, when posture continuity risks occur in local trajectory regions, existing methods tend to directly change the trajectory interpolation results or replan the joint space path, making it difficult to balance end-effector geometric constraints and joint posture continuity constraints. Third, when there are no posture reselection results that satisfy the continuity of joint rotation direction within the trajectory region, there is a lack of a processing mechanism to transfer posture changes to non-work contact trajectory segments before and after the trajectory region, which may lead to joint jumps, unstable inverse kinematic branch switching, or insufficient mechanical limit margins when the robot enters critical work areas, affecting continuous operation quality and equipment operation safety. Summary of the Invention

[0005] The purpose of this invention is to provide a method for optimizing the working trajectory of industrial robots, thereby addressing some of the drawbacks and shortcomings pointed out in the background art.

[0006] The present invention adopts the following technical solution to solve the above-mentioned technical problems: The end position, tool axis direction, tool rotation angle around the axis, inverse kinematic posture branch and joint angle sequence of each work trajectory point in the industrial robot's work trajectory are obtained. The trajectory areas where the wrist joint falls into the preset flip neighborhood, the elbow joint falls into the preset reversal neighborhood, or any joint falls into the preset limit neighborhood are extracted according to the execution order. The joints that fall into the preset limit neighborhood are used as limit approach joints. While keeping the end position and tool axis direction unchanged within the trajectory area, the tool rotation angle or inverse kinematic posture branch around the axis of the corresponding work trajectory point is reselected, and the continuity of joint rotation direction between adjacent work trajectory points is used as the reselection constraint. When there is no result that satisfies the reselection constraint within the trajectory area, the tool rotation angle change or inverse kinematic attitude branch switching is transferred to the attitude adjustment trajectory segment before and after the trajectory area for execution. The attitude adjustment trajectory segment is a trajectory segment that is not in operation contact and has attitude adjustment margin, generating a target operation trajectory with continuous joint attitude.

[0007] Furthermore, when reselecting the tool rotation angle around the axis, the joint rotation direction of the work trajectory points before and after the trajectory area is read; if any joint rotates towards the mechanical limit before entering the trajectory area and continues in the same direction after leaving the trajectory area, then among the rotation angle results where the tool axis direction remains unchanged, the tool rotation angle around the axis that causes the joint to retreat in the opposite direction within the trajectory area is selected.

[0008] Furthermore, when performing candidate reselection for the inverse kinematic posture branch, the wrist joint rotation direction, elbow joint rotation direction, and joint margin of the limiting proximity joint are read before and after reselection; when the candidate reselection result makes the wrist joint rotation direction continuous but makes the elbow joint rotation direction abrupt, the original inverse kinematic posture branch is retained, and the tool rotation angle change around the axis is advanced to the posture adjustment trajectory segment in front of the trajectory area.

[0009] Furthermore, when the tool is rotated around the axis or the reverse kinematic posture branch is switched and transferred to the posture adjustment trajectory segment before and after the trajectory area, a pre-yield angle is first formed in the posture adjustment trajectory segment in front of the trajectory area, which is opposite to the direction of the required posture change, so that the wrist joint or the limiting proximity joint when entering the trajectory area can obtain rotational margin, and then the posture adjustment trajectory segment behind the trajectory area cancels out the pre-yield angle.

[0010] Furthermore, when the tool that causes the joint to retract in the reverse direction within the trajectory area rotates around the axis, the joint rotation direction of each work trajectory point within the trajectory area is read. The first work trajectory point where the joint changes from rotating toward the mechanical limit to rotating away from the mechanical limit is taken as the retraction starting point, and the retraction starting point is located between the entrance point of the trajectory area and the center point of the trajectory area.

[0011] Furthermore, if multiple joints rotate toward the mechanical limit before entering the trajectory area and continue in the same direction after leaving the trajectory area, the remaining rotation angle of each joint from the corresponding mechanical limit is read, and the tool rotation angle around the axis that makes the joint with the remaining rotation angle lower than that of other joints is selected to retreat in the opposite direction within the trajectory area.

[0012] Furthermore, if the selected tool rotates around the axis, causing the joint to retract in the reverse direction within the trajectory area, but this results in another joint rotating toward the mechanical limit after leaving the trajectory area, then the individual execution mode of the tool rotating around the axis is canceled, and the retraction amount of the joint is allocated to the attitude adjustment trajectory segment in front of the trajectory area and executed together with the trajectory area.

[0013] Furthermore, when forming the pre-yield angle, the change in joint margin from each working trajectory point in the attitude adjustment trajectory segment in front of the trajectory area to the entrance point of the trajectory area is read. Among the angle results that make the wrist joint or the limiting approach joint move away from the corresponding mechanical limit before entering the trajectory area, the pre-yield angle with the angle amplitude at the lower limit is selected, and the pre-yield angle is restricted from causing the joint rotation direction in the attitude adjustment trajectory segment in front to switch more than twice.

[0014] Furthermore, when offsetting the pre-yield angle, the recovery sequence of the tool's rotation around the axis within the attitude adjustment trajectory segment behind the trajectory area is read; if offsetting according to the original recovery sequence would cause the wrist joint to approach the flipped position again, the offsetting of the pre-yield angle is delayed, and the offsetting process is distributed to multiple consecutive operation trajectory points within the attitude adjustment trajectory segment behind the trajectory area.

[0015] Furthermore, after the cancellation process is assigned to multiple consecutive work trajectory points within the attitude adjustment trajectory segment behind the trajectory area, the wrist joint rotation direction corresponding to each consecutive work trajectory point is read; if the latter part of canceling the pre-yield angle still causes the wrist joint to approach the flip position, then the increase in the tool's rotation angle recovery around the axis is stopped, and the remaining pre-yield angle is eliminated at the end of the attitude adjustment trajectory segment behind the trajectory area by reselecting the inverse kinematic attitude branch.

[0016] This invention obtains the end position of each trajectory point in the industrial robot's work trajectory, the tool axis direction, the tool rotation angle around the axis, the inverse kinematic posture branch, and the joint angle sequence. It then extracts the trajectory regions where the wrist joint falls into a preset flip neighborhood, the elbow joint falls into a preset reversal neighborhood, or any joint falls into a preset limit neighborhood, according to the execution order. The joints that fall into the preset limit neighborhood are used as limit approach joints. This allows trajectory optimization to no longer only process global path smoothing or velocity parameters, but can directly locate the key areas in the work trajectory that cause posture discontinuity, abnormal branch switching, or insufficient joint margin, thus improving the targeting of trajectory optimization.

[0017] This invention, while keeping the end position and tool axis direction unchanged within the trajectory area, reselects the tool rotation angle or inverse kinematic posture branch around the axis for the corresponding work trajectory point, and uses the continuity of joint rotation direction between adjacent work trajectory points as the reselection constraint. Thus, without destroying the tool contact posture and work geometry requirements, it can reduce the impact of wrist flipping, elbow reversal and joint limit approach on continuous work, enabling the robot to obtain more stable joint posture transition in the critical work area.

[0018] When there are no results that satisfy the reselection constraints within the trajectory area, the present invention transfers the tool's rotation angle change around the axis or the inverse kinematic posture branch switch to the posture adjustment trajectory segment before and after the trajectory area for execution. Moreover, the posture adjustment trajectory segment is not in the work contact area and has posture adjustment margin, thereby avoiding the forced completion of posture change within the work contact area. It can generate a target work trajectory with continuous joint posture and reduce the risk of pauses, jitters or trajectory distortion caused by mechanical limit approximation, wrist rotation and branch jump. Attached Figure Description

[0019] Figure 1 This is a flowchart illustrating the industrial robot trajectory optimization method of the present invention.

[0020] Figure 2 This is a diagram showing the joint margin recognition in the trajectory region in Embodiment 1 of the present invention.

[0021] Figure 3 This is a comparison diagram of the rotation angles of candidate tools around the axis in Embodiment 1 of the present invention.

[0022] Figure 4 This is the execution diagram of the reverse rollback allocation in Embodiment 1 of the present invention.

[0023] Figure 5 This is a screening diagram of the safety interval for the pre-retreat corner entrance in Embodiment 2 of the present invention.

[0024] Figure 6 This is a diagram showing the wrist joint avoidance before and after the pre-yield in Embodiment 2 of the present invention.

[0025] Figure 7 This is a diagram showing the pre-yield angle delay cancellation and residual elimination in Embodiment 2 of the present invention. Detailed Implementation

[0026] As attached Figure 1 As shown, this embodiment provides a method for optimizing the work trajectory of an industrial robot, applicable to industrial robots that need to perform continuous operations according to a preset trajectory, such as welding, grinding, spraying, handling, or assembly. Before the industrial robot performs the operation, the control system acquires the end effector position, tool axis direction, tool rotation angle around the axis, inverse kinematics posture branch, and joint angle sequence corresponding to each work trajectory point in the original work trajectory. The control system can be a robot control cabinet, an offline programming system, or a trajectory processing system formed by the collaboration of both. The end effector position is used to characterize the working position of the robot's end effector in space; the tool axis direction is used to characterize the orientation of the tool relative to the work surface; the tool rotation angle around the axis is used to characterize the amount of posture rotation generated by the tool around its own axis while keeping the axis direction unchanged; the inverse kinematics posture branch is used to characterize the selectable joint combination states of the robot under the same end effector pose; and the joint angle sequence is used to characterize the continuous change of the execution order of each joint along the trajectory.

[0027] The control system reads each work trajectory point according to the trajectory execution sequence and identifies the motion state of the wrist joint, elbow joint, and other joints. When the wrist joint falls into a preset flipping neighborhood, the elbow joint falls into a preset reversing neighborhood, or any joint falls into a preset limit neighborhood, the interval containing the corresponding continuous work trajectory points is extracted as the trajectory region, and the joint falling into the preset limit neighborhood is designated as the limit approach joint. The preset flipping neighborhood is determined based on the angle range of the wrist joint approaching the flipping position, the preset reversing neighborhood is determined based on the angle range of the elbow joint approaching the reversing position, and the preset limit neighborhood is determined based on the angle range of the joint approaching the mechanical limit. The angle range can be preset based on robot structural parameters, mechanical limit data, historical trajectory execution records, or work safety margins, and remains consistent within the same work task. Through this method, the trajectory region that needs optimization can be located in advance before the robot actually enters a sudden attitude change, reversing instability, or mechanical limit risk.

[0028] After extracting the trajectory region, the control system maintains the end position and tool axis direction of each work trajectory point within the trajectory region unchanged, ensuring that the robot's end effector continues to complete the work along the original work position and tool orientation, without altering the weld, grinding belt, spraying path, or assembly contact position. Based on this, the control system reselects the tool rotation angle or inverse kinematic posture branch for the corresponding work trajectory point, using the continuity of joint rotation direction between adjacent work trajectory points as a reselection constraint. The selectable result of the tool rotation angle around the axis is generated by the control system within the allowable tool rotation range, and the selectable result of the inverse kinematic posture branch is solved by the control system based on the same end position and the same tool axis direction. Continuity of joint rotation direction means that the joint rotation direction between adjacent work trajectory points does not undergo abrupt switching that leads to a change in posture; when the joint angle change between adjacent work trajectory points is within a preset small change range, the continuity comparison is performed using the joint rotation direction of the previous work trajectory point. Through this reselection method, the robot's internal joint posture can be adjusted without disrupting the end-effector's work trajectory, allowing the wrist joint to avoid the flipping area, the elbow joint to avoid reversing conflicts, and the limit-adjacent joints to move away from mechanical limits.

[0029] When a tool rotation angle or inverse kinematic posture branch satisfying the reselection constraint exists within the trajectory area, the control system directly uses the reselection result that meets the conditions to generate the target operation trajectory and performs an executability check on the joint angle sequence of the target operation trajectory. The executability check includes at least whether the joint angles exceed the limits, whether there are sudden attitude branch jumps between adjacent operation trajectory points, and whether the trajectory execution sequence maintains the original operation path. When no result satisfying the reselection constraint exists within the trajectory area, it indicates that attitude adjustment only within the risk area is insufficient to simultaneously ensure end-effector stability and joint attitude continuity. The control system then transfers the tool rotation angle change or inverse kinematic posture branch switching to the attitude adjustment trajectory segment before and after the trajectory area. The attitude adjustment trajectory segment is a segment that is not in operation contact and has attitude adjustment margin. "Not in operation contact" means that the tool does not perform effective operations such as welding, grinding, spraying, clamping, or assembly pressing within this trajectory segment. "Having attitude adjustment margin" means that the tool attitude is allowed to gradually transition without changing the end-effector position and tool axis direction of subsequent operations. The attitude adjustment trajectory segment can be located before entering the trajectory area or after leaving the trajectory area. By allocating posture changes in advance or delay to the posture adjustment trajectory segment, the robot can complete the posture transition outside the contact work area, avoiding problems such as wrist flipping, elbow reversal, or joint approach limit during the work contact process, and finally generating a target work trajectory with continuous joint posture.

[0030] In this embodiment, when the control system reselects the tool rotation angle around the axis, it first reads the joint rotation directions corresponding to the work trajectory points before the entrance of the trajectory area and the work trajectory points after the exit of the trajectory area. By comparing the rotation trends of the joints before and after entering the trajectory area, it identifies whether there are joints that continuously move towards the mechanical limit direction. Moving towards the mechanical limit direction means that the joint angle change causes the joint margin from the corresponding upper or lower mechanical limit to continuously decrease. If a joint has already rotated towards the corresponding mechanical limit before entering the trajectory area, and continues in the same direction after leaving the trajectory area, it indicates that there is a risk that the joint will further approach the mechanical limit within the trajectory area. At this time, the control system does not change the tool axis direction, but filters from the available tool rotation angles around the axis, selecting the tool rotation angle around the axis that can cause the joint to change from rotating towards the mechanical limit to rotating away from the mechanical limit within the trajectory area.

[0031] During execution, the control system reads the joint rotation direction at each work trajectory point within the trajectory area and compares the rotation trend of the joints point by point along the trajectory execution sequence. When a joint changes from rotating towards the mechanical limit to rotating away from the mechanical limit, the work trajectory point where this change in rotation direction first occurs is taken as the retraction start point. Rotation away from the mechanical limit refers to a change in joint angle that increases the joint margin between the joint and the corresponding mechanical limit. The retraction start point is located between the entrance point and the center point of the trajectory area, allowing the joint to form a reverse retraction trend in the early stage after entering the trajectory area, rather than releasing the limit risk only when approaching the end of the trajectory area. Through the above settings, the joint can obtain retraction space in advance during the process of passing through the trajectory area, reducing the possibility of trajectory interruption, posture jump, or sudden speed change caused by the joint continuing to approach the mechanical limit.

[0032] When multiple joints rotate toward their corresponding mechanical limits before entering the trajectory area and continue in the same direction after leaving the trajectory area, the control system reads the remaining angle of each joint from its corresponding mechanical limit. The remaining angle represents the angular margin between the joint's current angle and its corresponding mechanical limit; it is an angular representation of the joint's margin under mechanical limit conditions. Based on the remaining angles of each joint, the control system determines the priority processing targets and prioritizes joints with remaining angles lower than other joints, allowing them to reverse their movement around the axis within the trajectory area. This allows for the release of motion risks from joints closer to the mechanical limits first, preventing critical joints from failing to retract in time when multiple joints simultaneously approach the limits and adjust in an even manner.

[0033] After screening the tool's rotation around the axis, the control system continues to check the impact of the selected tool's rotation around the axis on other joints. If the selected tool's rotation around the axis, while enabling the target joint to retract in the trajectory area, causes another joint to rotate towards its mechanical limit after leaving the trajectory area, it indicates that the individual execution of the tool's rotation around the axis transfers the limit risk from one joint to another. In this case, the control system cancels the individual execution of the tool's rotation around the axis and distributes the joint's retraction amount to the attitude adjustment trajectory segment in front of the trajectory area, which is executed together with the trajectory area. The distribution is based on maintaining the end position at the trajectory area's entry point and the tool's axis direction unchanged, and ensuring that the target joint already has rotational margin to release the limit risk when entering the trajectory area. By pre-assuming a portion of the retraction amount before entering the trajectory area and continuing to complete the remaining retraction amount within the trajectory area, the amplitude of attitude changes within a single trajectory area can be reduced, avoiding new limit approach problems for other joints caused by overly concentrated local angle adjustments.

[0034] In this embodiment, when the control system performs candidate reselection for inverse kinematics posture branches, it does not directly write the candidate branches into the target operation trajectory. Instead, it first verifies the joint motion states before and after the candidate reselection. Specifically, the control system reads the wrist joint rotation direction, elbow joint rotation direction, and joint margin of the limit approach joint corresponding to the trajectory area and its adjacent operation trajectory points. The wrist joint rotation direction reflects whether there is a flipping trend in the robot's end-effector posture, the elbow joint rotation direction reflects whether there is a sudden change in direction in the robot's intermediate posture, and the joint margin of the limit approach joint reflects the remaining activity space of the corresponding joint from the mechanical limit. Adjacent operation trajectory points include at least one operation trajectory point before the trajectory area entrance and at least one operation trajectory point after the trajectory area exit, used to verify whether the candidate branch maintains joint state continuity when entering and leaving the trajectory area. By reading the above three types of information simultaneously, it can avoid using only the continuity of the wrist joint as the basis for posture branch reselection, thereby reducing the generation of new elbow reversal problems or limit approach problems during posture optimization.

[0035] When the candidate reselection result keeps the wrist joint rotation direction continuous, it indicates that the candidate reselection result can alleviate the risk of wrist rollover. However, the control system continues to compare the elbow joint rotation direction before and after the reselection. If the candidate reselection result causes a sudden change in the elbow joint rotation direction, it indicates that although the candidate inverse kinematics posture branch improves the continuity of wrist posture, it will create a new posture jump at the elbow joint. In this case, the control system does not use the candidate inverse kinematics posture branch, but retains the original inverse kinematics posture branch, so that the elbow joint maintains its original continuous motion state. At the same time, the control system converts the posture adjustment that originally needed to be completed through the inverse kinematics posture branch switching into a tool rotation angle change around the axis, and advances the tool rotation angle change around the axis to the posture adjustment trajectory segment ahead of the trajectory area. The converted tool rotation angle change around the axis is still constrained to keep the end position and tool axis direction unchanged in the target work trajectory. Since the attitude adjustment trajectory segment is not in contact with the work and has attitude adjustment margin, the robot can complete part of the tool attitude change in advance before entering the trajectory area, thereby maintaining the continuity of the wrist joint, avoiding abrupt changes in the elbow joint in the trajectory area, and ensuring a smooth transition of joint attitude in the target work trajectory.

[0036] In this embodiment, when the control system determines that it is difficult to directly complete the tool's rotation angle change around the axis or the inverse kinematic posture branch switch within the trajectory area, the corresponding posture change is transferred to the posture adjustment trajectory segment before and after the trajectory area. Specifically, the control system first generates a pre-yield angle in the posture adjustment trajectory segment before the trajectory area, opposite to the direction of the required posture change, so that the wrist joint or limit approach joint of the robot has obtained additional rotational margin before entering the trajectory area. The pre-yield angle is not used to directly complete the final posture adjustment, but to release the risk of flipping or limit approach that may occur in the trajectory area in advance. After the robot enters the trajectory area, it can use this rotational margin to complete the posture transition corresponding to the original work trajectory, thereby avoiding concentrated posture switching during the work contact process. After the robot leaves the trajectory area, the control system then cancels the pre-yield angle in the posture adjustment trajectory segment after the trajectory area, so that the tool posture gradually recovers to the state required by the subsequent work trajectory. Cancellation means that, while maintaining the entry constraint of the subsequent work trajectory, the tool's rotation angle offset around the axis caused by the pre-yield is gradually reduced to the posture state required by the subsequent work trajectory.

[0037] When forming the pre-yield angle, the control system reads the changes in joint margin between each working trajectory point and the entrance point of the trajectory area within the attitude adjustment trajectory segment ahead of the trajectory area. Joint margin characterizes the remaining range of motion of the wrist joint or limit approach joint from the corresponding flip position or mechanical limit. The control system filters multiple selectable angle results, selecting the angle result that allows the wrist joint or limit approach joint to move away from the corresponding flip position or mechanical limit before entering the trajectory area, and then selects the pre-yield angle with a lower limit angle amplitude from the angle results that meet this condition. A lower limit angle amplitude means selecting the angle result with the smallest attitude disturbance amplitude among the selectable angle results that meet the requirement of forming the required joint margin before entering the trajectory area. By controlling the amplitude of the pre-yield angle, the necessary rotational margin can be obtained while reducing additional attitude disturbances within the preceding attitude adjustment trajectory segment. The control system also verifies the joint rotation direction caused by the pre-yield angle. If the pre-yield angle causes the joint rotation direction to switch more than twice in the forward attitude adjustment trajectory segment, the pre-yield angle will not be used to avoid forming a repeatedly swinging joint motion state before entering the trajectory area.

[0038] When offsetting the pre-retreat angle, the control system reads the recovery sequence of the tool's rotation angle around the axis within the attitude adjustment trajectory segment behind the trajectory area and compares the trend of the wrist joint relative to the flip position when offsetting the pre-retreat angle according to the original recovery sequence. If performing offsetting according to the original recovery sequence would cause the wrist joint to approach the flip position again, the control system delays offsetting the pre-retreat angle, allowing the wrist joint to naturally move away from the flip position along with the attitude adjustment trajectory segment behind the trajectory area before starting the offsetting process. Simultaneously, the control system distributes the offsetting process to multiple consecutive work trajectory points within the attitude adjustment trajectory segment behind the trajectory area, allowing the tool's rotation angle recovery to be released gradually along the trajectory execution sequence, rather than being concentrated at a single work trajectory point. This reduces the impact of the offsetting process on the continuity of the wrist joint's rotation direction.

[0039] After the cancellation process has been assigned to multiple consecutive work trajectory points, the control system continues to read the wrist joint rotation direction corresponding to each consecutive work trajectory point and verifies the cancellation process of the later stage of the pre-yield angle. If the later stage of canceling the pre-yield angle still causes the wrist joint to approach the flip position, the control system stops increasing the tool's rotation angle recovery amount around the axis to avoid the risk of wrist flipping again due to the continued recovery of the tool's rotation angle around the axis. Subsequently, at the end of the attitude adjustment trajectory segment behind the trajectory area, the control system eliminates the remaining pre-yield angle by reselecting the inverse kinematic attitude branch, so that the remaining attitude deviation is borne by the attitude branch switching. When reselecting the inverse kinematic attitude branch, the end position of the corresponding work trajectory point and the tool axis direction remain unchanged, and the continuous movement state of the wrist joint, elbow joint, and limit approach joint is verified. Through the above processing, the formation, cancellation, and residual amount elimination of the pre-yield angle are all completed in the non-work contact area, which can improve the attitude continuity of the industrial robot when passing through the flip neighborhood, reversal neighborhood, and limit neighborhood while maintaining the stability of the end work path. Example

[0040] This embodiment provides a method for optimizing the working trajectory of an industrial robot, applied to a welding working trajectory optimization scenario for a six-axis industrial robot in a certain unit. Before the robot executes the welding task, the control system reads the end position, tool axis direction, tool rotation angle around the axis, inverse kinematics posture branch, and joint angle sequence corresponding to each working trajectory point in the original working trajectory. The end position is used to determine the spatial position of the welding torch tip along the weld seam, the tool axis direction is used to determine the incident direction of the welding torch relative to the weld seam surface, the tool rotation angle around the axis is used to represent the rotational posture of the welding torch while keeping the tool axis direction unchanged, the inverse kinematics posture branch is used to represent the combination methods that each joint can adopt under the same end position, and the joint angle sequence is used to represent the angular changes of each joint along the execution sequence of the trajectory.

[0041] In this embodiment, the control system reads the operation trajectory points according to their execution order, identifies whether the wrist joint falls into a preset flipping neighborhood, whether the elbow joint falls into a preset reversal neighborhood, and whether any joint falls into a preset limit neighborhood. When the 4th joint gradually approaches the positive mechanical limit and the 5th joint gradually approaches the negative mechanical limit within the continuous trajectory interval between the 34th and 49th operation trajectory points, the control system extracts the 34th to 49th operation trajectory points as the trajectory region and records the 4th and 5th joints as limit approach joints.

[0042] After extracting the trajectory region, the control system maintains the end position and tool axis direction unchanged within the 34th to 49th work trajectory points, ensuring the welding torch tip continues to move along the original weld seam position and maintains the original welding incident direction. Based on this, the control system only reselects the tool's rotation angle around the axis or the inverse kinematic posture branch, adjusting the internal joint posture without altering the welding path itself. The control system also uses the continuity of joint rotation direction between adjacent work trajectory points as a reselection constraint to avoid abrupt changes in joint rotation direction between adjacent work trajectory points.

[0043] In this embodiment, the positive mechanical limit of joint 4 is 170°, and the negative mechanical limit of joint 5 is -125°. Before entering the trajectory region, the angle of joint 4 is 156.8°, the original angle in the middle of the trajectory region is 163.5°, and the original angle after leaving the trajectory region is 166.2°, indicating that joint 4 has already rotated towards the positive mechanical limit before entering the trajectory region and continues in the same direction after leaving the trajectory region. Before entering the trajectory region, the angle of joint 5 is -111.6°, the original angle in the middle of the same trajectory region is -116.1°, and the original angle after leaving the trajectory region is -118.4°, indicating that joint 5 also tends to move towards the negative mechanical limit. Based on this, the control system initiates the tool rotation angle reselection process around the axis.

[0044] To determine the priority target among multiple limit approach joints, the control system first calculates the remaining limit distance of each limit approach joint from the corresponding mechanical limit at the same risk review position. The calculation formula is as follows:

[0045] in, Indicates the first The distance between each joint corresponds to the remaining limit of the mechanical limit. Indicates the first Mechanical limiting angles in the corresponding directions of each joint. This indicates the actual angle of the joint at the current risk review position. The calculation is based on the fact that this embodiment focuses on whether the joint continuously approaches the corresponding mechanical limit; therefore, the absolute value of the difference between the mechanical limit angle and the current joint angle is used as the available rotation margin of the joint. The smaller the limit margin, the closer the joint is to the mechanical limit, and the more priority is needed to release the limit risk. Corresponding to this identification process, Figure 2 The 34th to 49th operation trajectory points are used as the shaded trajectory area, and two limit remaining amount change lines are used to show the decreasing trend of the remaining amount of the 4th and 5th joints after entering the trajectory area. This establishes a correspondence between the trajectory area extraction results, the limit approach joint recognition results, and the priority processing objects.

[0046] When the actual operation data is substituted into the above calculation formula, the angle of the fourth joint in the middle of the trajectory area is 163.5°, corresponding to a positive mechanical limit of 170°. Therefore, the remaining limit of the fourth joint is:

[0047] The angle of the fifth joint in the middle of the same trajectory region is -116.1°, corresponding to a negative mechanical limit of -125°. Therefore, the remaining limit of the fifth joint is:

[0048] The calculation results above show that the remaining limit of the fourth joint is less than that of the fifth joint, indicating that the fourth joint is closer to the corresponding mechanical limit. Figure 2 The remaining limit amount curve of the fourth joint is lower than that of the fifth joint within the trajectory region and extends continuously below the risk identification reference line, further indicating that the fourth joint has a higher priority release requirement within this trajectory region. The control system prioritizes the fourth joint as the reverse retraction control object, and, while keeping the tool axis direction unchanged, selects from the available tool rotation angles around the axis results that can cause the fourth joint to change from rotation toward the mechanical limit to rotation away from the mechanical limit within the trajectory region.

[0049] In this embodiment, the candidate tool rotation angles around the axis generated by the control system include -8°, -5°, and 4°. The control system maps each candidate tool rotation angle around the axis to a sequence of joint angles from the 34th to the 49th work trajectory points, and reads the direction of change of the 4th joint within the trajectory area. When a candidate tool rotation angle around the axis causes the 4th joint to change from rotating towards the positive mechanical limit to rotating away from the positive mechanical limit, the control system continues to read the work trajectory point where the first change in rotation direction occurs, and uses this work trajectory point as the retraction start point. If the retraction start point is located between the entrance point and the center point of the trajectory area, it indicates that the 4th joint can obtain retraction space in the early stage after entering the risk area, rather than releasing the limit risk only when approaching the end of the trajectory area.

[0050] To compare the effects of different candidate tool rotation angles around the axis on the reverse retraction of the fourth joint, the control system calculates the improvement value of the limit residual amount corresponding to the candidate tool rotation angle around the axis. The calculation formula is as follows:

[0051] in, Indicates the first Improvement value of the remaining limit amount corresponding to the rotation angle of each candidate tool around the axis. Indicates the use of the first After the candidate tool rotates around the axis, the first... The remaining limit of each joint within the trajectory area. Indicates the first election before the re-election The remaining limit amount of each joint. The calculation formula is based on the fact that, in this embodiment, whether the remaining limit amount increases is used as a direct basis for the reverse retraction effect. When When the value is positive, it indicates that the corresponding joint is far from the mechanical limit; when... A larger value indicates that the rotation angle of the corresponding candidate tool around the axis has a more significant risk-relieving effect on the joint.

[0052] With the original limiting margin of the 4th joint being 6.5°, after using a -8° candidate tool to rotate around the axis, the limiting margin of the 4th joint within the trajectory region is 12.4°. Therefore:

[0053] After using a -5° candidate tool to rotate around the axis, the remaining limit of the 4th joint within the trajectory area is 10.1°. Therefore:

[0054] After using a 4° candidate tool to rotate around the axis, the remaining limit of the 4th joint within the trajectory region is 4.7°. Therefore:

[0055] The above results show that both -8° and -5° candidate tool rotation around the axis can move the fourth joint away from the positive mechanical limit, while 4° candidate tool rotation around the axis will bring the fourth joint closer to the mechanical limit. Therefore, 4° candidate tool rotation around the axis is not adopted. Figure 3 Furthermore, the improvement values ​​of the fourth joint's remaining limit amount corresponding to the rotation angle around the axis of the three candidate tools are represented in bar chart form, while the remaining limit amount of the fifth joint after leaving the trajectory area is represented in line chart form. This ensures that the candidate results are not only compared based on the improvement value of a single joint, but also reflect the target joint's retraction effect and the risk transfer of other joints. The control system then verifies the impact of other joints on the two candidate results of -8° and -5°, reading the rotation direction and remaining limit amount change of the fifth joint after leaving the trajectory area.

[0056] Upon review, when using the -8° candidate tool to rotate around the axis, the 4th joint achieves a larger reverse retraction amount. However, after leaving the trajectory area, the 5th joint continues to rotate towards the negative mechanical limit, causing the angle of the 5th joint after leaving the trajectory area to change from the original -118.4° to -121.3°, corresponding to a decrease in the remaining limit amount from 6.6° to 3.7°. This result indicates that if the -8° candidate tool rotation around the axis is performed alone within the trajectory area, it will transfer the limit risk of the 4th joint to the 5th joint. Figure 3 Although the improvement value of the 4th joint corresponding to -8° is 5.9°, the remaining distance of the 5th joint is only 3.7°, which is lower than the risk reference line. Therefore, it is not suitable as a reselection result to be written into the trajectory area separately. The control system therefore cancels the separate execution mode of the -8° candidate tool rotation around the axis and does not directly write it into the target operation trajectory.

[0057] When using a -5° candidate tool to rotate around the axis, the remaining limit of the fourth joint increases from 6.5° to 10.1°. At the 39th work trajectory point, the fourth joint first changes from rotating towards the positive mechanical limit to rotating away from it, and this 39th work trajectory point is located between the entry point and center point of the 34th to 49th work trajectory points. Simultaneously, the fifth joint does not develop a new tendency to rotate towards the negative mechanical limit after leaving the trajectory area, and the elbow joint rotation direction does not change abruptly. Figure 3 The region corresponding to -5° is highlighted as the selected result, with an improvement value of 3.6° for the 4th joint and a residual amount of 6.6° for the 5th joint, which can maintain a safety margin for other joints while releasing the risk of limit on the 4th joint. Therefore, the control system uses the -5° candidate tool rotation angle around the axis as the reselection result of the tool rotation angle around the axis within the trajectory region and generates the corresponding joint angle sequence.

[0058] For the -8° candidate tool rotation around the axis that has been cancelled from separate execution, the control system transfers the reverse retraction amount of the scheme exceeding -5° to the attitude adjustment trajectory segment in front of the trajectory area and executes it together with the trajectory area. Specifically, the control system pre-allocates a portion of the tool rotation around the axis change in the non-operational contact area before entering the 34th operation trajectory point, so that the 4th joint already has a large limit remaining amount when entering the trajectory area; then, it continues to complete the remaining retraction amount from the 34th to the 49th operation trajectory points. Figure 4 A comparison was made between the single-zone centralized execution scheme and the pre-allocation plus in-zone execution scheme. The single-zone centralized execution scheme directly assumes an 8° retraction amount at the entrance of the trajectory area, which can easily lead to significant local attitude changes. The pre-allocation plus in-zone execution scheme, on the other hand, pre-allocates a 3° retraction amount within the forward attitude adjustment trajectory segment corresponding to the 31st to 33rd work trajectory points, and then gradually continues to 5° within the trajectory area, thereby reducing the concentrated adjustment amplitude during welding contact. This allocation method can reduce the attitude change amplitude within a single trajectory area and avoid affecting the welding torch attitude stability by concentrating the tool's rotation around the axis during welding contact.

[0059] After completing the above processing, the control system verifies the target work trajectory. The verification includes checking whether the end position within the trajectory area remains unchanged, whether the tool axis direction remains unchanged, whether the joint rotation directions between adjacent work trajectory points are continuous, whether the limit approach joints are far from their corresponding mechanical limits, whether the wrist joints have not fallen into the flipping neighborhood, and whether the elbow joints have not formed a sudden change in direction. After the verification is passed, the control system writes the reselected tool rotation angle around the axis and the corresponding inverse kinematic posture branch into the target work trajectory and sends the target work trajectory to the industrial robot for execution. Figures 2 to 4 These correspond to three execution levels: trajectory region identification, candidate tool rotation angle screening around the axis, and reverse backoff amount allocation, respectively, forming a continuous implementation link between limit risk detection, reselection result selection, and attitude adjustment allocation.

[0060] Through the processing in this embodiment, the control system can make the limit approach joint form a reverse retreat trend in advance within the trajectory area without changing the welding end position and tool axis direction. It can also avoid new limit approach problems caused by the tool's rotation angle around the axis being adjusted separately through the influence of other joints, thereby generating a target operation trajectory with continuous joint posture and stable operation path. Example

[0061] This embodiment provides a method for optimizing the operational trajectory of an industrial robot, applied to a six-axis industrial robot spraying operation trajectory optimization scenario in a certain unit. Before the robot executes the spraying task, the control system reads the end-effector position, tool axis direction, tool rotation angle around the axis, inverse kinematics posture branch, and joint angle sequence corresponding to each operational trajectory point in the original operational trajectory. The end-effector position is used to determine the spatial position of the spray gun end along the spraying path, the tool axis direction is used to determine the spraying direction of the spray gun relative to the workpiece surface, the tool rotation angle around the axis is used to represent the amount of posture rotation of the spray gun around its own axis while maintaining the spraying direction unchanged, and the inverse kinematics posture branch is used to represent the selectable joint combination states of the robot under the same end-effector pose.

[0062] In this embodiment, the control system reads the changes in the angle of each joint according to the execution order of the work trajectory points. When the 5th joint of the wrist is continuously close to the flip position between the 80th and 96th work trajectory points, and the direct reselection of the tool rotation angle around the axis or the inverse kinematic posture branch within this trajectory area cannot satisfy the constraint of continuous reselection of the joint rotation direction between adjacent work trajectory points, the control system does not complete the posture switching in the spraying contact area, but instead transfers the corresponding posture change to the posture adjustment trajectory segment before and after the trajectory area for execution.

[0063] The 70th to 79th work trajectory points constitute the forward attitude adjustment trajectory segment, and the 97th to 108th work trajectory points constitute the rear attitude adjustment trajectory segment. Neither the forward nor the rear attitude adjustment trajectory segment is within the effective spraying zone; the spray gun does not effectively coat the workpiece surface within this range to maintain a consistent film thickness, thus allowing for attitude adjustment margins. The control system generates a pre-yield angle within the forward attitude adjustment trajectory segment, opposite to the desired attitude change direction, ensuring that when the robot enters the 80th work trajectory point, the 5th wrist joint has moved away from the flip position and gained rotational margin.

[0064] In the original work trajectory, the flip position corresponding to the 5th joint of the wrist is 0°. Before entering the trajectory area, the angle of the 5th joint gradually decreases from 9.6° to 3.2°. If the posture switch is performed directly between the 80th and 96th work trajectory points, the 5th joint will cross the flip position during the spraying contact, causing a sudden change in wrist posture. The control system therefore generates three selectable pre-yield angles of -3°, -5°, and -7°, and reads the entry safety distance of the 5th joint of the wrist at the entrance of the trajectory area relative to the flip position after adopting each selectable pre-yield angle.

[0065] The formula for calculating the entrance safety interval is:

[0066] in, Indicates the use of the first After an optional pre-yield angle, the fifth joint of the wrist has an entry safety interval relative to the flip position at the entrance of the trajectory area; Indicates the use of the first After an optional pre-yield angle, the angle of the fifth joint of the wrist at the entrance of the trajectory area; This indicates the flip position corresponding to the 5th wrist joint. The calculation is based on the fact that, in this embodiment, the robot focuses on whether the 5th wrist joint has moved away from the flip position when entering the trajectory area. Therefore, the distance between the wrist joint angle at the entrance and the flip position is used as the safety interval. When the entrance safety interval meets the preset process requirements, it indicates that the pre-yield angle can provide the necessary margin for subsequent posture transitions.

[0067] Substituting the operational data into the above calculation formula, and using a -3° pre-yield angle, the angle of the 5th wrist joint at the entrance of the trajectory area is 2.1°, then:

[0068] After adopting a -5° pre-yield rotation angle, the angle of the 5th wrist joint at the entrance of the trajectory area is 4.6°, then:

[0069] After adopting a -7° pre-yield rotation angle, the angle of the 5th wrist joint at the entrance of the trajectory area is 6.8°, then:

[0070] In this embodiment, the process preset entry safety interval is no less than 4°. The calculation results show that the entry safety interval corresponding to a -3° pre-retreat angle is 2.1°, which does not meet the process preset requirement; the entry safety interval corresponding to a -5° pre-retreat angle is 4.6°, which meets the requirement of being far from the flipping position before entering the trajectory area; the entry safety interval corresponding to a -7° pre-retreat angle is 6.8°. Although the safety interval is larger, the control system, after reading the joint rotation direction from the 70th to the 79th work trajectory point, finds that this angle will cause the joint rotation direction to switch twice within the preceding attitude adjustment trajectory segment, easily forming a repeated oscillating state before entering the trajectory area. Figure 5The entry safety intervals corresponding to the three selectable pre-retreat angles are presented together with the number of forward rotation direction switching, so that the selection of the pre-retreat angle is not only based on the size of the safety interval, but also considers whether repeated switching occurs within the forward attitude adjustment trajectory segment. Among them, the entry safety interval corresponding to -5° exceeds the process preset requirements, and the number of forward switching is 0. Therefore, the control system does not use the -3° and -7° pre-retreat angles, but selects -5° as the pre-retreat angle, which meets the entry safety interval and the angle amplitude is at the lower limit.

[0071] After the robot enters the trajectory area, the control system maintains the end position and tool axis direction unchanged from the 80th to the 96th work trajectory point, ensuring the spray gun continues along the original spraying path and maintains the original spraying direction. Since the preceding attitude adjustment trajectory segment has already formed a -5° pre-yield turning angle, and the 5th joint has a 4.6° entry safety interval when entering the trajectory area, the control system can complete the attitude transition required for the original work trajectory within the trajectory area, without concentrating on inverse kinematic attitude branch switching during the spraying contact process. Figure 6 The 70th to 108th operation trajectory points were divided into a forward attitude adjustment trajectory segment, a trajectory area, and a rear attitude adjustment trajectory segment. The original wrist angle and the wrist angle after pre-yield were compared. The original trajectory passed the 0° flip position within the trajectory area, while the 5th joint of the wrist after pre-yield formed a 4.6° safety interval at the entrance and remained on the same side as the flip position within the trajectory area. This directly demonstrates the role of the pre-yield angle in avoiding the risk of wrist flip.

[0072] After the robot leaves the trajectory area, the control system reads the recovery sequence of the tool's rotation angle around the axis within the 97th to 108th work trajectory points. If the -5° pre-yield angle is immediately offset according to the original recovery sequence, the 5th wrist joint will approach the 0° flip position again. Therefore, the control system delays the offset process, allowing the 5th wrist joint to naturally move away from the flip position according to the original posture change of the rear posture adjustment trajectory segment, and then distributes the recovery amount of the pre-yield angle to multiple consecutive work trajectory points for execution.

[0073] The formula for calculating the tool rotation angle recovery amount around the axis assigned to each continuous operation trajectory point in the rear attitude adjustment trajectory segment is:

[0074] in, Indicates the first segment within the rear attitude adjustment trajectory. The tool rotation angle recovery amount around the axis assigned to each offset operation trajectory point; This indicates the remaining amount of pre-retreat angle that has not yet been recovered before entering the offset operation trajectory point; This indicates the number of continuous operation trajectory points used for offsetting within the rear attitude adjustment trajectory segment; This indicates the current offset sequence. The calculation formula is based on the fact that the pre-retreat angle should not be offset in a single work trajectory point. Therefore, the control system distributes the remaining amount of pre-retreat angle that has not yet been recovered according to the number of subsequent remaining offset points, so that each work trajectory point bears a relatively gentle tool rotation angle recovery amount around the axis.

[0075] In this embodiment, the pre-yield angle is -5°. The rear attitude adjustment trajectory segment selects five consecutive work trajectory points from the 99th to the 103rd work trajectory point for cancellation. The initial unrecovered pre-yield angle remains at 5°. Therefore, the tool rotation angle recovery amount around the axis corresponding to the first cancelled work trajectory point is:

[0076] After the first offset operation trajectory point is executed, the remaining pre-retreat angle that has not yet been recovered becomes 4°. The second offset operation trajectory point is allocated according to the remaining 4 offset operation trajectory points, and the tool's rotation angle recovery around the axis is 1°. The third offset operation trajectory point is allocated according to the remaining 3 offset operation trajectory points, and the tool's rotation angle recovery around the axis is still 1°. Therefore, after executing the third offset operation trajectory point, a total of 3° has been recovered, and the remaining pre-retreat angle that has not yet been recovered is 2°. At this time, the control system continues to read the rotation direction of the 5th joint of the wrist and finds that the angle of the 5th joint has decreased from 5.4° to 1.2° and is approaching the 0° flip position again. This state indicates that continuing to increase the tool's rotation angle recovery around the axis will trigger the risk of wrist flipping again. The control system stops further increasing the tool's rotation angle recovery around the axis and maintains the completed 3° recovery result.

[0077] After ceasing further increase in the tool's rotation angle recovery around the axis, the control system reselects the inverse kinematic attitude branch at the end of the rear attitude adjustment trajectory segment to eliminate the remaining 2° pre-yield angle. This reselection of the inverse kinematic attitude branch is still constrained by the end position and the direction of the tool axis, and verifies the rotation direction of the fifth wrist joint, the rotation direction of the elbow joint, and the joint margin of the limit approach joint. Figure 7 The planned recovery amount, actual recovery amount, and wrist joint angle were compared within the same rear attitude adjustment trajectory segment. The 99th to 103rd operation trajectory points were continuous cancellation points. The actual recovery amount stopped increasing after accumulating to 3°, and then the remaining 2° was eliminated at the end of the rear attitude adjustment trajectory segment through attitude branch reselection. This figure further demonstrates that the control system did not mechanically complete all cancellations according to the original recovery sequence, but rather changed the way the remaining amount was handled when the wrist joint approached the rotation position again. After verification, the control system jointly wrote the pre-yield angle, delayed cancellation result, and end-point attitude branch reselection result into the target operation trajectory.

[0078] In this way, the control system can complete the formation of the pre-retreat angle, the delay cancellation of the tool's rotation angle around the axis, and the elimination of the remaining pre-retreat angle in the non-operation contact area. This allows the robot to avoid the wrist joint from crossing the flip position during the spraying contact process without changing the end position and the direction of the tool axis within the trajectory area, and to avoid approaching the flip position again when canceling the pre-retreat angle in the original recovery sequence. This improves the attitude continuity of the target operation trajectory and the stability of the spraying operation.

Claims

1. A method for optimizing the working trajectory of an industrial robot, characterized in that, The end position, tool axis direction, tool rotation angle around the axis, inverse kinematic posture branch and joint angle sequence of each work trajectory point in the industrial robot's work trajectory are obtained. The trajectory areas where the wrist joint falls into the preset flip neighborhood, the elbow joint falls into the preset reversal neighborhood, or any joint falls into the preset limit neighborhood are extracted according to the execution order. The joints that fall into the preset limit neighborhood are used as limit approach joints. While keeping the end position and tool axis direction unchanged within the trajectory area, the tool rotation angle or inverse kinematic posture branch around the axis of the corresponding work trajectory point is reselected, and the continuity of joint rotation direction between adjacent work trajectory points is used as the reselection constraint. When there is no result that satisfies the reselection constraint within the trajectory area, the tool rotation angle change or inverse kinematic attitude branch switching is transferred to the attitude adjustment trajectory segment before and after the trajectory area for execution. The attitude adjustment trajectory segment is a trajectory segment that is not in operation contact and has attitude adjustment margin, generating a target operation trajectory with continuous joint attitude.

2. The industrial robot operation trajectory optimization method according to claim 1, characterized in that, When reselecting the tool rotation angle around the axis, read the joint rotation direction of the work trajectory points before and after the trajectory area; if any joint rotates towards the mechanical limit before entering the trajectory area and continues in the same direction after leaving the trajectory area, then select the tool rotation angle around the axis that causes the joint to retreat in the opposite direction within the trajectory area from the rotation angle results where the tool axis direction remains unchanged.

3. The industrial robot operation trajectory optimization method according to claim 1, characterized in that, When reselecting candidates for the inverse kinematics posture branch, the wrist joint rotation direction, elbow joint rotation direction, and joint margin of the limit joint before and after reselection are read. When the candidate reselection result makes the wrist joint rotation direction continuous but makes the elbow joint rotation direction change abruptly, the original inverse kinematics posture branch is retained, and the tool rotation angle change around the axis is advanced to the posture adjustment trajectory segment in front of the trajectory area.

4. The industrial robot operation trajectory optimization method according to claim 1, characterized in that, When the tool rotates around the axis or switches between inverse kinematic posture branches and performs the rotation change or shift within the posture adjustment trajectory segment before and after the trajectory area, a pre-yield angle is first formed in the posture adjustment trajectory segment in front of the trajectory area, opposite to the direction of the desired posture change, so that the wrist joint or limit proximity joint when entering the trajectory area has rotational margin, and then the pre-yield angle is canceled out in the posture adjustment trajectory segment behind the trajectory area.

5. The industrial robot operation trajectory optimization method according to claim 2, characterized in that, When the tool that causes the joint to retract in the trajectory area rotates around the axis, the joint rotation direction of each work trajectory point in the trajectory area is read. The first work trajectory point where the joint changes from rotating toward the mechanical limit to rotating away from the mechanical limit is taken as the retraction starting point, and the retraction starting point is located between the entrance point of the trajectory area and the center point of the trajectory area.

6. The industrial robot operation trajectory optimization method according to claim 2, characterized in that, If multiple joints rotate toward the mechanical limit before entering the trajectory area and continue in the same direction after leaving the trajectory area, then the remaining rotation angle of each joint from the corresponding mechanical limit is read, and the tool rotation angle around the axis that makes the remaining rotation angle lower than that of other joints is selected to reverse back in the trajectory area.

7. The industrial robot operation trajectory optimization method according to claim 2, characterized in that, If the selected tool rotates around the axis, causing the joint to retract in the reverse direction within the trajectory area, but this results in another joint rotating toward the mechanical limit after leaving the trajectory area, then the individual execution mode of the tool rotating around the axis is canceled, and the retraction amount of the joint is allocated to the attitude adjustment trajectory segment in front of the trajectory area and executed together with the trajectory area.

8. The industrial robot operation trajectory optimization method according to claim 4, characterized in that, When forming the pre-yield angle, read the joint margin changes from each work trajectory point in the attitude adjustment trajectory segment in front of the trajectory area to the entrance point of the trajectory area. Among the angle results that make the wrist joint or the limit approach joint move away from the corresponding mechanical limit before entering the trajectory area, select the pre-yield angle with the angle amplitude at the lower limit, and restrict the pre-yield angle from causing the joint rotation direction in the attitude adjustment trajectory segment in front to switch more than twice.

9. The industrial robot operation trajectory optimization method according to claim 4, characterized in that, When offsetting the pre-yield angle, the recovery sequence of the tool's rotation around the axis within the attitude adjustment trajectory segment behind the trajectory area is read; if offsetting according to the original recovery sequence would cause the wrist joint to approach the flipped position again, the offsetting of the pre-yield angle is delayed, and the offsetting process is distributed to multiple consecutive operation trajectory points within the attitude adjustment trajectory segment behind the trajectory area.

10. The industrial robot operation trajectory optimization method according to claim 9, characterized in that, After the cancellation process is assigned to multiple consecutive work trajectory points within the attitude adjustment trajectory segment behind the trajectory area, the wrist joint rotation direction corresponding to each consecutive work trajectory point is read. If the latter part of canceling the pre-yield angle still causes the wrist joint to approach the flip position, the tool rotation angle recovery amount around the axis is stopped, and the remaining pre-yield angle is eliminated at the end of the attitude adjustment trajectory segment behind the trajectory area by reselecting the inverse kinematic attitude branch.

Citation Information

Patent Citations

  • A method for optimizing the spatial trajectory of robot arm joints for assembly operations

    CN118636162B

  • Industrial robot trajectory optimization control method based on intelligent algorithm

    CN121105038A