Speed planning method, device, storage medium and computer program

By combining the bisection method in the CNC system to approximate and calculate the starting speed and acceleration of the current cycle, the problem of the non-smoothness of the actual speed curve caused by the speed planning algorithm is solved, and the smoothness of machine tool motion and the improvement of machining quality are realized.

CN119472494BActive Publication Date: 2025-12-12HANS LASER TECH IND GRP CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411484426.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-23
Publication Date
2025-12-12
Estimated Expiration
2044-10-23

AI Technical Summary

Technical Problem

In existing CNC systems, the actual speed curve caused by the speed planning algorithm is not smooth, which can easily lead to machine tool vibration and affect machining quality.

Method used

By obtaining the actual displacement and planned displacement of the previous motion cycle, it is determined whether they are equal. If the difference does not exceed the preset difference, the starting velocity and acceleration of the current cycle are approximated using the bisection method to smooth the actual motion curve of the system.

Benefits of technology

This achieves smooth system motion curves, avoids machine tool vibration, and ensures the quality of processed products.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119472494B_ABST
    Figure CN119472494B_ABST
Patent Text Reader

Abstract

The application discloses a speed planning method, device, storage medium and computer program, and the method comprises the following steps: acquiring actual displacement and planned displacement of a system in a previous motion period, and judging whether the actual displacement is equal to the planned displacement; if the actual displacement is equal to the planned displacement, using actual terminal speed and actual terminal acceleration of the previous motion period as starting speed and starting acceleration of a current motion period; if the actual displacement is not equal to the planned displacement, using a speed planning model of the previous motion period and combining a bisection method to approach planned terminal speed and planned terminal acceleration of the previous motion period as starting speed and starting acceleration of the current motion period under the condition that a difference between the actual displacement and the planned displacement of the system in the previous motion period is not more than a preset difference. Based on the foregoing steps, the system can adopt more suitable starting speed and starting acceleration for speed planning in the current motion period, so that the actual speed curve of the system is smoother, vibration of a machine tool is avoided, and the quality of a processed product is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of speed planning, in particular to a speed planning method, device, storage medium and computer program. BACKGROUND

[0002] In a numerical control system, speed planning is an indispensable function of system movement, and common speed planning algorithms include trigonometric functions, polynomials, T-shaped curves, S-shaped curves, etc. In a speed planning algorithm, the system calculates the displacement of each period of movement of the system according to the start point and end point conditions of each path.

[0003] Since different speed planning algorithms are used in a numerical control system, the speed of the system can only be represented by the displacement change amount of each period, and the acceleration of the system can only be represented by the speed change amount of each period. The displacement of a speed planning algorithm is obtained by integrating the speed-time curve, the speed is obtained by integrating the acceleration-time curve, and the acceleration is obtained by integrating the jerk-time curve. The displacement of each period is obtained by integrating the speed of the speed-time curve and the time of the speed curve, and the speed of the speed curve is called instantaneous speed, and the acceleration of the acceleration curve is called instantaneous acceleration. The speed of the system is the displacement change amount, which is called discrete speed, and the acceleration of the system is the speed change amount, which is called discrete acceleration.

[0004] Under normal circumstances, the initial speed and acceleration of a speed planning algorithm are the speed and acceleration of the system. If the system uses a speed planning algorithm to plan new movement time every period, and the original speed curve model is maintained for a plurality of consecutive periods, since the movement of the system does not use the values on the speed-time curve, the movement of the system is only related to the displacement change amount, and the size of the displacement change amount represents the size of the speed of the system, so the size of the displacement change amount at time T is not equal to the speed value on the speed-time curve at time T, and the displacement of the T+1 period is calculated by the speed value on the speed-time curve at time T. If the displacement is directly integrated using the speed of the system, the displacement change amount at time T+1 will no longer be the value on the original speed-time curve, so directly using the parameters of the system will result in a large error, resulting in a less smooth actual speed curve of the system, which is prone to cause vibration of the machine tool and is not conducive to ensuring the quality of the processed product. SUMMARY

[0005] In view of the shortcomings of the prior art described above, the present application provides a speed planning method, device, storage medium and computer program, which can use more appropriate initial speed and initial acceleration for speed planning to make the actual speed curve of the system smoother.

[0006] The embodiment adopts the following technical solutions:

[0007] A speed planning method, comprising the steps of:

[0008] acquiring actual displacement and planned displacement of a system in a previous motion cycle, and determining whether the actual displacement and the planned displacement of the system are equal;

[0009] if yes, using actual end speed and actual end acceleration of the previous motion cycle as initial speed and initial acceleration of the current motion cycle;

[0010] if no, determining whether a difference between the actual displacement and the planned displacement of the system in the previous motion cycle exceeds a preset difference value;

