Welding robot S-speed curve trajectory planning method based on polynomial interpolation
By establishing the position and velocity round-in error model of the S curve of the welding robot and using the compensation method of seven-degree polynomial interpolation, the problems of large calculation amount and unsmooth speed in the trajectory planning of the S curve of the welding robot are solved, and higher trajectory accuracy and velocity smoothness are achieved.
Patent Information
- Application Number
- CN202411302621.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-18
- Publication Date
- 2025-04-25
AI Technical Summary
The calculation amount is large during the planning process of the S-curve trajectory of welding robots, and the velocity curve is not smooth under discrete control conditions, and there is a problem that circular error affects the accuracy of the trajectory.
Establish a circular error model of the position and speed of the S-curve acceleration section, uniform speed section and deceleration section of the welding robot. The circular error compensation method of the planning process of seven-order polynomial interpolation is adopted. By compensating the speed of the acceleration section and deceleration section, the smooth transition of speeds of each section is achieved.
It improves speed smoothness, reduces calculation amount, and improves trajectory accuracy. It is suitable for the trajectory planning process of the seven-stage S-speed curve of welding robots under different constraints.
Smart Images

Figure CN119871375A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of robot welding, and in particular to a speed planning method for coping with the uneven speed display in the acceleration and deceleration stages of an S curve in a robot welding process. Background Art
[0002] Robot accuracy is an important factor affecting processing, and robot trajectory accuracy is an important factor affecting processing errors and processing stability. Taking high-precision arc welding robots as an example, position accuracy and speed smoothness are required to ensure welding quality. In order to ensure trajectory accuracy and motion stability, the robot is required to plan position, speed, and acceleration smoothly during trajectory planning. Common smooth trajectory planning methods include polynomial trajectory planning and spline trajectory planning. It also derives from non-uniform rational B-spline curves, NURBS curves, etc., which ensure the smoothness of motion by planning the motion trajectory between discrete points, and have obvious advantages in processing efficiency and processing quality.
[0003] In addition to polynomial trajectory planning and spline curve trajectory planning, speed and acceleration are often restricted in actual applications. To meet motion requirements, trapezoidal trajectory and S-shaped trajectory speed planning are the two most common types. Among them, S-curve planning is often used in Cartesian space. S-curve planning has smooth displacement and speed, and continuous acceleration, which can effectively avoid impact. The most common seven-segment S-curve trajectory planning is widely used in high-speed and high-precision processing systems.
[0004] In the current welding robot motion control system, the trajectory planning cycle is isochronous and discrete, and its data sampling cycle, that is, the interpolation cycle, is a fixed time period constant, ranging from 2 to 8ms, and the number of interpolation points is an integer. However, when constructing a seven-segment S-speed curve according to the ideal given speed, acceleration, and jerk, the interpolation time is not an integer multiple of the interpolation cycle, which leads to the problem of uneven speed curve and position error. When the acceleration motion is completed and enters the uniform speed stage, the speed suddenly changes due to time rounding. When decelerating to the terminal speed, the speed cannot reach the set speed value due to time rounding. The speed rounding error will affect the accuracy of the planned position.
[0005] To ensure the smoothness of the trajectory, patent CN202211527971.2 designs quaternions to plan the trajectory of the arc trajectory to address the problem of uneven posture, ensuring the smooth operation of the robot's terminal trajectory. Patent CN202110797042.2 constructs a transition path between two adjacent given paths by establishing a cubic uniform spline and then performs S-curve trajectory planning on the constructed path. A similar patent CN202011544185.4 establishes a non-uniform B-spline curve as a transition curve to achieve smooth and continuous speed planning.
[0006] From the perspective of speed curve planning, patent CN202310602203.7 interpolates the speed curve according to acceleration, takes the speed stage as the boundary, performs acceleration smoothing on each interpolation cycle in each speed stage, optimizes the number of pulses in the later stage of interpolation, and increases the smoothness of the speed. Patent CN201810845279.1 performs acceleration and deceleration planning for the S curve with negative initial and final speeds, ensuring continuous trajectory planning when negative initial and final speeds appear. Patent CN202311217178.7 performs secondary planning on the S curve by establishing an auxiliary correction function, controls the motor with the speed curve after secondary planning, and converts the S speed curve into pulse output, obtaining smoother speed control.
[0007] From the perspective of rounding cycle, patent CN201710917904.4 compensates for rounding errors in trajectory planning by adjusting the interpolation time, and recalculates all motion parameters using displacement and speed adjustment to ensure that the adjusted motion parameters do not exceed the limit. Similarly, patent CN201710994472.7 performs bidirectional adaptive interpolation on NURBS curves based on the S-curve acceleration and deceleration algorithm, thereby improving the accuracy of speed planning interpolation. Patent CN202311744776.X also targets the rounding problem in the S-curve speed planning process, and compensates for the rounding error by increasing the interpolation cycle, which eliminates the rounding error to a certain extent.
[0008] Among the above inventions for trajectory smoothing, some inventions start from path smoothness and ensure the smoothness of the speed trajectory at the macro level by smooth planning of the path, but they are bound to sacrifice trajectory accuracy. There are few related inventions that focus on the problem of non-smooth speed caused by discrete control systems. Most of the existing inventions achieve smooth planning of speed trajectories by adjusting the time planning strategy and changing the discrete cycle. However, the discrete time of the control system is fixed, and the discrete cycle is inconvenient to adjust. The method of adjusting the discrete cycle will affect the stability of the servo system, which will have a negative impact on the trajectory accuracy.
[0009] The smoothing method of trajectory planning for welding robots is achieved through path smoothing on the one hand, and speed planning is mostly achieved by adjusting the time rounding strategy and planning cycle on the other hand. The path smoothing transition method is bound to sacrifice some trajectory accuracy, and the accumulation of rounding errors with discrete systems will cause the trajectory accuracy to further decrease. For the speed planning strategy for discrete systems, the discrete cycle is a fixed value in the actual control process, which is difficult to adjust. At the same time, the continuity of acceleration is not considered in the existing methods. Therefore, there is still a lot of room for development in the speed smoothing planning method for discrete control systems. Summary of the invention
[0010] In order to solve the problems in the known technology that the S-curve trajectory planning process of the welding robot has a large amount of calculation, the speed curve is not smooth under discrete control conditions, and the rounding error affects the trajectory accuracy, the present invention establishes a position and speed rounding error model of the S-curve acceleration section, the uniform speed section and the deceleration section of the welding robot on the basis of an isochronous discrete digital motion control system, and analyzes the influencing factors of the rounding error; on this basis, a planning process speed rounding error compensation method based on polynomial interpolation is proposed, and the rounding period error of the S-curve planning trajectory is compensated without affecting the initial and final speeds of the acceleration section and the deceleration section of the welding robot and the acceleration of the welding robot, and the smooth transition of the speeds of each section is realized by speed compensation of the acceleration section and the deceleration section of the welding robot, so as to achieve the effect of improving speed smoothness and improving trajectory accuracy.
[0011] The specific contents of the present invention are as follows:
[0012] In order to overcome the problems of large amount of calculation, non-smooth speed curve under discrete control conditions, and rounding error affecting trajectory accuracy in the prior art, the present invention divides the planning stage for the S speed curve of the welding robot, establishes the corresponding speed and position rounding error model, and uses the seventh-order polynomial error compensation method to compensate for the speed rounding error of each stage, and obtains the corresponding discrete position by integration. A planning error compensation method is provided that is simple in calculation, ensures speed smoothness, and improves trajectory accuracy.
[0013] The trajectory planning algorithm of the seven-segment S-speed curve of the welding robot under discrete control conditions is established. The input is the position information of the teaching point of the weld trajectory in Cartesian space, the maximum speed constraint in the welding process, and the maximum acceleration percentage. The maximum jerk constraint in Cartesian space is given according to the motor performance of the welding robot system, and the trajectory planning based on the seven-segment S-speed curve is carried out in Cartesian space. The relationship between the Cartesian space position and the discrete planning time, maximum speed, maximum acceleration, and maximum jerk is shown. The problem that the traditional discrete control system uses continuous planning expressions for the calculation time nodes in the planning process of the seven-segment S-speed curve trajectory of the welding robot, which leads to the failure of time mark judgment in the planning process and affects the calculation accuracy, is solved.
[0014] The seven-segment S-speed curve is divided, and on this basis, the acceleration curve characteristics are planned based on the seven-segment S-curve trajectory of the welding robot. The speed rounding error model and position rounding error model of the seven-segment S-speed curve of the welding robot are established through integral operation as the constraint information of the seventh-order polynomial speed compensation trajectory. The relationship between the discrete cycle, the maximum speed constraint and the speed rounding error and the position rounding error is established as the constraint condition of the seventh-order polynomial compensation trajectory. The problem of multiple curve division stages, short single-segment planning time, small error, high calculation difficulty and difficult compensation in the prior art is solved, which reduces the amount of calculation and improves the operation efficiency.
[0015] The advantages and positive effects of the present invention are:
[0016] 1. For discrete control systems, the trajectory expression of the seven-segment S-speed curve planning of the welding robot under discrete time is established to meet the discrete control requirements.
[0017] 2. Divide the discrete planning process of the seven-segment S-speed curve of the welding robot to reduce the computational complexity of the trajectory planning process.
[0018] 3. A seventh-order polynomial speed compensation trajectory was established to achieve smooth compensation for each segment of the seven-segment S speed curve of the welding robot.
[0019] 4. Compensation for basic trajectory and complex spline curve trajectory is realized to improve trajectory accuracy.
[0020] 5. The method is universal and can be applied to the seven-segment S-speed curve trajectory planning process of welding robots under different constraints, improving the trajectory accuracy and speed smoothness of industrial robots used in various scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 It is a flow chart of a seven-segment S-speed curve trajectory planning method for a welding robot based on seventh-order polynomial interpolation. DETAILED DESCRIPTION
[0022] The present invention is described in detail below with reference to the accompanying drawings and embodiments.
[0023] The technical solution adopted by the present invention is a seven-segment S speed curve trajectory planning method for a welding robot based on polynomial interpolation, comprising: establishing a seven-segment S speed curve trajectory planning expression for the welding robot under continuous time according to the position information of the welding seam trajectory teaching point and the speed constraint conditions required by the process in the welding process, dividing the seven-segment S speed curve of the welding robot into stages, and establishing a seven-segment S speed curve planning expression for the welding robot under discrete time on this basis; determining the rounding time of each segment in the planning process of the seven-segment S speed curve of the welding robot under discrete time, calculating the speed rounding error and the position rounding error; establishing a seventh-order polynomial speed compensation trajectory expression, calculating the speed compensation curve parameters, and calculating the discrete speed compensation value; integrating the speed curve to obtain the position information of the welding control points of the discrete planning.
[0024] The specific technical solutions of the present invention are as follows:
[0025] Step (1), establish the relationship between the robot's Cartesian spatial displacement and motion time during the welding process, q(t) is the Cartesian spatial displacement of the welding robot corresponding to time t. The maximum and minimum values of the jerk of the seven-segment S-speed curve trajectory planning of the welding robot are j max 、j min , the maximum and minimum values of acceleration are a max 、a min The initial welding speed is v0, the final cut-off speed is v1, and the welding speed required by the process is v max The position information of the initial welding point is recorded as q0, and the position information of the end welding point is recorded as q1.
[0026]
[0027] The overall planning time under continuous time is recorded as T, and the welding process is divided into three stages: acceleration stage, uniform speed stage, and deceleration stage according to the speed change trend;
[0028] The planning time of the three stages is denoted as T a 、T v 、T d , the seven-segment S-speed curve trajectory planning acceleration curve of the welding robot, defining the constant acceleration duration T in the acceleration segment j1 , the constant acceleration duration T in the deceleration section j2 .
[0029] T=T a +T v +T d (2)
[0030] In the process of speed planning, the weld trajectory length, acceleration, jerk, maximum speed, initial speed and final speed are given as the constraints of the S-speed curve planning trajectory expression of the welding robot. According to formula (1), the planning time of the acceleration stage, the uniform speed stage and the deceleration stage are obtained:
[0031]
[0032] Step (2) establishes the relationship between Cartesian spatial displacement and time during the welding process in discrete time, where q(t) is the Cartesian spatial displacement of the welding robot corresponding to time t. The maximum and minimum values of the jerk of the seven-segment S-speed curve trajectory planning of the welding robot are j max 、j min , the maximum and minimum values of acceleration are a max 、a min , the initial speed is v0, the final cut-off speed is v1, and the maximum speed is v max , the initial position of welding is recorded as q0, and the final position of welding is recorded as q1. The overall planning time in discrete time is recorded as T r , similar to continuous planning, the planning time of the three stages is recorded as T r1 、T r2 、T r3 , the constant acceleration duration T in the acceleration section j1 , the constant acceleration duration T in the deceleration section j2 .
[0033]
[0034] Step (3), determine whether each planning time segment is a discrete period T s For each stage, if the continuous planning time is an integer multiple of the discrete period, skip steps (4), (5), and (6). If the continuous planning time is not an integer multiple of the discrete period, round up the time to calculate the discrete planning time of this stage. Taking the acceleration stage as an example, the number of interpolation points is m1, ceil means rounding up, and when there is a remainder in the calculation result, round up to the nearest larger integer.
[0035]
[0036] T r1 =m1T s (8)
[0037] Step (4), calculate the round-off time of each stage, and record the total discrete planning time as T r , the total time of each discrete programming stage is T r1 、T r2 、T r3, the total rounding time is Δt, and the rounding time of each segment is Δt1, Δt2, Δt3
[0038] T r =T r1 +T r2 +T r3 (9)
[0039] Δt=Δt1+Δt2+Δt3, Δt i <T s (i=1,2,3) (10)
[0040] Δt=(T r1 -T a )+(T r2 -T v )+(T r3 -T d ) (11)
[0041] Step (5), establish the speed rounding error and position rounding error model for each stage. The overall position rounding error under discrete time planning is recorded as ΔL. The position rounding errors of each stage are recorded as ΔL1, ΔL2, ΔL3, and the speed rounding errors are recorded as Δv1, Δv2, Δv3 respectively.
[0042] ΔL=ΔL1+ΔL2+ΔL3 (12) In the acceleration phase, the speed increases from the initial speed v0 to v max
[0043]
[0044] Taking the acceleration stage as an example, the actual planning speed of the last planning point of the acceleration segment in the discrete planning process is greater than the set welding speed. The continuous planning time node of the acceleration segment is before the discrete planning time node, and there is a rounding time Δt1.
[0045] The velocity rounding error can be obtained by integrating the acceleration within the rounding time range:
[0046]
[0047] Calculate the velocity rounding error and position rounding error in the uniform speed segment:
[0048] ΔL2=v max Δt2 (15)
[0049] Δv2=0 (16)
[0050] The deceleration stage is the deceleration stage, and the speed is v max Reduce to the terminal cut-off speed v1, calculate the speed rounding error and position rounding error in the deceleration stage:
[0051]
[0052] Δv3=-a min (T r3 -T d ) (18)
[0053] Step (6), calculate the seventh-order polynomial speed compensation curve parameters. Define the seventh-order polynomial speed curve expression, v(t) is the compensation speed corresponding to time t, a i are the coefficients of the seventh-order polynomial, and t0 is the starting time.
[0054]
[0055] As calculated in step (4), the compensation trajectory time of the acceleration phase and the deceleration phase are T r1 , T r3 The total speed compensation values in the acceleration stage and deceleration stage are Δv1 and Δv3 respectively.
[0056] Taking the acceleration phase as an example, the discrete planning time T r1 As the planning time length of the seventh-order polynomial compensation trajectory, the starting point of the compensation trajectory is 0, and the total compensation value Δv1 is calculated according to formula (14), and the first-order derivative, second-order derivative, and third-order derivative constraints of the seventh-order polynomial at the beginning and end positions are set to 0.
[0057] T r1 =t1-t0 (20)
[0058] The coefficients of the compensation trajectory are calculated according to the seventh-order polynomial rounding error compensation constraint conditions.
[0059]
[0060] In step (7), if the seventh-order polynomial speed error compensation is not performed, the compensation value is recorded as 0. The speed value of each discrete point is calculated according to the S-curve speed trajectory planning formula of the welding robot, and the compensated speed of each point is obtained by superposition. The speed is integrated to obtain the position information of the welding control point.
Claims
1. A welding robot S-speed curve trajectory planning method based on polynomial interpolation, characterized in that: The trajectory planning algorithm of the seven-segment S-speed curve of the welding robot under discrete control conditions is established. The input is the position information of the teaching point of the weld trajectory in Cartesian space, the maximum speed constraint in the welding process, and the maximum acceleration percentage. The maximum jerk constraint condition in Cartesian space is given according to the motor performance of the welding robot system. The trajectory planning based on the seven-segment S-speed curve is carried out in Cartesian space. The relationship between the Cartesian space position and the discrete planning time, maximum speed, maximum acceleration, and maximum jerk is shown. The seven-segment S-speed curve is divided, and the acceleration curve characteristics of the seven-segment S-curve trajectory of the welding robot are planned. The speed rounding error model and position rounding error model of the seven-segment S-speed curve of the welding robot are established through integral operation as the constraint information of the seventh-order polynomial speed compensation trajectory. The relationship between the discrete period, the maximum speed constraint and the speed rounding error and the position rounding error is established as the constraint condition of the seventh-order polynomial compensation trajectory.
2. The S-speed curve trajectory planning method of a welding robot based on polynomial interpolation according to claim 1 is characterized in that: The method comprises the following steps: step (1), establishing the relationship between the Cartesian space displacement and the motion time of the robot during welding, q(t) being the Cartesian space displacement of the welding robot corresponding to the time t; the maximum and minimum values of the jerk of the seven-segment S-speed curve trajectory planning of the welding robot being j max 、j min , the maximum and minimum values of acceleration are a max 、a min The initial welding speed is v0, the final cut-off speed is v1, and the welding speed required by the process is v max , the position information of the welding initial point is recorded as q0, and the position information of the welding end point is recorded as q1; The overall planning time under continuous time is recorded as T, and the welding process is divided into three stages: acceleration stage, uniform speed stage, and deceleration stage according to the speed change trend; The planning time of the three stages is denoted as T a , T v , T d As shown in Figure 3, the seven-segment S-speed curve trajectory planning acceleration curve of the welding robot defines the constant acceleration duration T in the acceleration segment. j1 , the constant acceleration duration T in the deceleration section j2 ; T=T a +T v +T d (2) In the process of speed planning, the weld trajectory length, acceleration, jerk, maximum speed, initial speed and end speed are given as the constraint conditions of the S-speed curve planning trajectory expression of the welding robot; According to formula (1), the planning time of the acceleration phase, the uniform speed phase, and the deceleration phase is obtained: Step (2), establishing the relationship between Cartesian spatial displacement and time during the welding process in discrete time, where q(t) is the Cartesian spatial displacement of the welding robot corresponding to time t; The maximum and minimum values of the jerk for the seven-segment S-speed curve trajectory planning of the welding robot are j max 、j min , the maximum and minimum values of acceleration are a max 、a m i n , the initial speed is v0, the final cut-off speed is v1, and the maximum speed is v max , the initial welding point position information is recorded as q0, the welding end point position information is recorded as q1; the overall planning time under discrete time is recorded as T r , the planning time of the three stages is recorded as T r1 , T r2 , T r3 , the constant acceleration duration T in the acceleration segment j1 , the constant acceleration duration T in the deceleration section j2 ; Step (3), determine whether each planning time segment is a discrete period T s For each stage, if the continuous planning time is an integer multiple of the discrete period, skip steps (4), (5), and (6). If the continuous planning time is not an integer multiple of the discrete period, round up the time and calculate the discrete planning time for this stage. In the acceleration phase, the number of interpolation points is recorded as m1, ceil means rounding up, and when there is a remainder in the calculation result, the nearest larger integer is rounded up; T r1 =m1T s (8) Step (4), calculate the round-off time of each stage, and record the total discrete planning time as T r , the total time of each discrete programming stage is T r1 , T r2 , T r3 , the total rounding time is Δt, and the rounding time of each segment is Δt1, Δt2, Δt3 T r =T r1 +T r2 +T r3 (9) Δt=Δt1+Δt2+Δt3, Δt i <T s (i=1,2,3) (10)Δt=(T r1 -T a )+(T r2 -T v )+(T r3 -T d )(11) Step (5), establish the speed rounding error and position rounding error model of each stage; the overall position rounding error under discrete time planning is recorded as ΔL; the position rounding error of each stage is recorded as ΔL1, ΔL2, ΔL3, and the speed rounding error is recorded as Δv1, Δv2, Δv3 respectively ΔL=ΔL1+ΔL2+ΔL3 (12) The acceleration phase speed increases from the initial speed v0 to v max In the acceleration stage, the actual planning speed of the last planning point of the acceleration section in the discrete planning process is greater than the set welding speed. The continuous planning time node of the acceleration section is before the discrete planning time node, and there is a rounding time Δt1; The velocity rounding error is obtained by integrating the acceleration within the rounding time range: Calculate the velocity rounding error and position rounding error in the uniform speed segment: ΔL2=v max Δt2 (15)Δv2=0 (16) The deceleration stage is the deceleration stage, and the speed is v max Reduce to the terminal cut-off speed v1, calculate the speed rounding error and position rounding error in the deceleration stage: Δv3=-a min (T r3 -T d ) (18) Step (6), calculate the parameters of the seventh-order polynomial speed compensation curve; define the seventh-order polynomial speed curve expression, v(t) is the compensation speed corresponding to time t, a i are the coefficients of the seventh-order polynomial, and t0 is the starting time; As calculated in step (4), the compensation trajectory time of the acceleration phase and the deceleration phase are T r1 , T r3 , the total speed compensation values in the acceleration stage and deceleration stage are Δv1 and Δv3 respectively; In the acceleration phase, the discrete planning time T r1 As the planning time length of the seventh-order polynomial compensation trajectory, the starting point of the compensation trajectory is 0, and the total compensation value Δv1 is calculated according to formula (14), and the first-order derivative, second-order derivative, and third-order derivative constraints of the seventh-order polynomial at the beginning and end positions are set to 0; T r1 =t1-t0 (20) The coefficients of the compensation trajectory are calculated according to the seventh-order polynomial rounding error compensation constraint conditions. In step (7), if the seventh-order polynomial speed error compensation is not performed, the compensation value is recorded as 0. The speed value of each discrete point is calculated according to the S-curve speed trajectory planning formula of the welding robot, and the compensated speed of each point is obtained by superposition. The speed is integrated to obtain the position information of the welding control point.
Citation Information
Patent Citations
A method for rounding error compensation in S-curve acceleration and deceleration
CN107765639B
NURBS curve bi-directional adaptive interpolation algorithm based on S-curve acceleration and deceleration algorithm
CN107817764A
A method for S-curve acceleration / deceleration planning to handle negative initial and final velocities
CN108829044B
Industrial robot track section transition method based on non-uniform B spline curve
CN112659126A
Smoothing method for Cartesian space motion trail of six-axis series industrial robot
CN113442142A
Cited By
Robot smooth stop control method suitable for high-frequency communication period
CN120985636A
Automatic track planning method based on teaching type portal crane
CN122488661A