[0011] if no, using a speed planning model of the previous motion cycle and combining dichotomy approximation to obtain planned end speed and planned end acceleration of the previous motion cycle, and using the planned end speed and the planned end acceleration as the initial speed and the initial acceleration of the current cycle.

[0012] Further, in the speed planning method, the step of using the speed planning model of the previous motion cycle and combining dichotomy approximation to obtain the planned end speed and the planned end acceleration of the previous motion cycle, and using the planned end speed and the planned end acceleration as the initial speed and the initial acceleration of the current cycle comprises:

[0013] when the difference between the actual displacement and the planned displacement of the system in the previous motion cycle is greater than 0, using a speed curve model of the previous motion cycle to calculate a final speed on the speed curve that satisfies a displacement of Δ under a condition that a speed is v0+j and an acceleration is a0+j, and using t as 1, and combining dichotomy approximation to calculate a final acceleration that satisfies the displacement of Δ under the condition that the speed is v0+j and the acceleration is a0+j, and using t as 1.

[0014] wherein v0 is the initial speed of the previous motion cycle, a0 is the initial acceleration of the previous motion cycle, j is ±j max or 0, j max is a maximum jerk of the system, and t is a cycle time.

[0015] Further, in the speed planning method, the step of using the speed planning model of the previous motion cycle and combining dichotomy approximation to obtain the planned end speed and the planned end acceleration of the previous motion cycle, and using the planned end speed and the planned end acceleration as the initial speed and the initial acceleration of the current cycle comprises:

[0016] when the difference between the actual displacement and the planned displacement of the system in the previous motion cycle is less than 0, using a speed curve model of the previous motion cycle to calculate a final speed on the speed curve that satisfies a displacement of Δ under a condition that a speed is v0 and an acceleration is a0, and using t as 1, and combining dichotomy approximation to calculate a final acceleration that satisfies the displacement of Δ under the condition that the speed is v0 and the acceleration is a0, and using t as 1.

[0017] ​​​Wherein, v0 is the starting speed of the last motion cycle, a0 is the starting acceleration of the last motion cycle, j is ±j max or 0, j max is the maximum jerk of the system, and t is the cycle time.

[0018] Further, in the speed planning method, the method further comprises the steps of:

[0019] If the preset difference is exceeded, the starting speed and the starting acceleration of the current motion cycle are calculated according to the assumption that the acceleration of the current motion cycle continues to increase in the direction of the system acceleration, and whether the assumption is satisfied is determined according to the final speed of the current motion cycle, and if the assumption is satisfied, the starting speed and the starting acceleration of the current motion cycle are applied.

[0020] Further, in the speed planning method, the method further comprises the steps of:

[0021] If the assumption is not satisfied, the starting speed and the starting acceleration of the new current motion cycle are derived under the condition of reverse motion of the acceleration.

[0022] Further, in the speed planning method, the step of calculating the starting speed and the starting acceleration of the current motion cycle according to the assumption that the acceleration of the current motion cycle continues to increase in the direction of the system acceleration comprises:

[0023] Assuming that x represents the variable to be added when the speed of the current motion cycle of the system is converted into the starting speed, and y represents the variable to be added when the acceleration of the current motion cycle of the system is converted into the starting acceleration, in

[0024]

[0025] a 系 = -a max Under the circumstances, the value of y is set respectively, and the value of x is solved, so as to obtain the starting speed and the starting acceleration of the current cycle.

[0026] Further, in the speed planning method, the step of deriving the starting speed and the starting acceleration of the new current motion cycle under the condition of reverse motion of the acceleration if the assumption is not satisfied comprises:

[0027] If the assumption is not satisfied according to the final speed of the current motion cycle, the value of y is reset under the condition of reverse motion of the acceleration, and the value of x is solved, so as to obtain the starting speed and the starting acceleration of the current cycle.

[0028] A speed planning device comprises a processor and a memory; the memory is used to store a computer program, the computer program comprises program instructions; the processor is used to call the computer program to realize the above speed planning method.

[0029] A computer readable storage medium, the storage medium stores a computer program, the computer program is executed by a processor to realize the steps of the above speed planning method.

[0030] A computer program product, the computer program product stores computer instructions, the computer instructions are executed by a processor to realize the steps of the above speed planning method.

[0031] Compared with the prior art, the speed planning method, device, storage medium and computer program provided by the application can judge whether the current period needs to follow the end point parameter of the last motion period speed planning in combination with the start parameter condition of each period and the displacement planned in the last period. If the actual displacement of the system and the displacement planned by the speed planning are equal, the end point parameter of the last period can be directly followed. If the actual displacement of the system and the displacement planned by the speed planning are not equal, the planning end point speed and the planning end point acceleration of the last motion period are obtained by using the speed planning model of the last motion period and combining the bisection method approximation under the condition that the difference between the actual displacement and the planned displacement of the system in the last motion period does not exceed a preset difference value, and are used as the start speed and acceleration of the current period. Finally, the actual motion curve of the system can be made more smooth, the vibration of the machine tool can be avoided, and the quality of the processed product can be ensured. BRIEF DESCRIPTION OF DRAWINGS

[0032] Figure 1 The flowchart of the speed planning method provided by the application.

[0033] Figure 2 The system speed curve obtained by directly using the system parameter planning.

[0034] Figure 3 The system acceleration curve obtained by directly using the system parameter planning.

[0035] Figure 4 The system jerk curve obtained by directly using the system parameter planning.

[0036] Figure 5 The system speed curve obtained by using the speed planning method provided by the application.

[0037] Figure 6 The system acceleration curve obtained by using the speed planning method provided by the application.

[0038] Figure 7A system jerk curve diagram obtained by using the speed planning method provided in the application.

[0039] Figure 8 A structure block diagram of a speed planning device provided in the application. DETAILED DESCRIPTION

[0040] In order to make the technical problems, technical solutions and beneficial effects to be solved in the application more clearly understood, the application is further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the application and do not limit the application.

[0041] In the following description, specific details are set forth in order to provide a thorough understanding of embodiments of the application. However, persons of ordinary skill in the art will appreciate that embodiments of the application can be practiced without these specific details. In other instances, well-known methods, structures, circuits, and processes have not been described in detail in order to avoid obscuring the application.

[0042] It should be understood that when used in the specification and the appended claims, the term "comprises" indicates the presence of the described features, integers, steps, operations, elements, and / or components, but does not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0043] It should also be understood that the term "and / or" as used herein refers to any combination of associated listed items, and all possible combinations, and includes these combinations.

[0044] In addition, in the description of the specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the description, and cannot be understood as indicating or implying relative importance.

[0045] In the specification of the application, the reference "one embodiment" or "some embodiments" means that the specific features, structures or characteristics described in connection with the embodiment are included in one or more embodiments of the application. Therefore, the statements "in one embodiment", "in some embodiments", "in other some embodiments", "in further some embodiments" and the like appearing in different places in the specification are not necessarily all referring to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized. The terms "include", "contain", "have" and their variants mean "include but not limited to", unless otherwise specifically emphasized.

[0046] The application provides a speed planning method applied to a numerical control system, which comprises a jerk stage, a uniform acceleration stage, a deceleration stage, a uniform speed stage, an acceleration-deceleration stage, a uniform deceleration stage and a deceleration-deceleration stage.

[0047] The speed planning method plans a starting speed and acceleration of a starting point of a path, and plans displacement-time curves, speed-time curves, acceleration-time curves and jerk-time curves on the whole path according to the length of the path and the final speed and acceleration of the end point of the path. The relationship among the four curve models is a layer-by-layer integral relationship, the acceleration-time curves are obtained by integrating the jerk-time curves, the speed-time curves are obtained by integrating the acceleration-time curves, and the displacement-time curves are obtained by integrating the speed-time curves.

[0048] Please refer to Figure 1 The speed planning method provided by the application comprises the following steps.

[0049] S10, acquiring actual displacement and planned displacement of a system in a previous motion cycle, and determining whether the actual displacement is equal to the planned displacement;

[0050] S20, if the actual displacement is equal to the planned displacement, using an actual end point speed and an actual end point acceleration of the previous motion cycle as a starting speed and a starting acceleration of a current motion cycle;

[0051] S30, if the actual displacement is not equal to the planned displacement, determining whether a difference between the actual displacement and the planned displacement exceeds a preset difference value;

[0052] S40, if the difference does not exceed the preset difference value, using a speed planning model of the previous motion cycle and combining a bisection method to approximate a planned end point speed and a planned end point acceleration of the previous motion cycle, and using the planned end point speed and the planned end point acceleration as the starting speed and the starting acceleration of the current cycle.

[0053] In the speed planning process of each motion cycle of the system, the starting parameter condition of each cycle and the planned displacement of the previous cycle are combined, and it is determined whether the end point parameters of the speed planning of the previous motion cycle are used in the current cycle. If the actual motion displacement of the system is equal to the planned displacement, the end point parameters of the previous cycle can be directly used. If the actual motion displacement of the system is not equal to the planned displacement, the speed planning model of the previous motion cycle is used and the bisection method is combined to approximate the planned end point speed and the planned end point acceleration of the previous motion cycle, and the planned end point speed and the planned end point acceleration are used as the starting speed and the starting acceleration of the current cycle, so that the actual motion curve of the system can be finally made more smooth, the vibration of the machine tool can be avoided, and the quality of the processed product can be ensured.

[0054] In implementation, the system can send instructions to the servo system, which needs to control the system movement in one cycle, and the actual displacement of the system can be fed back in the current cycle, that is, the actual displacement of the system is obtained by subtracting the difference between the motor feedback coordinates read in the last movement cycle from the motor feedback coordinates read in the current cycle.

[0055] Similarly, the actual speed of the system is calculated from the motor feedback coordinates in the current cycle, and the acceleration of the system is the difference between the actual speed of the system in the current cycle and the actual speed of the system in the last movement cycle.

[0056] In step S20, when planning the speed, the planned initial parameter conditions include displacement S 总 , initial speed v0, initial acceleration a0, maximum speed v max , maximum acceleration a max , maximum jerk j max , etc., and the speed planning formula is as follows:

[0057] a=a0+jt

[0058]

[0059] wherein the value of j is ±j max or 0, and t is the cycle time.

[0060] According to the speed planning formula, when t=1, the displacement planned in each cycle is the final speed is and the final acceleration is a0+j. If the actual displacement of the system is the same as the planned displacement, the speed of the system is

[0061] Taking the system end point coordinates as constant and the total displacement as S 总 , the total time of movement is T 总 , the displacement of the current cycle is the total displacement planned in the next cycle is Each cycle s is obtained by integrating the v-t curve from t to t+1. Therefore, the initial speed planned in the next cycle is the final speed of the current cycle and the initial acceleration is a0+j. Because the speed of the system is and the speed planning final speed are not equal, using may result in low efficiency due to long time or movement beyond the end point due to slow speed reduction. Therefore, selecting the final speed and final acceleration of the current cycle as the initial parameters of the next cycle is the best choice.

[0062] In step S30, it can be understood that in the case of cycle time t = 1, that is, within one cycle, the acceleration of the system should be But in the case of deviation, the acceleration is The difference between the two accelerations is Δ, and the theoretical motion displacement at the last motion cycle t = 1 is In fact, it is For the speed and acceleration of the system, the actual motion displacement is different from the planned displacement, and the system acceleration is also different, so the preset difference Δ can be set as j max .

[0063] In step S40, when the preset difference Δ does not exceed j max , the system in the actual motion process, the distance of motion and the theoretical distance is not much different. The change of the speed planning acceleration of each cycle does not exceed a j max , the speed of the system is Assuming that the speed of the system at the last motion cycle is v 系 , the acceleration is a 系 , then the acceleration of the current cycle of the system is The jerk is The jerk of the system increases Δ from the theoretical value. If the speed of the system is The starting speed of the current cycle is The starting acceleration is a0+j, which is planned to make the jerk of the system not exceed a jma x , so the system motion does not deviate from the planned speed curve model of the last motion cycle.

[0064] And, different speed planning can be performed according to whether the preset difference Δ is greater than 0. In some embodiments, step S40 specifically includes:

[0065] S41, when the difference between the actual displacement and the planned displacement of the system at the last motion cycle is greater than 0, the starting point is the speed of The acceleration is a0+j, t is 1, and the end speed on the speed curve that satisfies the displacement is Δ is calculated by combining the bisection method for t, and the end acceleration that satisfies the displacement is Δ is calculated by t;

[0066] Where v0 is the starting speed of the last motion cycle, a0 is the starting acceleration of the last motion cycle, the value of j is ±j max or 0, j max is the maximum jerk of the system, and t is the cycle time.

[0067] When Δ is greater than 0 but does not exceed j max, the acceleration of the velocity planning in a unit period cannot exceed j max , it can be considered that Δ does not exceed j max , the whole movement is still on the planning model of the last movement period. Theoretically, the displacement of the movement at t = 1 is Actually, it is The value of t is between t = 1 and t = 2. When t = 1, the value of the velocity curve model is The value of the acceleration curve model is a0 + j.

[0068] The bisection process is:

[0069] (1) First, the starting velocity is The starting acceleration is a0 + j, and the value of t in the last week movement planning model is divided into three, t1 = 0, t3 = 1.

[0070] (2) Calculate whether the displacement s1, s2, s3 of t at the three values satisfies Δ, because s1 = 0 when t1 = 0, so s1 < Δ.

[0071] (3) If s2 > Δ, it means that the value of t is between [t1, t2], let t3 = t2, Step (2) is performed.

[0072] (4) If s2 < Δ, it means that the value of t is between [t2, t3], let t1 = t2, Step (2) is performed. According to the above steps, the value of t satisfies s = Δ, and the velocity value and acceleration value at the current t are calculated as the starting velocity and starting acceleration of the current period velocity planning.

[0073] Step S40 can further include:

[0074] S42, when the difference between the actual displacement and the planned displacement of the system in the last movement period is less than 0, the starting point of the velocity curve model in the last movement period is velocity v0 and acceleration a0, t is 1, and the end velocity on the velocity curve that satisfies the displacement is is calculated by bisection of t, and the end acceleration that satisfies the displacement is is calculated by t;

[0075] Wherein, v0 is the starting velocity of the last movement period, a0 is the starting acceleration of the last movement period, j is ±j max or 0, j max is the maximum jerk of the system, and t is the period time.

[0076] When Δ is less than 0 but greater than jmax , the acceleration of the seven-stage speed planning in a unit period cannot be less than -j max , it can be considered that Δ is not less than -j max , the entire movement is still on the planning model of the last movement period. The theoretical displacement of the movement at t = 1 of the last movement period is , which is actually -j max ≤ Δ < 0 corresponds to the value of t between t = 0 and t = 1. The starting speed value of the speed curve model is v0, and the acceleration value of the acceleration curve model is a0.

[0077] The bisection process is as follows:

[0078] (1) First, the starting speed is v0, the starting acceleration is a0, and the value of t is divided into three, t1 = 0, t3 = 1.

[0079] (2) Calculate whether the displacement s1, s2, s3 of the movement at the three values of t satisfies s = Δ, because s1 = 0 at t1 = 0, so s1 < Δ.

[0080] (3) If s2 > Δ, it means that the value of t is between [t1, t2], let t3 = t2, step (2) is performed.

[0081] (4) If s2 < Δ, it means that the value of t is between [t2, t3], let t1 = t2, step (2) is performed. According to the above steps, the value of t satisfies s = Δ, and the speed value and acceleration value at the current t are calculated as the starting speed and starting acceleration of the current period speed planning.

[0082] In addition, when the difference between the actual displacement and the planned displacement of the system in the last movement period exceeds the preset difference, the speed planning method provided by the application can include the following steps:

[0083] S50, if the preset difference is exceeded, the starting speed and starting acceleration of the current movement period are calculated according to the direction of the system acceleration, assuming that the acceleration of the current movement period continues to increase in the direction, and whether the assumption is satisfied is determined according to the final speed of the current movement period, if the assumption is satisfied, the calculated starting speed and starting acceleration of the current movement period are applied.

[0084] In some embodiments, step S50 specifically includes:

[0085] assuming that x represents the variable to be added when the current movement period speed of the system is converted into the starting speed, y represents the variable to be added when the current movement period acceleration of the system is converted into the starting acceleration, and in

[0086] a 系 = -a max Similarly, the value of y is set and the value of x is calculated to obtain the initial speed and initial acceleration of the current period.

[0087] Further, when it is determined that the assumption is not met according to the final speed of the current motion period, the speed planning method provided by the application can include the following steps:

[0088] S60, if not, the initial speed and initial acceleration of the new current motion period are derived under the condition of reverse motion of acceleration.

[0089] In some embodiments, step S60 specifically includes:

[0090] If the assumption is not met according to the final speed of the current motion period, the value of y is reset and the value of x is calculated under the condition of reverse motion of acceleration, so as to obtain the initial speed and initial acceleration of the current period.

[0091] The detailed analysis of steps S50 and S60 is as follows:

[0092] The difference Δ between the actual value and the theoretical value exceeds j max , indicating that the actual motion of the system deviates from the speed curve model planned in the previous motion period. Assuming is the displacement planned in the current period, v 当 is the speed of the system in the current period, a 当 is the acceleration of the system in the current period, j 当 is the jerk of the system in the current period, it can be obtained that:

[0093]

[0094]

[0095]

[0096] Wherein, x represents the variable to be added when the system speed is converted into the initial speed, and y represents the variable to be added when the system acceleration is converted into the initial acceleration.

[0097] a 当 does not exceed a max , and is not less than -a max , so At the same time, j 当 does not exceed j max , and is not less than -j max , so Combining these two formulas, we can obtain:

[0098] If v 系 =0, a 系 =0, then x=0, y=0. During the acceleration phase, It is in v 系 =0 and a 系 =0 reaches its minimum value. The maximum value is a during uniformly accelerated motion. max Therefore, it can be concluded that the acceleration phase satisfies Derived from these two formulas

[0099] During the uniform acceleration phase, a 系 =a max y = 0 Let x be the maximum value that x can take during the acceleration phase, therefore the range of y is...

[0100] Similarly, during the deceleration phase, Reaching the maximum value is The minimum value is -a max Therefore, it can be concluded that the following conditions are met during the deceleration phase. Derived from these two formulas

[0101] During the uniform deceleration phase, a 系 =-a max y = 0 Let x be the minimum value that x can reach during the deceleration phase, therefore the range of values ​​for y is...

[0102] In summary, When j = j max , When j = -j max , Therefore, the value of y is The displacement, final velocity, and final acceleration for each cycle are as follows:

[0103] a = a 系 +y+j

[0104]

[0105]

[0106] And -a max ≤a≤a max-v max ≤v≤v max .

[0107] 1. When

[0108] make From this we can obtain Starting speed Initial acceleration

[0109] (1) If the final velocity v of the current period satisfies The current period involves either accelerated motion or uniform motion, therefore the initial velocity... Initial acceleration

[0110] (2) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration undergo deceleration and acceleration / deceleration motion in the current cycle. Let...

[0111] From this we can obtain

[0112] when if Starting speed Initial acceleration

[0113] if Starting speed Initial acceleration

[0114] when if Initial velocity v0 = 0, initial acceleration

[0115] if Starting speed Initial acceleration

[0116] 2. When

[0117] make From this we can obtain The initial speed is Initial acceleration is

[0118] (1) If the final velocity v of the current period satisfies The current cycle involves accelerated motion, therefore the initial velocity... Initial acceleration

[0119] (2) If the end velocity v of the current period satisfies The converted start velocity and start acceleration do not have jerk motion in the current period, let Thus, we have The start velocity The start acceleration

[0120] 3. When

[0121] If a max -a 系 ≤ j max , it means that the system acceleration and the maximum velocity do not exceed j max , y = a max -a 系 , so Thus, we have The start velocity The start acceleration a0 = a max .

[0122] (1) If the end velocity v of the current period satisfies The current period has uniform acceleration motion, so the start velocity The start acceleration a0 = a max .

[0123] (2) If the end velocity v of the current period satisfies The converted start velocity and start acceleration only have deceleration motion in the current period, let Thus, we have The start acceleration If a max -a 系 > j max , it means that the system acceleration and the maximum velocity exceed j max , y = a max -a 系 -j max , so Thus, we have The start velocity The start acceleration a0 = a max -j max .

[0124] (3) If the end velocity v of the current period satisfies The current cycle involves accelerated motion, therefore the initial velocity... Initial acceleration a0 = a max -j max .

[0125] (4) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration only undergo deceleration and acceleration motion in the current cycle. Let From this we can obtain Starting speed Initial acceleration

[0126] 4. When a 系 =a max .

[0127] Let y = 0, From this we can obtain The initial speed is The initial acceleration is a0 = a 系 .

[0128] (1) If the final velocity v of the current period satisfies The current period exhibits uniformly accelerated motion, therefore the initial velocity is The initial acceleration is a0 = a 系 .

[0129] (2) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration exhibit deceleration during the current cycle, causing... From this we can obtain The initial speed is The initial acceleration is a0 = a 系 .

[0130] 5. When

[0131] make From this we can obtain Starting speed Initial acceleration

[0132] (1) If the final velocity v of the current period satisfies The current cycle involves acceleration and deceleration, so the initial velocity... Initial acceleration

[0133] (2) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration only result in motion with increasing acceleration during the current cycle. Let... Thus, we have Initial velocity Initial acceleration

[0134] 6. When

[0135] Let Thus, we have Initial velocity Initial acceleration

[0136] (1) If the end velocity v of the current period satisfies There is acceleration and deceleration motion in the current period, so the initial velocity Initial acceleration

[0137] (2) If the end velocity v of the current period satisfies The converted initial velocity and initial acceleration do not have acceleration and deceleration motion in the current period, let Thus, we have Initial velocity Initial acceleration

[0138] 7. When

[0139] If a max +a 系 ≤j max , it means that the system acceleration and maximum speed do not exceed j max , y = -(a max +a 系 ), so Thus, we have Initial velocity Initial acceleration a0 = -a max .

[0140] (1) The end velocity v of the current period satisfies There is uniform deceleration motion in the current period, so the initial velocity Initial acceleration a0 = -a max .

[0141] (2) The end velocity v of the current period satisfies The converted initial velocity and initial acceleration only do deceleration in the current period, let Thus, we have Initial acceleration If a max +a 系 > j max , it means that the system acceleration exceeds j max , y = -(a max +a 系 -jmax), so Thus we have Initial velocity Initial acceleration a0 = -a max +j max .

[0142] (3) If the final velocity v of the current period satisfies There is acceleration-deceleration motion in the current period, so the initial velocity Initial acceleration a0 = -a max +j max .

[0143] (4) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration only do deceleration-deceleration motion in the current period. Let Thus we have Initial velocity Initial acceleration

[0144] 8、If a 系 = -a max .

[0145] Let y = 0, Thus we have Initial velocity Initial acceleration a0 = -a max .

[0146] (1) If the final velocity v of the current period satisfies There is uniform deceleration motion in the current period, so the initial velocity Initial acceleration a0 = -a max .

[0147] (2) If the final velocity v of the current period satisfies The converted initial velocity and initial acceleration do deceleration-deceleration motion in the current period, let y = 0, Thus we have Initial velocity is Initial acceleration is a0 = a 系 .

[0148] In order to better understand the scheme of the present application, taking displacement S 总 = 10000, initial velocity v0= 0, initial acceleration a0= 0, final velocity v 终 = 0, maximum velocity v max = 50, maximum acceleration a max = 2.5, maximum jerk j max = 0.02, and the actual displacement during the movement is different from the planning, please refer to Figures 2-4 , which is a system motion curve diagram obtained by directly using system parameters planning. As can be seen from the figure, if the time used for velocity planning is too long and the terminal velocity still exists, the overshoot problem will definitely occur. Please refer to Figures 5-7 , which is a system motion curve diagram obtained after using the velocity planning method provided by the present application. It can be seen that the system motion curve obtained after using the velocity planning method provided by the present application conforms to the seven-segment velocity planning model, and the motion curve is smoother, which can avoid vibration of the machine tool during processing and ensure the quality of the processed products.

[0149] The present application also provides a velocity planning device, please refer to Figure 8 , which comprises at least one processor A1, a communication bus A2, a memory A3, and at least one communication interface A4.

[0150] The processor A1 can be a general central processing unit (CPU), a network processor (NP), a microprocessor, or can be one or more integrated circuits for implementing the scheme of the present application, such as an application-specific integrated circuit (ASIC), a programmable logic device (PLD) or a combination thereof. The above-mentioned PLD can be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof.

[0151] The communication bus A2 is used for transmitting information between the above-mentioned components. The communication bus A2 can be divided into address bus, data bus, control bus, etc. For the convenience of representation, Figure 8 only one thick line is used in the above-mentioned components, but it does not mean that there is only one bus or one type of bus.

[0152] The memory A3 can be a read-only memory (ROM), a random access memory (RAM), an electrically erasable programmable read-only memory (EEPROM), an optical disk (including a compact disc read-only memory (CD-ROM), a compact disc, a laser disc, a digital versatile disc, a Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto. The memory A3 can exist independently and be connected to the processor A1 through the communication bus A2. The memory A3 can also be integrated with the processor A1.

[0153] The communication interface A4 uses any transceiver-like device for communicating with other devices or communication networks. The communication interface A4 includes a wired communication interface and can also include a wireless communication interface. The wired communication interface can be, for example, an Ethernet interface. The Ethernet interface can be an optical interface, an electrical interface, or a combination thereof. The wireless communication interface can be, for example, a wireless local area networks (WLAN) interface, a cellular network communication interface, or a combination thereof.

[0154] In implementation, the processor A1 can include one or more CPUs.

[0155] In implementation, the speed planning device can include multiple processors. Each of the processors can be a single-core processor or a multi-core processor. The processor herein can refer to one or more devices, circuits, and / or processing cores for processing data (such as computer program instructions).

[0156] In implementation, as an embodiment, the speed planning device can further include an output device A5 and an input device A6. The output device A5 communicates with the processor A1 and displays various calculation result data or information in the form of numbers, characters, images, sounds, etc. For example, the output device A5 can be a liquid crystal display (LCD), a light emitting diode (LED) display device, a cathode ray tube (CRT) display device, a projector, etc. The input device A6 communicates with the processor A1 and can receive user input in various ways. For example, the input device A6 can be a mouse, a keyboard, a touch screen device, other sensing devices, etc.

[0157] In some embodiments, the memory A3 is configured to store program code A7 for implementing the schemes of the present application, and the processor A1 can execute the program code A7 stored in the memory A3. The program code A7 can include one or more software modules, and the speed planning device can implement the S-shaped seven-segment speed planning method provided in the foregoing embodiments by means of the processor A1 and the program code A7 in the memory A3.

[0158] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments can be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of the present application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through wired (for example: coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (for example: infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that can be accessed by a computer, or a data storage device such as a server, data center, etc. integrated with one or more available media. The available media can be a magnetic medium (for example: floppy disk, hard disk, magnetic tape), an optical medium (for example: digital versatile disc (DVD)) or a semiconductor medium (for example: solid state disk (SSD)) and the like. It is worth noting that the computer-readable storage medium mentioned in the embodiments of the present application can be a non-volatile storage medium, in other words, it can be a non-transitory storage medium.

[0159] The present application also provides a computer-readable storage medium having instructions stored therein, which, when executed on a computer, cause the computer to perform the steps of the speed planning method described above.

[0160] The present application also provides a computer program product containing instructions, which, when executed on a computer, cause the computer to perform the steps of the speed planning method described above. Alternatively, a computer program is provided, which, when executed on a computer, causes the computer to perform the steps of the speed planning method described above.

[0161] It can be understood that, for those skilled in the art, equivalent replacements or changes can be made according to the technical solutions and application concepts of the present application, and all such changes or replacements shall fall within the protection scope of the claims attached to the present application.

Claims

1. A speed planning method characterized by, The method comprises the steps of: acquiring actual displacement and planned displacement of the system in the previous motion cycle, and determining whether the actual displacement and the planned displacement are equal; if yes, using the actual terminal velocity and the actual terminal acceleration in the previous motion cycle as the initial velocity and the initial acceleration in the current motion cycle; if no, determining whether the difference between the actual displacement and the planned displacement in the previous motion cycle exceeds a preset difference value; if no, using a velocity planning model of the previous motion cycle and combining a bisection method to approximate the planned terminal velocity and the planned terminal acceleration in the previous motion cycle, and using the planned terminal velocity and the planned terminal acceleration as the initial velocity and the initial acceleration in the current cycle.

2. The speed planning method of claim 1, wherein, The step of using the velocity planning model of the previous motion cycle and combining the bisection method to approximate the planned terminal velocity and the planned terminal acceleration in the previous motion cycle, and using the planned terminal velocity and the planned terminal acceleration as the initial velocity and the initial acceleration in the current cycle comprises the steps of: When the difference between the actual displacement and the planned displacement of the system in the last motion cycle is greater than 0, the velocity is taken as the starting point under the velocity curve model of the last motion cycle, t is taken as 1, and the final velocity on the velocity curve that satisfies the displacement of Δ is calculated by combining the bisection method for t, and the final acceleration that satisfies the displacement of Δ is calculated by t. acceleration a0+j as the starting point, t is taken as 1, and the final velocity on the velocity curve that satisfies the displacement of Δ is calculated by combining the bisection method for t, and the final acceleration that satisfies the displacement of Δ is calculated by t. where v0 is the starting velocity of the previous motion cycle, a0 is the starting acceleration of the previous motion cycle, j takes the values ±j max or 0, j max is the maximum jerk of the system, and t is the cycle time.

3. The speed planning method of claim 1, wherein, The step of using the velocity planning model of the previous motion cycle and combining the bisection method to approximate the planned terminal velocity and the planned terminal acceleration in the previous motion cycle, and using the planned terminal velocity and the planned terminal acceleration as the initial velocity and the initial acceleration in the current cycle comprises the steps of: When the difference between the actual displacement and the planned displacement of the system in the last motion cycle is less than 0, the end velocity on the velocity curve that satisfies the displacement of is calculated under the velocity curve model of the last motion cycle with the velocity v0 and the acceleration a0 as the starting point and t as 1, and the end acceleration that satisfies the displacement of is calculated through t in combination with the dichotomy of t; where v0 is the starting velocity of the previous motion cycle, a0 is the starting acceleration of the previous motion cycle, j takes the values ±j max or 0, j max is the maximum jerk of the system, and t is the cycle time.

4. The speed schedule method of claim 1, wherein, The method further comprises the steps of: if yes, using the initial velocity and the initial acceleration in the current motion cycle; and 5. The speed planning method of claim 4, wherein, if no, using the initial velocity and the initial acceleration in the current motion cycle. The step of using the initial velocity and the initial acceleration in the current motion cycle comprises the steps of:

6. The speed planning method of claim 5, wherein, assuming that x represents a variable to be added for converting the velocity in the current motion cycle of the system into the initial velocity, and y represents a variable to be added for converting the acceleration in the current motion cycle of the system into the initial acceleration, and in The step of using the initial velocity and the initial acceleration in the current motion cycle comprises the steps of: a 系 = -a max The value of y is set in each case, and the value of x is found, to obtain the starting speed and starting acceleration for the current cycle.

7. The speed scheduling method of claim 6, wherein, if the assumption is not satisfied according to the final velocity in the current motion cycle, redefining the value of y and calculating the value of x, so as to obtain the initial velocity and the initial acceleration in the current cycle. The device comprises a processor and a memory; the memory is used to store a computer program, the computer program comprises program instructions; and the processor is used to call the computer program to implement the velocity planning method according to any one of claims 1 to 7.

8. A speed planning device characterized by comprising: The storage medium stores a computer program, and the computer program is executed by the processor to implement the steps of the velocity planning method according to any one of claims 1 to 7.

9. A computer-readable storage medium, characterized in that, The computer program product stores computer instructions, and the computer instructions are executed by the processor to implement the steps of the velocity planning method according to any one of claims 1 to 7.

10. A computer program product, characterised in that, ​

Citation Information

Patent Citations

  • Speed control method and device of numerical control model, computer device and storage medium

    CN113495531A

  • S-shaped curve speed planning method, control terminal and computer readable storage medium

    CN114077226A