WO2017113069A1 - S-shaped curve planning method and device, and numerically-controlled machine tool - Google Patents

S-shaped curve planning method and device, and numerically-controlled machine tool Download PDF

Info

Publication number
WO2017113069A1
WO2017113069A1 PCT/CN2015/099244 CN2015099244W WO2017113069A1 WO 2017113069 A1 WO2017113069 A1 WO 2017113069A1 CN 2015099244 W CN2015099244 W CN 2015099244W WO 2017113069 A1 WO2017113069 A1 WO 2017113069A1
Authority
WO
WIPO (PCT)
Prior art keywords
speed
shaped curve
acceleration
point
curve
Prior art date
Application number
PCT/CN2015/099244
Other languages
French (fr)
Chinese (zh)
Inventor
陈晓颖
Original Assignee
深圳配天智能技术研究院有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳配天智能技术研究院有限公司 filed Critical 深圳配天智能技术研究院有限公司
Priority to CN201580079779.3A priority Critical patent/CN107850887B/en
Priority to PCT/CN2015/099244 priority patent/WO2017113069A1/en
Publication of WO2017113069A1 publication Critical patent/WO2017113069A1/en

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/18Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form
    • G05B19/416Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form characterised by control of velocity, acceleration or deceleration

Definitions

  • the invention relates to the field of numerical control processing technology, in particular to an S-shaped curve planning method, device and numerical control machine tool.
  • the parts machined by CNC machine tools are often irregular in shape, and the machining trajectory of CNC machine tools on these parts is also an irregular curve.
  • the S-curve is generally selected for speed planning. According to the S-shaped curve, the possible impact is minimized, the speed changes during the feeding process is relatively stable, and it has good flexibility, and is suitable for high-speed, high-precision motion control systems.
  • the traditional S-curve acceleration/deceleration control is used for high-precision position control on the machining curve. It does not have a forward-looking function. If it is necessary to ensure the accuracy of the small-line corner, it is necessary to use each curve as the control range to achieve symmetrical speed control. . In recent years, the traditional controller algorithm has been improved, and the speed segmentation is performed at the line segment transfer, thus introducing an asymmetric S-curve planning algorithm.
  • the S-curve velocity planning is the speed planning of the segmentation curve
  • the current forward-looking algorithm cannot accurately perform the maximum acceleration capability according to the S-curve; because, when performing the S-curve planning of a single line segment, although Symmetrical, but the initial acceleration is still zero. Therefore, the S-shaped curve thus obtained is not the most efficient planning curve.
  • the technical problem mainly solved by the present invention is to provide an S-shaped curve planning method, device and numerical control machine tool, which can ensure the maximum processing efficiency.
  • a technical solution adopted by the present invention is to provide an S-curve planning method, comprising: obtaining a corresponding limiting speed of a line segment to be processed; calculating an acceleration from a starting point of the line segment to be processed to a desired target of the user.
  • a first S-curve of speed and then running at a constant speed of the user desired target speed; determining whether the first S-curve has a position at which the speed exceeds the limit speed, and if present, adjusting the first S The curve is such that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speed on the line segment to be processed does not exceed the respective limit speed, and at least one line segment has a velocity equal to a constant speed position point that limits speed; a portion of the second sigmoid curve becomes a third sigmoid curve, wherein a starting point of the third sigmoid curve is a starting point of the second sigmoid curve, and an ending point is first appearing in the point of the constant velocity position Speed position point; S-shaped curve planning is performed again starting from the end point of the third S-shaped curve; after all the planned line segments are completely planned, the planned plurality of third-segment curves are combined to form a final S Curve planning data.
  • an S-curve planning device comprising: a first acquiring module, configured to acquire a corresponding limiting speed of a line segment to be processed; and a calculation module, a first S-shaped curve for calculating acceleration from a starting point of the line segment to be processed to a desired target speed of the user and then running at a target speed of the user desired speed; a determining module for determining the first S-shaped curve Whether there is a position point whose speed exceeds the speed limit; an adjustment module, configured to adjust the first S-shaped curve when the determination result is present, so that the second S-shaped curve obtained after the adjustment is finally decelerated to both speed and acceleration Zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; and a second acquisition module is configured to take the second S The portion of the profile curve becomes a third sigmoid
  • the beneficial effects of the present invention are: different from the prior art, the end point of the third curve is the first constant velocity position point, and when planning again, the end point is used as the starting point for planning, that is, When planning again, the acceleration and speed of the starting point are not zero.
  • the disadvantage that the acceleration of the line segment transfer must be zero in the existing algorithm can be overcome, and the acceleration can be accelerated in the case of acceleration. Deceleration is only required when decelerating, thus ensuring maximum processing efficiency.
  • FIG. 1 is a flow chart of an embodiment of a S-curve planning method of the present invention
  • FIG. 2 is a schematic diagram of a speed-displacement curve according to a speed limit of each line segment to be processed according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram showing a speed-displacement first S-shaped curve of accelerating from a starting point with a maximum acceleration capability to a user desired target speed and then running at a constant speed at that speed in an embodiment of the present invention
  • FIG. 5 is a schematic diagram of combining an acceleration-time curve and a velocity-displacement curve in an embodiment of the present invention
  • FIG. 6 is a flow chart of still another embodiment of the S-curve planning method of the present invention.
  • FIG. 8 is a schematic diagram showing an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • FIG. 9 is another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • FIG. 10 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • FIG. 11 is another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • FIG. 12 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • FIG. 13 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention.
  • Figure 14 is a schematic view of a separate curve 6 of Figure 13;
  • 15 is a schematic diagram of a portion of an image captured by an acquisition data when an actual running track is performed in an embodiment of the present invention
  • 16 is a schematic structural view of an embodiment of an S-shaped curve planning device of the present invention.
  • FIG. 17 is a schematic structural view of another embodiment of the S-curve planning device of the present invention.
  • FIG. 18 is a schematic structural view of still another embodiment of the S-curve planning device of the present invention.
  • FIG. 19 is a schematic structural view of still another embodiment of the S-curve planning device of the present invention.
  • 20 is a schematic diagram showing the physical structure of an embodiment of a numerically controlled machine tool according to the present invention.
  • FIG. 1 is a flowchart of an embodiment of a S-curve planning method according to the present invention, where the method includes:
  • Step S101 Acquire a limit speed corresponding to each line segment to be processed.
  • the speed limit is the maximum speed allowed for the line segment to be processed.
  • Most of the segments to be processed are irregularly shaped segments, which makes the maximum speed allowed for each segment to be processed generally different.
  • the value of the limit speed may be the respective curvature limit speed on the line segment to be processed (ie, the maximum speed allowed by the curvature of the line segment), or may be the target speed preset by the user (ie, the user preset target speed).
  • the size of the corresponding limit speed of the line segments to be processed is the minimum of the preset target speed and the curvature limit speed of the corresponding user on the line segment to be processed.
  • the curvature limiting speed includes a speed limit caused by curvature and bow height error and a speed limit caused by curvature, acceleration, and jerk.
  • the speed limit caused by the curvature and bow height error can be:
  • F i is the speed limit of the line segment to be processed
  • ⁇ i is the radius of curvature of the line segment to be processed
  • ⁇ i is the bow height error of the line segment to be processed
  • T is time.
  • curvature, acceleration, and speed limit caused by jerk those skilled in the art can determine the calculation formula according to the type of the curve, which will not be listed here.
  • FIG. 2 is a schematic diagram of a limited speed-displacement curve produced according to respective limiting speeds of respective line segments to be processed in an embodiment.
  • the abscissa is the displacement and the ordinate is the limiting speed.
  • the speed limit on each line segment to be processed can be clearly seen, which means that the machining speed cannot be exceeded during processing.
  • Step S102 Calculate a first S-shaped curve that is accelerated from the starting point of the line segment to be processed to the user's desired target speed and then runs at a constant speed at the target speed desired by the user.
  • Accelerating from the starting point of the line segment to be processed to the desired target speed of the line can be accelerated to the desired target speed by the user in the acceleration mode allowed on the line segment to be processed.
  • the planning Time in order to shorten the planning Time can be accelerated to the user's desired target speed with maximum acceleration capability (ie full acceleration).
  • the maximum acceleration capability refers to an acceleration mode that accelerates as much as possible by using the maximum jerk allowed by the system and the maximum acceleration allowed by the system, so as to accelerate to the desired target speed in the shortest time. For example, referring to FIG. 3, FIG.
  • FIG. 3 is a velocity-displacement first S-shaped curve which is accelerated from the starting point of the line to be processed with the maximum acceleration capability to the user's desired target speed, and then uniformly operated at the target speed desired by the user.
  • FIG. 3 also includes the limited speed-displacement curve of FIG. 2. According to FIG. 3, it can be visually seen on which line segment the first S-shaped curve exceeds its speed limit.
  • Step S103 determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and The speeds on the line segments to be processed do not exceed the respective limit speeds, and at least one line segment has a constant velocity position point whose speed is equal to the speed limit.
  • Each line segment to be processed has its own limiting speed.
  • the speed of the first S-shaped curve on each line segment to be processed cannot exceed the corresponding limiting speed.
  • the line segment corresponding to the position point ie, the overspeed line segment
  • the approximate range in which the first S-shaped curve should start deceleration is known, that is, at least before the line segment corresponding to the position point.
  • the line segment begins to decelerate and is ready to adjust the first S-curve. This step can be obtained intuitively by the schematic diagram of FIG. 3 to obtain a position point in the first S-shaped curve where the speed exceeds the limit speed, and can of course also be obtained by calculation.
  • the first S-shaped curve calculated in step S102 and the limited speed-displacement curve in step S101 are represented together in FIG. 3, and it can be clearly seen from FIG. 3 that the first S-shaped curve is in the first The line segment has already been overspeeded, so the acceleration is too large and the acceleration needs to be reduced.
  • a dichotomy can be used to find a point in time at which the second S-curve decelerates to zero speed and acceleration, and the speed on the line to be processed does not exceed the respective speed limit, and at least one line segment has a speed.
  • a constant velocity position equal to the speed limit.
  • the so-called constant velocity position point refers to a position point at which the processing speed is equal to the speed limit on the processing line segment.
  • the characteristic of the second S-shaped curve at this time is: in the case of acceleration, try to accelerate, and decelerate when it has to be decelerated, so as to ensure that the machining efficiency can no longer be improved theoretically.
  • the second S-shaped curve is finally decelerated to zero speed and acceleration, and can be decelerated to the speed and acceleration of zero in the deceleration mode allowed on the line segment to be processed.
  • Step S104 taking a portion of the second S-shaped curve to become a third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first constant-speed position point in the constant-speed position point.
  • Step S105 S-curve planning is performed again starting from the end point of the third S-shaped curve.
  • Step S106 After all the planned line segments are completely planned, the planned plurality of third S-shaped curves are combined to form the final S-shaped curve planning data.
  • the third S-shaped curve does not take the second S-shaped curve to decelerate to the entire curve with zero speed and acceleration. But take part of it, specifically: the part taking the second S-shaped curve becomes the third S-shaped curve, the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the end point is the first point in the constant velocity position The same speed position point appears.
  • the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, the first constant velocity position point in the end point constant velocity position point, the speed is not zero at this time, and the planning of the other part to be processed is from the third
  • the end point of the S-curve is the starting point for the S-curve planning again, so as to ensure that the processing efficiency is not reduced.
  • the embodiment of the present invention obtains the corresponding speed limit of the line segments to be processed; calculates a first S-shaped curve that is accelerated from the line segment to be processed to the user's desired target speed, and then runs at a uniform speed desired by the user; and determines whether the first S-shaped curve is There is a position point where the speed exceeds the speed limit, and if present, the first S-shaped curve is adjusted, so that the second S-shaped curve obtained after the adjustment is finally decelerated to zero speed and acceleration, and the speed on the line segment to be processed is not exceeded.
  • the segment has a velocity equal to the constant velocity position point of the limiting speed, and the portion of the second S-shaped curve becomes the third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the constant velocity position point.
  • the first constant velocity position appears; the S-curve planning is performed again with the end point of the third S-shaped curve as the starting point; after all the planned segments are completed, the planned multi-segment third S-shaped curves are combined to form the finalized S-curve planning data.
  • the end point of the third curve is the first constant velocity position point
  • the end point is used as the starting point for planning, that is, the acceleration and velocity of the starting point are not 0 when planning again. It can overcome the shortcomings that the acceleration of the line segment transfer must be zero in the existing algorithm, and ensure that the acceleration can be accelerated in the case of acceleration, and the deceleration is performed when the speed has to be decelerated, thereby ensuring the maximum processing efficiency.
  • step S102 may include: sub-step S1021 and sub-step S1022.
  • Sub-step S1021 determining an operation process of the first S-shaped curve, the operation process includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section.
  • the acceleration from the starting point of the line segment to be processed is accelerated to the user's desired target speed, and then the user's desired target speed is uniformly operated.
  • This operation generally includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section.
  • the running process can also be planned as: uniform acceleration section, deceleration section and uniform section, or the operation process is planned as other processes according to actual needs or application and calculation convenience.
  • Sub-step S1022 calculating acceleration a( ⁇ ), velocity f( ⁇ ), and displacement l( ⁇ ) during operation, wherein acceleration a( ⁇ ), velocity f( ⁇ ), and displacement l( ⁇ ) are:
  • t 1 ⁇ t ⁇ t 1 is the acceleration acceleration section
  • t 1 ⁇ t ⁇ t 2 is the uniform acceleration section
  • t 2 ⁇ t ⁇ t 3 is the acceleration acceleration section
  • t 3 ⁇ t ⁇ t 4 is the uniform velocity section
  • ⁇ 2 is the time accumulation of the uniform acceleration section
  • ⁇ 3 is the time accumulation of the acceleration section
  • ⁇ 4 is the time accumulation of the uniform velocity section
  • t is the time accumulation of the total operation process
  • t 1 , t 2 , t 3 , t 4 are the respective time points in t
  • J is the maximum jerk allowed by the system
  • A is the maximum acceleration allowed by the system
  • a s is the initial acceleration
  • f s is the initial velocity
  • l s is the initial displacement .
  • the velocity-displacement first S-curve is also easy to calculate with both speed and displacement known. As shown in Fig. 3, Fig. 3 is the calculated velocity-displacement first S-shaped curve.
  • the acceleration-time curve and the velocity-displacement curve are combined together in FIG. 5, the upper half is an acceleration-time curve, the ordinate represents acceleration, the abscissa is time, and the lower half is a velocity-displacement curve.
  • the ordinate represents the velocity and the abscissa represents the displacement.
  • the running process of starting planning includes: acceleration section (time period is 0-t 1 ), uniform acceleration section (time period is t 1 -t 2 ), deceleration section (time period) It is t 2 -t 3 ) and four processes of uniform velocity (time period is t 3 -t 4 ), and the calculation formula of the acceleration of these four processes can be obtained. According to the relationship between acceleration and speed, the calculation formula of the speed of these four processes can be obtained. According to the relationship between velocity and displacement, the calculation formula of the displacement of these four processes can be obtained. On the velocity-displacement curve of Fig.
  • the velocity-displacement curve corresponding to t 3 ) and the uniform velocity section (time period is t 3 -t 4 ) has a curve composed of curve segments 1, 2, and 3 as follows.
  • the operation process of the first S-shaped curve includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform velocity section. According to common physical knowledge, calculation formulas of acceleration, velocity, and displacement can be respectively obtained. This way, the process can be simplified and the time required for planning can be shortened.
  • step S103 the step of determining whether the first S-curve has a position where the speed exceeds the limit speed may include: sub-step S201, sub-step S202, and sub-step S203.
  • Sub-step S201 by f ( ⁇ ), the speed limit of the line segment L i F i determined time limit is reached required speed F i t i, l and thus determining the displacement reaches the limit when the speed and acceleration F i a.
  • the speed limit of the line segment is known, and the time t i at which the speed limit is reached can be determined by the speed formula f( ⁇ ), and then the displacement l and the acceleration a when the speed limit F i is reached can be further determined.
  • Sub-step S202 If a>0, and l ⁇ l i+1 , it is determined that the first S-curve line segment L i has a speed point exceeding the limit speed F i , and l i+1 is the end point of the line segment L i The distance to the starting point of the line segment to be processed.
  • Sub-step S203 If a ⁇ 0, and l>l i , it is determined that the first S-curve line segment L i has a position where the speed exceeds the limit speed F i , and l i is the starting point of the line segment L i to the line segment to be processed The starting point of the distance.
  • step S103 the first S-shaped curve is adjusted, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speeds on the line segments to be processed are not exceeded.
  • the step of limiting the speed and having at least one line segment having a constant speed position point equal to the speed limit may include: sub-step S301, sub-step S302, sub-step S303, sub-step S304, sub-step S305, sub-step S306, sub-step S307 and sub-step S308.
  • Sub-step S301 determining a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second time point t E is a first S-shaped The starting time point of the acceleration section in the curve.
  • the first S-curve can be adjusted by using the dichotomy, and the adjusted time interval is first determined: the first time point t S and the second time point t E , and the first time point t S is the first S The starting point of the curve is t 0 , and the second time is the starting time of the first S-curve minus the acceleration segment.
  • Sub-step S302 determining a third time point t M , wherein the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
  • Sub-step S303 adjusting the first S-shaped curve such that the starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerating as fast as possible to the acceleration and the speed drop to 0 after the adjustment, after the adjustment
  • the curve obtained is the fourth sigmoid curve.
  • deceleration as fast as possible refers to decelerating as much as possible by using the maximum deceleration (which may be equal to the maximum jerk) and the maximum deceleration (which may be equal to the maximum acceleration) allowed by the system. Deceleration to acceleration and speed drop to zero in the shortest time. In this way, the time required can be reduced, and the processing efficiency of the planned S-shaped curve can be improved.
  • Sub-step S304 determining whether the fourth sigmoid curve has a position point where the speed exceeds the speed limit, and if so, performing sub-step S306, otherwise performing sub-step S305.
  • Sub-step S305 determining whether the fourth sigmoid curve has at least one line segment having a constant speed position point whose speed is equal to the speed limit, and if so, performing sub-step S308, otherwise performing sub-step S307.
  • Sub-step S306 making the value of the second time point t E equal to the third time point t M and returning to sub-step S302.
  • the fourth S-curve has a position where the speed exceeds the limit speed, indicating that the start time of the deceleration section decelerates at t m point a little late, and needs to be decelerated earlier, and the fourth S-curve deceleration start time of the acceleration section Point before t M , that is, between t S and t M.
  • the intermediate time point should be In connection with the problem of calculating the cycle, the value of the second time point t E is here recorded as equal to the third time point t M , so returning to sub-step S302, the overall formula is kept consistent.
  • Sub-step S307 making the value of the first time point t S equal to the third time point t M and returning to sub-step S302.
  • the fourth sigmoid curve does not have at least one line segment having the same speed position point whose speed is equal to the speed limit, that is, the speed is less than the corresponding speed limit, no speeding is exceeded, indicating that the starting time point of the speed reduction section is decelerated at t M point.
  • the starting point of the fourth S-curve reduction acceleration section is after t M , that is, between t M and t E.
  • the intermediate time point should be In connection with the problem of the calculation cycle, the value of the first time point t S is recorded here to be equal to the third time point t M , so the sub-step S302 is returned to keep the overall formula consistent.
  • Sub-step S308 determining that the fourth sigmoid curve is the second sigmoid curve.
  • the time point t g is found, and the full force deceleration from the time point t g until the acceleration and velocity are zero (at the time point t 5 ', the acceleration and the speed are both zero), from the time
  • the acceleration-time curve after point t g is shown by the dashed line in the figure; corresponding to the speed-displacement curve, the adjusted S curve is the curve composed of curve segments 1, 4.
  • FIG. 8 to FIG. 14 show an adjustment process of the S-shaped curve in an embodiment (only the velocity-displacement curve is drawn in the figure), and FIG. 14 is an adjusted S-shaped curve (ie, a diagram).
  • Curve 6) in 11 for the convenience of explanation and explanation, it is considered that curve 1 represents the first adjusted S-shaped curve (curve 1 is actually an S-shaped curve that does not overspeed on the a-line segment after multiple adjustments)
  • Curve 2 represents the second adjusted S-curve
  • curve 3 represents the third adjusted S-curve
  • curve 4 represents the fourth adjusted S-curve
  • curve 5 represents the fifth adjusted S-curve.
  • the curve, curve 6 represents the sixth adjusted S-curve; a, b, c, d, e, f, g respectively represent the line segment.
  • curve 1 is the first adjusted S-shaped curve. It can be seen that when the velocity and acceleration both decrease to 0, the line segment a just does not overspeed, and the line segments b and c do not overspeed. The line segments d, e, and f are overspeeded, indicating that the starting time point of the adjusted deceleration section should be before the start time of the curve 1 deceleration section.
  • the line segments a, b, c, d, and e do not overspeed, indicating that the starting time of the curve 3 minus the acceleration segment is too early, and the acceleration needs to be delayed.
  • the starting time point of the segment that is, the starting time point of the adjusted deceleration segment should be between the start time point of the curve 3 minus the acceleration segment and the start time point of the curve 2 deceleration segment.
  • Figure 14 is a schematic view of a separate curve 6 of Figure 13, taking the portion of the second S-shaped curve 6 into a third S-shaped curve, the starting point of the third S-shaped curve being point A, and the ending point being point B (in the constant velocity position point)
  • the first constant velocity position point, in this embodiment, the end point is the starting point of the line segment e).
  • the S-curve plan can be performed again on the remaining line segments starting from point B.
  • Figure 15 is a portion of an image captured by the acquisition data when the trajectory is actually traversed in an embodiment of the present invention.
  • the given parameters are: maximum acceleration of the system: 5m/s 2 , maximum jerk: 5000m/s 3 .
  • the first picture is a velocity-displacement image
  • the horizontal axis is the distance
  • the vertical axis is the speed
  • the solid line is the speed limit corresponding to each line segment
  • the broken line is the actual running speed
  • the second picture For the acceleration image, the horizontal axis is the distance and the vertical axis is the acceleration, wherein the broken line is the composite value of each axis acceleration, the solid line is the acceleration of the tangential direction of the running track
  • the third picture is the jerk value
  • the horizontal axis is the distance
  • the vertical axis is The jerk, wherein the broken line is the composite value of the acceleration of each axis, and the solid line is the jerk value generated by the acceleration change of the tangential direction of the track.
  • the processing efficiency of the method of the present invention is increased by 10 to 14% over the processing efficiency of the prior art.
  • FIG. 16 is a schematic structural diagram of an embodiment of an S-shaped curve planning device according to the present invention.
  • the device in the embodiment of the present invention may perform the foregoing method.
  • the device includes: a first obtaining module 101, a calculating module 102, a determining module 103, an adjusting module 104, a second obtaining module 105, and a combining module 106.
  • the first obtaining module 101 is configured to acquire a speed limit corresponding to each line segment to be processed.
  • the calculation module 102 is configured to calculate a first S-shaped curve that accelerates from the starting point of the line segment to be processed to the user's desired target speed and then runs at a constant speed at the target speed desired by the user.
  • the determining module 103 is configured to determine whether the first S-shaped curve has a position point whose speed exceeds the limiting speed.
  • the adjusting module 104 is configured to adjust the first S-shaped curve when the determination result is present, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speed on the line segment to be processed is not exceeded.
  • the respective speed limits, and at least one line segment has a constant speed position point whose speed is equal to the speed limit.
  • the second obtaining module 105 is configured to take the portion of the second S-shaped curve to become a third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first occurrence in the constant-speed position, etc. Speed position point.
  • the S-curve plan is again performed starting from the end point of the third S-shaped curve and returned to the calculation module 102.
  • the combination module 106 is configured to combine the plurality of third sigmoid curves obtained by the planning to form the finally obtained S-curve planning data after all the planned segments are planned.
  • the size of the corresponding limit speed of the line segments to be processed is the minimum of the preset target speed and the curvature limit speed of the corresponding user on the line segment to be processed.
  • the curvature limiting speed includes a speed limit caused by curvature and bow height error and a speed limit caused by curvature, acceleration, and jerk.
  • the calculation module 102 is specifically configured to calculate a first S-shaped curve that is accelerated from the starting point of the line segment to be processed to the user's desired target speed with the maximum acceleration capability, and then runs at the target speed that is desired by the user.
  • the calculation module 102 includes: a first determining unit 1021 and a first calculating unit 1022.
  • the first determining unit 1021 is configured to determine an operation process of the first S-shaped curve, and the running process includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section.
  • the first calculating unit 1022 is configured to calculate the acceleration a( ⁇ ), the velocity f( ⁇ ), and the displacement l( ⁇ ) during the operation, the acceleration a( ⁇ ), the velocity f( ⁇ ), and the displacement l( ⁇ ) are respectively:
  • t 1 ⁇ t ⁇ t 1 is the acceleration acceleration section
  • t 1 ⁇ t ⁇ t 2 is the uniform acceleration section
  • t 2 ⁇ t ⁇ t 3 is the acceleration acceleration section
  • t 3 ⁇ t ⁇ t 4 is the uniform velocity section
  • ⁇ 2 is the time accumulation of the uniform acceleration section
  • ⁇ 3 is the time accumulation of the acceleration section
  • ⁇ 4 is the time accumulation of the uniform velocity section
  • t is the time accumulation of the total operation process
  • t 1 , t 2 , t 3 , t 4 are the respective time points in t
  • J is the maximum jerk allowed by the system
  • A is the maximum acceleration allowed by the system
  • a s is the initial acceleration
  • f s is the initial velocity
  • l s is the initial displacement .
  • the determining module 103 includes: a second determining unit 1031 and a first result unit 1032.
  • the first result unit 1032 is configured to determine, when a>0, and l ⁇ l i+1 , that the first S-curve line segment L i has a speed exceeding a limit speed F i , and l i+1 is a line segment L The distance from the end point of i to the starting point of the line segment to be processed; or, if a ⁇ 0, and l>l i , it is determined that the first S-curve line segment L i has a speed exceeding the limit speed F i , l i It is the distance from the starting point of the line segment L i to the starting point of the line segment to be processed.
  • the adjustment module 104 includes: a third determining unit 1041, a fourth determining unit 1042, an adjusting unit 1043, a first determining unit 1044, a second determining unit 1045, a first executing unit 1046, and a second executing unit 1047. And a fifth determining unit 1048.
  • the third determining unit 1041 is configured to determine a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second time point t E is the first time point The starting time point of the acceleration section is reduced in an S-shaped curve.
  • the fourth determining unit 1042 is configured to determine a third time point t M , where the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
  • the adjusting unit 1043 is configured to adjust the first S-shaped curve such that the starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerate as quickly as possible to the acceleration and the speed drop to 0, and adjust The resulting curve is the fourth sigmoid curve.
  • the first determining unit 1044 is configured to determine whether the fourth S-shaped curve has a position where the speed exceeds the limiting speed, and if so, enters the first executing unit 1046, and otherwise enters the second determining unit 1045.
  • the second determining unit 1045 is configured to determine whether the fourth S-shaped curve has at least one line segment having a constant speed position point whose speed is equal to the limiting speed, and if so, enters the fifth determining unit 1048, and otherwise enters the second executing unit 1047.
  • the first execution unit 1046 is configured to make the value of the second time point t E equal to the third time point t M and return to the fourth determining unit.
  • the second execution unit 1047 is for causing the value of the first time point t S to be equal to the third time point t M and returning to the fourth determining unit.
  • the fifth determining unit 1048 is configured to determine that the fourth S-shaped curve is a second S-shaped curve.
  • the present invention further provides a numerical control machine tool including a machine tool body and a numerical control device mounted on the machine body.
  • the numerical control device can perform the steps in the above method.
  • details of the related content please refer to the method part. I will not repeat it here.
  • the numerical control device includes a processor 11 and a memory 12 connected to the bus 13.
  • the memory 12 stores a program
  • the processor 11 is configured to execute a program.
  • the program includes the following steps: acquiring a speed limit corresponding to each line segment to be processed; calculating a speed from a starting point of the line segment to be processed to a desired target speed of the user, and then using the user
  • the first S-shaped curve of the target speed is expected to run at a constant speed; determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated
  • the speed and acceleration are both zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; the portion of the second S-shaped curve becomes the first The three S-shaped curve, wherein the starting point of the third S-
  • An embodiment of the present invention further provides a computer storage medium, where the computer storage medium stores a program.
  • the program is executed by a computer processor to run an S-curve planning method, the method comprising: obtaining a respective limiting speed of the line segments to be processed; calculating a speed from a starting point of the line segment to be processed to a desired target speed of the user, and then using the user
  • the first S-shaped curve of the target speed is expected to run at a constant speed; determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated
  • the speed and acceleration are both zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; the portion of the second S-shaped curve becomes the first The three S-shaped curve, wherein the starting point of the third S-

Landscapes

  • Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Manufacturing & Machinery (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Numerical Control (AREA)

Abstract

Disclosed are an S-shaped curve planning method and device, and a numerically-controlled machine tool. The method comprises: obtaining a speed limit of each segment to be machined; calculating a first S-shaped curve where the speed rises from a start point to a target speed and then is kept constant; if a position point where the speed exceeds the speed limit exists in the first S-shaped curve, adjusting the first S-shaped curve, such that both the speed and the acceleration of a second S-shaped curve obtained after the adjustment is decreased to zero, the speeds are within the speed limit, and at least one segment has a constant speed position point; taking a part of the second S-shaped curve as a third S-shaped curve, wherein the start point of the third S-shaped curve is the start point of the second S-shaped curve, and the end point of the third S-shaped curve is the first constant speed position point; planning again by using the end point of the third S-shaped curve as the start point; after planning, combining multiple third S-shaped curves to form final S-shaped curve planning data. By means of said approach, the present invention can ensure the maximum machining efficiency.

Description

S型曲线规划方法、装置及数控机床S-curve planning method, device and numerical control machine tool 【技术领域】[Technical Field]
本发明涉及数控加工技术领域,特别是涉及一种S型曲线规划方法、装置及数控机床。The invention relates to the field of numerical control processing technology, in particular to an S-shaped curve planning method, device and numerical control machine tool.
【背景技术】【Background technique】
数控机床加工的零件,其形状往往是不规则的,数控机床在这些零件上的加工轨迹也是不规则的曲线。在加工时,为了使这些形状不规则的曲线轮廓轨迹上的加工速度较平滑,一般选择S型曲线进行速度规划。按照S型曲线进行加工,将可能的冲击减小到最小,进给过程中速度变化较为平稳,具有良好的柔性,适用于高速、高精度运动控制系统。The parts machined by CNC machine tools are often irregular in shape, and the machining trajectory of CNC machine tools on these parts is also an irregular curve. In the processing, in order to make the processing speed on the irregular contour contour track smooth, the S-curve is generally selected for speed planning. According to the S-shaped curve, the possible impact is minimized, the speed changes during the feeding process is relatively stable, and it has good flexibility, and is suitable for high-speed, high-precision motion control systems.
传统的S型曲线上加减速的控制用于加工曲线上高精度位置的控制,不具有前瞻功能,若需要保证小线段转角处的精度,必须以每一段曲线作为控制范围,实现对称的速度控制。近年的研究中,对传统的控制器算法进行了改善,在线段转接处进行速度前瞻,从而引入了非对称的S型曲线规划算法。The traditional S-curve acceleration/deceleration control is used for high-precision position control on the machining curve. It does not have a forward-looking function. If it is necessary to ensure the accuracy of the small-line corner, it is necessary to use each curve as the control range to achieve symmetrical speed control. . In recent years, the traditional controller algorithm has been improved, and the speed segmentation is performed at the line segment transfer, thus introducing an asymmetric S-curve planning algorithm.
但是,由于S型曲线速度规划是对分段曲线进行速度规划,现在的前瞻算法并不能精确地按照S型曲线发挥最大的加速能力;因为,在进行单个线段的S型曲线规划时,虽然是非对称的,但是起末加速度仍然是零。因此,这样得到的S型曲线并不是加工效率最高的规划曲线。However, since the S-curve velocity planning is the speed planning of the segmentation curve, the current forward-looking algorithm cannot accurately perform the maximum acceleration capability according to the S-curve; because, when performing the S-curve planning of a single line segment, although Symmetrical, but the initial acceleration is still zero. Therefore, the S-shaped curve thus obtained is not the most efficient planning curve.
【发明内容】[Summary of the Invention]
本发明主要解决的技术问题是提供一种S型曲线规划方法、装置及数控机床,能够保证最大的加工效率。The technical problem mainly solved by the present invention is to provide an S-shaped curve planning method, device and numerical control machine tool, which can ensure the maximum processing efficiency.
为解决上述技术问题,本发明采用的一个技术方案是:提供一种S型曲线规划方法,包括:获取待加工线段各自对应的限制速度;计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;确定所述第一S型曲线是否存在速度超出所述限制速度的位置点,如果存在,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于其限制速度的等速位置点;取 所述第二S型曲线的部分成为第三S型曲线,其中所述第三S型曲线的起点为所述第二S型曲线的起点,终点为所述等速位置点中首先出现的等速位置点;以所述第三S型曲线的终点为起点再次进行S型曲线规划;在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。In order to solve the above technical problem, a technical solution adopted by the present invention is to provide an S-curve planning method, comprising: obtaining a corresponding limiting speed of a line segment to be processed; calculating an acceleration from a starting point of the line segment to be processed to a desired target of the user. a first S-curve of speed, and then running at a constant speed of the user desired target speed; determining whether the first S-curve has a position at which the speed exceeds the limit speed, and if present, adjusting the first S The curve is such that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speed on the line segment to be processed does not exceed the respective limit speed, and at least one line segment has a velocity equal to a constant speed position point that limits speed; a portion of the second sigmoid curve becomes a third sigmoid curve, wherein a starting point of the third sigmoid curve is a starting point of the second sigmoid curve, and an ending point is first appearing in the point of the constant velocity position Speed position point; S-shaped curve planning is performed again starting from the end point of the third S-shaped curve; after all the planned line segments are completely planned, the planned plurality of third-segment curves are combined to form a final S Curve planning data.
为解决上述技术问题,本发明采用的另一个技术方案是:提供一种S型曲线规划装置,所述装置包括:第一获取模块,用于获取待加工线段各自对应的限制速度;计算模块,用于计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;判断模块,用于判断所述第一S型曲线是否存在速度超出所述限制速度的位置点;调整模块,用于在判断结果为存在时,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;第二获取模块,用于取所述第二S型曲线的部分成为第三S型曲线,其中,所述第三S型曲线的起点为所述第二S型曲线的起点,终点所述等速位置点中首先出现的等速位置点;以所述第三S型曲线的终点为起点再次进行S型曲线规划;组合模块,用于在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。In order to solve the above technical problem, another technical solution adopted by the present invention is to provide an S-curve planning device, the device comprising: a first acquiring module, configured to acquire a corresponding limiting speed of a line segment to be processed; and a calculation module, a first S-shaped curve for calculating acceleration from a starting point of the line segment to be processed to a desired target speed of the user and then running at a target speed of the user desired speed; a determining module for determining the first S-shaped curve Whether there is a position point whose speed exceeds the speed limit; an adjustment module, configured to adjust the first S-shaped curve when the determination result is present, so that the second S-shaped curve obtained after the adjustment is finally decelerated to both speed and acceleration Zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; and a second acquisition module is configured to take the second S The portion of the profile curve becomes a third sigmoid curve, wherein the starting point of the third sigmoid curve is the starting point of the second sigmoid curve, and the end point is the constant velocity position The first constant velocity position point occurs; the S-curve planning is performed again with the end point of the third S-shaped curve as a starting point; the combination module is used for planning the obtained multi-segment after the entire planned to-be-processed line segment is completed. The combination of the three sigmoidal curves forms the resulting sigmoidal curve planning data.
为解决上述技术问题,本发明采用的又一个技术方案是:提供一种数控机床,包括机床本体和安装在所述机床本体上的数控设备,所述数控设备包括:连接在总线的处理器和存储器;所述存储器存储有程序,所述处理器用于执行所述程序,所述程序执行时包括如下步骤:获取待加工线段各自对应的限制速度;计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;判断所述第一S型曲线是否存在速度超出所述限制速度的位置点,如果存在,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;取所述第二S型曲线的部分成为第三S型曲线,其中所述第三S型曲线的起点为所述第二S型曲线的起点,终点为所述等速位置点中首先出现的等速位置点;以所述第三S型曲线的终点为起点再次进行S型曲线规划;在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合 形成最终得到的S型曲线规划数据。In order to solve the above technical problem, another technical solution adopted by the present invention is to provide a numerical control machine tool, including a machine tool body and a numerical control device mounted on the machine tool body, the numerical control device comprising: a processor connected to the bus and a memory; the memory stores a program, the processor is configured to execute the program, and the program includes the following steps: acquiring a speed limit corresponding to each line segment to be processed; calculating from the starting point of the line segment to be processed to the user Determining a target speed, and then a first S-curve running at a constant speed of the user desired target speed; determining whether the first S-curve has a position at which the speed exceeds the limit speed, and if so, adjusting the An S-shaped curve, so that the adjusted second S-shaped curve is finally decelerated to a speed and an acceleration of zero, and the speed on the line segment to be processed does not exceed the respective limit speed, and at least one line segment exists at a speed a constant velocity position point equal to the speed limit; the portion taking the second S-shaped curve becomes a third S-shaped curve, wherein The starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first constant velocity position point in the constant velocity position point; and the S end is taken as the starting point of the third S-shaped curve. Curve planning; after the entire planned line segment is completed, the planned multi-segment third S-shaped curve combination The resulting S-curve planning data is formed.
本发明的有益效果是:区别于现有技术的情况,本发明由于第三曲线的终点为首先出现的等速位置点,再次规划时,以该终点为起点进行规划的,也即是说,再次规划时起点的加速度和速度并不为0,通过这种方式,能够克服现有算法中在线段转接处加速度必须变为零的缺点,并且保证在能加速的情况下,尽力加速,在不得不减速时才进行减速,从而保证最大的加工效率。The beneficial effects of the present invention are: different from the prior art, the end point of the third curve is the first constant velocity position point, and when planning again, the end point is used as the starting point for planning, that is, When planning again, the acceleration and speed of the starting point are not zero. In this way, the disadvantage that the acceleration of the line segment transfer must be zero in the existing algorithm can be overcome, and the acceleration can be accelerated in the case of acceleration. Deceleration is only required when decelerating, thus ensuring maximum processing efficiency.
【附图说明】[Description of the Drawings]
图1是本发明S型曲线规划方法一实施方式的流程图;1 is a flow chart of an embodiment of a S-curve planning method of the present invention;
图2是本发明一实施例中根据各个待加工线段的限制速度制作的限制速度-位移曲线示意图;2 is a schematic diagram of a speed-displacement curve according to a speed limit of each line segment to be processed according to an embodiment of the present invention;
图3是本发明一实施例中从起点用最大加速能力加速到用户期望目标速度、并在之后以该速度匀速运行的速度-位移第一S型曲线示意图;3 is a schematic diagram showing a speed-displacement first S-shaped curve of accelerating from a starting point with a maximum acceleration capability to a user desired target speed and then running at a constant speed at that speed in an embodiment of the present invention;
图4是本发明S型曲线规划方法另一实施方式的流程图;4 is a flow chart of another embodiment of the S-curve planning method of the present invention;
图5是本发明一实施例中将加速度-时间曲线与速度-位移曲线合并制作在一起的示意图;5 is a schematic diagram of combining an acceleration-time curve and a velocity-displacement curve in an embodiment of the present invention;
图6是本发明S型曲线规划方法又一实施方式的流程图;6 is a flow chart of still another embodiment of the S-curve planning method of the present invention;
图7是本发明S型曲线规划方法又一实施方式的流程图;7 is a flow chart of still another embodiment of the S-curve planning method of the present invention;
图8是本发明一实施例中S型曲线的调整过程一示意图;FIG. 8 is a schematic diagram showing an adjustment process of an S-shaped curve according to an embodiment of the present invention; FIG.
图9是本发明一实施例中S型曲线的调整过程另一示意图;9 is another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention;
图10是本发明一实施例中S型曲线的调整过程又一示意图;FIG. 10 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention; FIG.
图11是本发明一实施例中S型曲线的调整过程又一示意图;11 is another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention;
图12是本发明一实施例中S型曲线的调整过程又一示意图;FIG. 12 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention; FIG.
图13是本发明一实施例中S型曲线的调整过程又一示意图;FIG. 13 is still another schematic diagram of an adjustment process of an S-shaped curve according to an embodiment of the present invention; FIG.
图14是图13中单独的曲线6的示意图;Figure 14 is a schematic view of a separate curve 6 of Figure 13;
图15是本发明一实施例中实际运行轨迹时采集数据截取的一部分图像示意图;15 is a schematic diagram of a portion of an image captured by an acquisition data when an actual running track is performed in an embodiment of the present invention;
图16是本发明S型曲线规划装置一实施方式的结构示意图;16 is a schematic structural view of an embodiment of an S-shaped curve planning device of the present invention;
图17是本发明S型曲线规划装置另一实施方式的结构示意图;17 is a schematic structural view of another embodiment of the S-curve planning device of the present invention;
图18是本发明S型曲线规划装置又一实施方式的结构示意图;18 is a schematic structural view of still another embodiment of the S-curve planning device of the present invention;
图19是本发明S型曲线规划装置又一实施方式的结构示意图; 19 is a schematic structural view of still another embodiment of the S-curve planning device of the present invention;
图20是本发明数控机床一实施方式的实体结构示意图。20 is a schematic diagram showing the physical structure of an embodiment of a numerically controlled machine tool according to the present invention.
【具体实施方式】【detailed description】
下面结合附图和实施方式对本发明进行详细说明。The invention will now be described in detail in conjunction with the drawings and embodiments.
参阅图1,图1是本发明S型曲线规划方法一实施方式的流程图,该方法包括:Referring to FIG. 1, FIG. 1 is a flowchart of an embodiment of a S-curve planning method according to the present invention, where the method includes:
步骤S101:获取待加工各线段各自对应的限制速度。Step S101: Acquire a limit speed corresponding to each line segment to be processed.
本实施例中,限制速度是指该待加工线段所允许的最大的速度。待加工线段多数是形状不规则的线段,这使得每个待加工线段上各自所允许的最大的速度一般是不一样的。限制速度的取值可能是待加工线段上各自的曲率限制速度(即线段的曲率所允许的最大的速度),也可能是用户预先设置的目标速度(即用户预设目标速度)。In this embodiment, the speed limit is the maximum speed allowed for the line segment to be processed. Most of the segments to be processed are irregularly shaped segments, which makes the maximum speed allowed for each segment to be processed generally different. The value of the limit speed may be the respective curvature limit speed on the line segment to be processed (ie, the maximum speed allowed by the curvature of the line segment), or may be the target speed preset by the user (ie, the user preset target speed).
其中,待加工线段各自对应的限制速度的大小为待加工线段上各自对应的用户预设目标速度和曲率限制速度中的最小值。其中,曲率限制速度包括由曲率和弓高误差导致的限制速度和由曲率、加速度以及加加速度导致的限制速度。举例来说,由曲率和弓高误差导致的限制速度可以为:The size of the corresponding limit speed of the line segments to be processed is the minimum of the preset target speed and the curvature limit speed of the corresponding user on the line segment to be processed. Among them, the curvature limiting speed includes a speed limit caused by curvature and bow height error and a speed limit caused by curvature, acceleration, and jerk. For example, the speed limit caused by the curvature and bow height error can be:
Figure PCTCN2015099244-appb-000001
Figure PCTCN2015099244-appb-000001
其中,Fi为待加工线段的限制速度,ρi为待加工线段的曲率半径,δi为待加工线段的弓高误差,T为时间。而由曲率、加速度以及加加速度导致的限制速度,本领域技术人员可以根据曲线类型确定计算公式,在这里就不一一列出。Where F i is the speed limit of the line segment to be processed, ρ i is the radius of curvature of the line segment to be processed, δ i is the bow height error of the line segment to be processed, and T is time. However, by the curvature, acceleration, and speed limit caused by jerk, those skilled in the art can determine the calculation formula according to the type of the curve, which will not be listed here.
获取待加工线段各自对应的限制速度后,为了直观可见,可以制作限制速度-位移曲线。例如,参见图2,图2为一实施例中,根据各个待加工线段各自对应的限制速度,制作的限制速度-位移曲线示意图。图2中,横坐标为位移,纵坐标为限制速度,根据该限制速度-位移曲线图可以明确看到各个待加工线段上的限制速度,这也就是说,在加工的时候,加工速度不能超出该待加工线段上的限制速度。After obtaining the corresponding speed limit of the line segments to be processed, a speed-displacement curve can be made for visually visible. For example, referring to FIG. 2, FIG. 2 is a schematic diagram of a limited speed-displacement curve produced according to respective limiting speeds of respective line segments to be processed in an embodiment. In Fig. 2, the abscissa is the displacement and the ordinate is the limiting speed. According to the speed-displacement graph, the speed limit on each line segment to be processed can be clearly seen, which means that the machining speed cannot be exceeded during processing. The speed limit on the line segment to be processed.
步骤S102:计算从待加工线段的起点加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线。Step S102: Calculate a first S-shaped curve that is accelerated from the starting point of the line segment to be processed to the user's desired target speed and then runs at a constant speed at the target speed desired by the user.
从待加工线段的起点加速到用户期望目标速度,可以以待加工线段上所允许的加速方式加速到用户期望目标速度。在一实施例中,为了缩短规划所需要 时间,可以以最大的加速能力(即全力加速)加速到用户期望目标速度。此处,最大的加速能力,是指尽可能地利用系统所允许的最大加加速度、系统所允许的最大加速度进行加速的加速方式,以在最短时间内加速到用户期望目标速度。例如,参见图3,图3为一实施例中,从待加工线段的起点用最大加速能力加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的速度-位移第一S型曲线,图3还包括图2的限制速度-位移曲线,根据图3,可以很直观地看出第一S型曲线在哪个线段上超出其限制速度。Accelerating from the starting point of the line segment to be processed to the desired target speed of the line can be accelerated to the desired target speed by the user in the acceleration mode allowed on the line segment to be processed. In an embodiment, in order to shorten the planning Time can be accelerated to the user's desired target speed with maximum acceleration capability (ie full acceleration). Here, the maximum acceleration capability refers to an acceleration mode that accelerates as much as possible by using the maximum jerk allowed by the system and the maximum acceleration allowed by the system, so as to accelerate to the desired target speed in the shortest time. For example, referring to FIG. 3, FIG. 3 is a velocity-displacement first S-shaped curve which is accelerated from the starting point of the line to be processed with the maximum acceleration capability to the user's desired target speed, and then uniformly operated at the target speed desired by the user. FIG. 3 also includes the limited speed-displacement curve of FIG. 2. According to FIG. 3, it can be visually seen on which line segment the first S-shaped curve exceeds its speed limit.
步骤S103:判断第一S型曲线是否存在速度超出限制速度的位置点,如果存在,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点。Step S103: determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and The speeds on the line segments to be processed do not exceed the respective limit speeds, and at least one line segment has a constant velocity position point whose speed is equal to the speed limit.
每个待加工线段对应有各自的限制速度,第一S型曲线在每个待加工线段上的速度不能超出各自对应的限制速度,首先判断第一S型曲线是否存在速度超出限制速度的位置点,根据该位置点,即可确定该位置点对应的线段(即超速线段),进一步即可知道第一S型曲线应该开始减速的大致范围,也就是在至少在该位置点对应的线段之前的线段要开始减速了,为调整第一S型曲线做好准备。该步骤可以通过图3的示意图很直观地获得第一S型曲线中存在速度超出限制速度的位置点,当然也可以通过计算的方式获得。Each line segment to be processed has its own limiting speed. The speed of the first S-shaped curve on each line segment to be processed cannot exceed the corresponding limiting speed. First, it is determined whether the first S-shaped curve has a position where the speed exceeds the limiting speed. According to the position point, the line segment corresponding to the position point (ie, the overspeed line segment) can be determined, and further, the approximate range in which the first S-shaped curve should start deceleration is known, that is, at least before the line segment corresponding to the position point. The line segment begins to decelerate and is ready to adjust the first S-curve. This step can be obtained intuitively by the schematic diagram of FIG. 3 to obtain a position point in the first S-shaped curve where the speed exceeds the limit speed, and can of course also be obtained by calculation.
参见图3,图3中将步骤S102中计算的第一S型曲线和步骤S101中的限制速度-位移曲线表示在一起,从图3中可以非常清楚地看到第一S型曲线在第一条线段上即已经超速,因此说明加速度过大,需要降低加速度。Referring to FIG. 3, the first S-shaped curve calculated in step S102 and the limited speed-displacement curve in step S101 are represented together in FIG. 3, and it can be clearly seen from FIG. 3 that the first S-shaped curve is in the first The line segment has already been overspeeded, so the acceleration is too large and the acceleration needs to be reduced.
调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点。为达到该调整的目的,可以采用很多的方法,例如:二分法、插值法、曲线拟合法等等。其中,以二分法为例说明具体解题步骤是:Adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated to zero speed and acceleration, and the speed on the line segment to be processed does not exceed the respective limit speed, and at least one line segment exists at a speed A constant velocity position equal to the speed limit. To achieve this adjustment, many methods can be used, such as dichotomy, interpolation, curve fitting, and the like. Among them, taking the dichotomy as an example to illustrate the specific problem solving steps are:
(1)计算函数f(x)在区间[a,b]上中点的函数值f((a+b)/2),并做下面的判断:如果f(a)f((a+b)/2)<0,转到(2);如果f(a)f((a+b)/2)>0,令a=(a+b)/2,转到(1);如果f(a)f((a+b)/2)=0,则x=(a+b)/2为一个根。(1) Calculate the function value f((a+b)/2) of the midpoint of the function f(x) at the interval [a, b], and make the following judgment: if f(a)f((a+b) )/2)<0, go to (2); if f(a)f((a+b)/2)>0, let a=(a+b)/2, go to (1); if f (a) f((a+b)/2)=0, then x=(a+b)/2 is a root.
(2)如果|a-(a+b)/2|<ε(ε为预先给定的精度),则x=(b+3a)/4为一个根,否则令b=(a+b)/2,转到(1)。 (2) If |a-(a+b)/2|<ε(ε is a predetermined precision), then x=(b+3a)/4 is a root, otherwise let b=(a+b) /2, go to (1).
通过二分法可以找到一个时间点,在该时间点第二S型曲线减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点。所谓等速位置点是指加工的速度等于该加工线段上的限制速度的位置点。此时的第二S型曲线的特点是:在能加速的情况下,尽力加速,在不得不减速时才进行减速,这样可以保证在理论上加工效率已经不可再提高。A dichotomy can be used to find a point in time at which the second S-curve decelerates to zero speed and acceleration, and the speed on the line to be processed does not exceed the respective speed limit, and at least one line segment has a speed. A constant velocity position equal to the speed limit. The so-called constant velocity position point refers to a position point at which the processing speed is equal to the speed limit on the processing line segment. The characteristic of the second S-shaped curve at this time is: in the case of acceleration, try to accelerate, and decelerate when it has to be decelerated, so as to ensure that the machining efficiency can no longer be improved theoretically.
其中,第二S型曲线最终减速到速度和加速度均为零,可以以待加工线段上所允许的减速方式减速到速度和加速度均为零。Among them, the second S-shaped curve is finally decelerated to zero speed and acceleration, and can be decelerated to the speed and acceleration of zero in the deceleration mode allowed on the line segment to be processed.
步骤S104:取第二S型曲线的部分成为第三S型曲线,其中第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点。Step S104: taking a portion of the second S-shaped curve to become a third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first constant-speed position point in the constant-speed position point.
步骤S105:以第三S型曲线的终点为起点再次进行S型曲线规划。Step S105: S-curve planning is performed again starting from the end point of the third S-shaped curve.
步骤S106:在待加工线段全部规划完毕后,将规划得到的多段第三S型曲线组合形成最终得到的S型曲线规划数据。Step S106: After all the planned line segments are completely planned, the planned plurality of third S-shaped curves are combined to form the final S-shaped curve planning data.
虽然在调整的时候,调整后得到的第二S型曲线最终减速到速度和加速度均为零,但是第三S型曲线并不取第二S型曲线减速到速度和加速度均为零的整个曲线,而是取其中的一部分,具体是:取第二S型曲线的部分成为第三S型曲线,第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点。因为,在进行规划时,情况随时在变化,通常规划一部分待加工线段,再接着规划另一部分待加工线段,如果一部分待加工线段的第三S型曲线为速度和加速度均为零的整个曲线,那么另一部分的待加工线段的S型曲线又必须要从速度和加速度均为零的起点开始重新规划,这显然降低加工效率。因此,第三S型曲线的起点为第二S型曲线的起点,终点等速位置点中首先出现的等速位置点,此时速度并不为零,另一部分待加工线段的规划从第三S型曲线的终点为起点再次进行S型曲线规划,从而保证不降低加工效率。在待加工线段全部规划完毕后,将规划得到的多段第三S型曲线组合形成最终得到的S型曲线规划数据。Although the second S-shaped curve obtained after the adjustment is finally decelerated to zero speed and acceleration during the adjustment, the third S-shaped curve does not take the second S-shaped curve to decelerate to the entire curve with zero speed and acceleration. But take part of it, specifically: the part taking the second S-shaped curve becomes the third S-shaped curve, the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the end point is the first point in the constant velocity position The same speed position point appears. Because, when planning, the situation changes at any time, usually planning a part of the line to be processed, and then planning another part of the line to be processed, if the third S-shaped curve of a part of the line to be processed is the entire curve with zero speed and acceleration, Then the S-shaped curve of the other part of the line to be processed must be re-planned from the starting point where the speed and acceleration are zero, which obviously reduces the processing efficiency. Therefore, the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, the first constant velocity position point in the end point constant velocity position point, the speed is not zero at this time, and the planning of the other part to be processed is from the third The end point of the S-curve is the starting point for the S-curve planning again, so as to ensure that the processing efficiency is not reduced. After all the planned segments are planned, the planned multi-segment third S-shaped curves are combined to form the final S-curve planning data.
本发明实施方式获取待加工线段各自对应的限制速度;计算从待加工线段加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线;判断第一S型曲线是否存在速度超出限制速度的位置点,如果存在,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线 段存在速度等于限制速度的等速位置点,取第二S型曲线的部分成为第三S型曲线,其中第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点;以第三S型曲线的终点为起点再次进行S型曲线规划;在待加工线段全部规划完毕后,将规划得到的多段第三S型曲线组合形成最终得到的S型曲线规划数据。由于第三曲线的终点为首先出现的等速位置点,再次规划时,以该终点为起点进行规划的,也即是说,再次规划时起点的加速度和速度并不为0,通过这种方式,能够克服现有算法中在线段转接处加速度必须变为零的缺点,并且保证在能加速的情况下,尽力加速,在不得不减速时才进行减速,从而保证最大的加工效率。The embodiment of the present invention obtains the corresponding speed limit of the line segments to be processed; calculates a first S-shaped curve that is accelerated from the line segment to be processed to the user's desired target speed, and then runs at a uniform speed desired by the user; and determines whether the first S-shaped curve is There is a position point where the speed exceeds the speed limit, and if present, the first S-shaped curve is adjusted, so that the second S-shaped curve obtained after the adjustment is finally decelerated to zero speed and acceleration, and the speed on the line segment to be processed is not exceeded. Individual speed limit, and at least one line The segment has a velocity equal to the constant velocity position point of the limiting speed, and the portion of the second S-shaped curve becomes the third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the constant velocity position point. The first constant velocity position appears; the S-curve planning is performed again with the end point of the third S-shaped curve as the starting point; after all the planned segments are completed, the planned multi-segment third S-shaped curves are combined to form the finalized S-curve planning data. Since the end point of the third curve is the first constant velocity position point, when planning again, the end point is used as the starting point for planning, that is, the acceleration and velocity of the starting point are not 0 when planning again. It can overcome the shortcomings that the acceleration of the line segment transfer must be zero in the existing algorithm, and ensure that the acceleration can be accelerated in the case of acceleration, and the deceleration is performed when the speed has to be decelerated, thereby ensuring the maximum processing efficiency.
其中,参见图4,步骤S102可以包括:子步骤S1021和子步骤S1022。Wherein, referring to FIG. 4, step S102 may include: sub-step S1021 and sub-step S1022.
子步骤S1021:确定第一S型曲线的运行过程,运行过程包括:加加速段、匀加速段、减加速段以及匀速段。Sub-step S1021: determining an operation process of the first S-shaped curve, the operation process includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section.
从待加工线段的起点用最大加速能力加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行,这个运行过程一般包括:加加速段、匀加速段、减加速段以及匀速段。当然,也可以将运行过程规划为:匀加速段、减加速段以及匀速段,或者,根据实际需求或者应用、计算的方便,将运行过程规划为其它的几个过程。The acceleration from the starting point of the line segment to be processed is accelerated to the user's desired target speed, and then the user's desired target speed is uniformly operated. This operation generally includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section. Of course, the running process can also be planned as: uniform acceleration section, deceleration section and uniform section, or the operation process is planned as other processes according to actual needs or application and calculation convenience.
子步骤S1022:计算运行过程中的加速度a(τ)、速度f(τ)以及位移l(τ),其中加速度a(τ)、速度f(τ)以及位移l(τ)分别为:Sub-step S1022: calculating acceleration a(τ), velocity f(τ), and displacement l(τ) during operation, wherein acceleration a(τ), velocity f(τ), and displacement l(τ) are:
Figure PCTCN2015099244-appb-000002
Figure PCTCN2015099244-appb-000002
Figure PCTCN2015099244-appb-000003
Figure PCTCN2015099244-appb-000003
Figure PCTCN2015099244-appb-000004
Figure PCTCN2015099244-appb-000004
其中,0≤t≤t1是加加速段,t1≤t≤t2是匀加速段,t2≤t≤t3是减加速段,t3≤t≤t4是匀速段,τ1是加加速段的时间累积,τ2是匀加速段的时间累积,τ3是减加速段的时间累积,τ4是匀速段的时间累积,t是总运行过程的时间累积,t1,t2,t3,t4分别是t中的各个时间点,J是系统允许的最大加加速度,A是系统允许的最大加速度,as是初始加速度,fs是初始速度,ls是初始位移。Where 0 ≤ t ≤ t 1 is the acceleration acceleration section, t 1 ≤ t ≤ t 2 is the uniform acceleration section, t 2 ≤ t ≤ t 3 is the acceleration acceleration section, t 3 ≤ t ≤ t 4 is the uniform velocity section, τ 1 It is the time accumulation of the acceleration section, τ 2 is the time accumulation of the uniform acceleration section, τ 3 is the time accumulation of the acceleration section, τ 4 is the time accumulation of the uniform velocity section, t is the time accumulation of the total operation process, t 1 , t 2 , t 3 , t 4 are the respective time points in t, J is the maximum jerk allowed by the system, A is the maximum acceleration allowed by the system, a s is the initial acceleration, f s is the initial velocity, and l s is the initial displacement .
在速度与位移均已知的情况下,速度-位移第一S型曲线也很容易计算。如图3,图3为计算出来的速度-位移第一S型曲线。The velocity-displacement first S-curve is also easy to calculate with both speed and displacement known. As shown in Fig. 3, Fig. 3 is the calculated velocity-displacement first S-shaped curve.
参见图5,图5中将加速度-时间曲线与速度-位移曲线合并制作在一起,上半部分为加速度-时间曲线,纵坐标表示加速度,横坐标为时间;下半部分为速度-位移曲线,纵坐标表示速度,横坐标表示位移。Referring to FIG. 5, the acceleration-time curve and the velocity-displacement curve are combined together in FIG. 5, the upper half is an acceleration-time curve, the ordinate represents acceleration, the abscissa is time, and the lower half is a velocity-displacement curve. The ordinate represents the velocity and the abscissa represents the displacement.
在图5的加速度-时间曲线上,开始规划的运行过程包括:加加速段(时间段是0-t1)、匀加速段(时间段是t1-t2)、减加速段(时间段是t2-t3)以及匀速段(时间段是t3-t4)四个过程,可以获得这四个过程的加速度的计算公式。根据加速度和速度之间的关系,可以获得这四个过程的速度的计算公式。根据速度和位移之间的关系,可以获得这四个过程的位移的计算公式。在图5的速度-位移曲线上,与运行过程加加速段(时间段是0-t1)、匀加速段(时间段是t1-t2)、减加速段(时间段是t2-t3)以及匀速段(时间段是t3-t4)对应的速度-位移曲线如下半部分有曲线段1、2、3组成的曲线。On the acceleration-time curve of Fig. 5, the running process of starting planning includes: acceleration section (time period is 0-t 1 ), uniform acceleration section (time period is t 1 -t 2 ), deceleration section (time period) It is t 2 -t 3 ) and four processes of uniform velocity (time period is t 3 -t 4 ), and the calculation formula of the acceleration of these four processes can be obtained. According to the relationship between acceleration and speed, the calculation formula of the speed of these four processes can be obtained. According to the relationship between velocity and displacement, the calculation formula of the displacement of these four processes can be obtained. On the velocity-displacement curve of Fig. 5, the accelerating section (time period is 0-t 1 ), the uniform acceleration section (time period is t 1 -t 2 ), and the deceleration section (time period is t 2 -) The velocity-displacement curve corresponding to t 3 ) and the uniform velocity section (time period is t 3 -t 4 ) has a curve composed of curve segments 1, 2, and 3 as follows.
上述实施方式中,第一S型曲线的运行过程包括:加加速段、匀加速段、减加速段以及匀速段,根据普通的物理知识,可以分别获得加速度、速度以及位移的计算公式,通过这种方式,可以简化处理过程,缩短规划所需要的时间。In the above embodiment, the operation process of the first S-shaped curve includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform velocity section. According to common physical knowledge, calculation formulas of acceleration, velocity, and displacement can be respectively obtained. This way, the process can be simplified and the time required for planning can be shortened.
其中,参见图6,步骤S103中,判断第一S型曲线是否存在速度超出所述限制速度的位置点的步骤,可以包括:子步骤S201、子步骤S202以及子步骤S203。Referring to FIG. 6, in step S103, the step of determining whether the first S-curve has a position where the speed exceeds the limit speed may include: sub-step S201, sub-step S202, and sub-step S203.
子步骤S201:通过f(τ)、线段Li的限制速度Fi确定达到限制速度Fi所需要的 时间ti,并进而确定达到限制速度Fi时的位移l和加速度a。Sub-step S201: by f (τ), the speed limit of the line segment L i F i determined time limit is reached required speed F i t i, l and thus determining the displacement reaches the limit when the speed and acceleration F i a.
线段的限制速度是已知的,通过速度公式f(τ)可以确定达到该限制速度的时间ti,然后进一步可以确定达到限制速度Fi时的位移l和加速度a。The speed limit of the line segment is known, and the time t i at which the speed limit is reached can be determined by the speed formula f(τ), and then the displacement l and the acceleration a when the speed limit F i is reached can be further determined.
子步骤S202:若a>0,且l<li+1,则判断出第一S型曲线在线段Li存在速度超出限制速度Fi的位置点,li+1为线段Li的终点到待加工线段的起点的距离。Sub-step S202: If a>0, and l<l i+1 , it is determined that the first S-curve line segment L i has a speed point exceeding the limit speed F i , and l i+1 is the end point of the line segment L i The distance to the starting point of the line segment to be processed.
若a>0,且l<li+1,说明在速度达到该线段Li的限制速度Fi时,已加工的位移还没有达到该线段Li的终点,但是加速度大于零,还在加速中,那么当位移达到该线段Li的终点时,速度肯定超出该线段Li的限制速度Fi,因此,判断出第一S型曲线在线段Li存在速度超出限制速度的Fi的位置点。若a>0,且l>li+1,说明在速度达到该线段Li的限制速度Fi时,已加工的位移已经超出该线段Li的终点,加速度大于零,还在加速,但是位移已经超出该线段Li的终点,即使还在加速,已经和该线段Li的限制速度Fi没有关系了,在该线段Li上加工的时候,速度是小于该限制速度Fi的。若a>0,且l=li+1,说明在速度达到该线段Li的限制速度Fi时,已加工的位移刚好到达该线段Li的终点,加速度大于零,还在加速,但是位移已经达到该线段Li的终点,即使还在加速,已经和该线段Li的限制速度Fi没有关系了,在该线段Li上加工的时候,速度是小于或等于该限制速度Fi的,在到达该线段Li的终点时,速度刚好到达限制速度FiIf a>0, and l<l i+1 , it means that when the speed reaches the limit speed F i of the line segment L i , the processed displacement has not reached the end point of the line segment L i , but the acceleration is greater than zero and is still accelerating. position, then when the displacement reaches the end point of the line segment L i, the line speed is definitely beyond the limit speed L i, F i, therefore, determined that the first S-curve the line segment L i present speed exceeds the speed limit of F i, point. If a>0, and l>l i+1 , it means that when the speed reaches the limit speed F i of the line segment L i , the processed displacement has exceeded the end point of the line segment L i , the acceleration is greater than zero, and is still accelerating, but displacement beyond the end of the line segment L i, even still accelerating, and has the line segment L i, F i the speed limit does not matter, in the processed line segment L i, the speed is less than the limit velocity of F i. If a> 0, and l = l i + 1, described in the speed reaches the speed limit of the line segment L i i, F., Just reaching the processed displacement of the end of the line segment L i, acceleration is greater than zero, it is accelerating, but displacement L i has reached the end of the line segment, even if is accelerating, and the line segment L has a speed limit of F i i no relationship, processed on the line segment L i when the speed is less than or equal to the limit speed F i When the end point of the line segment L i is reached, the speed just reaches the limit speed F i .
子步骤S203:若a<0,且l>li,则判断出第一S型曲线在线段Li存在速度超出限制速度Fi的位置点,li为线段Li的起点到待加工线段的起点的距离。Sub-step S203: If a<0, and l>l i , it is determined that the first S-curve line segment L i has a position where the speed exceeds the limit speed F i , and l i is the starting point of the line segment L i to the line segment to be processed The starting point of the distance.
若a<0,且l>li,说明在速度达到该线段Li的限制速度Fi时,已加工的位移已经达到并超过该线段Li的起点,还没有到达终点,加速度小于零,在减速阶段,速度先上升后下降,速度必然超出该线段Li的限制速度Fi,因此,判断出第一S型曲线在线段Li存在速度超出限制速度Fi的位置点。若a<0,且l<li,说明在速度达到该线段Li的限制速度Fi时,已加工的位移还没有达到该线段Li的起点,加速度小于零,在减速阶段,速度下降,到达该线段Li的起点时,速度必然小于限制速度Fi。若a<0,且l=li,说明在速度达到该线段Li的限制速度Fi时,已加工的位移刚好到达该线段Li的起点,加速度小于零,在减速阶段,速度下降,到达该线段Li的终点时,速度必然小于限制速度FiIf a <0, and l> l i, be described in the speed reaches the line segment L limit speed i, F. I, processed displacement has reached the start point and beyond the line L i, and has not yet reached the end, acceleration is less than zero, In the deceleration phase, the speed first rises and then falls, and the speed necessarily exceeds the limit speed F i of the line segment L i . Therefore, it is determined that the first S-curve line segment L i has a position point where the speed exceeds the limit speed F i . If a<0, and l<l i , it means that when the speed reaches the limit speed F i of the line segment L i , the processed displacement has not reached the starting point of the line segment L i , the acceleration is less than zero, and the speed decreases during the deceleration phase. when reaching the start point of the line segment L i, the speed must be smaller than the limit speed F i. If a<0, and l=l i , it means that when the speed reaches the limit speed F i of the line segment L i , the processed displacement just reaches the starting point of the line segment L i , the acceleration is less than zero, and in the deceleration phase, the speed decreases. When the end point of the line segment L i is reached, the speed must be less than the speed limit F i .
其中,参见图7,步骤S103中,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点的步骤,可以包括:子步骤S301、子步骤S302、子步骤S303、子步骤S304、子步骤S305、子步骤S306、子步骤S307以及子步骤S308。Referring to FIG. 7, in step S103, the first S-shaped curve is adjusted, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speeds on the line segments to be processed are not exceeded. The step of limiting the speed and having at least one line segment having a constant speed position point equal to the speed limit may include: sub-step S301, sub-step S302, sub-step S303, sub-step S304, sub-step S305, sub-step S306, sub-step S307 and sub-step S308.
子步骤S301:确定第一时间点tS和第二时间点tE,其中,第一时间点tS为第一S型曲线的起点时刻t0,第二时间点tE为第一S型曲线中减加速段的起始时间点。Sub-step S301: determining a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second time point t E is a first S-shaped The starting time point of the acceleration section in the curve.
因为判断出第一S型曲线存在速度超出限制速度的位置点,说明减速的起始时间点太晚。因此,在本实施方式中,可以利用二分法调整第一S型曲线,首先确定调整的时间区间:第一时间点tS和第二时间点tE,第一时间点tS为第一S型曲线的起点时刻t0,第二时间点为第一S型曲线减加速段的起始时间点。Since it is judged that the first S-shaped curve has a position where the speed exceeds the limit speed, the start time point of the deceleration is too late. Therefore, in the present embodiment, the first S-curve can be adjusted by using the dichotomy, and the adjusted time interval is first determined: the first time point t S and the second time point t E , and the first time point t S is the first S The starting point of the curve is t 0 , and the second time is the starting time of the first S-curve minus the acceleration segment.
子步骤S302:确定第三时间点tM,第三时间点tM为第一时间点tS和第二时间点tE的中间时间点tM
Figure PCTCN2015099244-appb-000005
Sub-step S302: determining a third time point t M , wherein the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
Figure PCTCN2015099244-appb-000005
子步骤S303:对第一S型曲线进行调整,使得减加速段的起始时间点T调整为第三时间点tM,并在之后尽可能快地减速到加速度和速度降为0,调整后得到的曲线为第四S型曲线。Sub-step S303: adjusting the first S-shaped curve such that the starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerating as fast as possible to the acceleration and the speed drop to 0 after the adjustment, after the adjustment The curve obtained is the fourth sigmoid curve.
需要说明的是,本实施例中“尽可能快地减速”是指尽可能地利用系统所允许的最大减加速度(可等于最大加加速度)和最大减速度(可等于最大加速度)进行减速,以在最短时间内减速到加速度和速度降为0。通过这种方式,可以减少所需要的时间,提高规划得到的S型曲线的加工效率。It should be noted that “deceleration as fast as possible” in the present embodiment refers to decelerating as much as possible by using the maximum deceleration (which may be equal to the maximum jerk) and the maximum deceleration (which may be equal to the maximum acceleration) allowed by the system. Deceleration to acceleration and speed drop to zero in the shortest time. In this way, the time required can be reduced, and the processing efficiency of the planned S-shaped curve can be improved.
确定第一S型曲线存在速度超出限制速度的位置点,说明减加速段的起始时间点太晚,因此,将减加速段的起始时间点调整为第三时间点,在第二时间点tE之前。Determining that the first S-shaped curve has a speed exceeding the limit speed, indicating that the start time point of the deceleration section is too late, therefore, adjusting the start time point of the deceleration section to the third time point, at the second time point Before t E.
子步骤S304:判断第四S型曲线是否存在速度超出限制速度的位置点,如果存在则执行子步骤S306,否则执行子步骤S305。Sub-step S304: determining whether the fourth sigmoid curve has a position point where the speed exceeds the speed limit, and if so, performing sub-step S306, otherwise performing sub-step S305.
子步骤S305:判断第四S型曲线是否至少有一条线段存在速度等于限制速度的等速位置点,如果有则执行子步骤S308,否则执行子步骤S307。Sub-step S305: determining whether the fourth sigmoid curve has at least one line segment having a constant speed position point whose speed is equal to the speed limit, and if so, performing sub-step S308, otherwise performing sub-step S307.
子步骤S306:使第二时间点tE的值等于第三时间点tM,并返回子步骤S302。 Sub-step S306: making the value of the second time point t E equal to the third time point t M and returning to sub-step S302.
第四S型曲线存在速度超出限制速度的位置点,说明减加速段的起始时间点在tM点减速有点晚,需要再往前提前减速,第四S型曲线减加速段的起始时间点在tM之前,也就是在tS和tM之间,此时,中间时间点应该为
Figure PCTCN2015099244-appb-000006
涉及计算循环的问题,此处将第二时间点tE的值记为等于第三时间点tM,因此返回子步骤S302,使总体的公式保持一致。
The fourth S-curve has a position where the speed exceeds the limit speed, indicating that the start time of the deceleration section decelerates at t m point a little late, and needs to be decelerated earlier, and the fourth S-curve deceleration start time of the acceleration section Point before t M , that is, between t S and t M. At this time, the intermediate time point should be
Figure PCTCN2015099244-appb-000006
In connection with the problem of calculating the cycle, the value of the second time point t E is here recorded as equal to the third time point t M , so returning to sub-step S302, the overall formula is kept consistent.
子步骤S307:使第一时间点tS的值等于第三时间点tM,并返回子步骤S302。Sub-step S307: making the value of the first time point t S equal to the third time point t M and returning to sub-step S302.
若第四S型曲线没有至少有一条线段存在速度等于限制速度的等速位置点,即速度小于各自对应的限制速度,均不超速,说明减加速段的起始时间点在tM点减速有点早,需要往后再减速,第四S型曲线减加速段的起始时间点在tM之后,也就是在tM和tE之间,此时,中间时间点应该为
Figure PCTCN2015099244-appb-000007
涉及计算循环的问题,此处将第一时间点tS的值记为等于第三时间点tM,因此返回子步骤S302,使总体的公式保持一致。
If the fourth sigmoid curve does not have at least one line segment having the same speed position point whose speed is equal to the speed limit, that is, the speed is less than the corresponding speed limit, no speeding is exceeded, indicating that the starting time point of the speed reduction section is decelerated at t M point. Early, need to slow down again, the starting point of the fourth S-curve reduction acceleration section is after t M , that is, between t M and t E. At this time, the intermediate time point should be
Figure PCTCN2015099244-appb-000007
In connection with the problem of the calculation cycle, the value of the first time point t S is recorded here to be equal to the third time point t M , so the sub-step S302 is returned to keep the overall formula consistent.
子步骤S308:确定第四S型曲线为第二S型曲线。Sub-step S308: determining that the fourth sigmoid curve is the second sigmoid curve.
参阅图5,在加速度-时间曲线上,找到时间点tg,从时间点tg开始全力减速至加速度和速度均为零(在时间点t5’,加速度和速度均为零),从时间点tg之后的加速度-时间曲线为图中的虚线所示;对应到速度-位移曲线上,调整后的S曲线为曲线段1、4组成的曲线。Referring to Figure 5, on the acceleration-time curve, the time point t g is found, and the full force deceleration from the time point t g until the acceleration and velocity are zero (at the time point t 5 ', the acceleration and the speed are both zero), from the time The acceleration-time curve after point t g is shown by the dashed line in the figure; corresponding to the speed-displacement curve, the adjusted S curve is the curve composed of curve segments 1, 4.
请参见图8至图14,其中,图8至图14表示一实施例中S型曲线的调整过程(图中仅画出速度-位移曲线),图14为调整后的S型曲线(即图11中的曲线6),为了便于解释和说明,认为:曲线1代表第一次调整后的S型曲线(曲线1实际上是经过多次调整后在a线段上刚好不超速的S型曲线),曲线2代表第二次调整后的S型曲线,曲线3代表第三次调整后的S型曲线,曲线4代表第四次调整后的S型曲线,曲线5代表第五次调整后的S型曲线,曲线6代表第六次调整后的S型曲线;a、b、c、d、e、f、g分别表示线段。Referring to FIG. 8 to FIG. 14 , FIG. 8 to FIG. 14 show an adjustment process of the S-shaped curve in an embodiment (only the velocity-displacement curve is drawn in the figure), and FIG. 14 is an adjusted S-shaped curve (ie, a diagram). Curve 6) in 11, for the convenience of explanation and explanation, it is considered that curve 1 represents the first adjusted S-shaped curve (curve 1 is actually an S-shaped curve that does not overspeed on the a-line segment after multiple adjustments) Curve 2 represents the second adjusted S-curve, curve 3 represents the third adjusted S-curve, curve 4 represents the fourth adjusted S-curve, and curve 5 represents the fifth adjusted S-curve. The curve, curve 6 represents the sixth adjusted S-curve; a, b, c, d, e, f, g respectively represent the line segment.
图8中,曲线1是第一次调整后的S型曲线,可以看出:曲线1在速度和加速度均下降为0时,在线段a上刚好不超速,在线段b、c上均不超速,在线段d、e、f上均超速,说明调整后的减加速段的起始时间点应该在曲线1减加速段的起始时间点之前。In Fig. 8, curve 1 is the first adjusted S-shaped curve. It can be seen that when the velocity and acceleration both decrease to 0, the line segment a just does not overspeed, and the line segments b and c do not overspeed. The line segments d, e, and f are overspeeded, indicating that the starting time point of the adjusted deceleration section should be before the start time of the curve 1 deceleration section.
图9中,曲线2在速度和加速度均下降为0时,在线段a、b、c上均不超速, 在线段d、e上超速,说明调整后的减加速段的起始时间点应该继续提前,应该在曲线2减加速段的起始时间点之前。In Fig. 9, when the velocity and the acceleration both decrease to 0, the curve 2 does not overspeed on the line segments a, b, and c. The overspeed on the line segments d and e indicates that the starting time point of the adjusted deceleration section should continue to advance, and should be before the start time of the acceleration section of curve 2.
图10中,曲线3在速度和加速度均下降为0时,在线段a、b、c、d、e上均不超速,说明曲线3减加速段的起始时间点过早,需要推迟减加速段的起始时间点,也就是说,调整后的减加速段的起始时间点应该在曲线3减加速段的起始时间点和曲线2减加速段的起始时间点之间。In Fig. 10, when the velocity and acceleration both decrease to 0, the line segments a, b, c, d, and e do not overspeed, indicating that the starting time of the curve 3 minus the acceleration segment is too early, and the acceleration needs to be delayed. The starting time point of the segment, that is, the starting time point of the adjusted deceleration segment should be between the start time point of the curve 3 minus the acceleration segment and the start time point of the curve 2 deceleration segment.
图11中,曲线4在速度和加速度均下降为0时,在线段a、b、c、d上均不超速,在线段e上有一点超速,没有刚刚不超速的情况出现,继续调整,调整的方向是使调整后的S型曲线在线段e上刚刚达到线段e的限制速度,即刚好不超速。In Fig. 11, when the speed and the acceleration decrease to 0, the curve 4 does not overspeed on the line segments a, b, c, and d. There is a little overspeed on the line segment e, and there is no case of not overspeeding. Continue to adjust and adjust. The direction is such that the adjusted S-curve has just reached the limit speed of the line segment e on the line segment e, that is, it does not just overspeed.
图12中,曲线5在速度和加速度均下降为0时,在线段a、b、c、d上均不超速,在线段e上稍微超速,没有刚刚不超速的情况出现,继续调整,调整的方向是使调整后的S型曲线在线段e上刚刚达到线段e的限制速度,即刚好不超速。In Fig. 12, when the speed and the acceleration both fall to 0, the line segments a, b, c, and d do not overspeed, and the line segment e is slightly over-speeded, and there is no case of not overspeeding. Continue to adjust and adjust. The direction is such that the adjusted S-curve has just reached the limit speed of the line segment e on the line segment e, that is, it does not just overspeed.
图13中,曲线6在速度和加速度均下降为0时,在线段a、b、c、d上均不超速,在线段e上刚刚不超速,因此,调整后得到的第二S型曲线在线段a、b、c、d、e上是满足要求的,正是本发明需要调整的结果。In Fig. 13, when the velocity and the acceleration both decrease to 0, the line segments a, b, c, and d do not overspeed, and the line segment e does not just overspeed. Therefore, the second S-curve curve obtained after adjustment is online. The segments a, b, c, d, and e are satisfactory, and it is the result of the adjustment of the present invention.
图14是图13中单独的曲线6的示意图,取第二S型曲线6的部分成为第三S型曲线,第三S型曲线的起点为A点,终点为B点(等速位置点中首先出现的等速位置点,在本实施例中,终点是线段e的起点)。Figure 14 is a schematic view of a separate curve 6 of Figure 13, taking the portion of the second S-shaped curve 6 into a third S-shaped curve, the starting point of the third S-shaped curve being point A, and the ending point being point B (in the constant velocity position point) The first constant velocity position point, in this embodiment, the end point is the starting point of the line segment e).
下一步,则可以B点为起点对剩余线段再次进行S型曲线规划。In the next step, the S-curve plan can be performed again on the remaining line segments starting from point B.
参见图15,图15是本发明一实施例中,实际运行轨迹时采集数据截取的一部分图像。其中,给定参数为:系统最大加速度:5m/s2,最大加加速度:5000m/s3Referring to Figure 15, Figure 15 is a portion of an image captured by the acquisition data when the trajectory is actually traversed in an embodiment of the present invention. Among them, the given parameters are: maximum acceleration of the system: 5m/s 2 , maximum jerk: 5000m/s 3 .
图15中,由上到下,第一幅图为速度-位移图像,横轴为距离,纵轴为速度,其中实线为各个线段对应的限制速度,虚线为实际运行速度;第二幅图为加速度图像,横轴为距离,纵轴为加速度,其中虚线为各个轴加速度合成值,实线为运行轨迹切线方向的加速度;第三幅图为加加速度值,横轴为距离,纵轴为加加速度,其中虚线为各个轴加加速度的合成值,实线为轨迹切线方向的加速度变化产生的加加速度值。在该实施例中,本发明方法的加工效率比现有技术的加工效率提高10~14%。In Fig. 15, from top to bottom, the first picture is a velocity-displacement image, the horizontal axis is the distance, and the vertical axis is the speed, wherein the solid line is the speed limit corresponding to each line segment, and the broken line is the actual running speed; the second picture For the acceleration image, the horizontal axis is the distance and the vertical axis is the acceleration, wherein the broken line is the composite value of each axis acceleration, the solid line is the acceleration of the tangential direction of the running track; the third picture is the jerk value, the horizontal axis is the distance, and the vertical axis is The jerk, wherein the broken line is the composite value of the acceleration of each axis, and the solid line is the jerk value generated by the acceleration change of the tangential direction of the track. In this embodiment, the processing efficiency of the method of the present invention is increased by 10 to 14% over the processing efficiency of the prior art.
参阅图16,图16是本发明S型曲线规划装置一实施方式的结构示意图,本 发明实施方式的装置可以执行上述的方法,本实施方式装置中的相关内容请参见上述方法中的详细说明,在此不再赘叙。该装置包括:第一获取模块101、计算模块102、判断模块103、调整模块104、第二获取模块105以及组合模块106。Referring to FIG. 16, FIG. 16 is a schematic structural diagram of an embodiment of an S-shaped curve planning device according to the present invention. The device in the embodiment of the present invention may perform the foregoing method. For related content in the device in this embodiment, refer to the detailed description in the foregoing method, and details are not described herein. The device includes: a first obtaining module 101, a calculating module 102, a determining module 103, an adjusting module 104, a second obtaining module 105, and a combining module 106.
第一获取模块101用于获取待加工线段各自对应的限制速度。The first obtaining module 101 is configured to acquire a speed limit corresponding to each line segment to be processed.
计算模块102用于计算从待加工线段的起点加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线。The calculation module 102 is configured to calculate a first S-shaped curve that accelerates from the starting point of the line segment to be processed to the user's desired target speed and then runs at a constant speed at the target speed desired by the user.
判断模块103用于判断第一S型曲线是否存在速度超出限制速度的位置点。The determining module 103 is configured to determine whether the first S-shaped curve has a position point whose speed exceeds the limiting speed.
调整模块104用于在判断结果为存在时,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点。The adjusting module 104 is configured to adjust the first S-shaped curve when the determination result is present, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and the speed on the line segment to be processed is not exceeded. The respective speed limits, and at least one line segment has a constant speed position point whose speed is equal to the speed limit.
第二获取模块105用于取第二S型曲线的部分成为第三S型曲线,其中第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点。The second obtaining module 105 is configured to take the portion of the second S-shaped curve to become a third S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first occurrence in the constant-speed position, etc. Speed position point.
以第三S型曲线的终点为起点再次进行S型曲线规划,返回计算模块102。The S-curve plan is again performed starting from the end point of the third S-shaped curve and returned to the calculation module 102.
组合模块106用于在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。The combination module 106 is configured to combine the plurality of third sigmoid curves obtained by the planning to form the finally obtained S-curve planning data after all the planned segments are planned.
其中,待加工线段各自对应的限制速度的大小为待加工线段上各自对应的用户预设目标速度和曲率限制速度中的最小值。其中,曲率限制速度包括由曲率和弓高误差导致的限制速度和由曲率、加速度以及加加速度导致的限制速度。The size of the corresponding limit speed of the line segments to be processed is the minimum of the preset target speed and the curvature limit speed of the corresponding user on the line segment to be processed. Among them, the curvature limiting speed includes a speed limit caused by curvature and bow height error and a speed limit caused by curvature, acceleration, and jerk.
其中,计算模块102具体用于计算从待加工线段的起点以最大加速能力加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线。The calculation module 102 is specifically configured to calculate a first S-shaped curve that is accelerated from the starting point of the line segment to be processed to the user's desired target speed with the maximum acceleration capability, and then runs at the target speed that is desired by the user.
其中,参见图17,计算模块102包括:第一确定单元1021和第一计算单元1022。Referring to FIG. 17, the calculation module 102 includes: a first determining unit 1021 and a first calculating unit 1022.
第一确定单元1021用于确定第一S型曲线的运行过程,运行过程包括:加加速段、匀加速段、减加速段以及匀速段。The first determining unit 1021 is configured to determine an operation process of the first S-shaped curve, and the running process includes: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section.
第一计算单元1022用于计算运行过程中的加速度a(τ)、速度f(τ)以及位移l(τ),加速度a(τ)、速度f(τ)以及位移l(τ)分别为: The first calculating unit 1022 is configured to calculate the acceleration a(τ), the velocity f(τ), and the displacement l(τ) during the operation, the acceleration a(τ), the velocity f(τ), and the displacement l(τ) are respectively:
Figure PCTCN2015099244-appb-000008
Figure PCTCN2015099244-appb-000008
Figure PCTCN2015099244-appb-000009
Figure PCTCN2015099244-appb-000009
Figure PCTCN2015099244-appb-000010
Figure PCTCN2015099244-appb-000010
其中,0≤t≤t1是加加速段,t1≤t≤t2是匀加速段,t2≤t≤t3是减加速段,t3≤t≤t4是匀速段,τ1是加加速段的时间累积,τ2是匀加速段的时间累积,τ3是减加速段的时间累积,τ4是匀速段的时间累积,t是总运行过程的时间累积,t1,t2,t3,t4分别是t中的各个时间点,J是系统允许的最大加加速度,A是系统允许的最大加速度,as是初始加速度,fs是初始速度,ls是初始位移。之后,通过速度f(τ)以及位移l(τ),很容易即可计算速度-位移第一S型曲线。Where 0 ≤ t ≤ t 1 is the acceleration acceleration section, t 1 ≤ t ≤ t 2 is the uniform acceleration section, t 2 ≤ t ≤ t 3 is the acceleration acceleration section, t 3 ≤ t ≤ t 4 is the uniform velocity section, τ 1 It is the time accumulation of the acceleration section, τ 2 is the time accumulation of the uniform acceleration section, τ 3 is the time accumulation of the acceleration section, τ 4 is the time accumulation of the uniform velocity section, t is the time accumulation of the total operation process, t 1 , t 2 , t 3 , t 4 are the respective time points in t, J is the maximum jerk allowed by the system, A is the maximum acceleration allowed by the system, a s is the initial acceleration, f s is the initial velocity, and l s is the initial displacement . After that, the velocity-displacement first sigmoid curve can be easily calculated by the velocity f(τ) and the displacement l(τ).
其中,参见图18,判断模块103包括:第二确定单元1031和第一结果单元1032。Referring to FIG. 18, the determining module 103 includes: a second determining unit 1031 and a first result unit 1032.
第二确定单元1031用于通过f(τ)、线段Li的限制速度Fi确定达到限制速度Fi所需要的时间ti,并进而确定达到限制速度Fi时的位移l和加速度a。第一结果单元1032用于在a>0,且l<li+1时,判断出第一S型曲线在线段Li存在速度超出限制速度Fi的位置点,li+1为线段Li的终点到待加工线段的起点的距离;或,若a<0,且l>li,则判断出第一S型曲线在线段Li存在速度超出限制速度Fi的位置点,li为线段Li的起点到待加工线段的起点的距离。A second determining unit 1031 via f (τ), the speed limit line F i L i to determine the time limit is reached required speed F i t i, l and thus determining the displacement reaches the limit when the speed and acceleration F i a. The first result unit 1032 is configured to determine, when a>0, and l<l i+1 , that the first S-curve line segment L i has a speed exceeding a limit speed F i , and l i+1 is a line segment L The distance from the end point of i to the starting point of the line segment to be processed; or, if a<0, and l>l i , it is determined that the first S-curve line segment L i has a speed exceeding the limit speed F i , l i It is the distance from the starting point of the line segment L i to the starting point of the line segment to be processed.
其中,参见图19,调整模块104包括:第三确定单元1041、第四确定单元1042、调整单元1043、第一判断单元1044、第二判断单元1045、第一执行单元1046、第二执行单元1047以及第五确定单元1048。 Referring to FIG. 19, the adjustment module 104 includes: a third determining unit 1041, a fourth determining unit 1042, an adjusting unit 1043, a first determining unit 1044, a second determining unit 1045, a first executing unit 1046, and a second executing unit 1047. And a fifth determining unit 1048.
第三确定单元1041用于确定第一时间点tS和第二时间点tE,其中,第一时间点tS为第一S型曲线的起点时刻t0,第二时间点tE为第一S型曲线中减加速段的起始时间点。第四确定单元1042用于确定第三时间点tM,第三时间点tM为第一时间点tS和第二时间点tE的中间时间点tM
Figure PCTCN2015099244-appb-000011
调整单元1043用于对第一S型曲线进行调整,使得减加速段的起始时间点T调整为第三时间点tM,并在之后尽可能快地减速到加速度和速度降为0,调整后得到的曲线为第四S型曲线。第一判断单元1044用于判断第四S型曲线是否存在速度超出限制速度的位置点,如果存在,则进入第一执行单元1046,否则进入第二判断单元1045。第二判断单元1045用于判断第四S型曲线是否至少有一条线段存在速度等于限制速度的等速位置点,如果有,则进入第五确定单元1048,否则进入第二执行单元1047。第一执行单元1046用于使第二时间点tE的值等于第三时间点tM,并返回第四确定单元。第二执行单元1047用于使第一时间点tS的值等于第三时间点tM,并返回第四确定单元。第五确定单元1048用于确定第四S型曲线为第二S型曲线。
The third determining unit 1041 is configured to determine a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second time point t E is the first time point The starting time point of the acceleration section is reduced in an S-shaped curve. The fourth determining unit 1042 is configured to determine a third time point t M , where the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
Figure PCTCN2015099244-appb-000011
The adjusting unit 1043 is configured to adjust the first S-shaped curve such that the starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerate as quickly as possible to the acceleration and the speed drop to 0, and adjust The resulting curve is the fourth sigmoid curve. The first determining unit 1044 is configured to determine whether the fourth S-shaped curve has a position where the speed exceeds the limiting speed, and if so, enters the first executing unit 1046, and otherwise enters the second determining unit 1045. The second determining unit 1045 is configured to determine whether the fourth S-shaped curve has at least one line segment having a constant speed position point whose speed is equal to the limiting speed, and if so, enters the fifth determining unit 1048, and otherwise enters the second executing unit 1047. The first execution unit 1046 is configured to make the value of the second time point t E equal to the third time point t M and return to the fourth determining unit. The second execution unit 1047 is for causing the value of the first time point t S to be equal to the third time point t M and returning to the fourth determining unit. The fifth determining unit 1048 is configured to determine that the fourth S-shaped curve is a second S-shaped curve.
参见图20,本发明还提供一种数控机床,该数控机床包括机床本体和安装在机床本体上的数控设备,该数控设备可以执行上述方法中的步骤,相关内容的详细说明请参见上述方法部分,在此不再赘叙。Referring to FIG. 20, the present invention further provides a numerical control machine tool including a machine tool body and a numerical control device mounted on the machine body. The numerical control device can perform the steps in the above method. For details of the related content, please refer to the method part. I will not repeat it here.
该数控设备包括:连接在总线13的处理器11和存储器12。存储器12存储有程序,处理器11用于执行程序,程序执行时包括如下步骤:获取待加工线段各自对应的限制速度;计算从待加工线段的起点加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线;判断第一S型曲线是否存在速度超出限制速度的位置点,如果存在,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;取第二S型曲线的部分成为第三S型曲线,其中第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点;以第三S型曲线的终点为起点再次进行S型曲线规划;在待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。The numerical control device includes a processor 11 and a memory 12 connected to the bus 13. The memory 12 stores a program, and the processor 11 is configured to execute a program. The program includes the following steps: acquiring a speed limit corresponding to each line segment to be processed; calculating a speed from a starting point of the line segment to be processed to a desired target speed of the user, and then using the user The first S-shaped curve of the target speed is expected to run at a constant speed; determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated The speed and acceleration are both zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; the portion of the second S-shaped curve becomes the first The three S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, the ending point is the first constant velocity position point in the constant velocity position point; and the end point of the third S-shaped curve is taken as the starting point again. Curve planning; after all the planned segments are planned, the planned multi-segment third sigmoid curves are combined to form the final S-shaped curve gauge. Data.
本发明实施例还提供一种计算机存储介质,该计算机存储介质存储有程序, 该程序被计算机处理器执行时运行一种S型曲线规划方法,该方法包括:获取待加工线段各自对应的限制速度;计算从待加工线段的起点加速到用户期望目标速度、并在之后以用户期望目标速度匀速运行的第一S型曲线;判断第一S型曲线是否存在速度超出限制速度的位置点,如果存在,调整第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;取第二S型曲线的部分成为第三S型曲线,其中第三S型曲线的起点为第二S型曲线的起点,终点为等速位置点中首先出现的等速位置点;以第三S型曲线的终点为起点再次进行S型曲线规划;在待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。An embodiment of the present invention further provides a computer storage medium, where the computer storage medium stores a program. The program is executed by a computer processor to run an S-curve planning method, the method comprising: obtaining a respective limiting speed of the line segments to be processed; calculating a speed from a starting point of the line segment to be processed to a desired target speed of the user, and then using the user The first S-shaped curve of the target speed is expected to run at a constant speed; determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated The speed and acceleration are both zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit; the portion of the second S-shaped curve becomes the first The three S-shaped curve, wherein the starting point of the third S-shaped curve is the starting point of the second S-shaped curve, the ending point is the first constant velocity position point in the constant velocity position point; and the end point of the third S-shaped curve is taken as the starting point again. Curve planning; after all the planned segments are planned, the planned multi-section third sigmoid curves are combined to form the final S-shaped curve plan. data.
以上所述仅为本发明的实施方式,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。 The above is only the embodiment of the present invention, and is not intended to limit the scope of the invention, and the equivalent structure or equivalent process transformations made by the description of the invention and the drawings are directly or indirectly applied to other related technologies. The fields are all included in the scope of patent protection of the present invention.

Claims (15)

  1. 一种S型曲线规划方法,其特征在于,包括:An S-curve planning method, comprising:
    获取待加工线段各自对应的限制速度;Obtaining a corresponding speed limit of each line segment to be processed;
    计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;Calculating a first S-shaped curve that accelerates from a starting point of the line segment to be processed to a user desired target speed and then runs at a constant speed at the target speed desired by the user;
    判断所述第一S型曲线是否存在速度超出所述限制速度的位置点,如果存在,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;Determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated to both speed and acceleration Zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit;
    取所述第二S型曲线的部分成为第三S型曲线,其中所述第三S型曲线的起点为所述第二S型曲线的起点,终点为所述等速位置点中首先出现的等速位置点;Taking a portion of the second S-shaped curve into a third S-shaped curve, wherein a starting point of the third S-shaped curve is a starting point of the second S-shaped curve, and an ending point is first appearing in the constant-speed position point Constant velocity position point;
    以所述第三S型曲线的终点为起点再次进行S型曲线规划;S-curve planning is performed again starting from the end point of the third S-shaped curve;
    在所述待加工线段全部规划完毕后,将规划得到的多段第三S型曲线组合形成最终得到的S型曲线规划数据。After all the planned line segments are completely planned, the planned plurality of third S-shaped curves are combined to form the final S-shaped curve planning data.
  2. 根据权利要求1所述的方法,其特征在于,所述计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线包括:The method of claim 1 wherein said calculating a first sigmoid curve that accelerates from a starting point of said line segment to be processed to a user desired target speed and then operates at said user desired target speed at a uniform speed comprises :
    计算从所述待加工线段的起点以最大加速能力加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线。A first S-shaped curve is calculated that is accelerated from the starting point of the line segment to be processed with a maximum acceleration capability to a user desired target speed, and then runs at a constant speed at the target speed desired by the user.
  3. 根据权利要求1所述的方法,其特征在于,所述待加工线段各自对应的限制速度的大小为所述待加工线段上各自对应的用户预设目标速度和曲率限制速度中的最小值。The method according to claim 1, wherein the size of the respective limiting speeds of the line segments to be processed is the minimum of the user-preset target speed and the curvature limiting speed of the respective corresponding line segments on the line to be processed.
  4. 根据权利要求3所述的方法,其特征在于,所述曲率限制速度包括由曲率和弓高误差导致的限制速度和由曲率、加速度以及加加速度导致的限制速度。The method of claim 3 wherein said curvature limiting speed comprises a speed limit caused by curvature and bow height errors and a speed limit caused by curvature, acceleration and jerk.
  5. 根据权利要求2所述的方法,其特征在于,所述计算从所述待加工线段的起点以最大加速能力加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线的步骤,包括:The method according to claim 2, wherein said calculating a first acceleration from a starting point of said line segment to be accelerated with a maximum acceleration capability to a user desired target speed and then running at a constant speed of said user desired target speed The steps of the S-curve include:
    确定所述第一S型曲线的运行过程,所述运行过程包括:加加速段、匀加速段、减加速段以及匀速段; Determining an operation process of the first S-shaped curve, the operation process comprising: an acceleration section, a uniform acceleration section, a deceleration section, and a uniform section;
    计算所述运行过程中的加速度a(τ)、速度f(τ)以及位移l(τ),所述加速度a(τ)、速度f(τ)以及位移l(τ)分别为:Calculating the acceleration a(τ), the velocity f(τ), and the displacement l(τ) during the operation, the acceleration a(τ), the velocity f(τ), and the displacement l(τ) are respectively:
    Figure PCTCN2015099244-appb-100001
    Figure PCTCN2015099244-appb-100001
    Figure PCTCN2015099244-appb-100002
    Figure PCTCN2015099244-appb-100002
    Figure PCTCN2015099244-appb-100003
    Figure PCTCN2015099244-appb-100003
    其中,0≤t≤t1是所述加加速段,t1≤t≤≤t2是所述匀加速段,t2≤t≤t3是所述减加速段,t3≤t≤t4是所述匀速段,τ1是所述加加速段的时间累积,τ2是所述匀加速段的时间累积,τ3是所述减加速段的时间累积,τ4是所述匀速段的时间累积,t是总运行过程的时间累积,t1,t2,t3,t4分别是t中的各个时间点,J是系统允许的最大加加速度,A是系统允许的最大加速度,as是初始加速度,fs是初始速度,ls是初始位移。Where 0 ≤ t ≤ t 1 is the acceleration acceleration section, t 1 ≤ t ≤ ≤ t 2 is the uniform acceleration section, and t 2 ≤ t ≤ t 3 is the deceleration acceleration section, t 3 ≤ t ≤ t 4 is the uniform velocity section, τ 1 is the time accumulation of the acceleration acceleration section, τ 2 is the time accumulation of the uniform acceleration section, τ 3 is the time accumulation of the deceleration acceleration section, and τ 4 is the uniform velocity section. Time accumulation, t is the time accumulation of the total running process, t 1 , t 2 , t 3 , t 4 are the respective time points in t, J is the maximum jerk allowed by the system, and A is the maximum acceleration allowed by the system. a s is the initial acceleration, f s is the initial velocity, and l s is the initial displacement.
  6. 根据权利要求5所述的方法,其特征在于,所述判断所述第一S型曲线是否存在速度超出所述限制速度的位置点的步骤,包括:The method according to claim 5, wherein the step of determining whether the first S-curve has a position point whose speed exceeds the limit speed comprises:
    通过所述f(τ)、线段Li的限制速度Fi确定达到所述限制速度Fi所需要的时间ti,并进而确定达到所述限制速度Fi时的位移l和加速度a;By the f (τ), the speed limit of the line segment L i F i is determined to reach the limit time required velocity F i t i, l and thus determining the displacement reaches the limit when the speed and acceleration F i a;
    若a>0,且l<li+1,则判断出所述第一S型曲线在所述线段Li存在速度超出所述限制速度Fi的位置点,所述li+1为所述线段Li的终点到所述待加工线段的起点的距离;或,若a<0,且l>li,则判断出所述第一S型曲线在所述线段Li存在速度超出所述限制速度Fi的位置点,所述li为所述线段Li的起点到所述待加工线段的起点的距离。 If a>0, and l<l i+1 , it is determined that the first S-shaped curve has a speed at which the line segment L i exceeds the limit speed F i , and the l i+1 is Determining the distance from the end point of the line segment L i to the starting point of the line segment to be processed; or, if a<0, and l>l i , determining that the first S-shaped curve has a speed exceeding the line segment L i said speed limit position of the point F i of the l i L i is the starting point of the line segment from the starting point of the line segment to be processed.
  7. 根据权利要求1或2所述的方法,其特征在于,所述调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点的步骤,包括:The method according to claim 1 or 2, wherein said adjusting said first sigmoid curve such that the adjusted second sigmoid curve is finally decelerated to a speed and an acceleration of zero, and The speeds on the line segments to be processed do not exceed the respective limit speeds, and at least one line segment has a step of a speed equal to the constant speed position point of the speed limit, including:
    A1、确定第一时间点tS和第二时间点tE,其中,所述第一时间点tS为所述第一S型曲线的起点时刻t0,所述第二时间点tE为所述第一S型曲线中减加速段的起始时间点;A1, determining a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second time point t E is Deducing a starting time point of the acceleration section in the first S-shaped curve;
    A2、确定第三时间点tM,所述第三时间点tM为所述第一时间点tS和所述第二时间点tE的中间时间点tM
    Figure PCTCN2015099244-appb-100004
    A2. Determine a third time point t M , where the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
    Figure PCTCN2015099244-appb-100004
    A3、对所述第一S型曲线进行调整,使得减加速段的起始时间点T调整为所述第三时间点tM,并在之后尽可能快地减速到加速度和速度降为0,调整后得到的曲线为第四S型曲线;A3. Adjusting the first S-shaped curve so that the starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerating as fast as possible to an acceleration and a speed drop of 0, The adjusted curve is the fourth sigmoid curve;
    A4、判断所述第四S型曲线是否存在速度超出所述限制速度的位置点,如果存在则执行A6,否则执行A5;A4, determining whether the fourth S-curve has a speed point beyond the speed limit, if yes, executing A6, otherwise executing A5;
    A5、判断所述第四S型曲线是否至少有一条线段存在速度等于限制速度的等速位置点,如果有则执行A8,否则执行A7;A5, determining whether the fourth S-shaped curve has at least one line segment having a constant speed position point equal to the speed limit, if yes, executing A8, otherwise executing A7;
    A6、使所述第二时间点tE的值等于所述第三时间点tM,并返回A2;A6, making the value of the second time point t E equal to the third time point t M , and returning to A2;
    A7、使所述第一时间点tS的值等于所述第三时间点tM,并返回A2;A7, the value of the first time point t S is equal to the third time point t M , and returns to A2;
    A8、确定所述第四S型曲线为所述第二S型曲线。A8. Determine that the fourth S-shaped curve is the second S-shaped curve.
  8. 一种S型曲线规划装置,其特征在于,所述装置包括:An S-curve planning device, characterized in that the device comprises:
    第一获取模块,用于获取待加工线段各自对应的限制速度;a first obtaining module, configured to acquire a corresponding limiting speed of the line segments to be processed;
    计算模块,用于计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;a calculation module, configured to calculate a first S-shaped curve that accelerates from a starting point of the line segment to be processed to a desired target speed of the user, and then runs at a constant speed of the target speed desired by the user;
    判断模块,用于判断所述第一S型曲线是否存在速度超出所述限制速度的位置点;a judging module, configured to determine whether the first S-shaped curve has a position point whose speed exceeds the limit speed;
    调整模块,用于在判断结果为存在时,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;And an adjustment module, configured to adjust the first S-shaped curve when the determination result is present, so that the second S-shaped curve obtained after the adjustment is finally decelerated to a speed and an acceleration of zero, and on the line segment to be processed The speeds do not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit;
    第二获取模块,用于取所述第二S型曲线的部分成为第三S型曲线,其中 所述第三S型曲线的起点为所述第二S型曲线的起点,终点为所述等速位置点中首先出现的等速位置点;以所述第三S型曲线的终点为起点再次进行S型曲线规划;a second acquiring module, configured to take a portion of the second S-shaped curve to become a third S-shaped curve, wherein The starting point of the third S-shaped curve is the starting point of the second S-shaped curve, and the ending point is the first constant velocity position point in the constant velocity position; the end point of the third S-shaped curve is used as the starting point. Perform S-shaped curve planning;
    组合模块,用于在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。The combination module is configured to combine the plurality of third sigmoid curves obtained by the planning to form the final S-shaped curve planning data after all the planned segments are planned.
  9. 根据权利要求8所述的装置,其特征在于,所述计算模块具体用于计算从所述待加工线段的起点以最大加速能力加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线。The apparatus according to claim 8, wherein the calculation module is specifically configured to calculate acceleration from a starting point of the line segment to be processed with a maximum acceleration capability to a desired target speed of the user, and then to the target speed desired by the user. The first S-curve running at a constant speed.
  10. 根据权利要求8所述的装置,其特征在于,所述待加工线段各自对应的限制速度的大小为所述待加工线段上各自对应的用户预设目标速度和曲率限制速度中的最小值。The apparatus according to claim 8, wherein the magnitude of the respective limiting speeds of the line segments to be processed is a minimum of the respective preset target speeds and curvature limiting speeds of the respective users on the line segment to be processed.
  11. 根据权利要求10所述的装置,其特征在于,所述曲率限制速度包括由曲率和弓高误差导致的限制速度和由曲率、加速度以及加加速度导致的限制速度。The apparatus of claim 10 wherein said curvature limiting speed comprises a speed limit caused by curvature and bow height errors and a speed limit caused by curvature, acceleration and jerk.
  12. 根据权利要求9所述的装置,其特征在于,所述计算模块包括:The device according to claim 9, wherein the calculation module comprises:
    第一确定单元,用于确定所述第一S型曲线的运行过程,所述运行过程包括:加加速段、匀加速段、减加速段以及匀速段;a first determining unit, configured to determine an operation process of the first S-shaped curve, the operating process includes: an acceleration segment, a uniform acceleration segment, a deceleration segment, and a uniform velocity segment;
    第一计算单元,用于计算所述运行过程中的加速度a(τ)、速度f(τ)以及位移l(τ),所述加速度a(τ)、速度f(τ)以及位移l(τ)分别为:a first calculating unit, configured to calculate an acceleration a(τ), a speed f(τ), and a displacement l(τ) during the running, the acceleration a(τ), the speed f(τ), and the displacement l(τ ) are:
    Figure PCTCN2015099244-appb-100005
    Figure PCTCN2015099244-appb-100005
    Figure PCTCN2015099244-appb-100006
    Figure PCTCN2015099244-appb-100006
    Figure PCTCN2015099244-appb-100007
    Figure PCTCN2015099244-appb-100007
    其中,0≤t≤t1是所述加加速段,t1≤t≤t2是所述匀加速段,t2≤t≤t3是所述减加速段,t3≤t≤t4是所述匀速段,τ1是所述加加速段的时间累积,τ2是所述匀加速段的时间累积,τ3是所述减加速段的时间累积,τ4是所述匀速段的时间累积,t是总运行过程的时间累积,t1,t2,t3,t4分别是t中的各个时间点,J是系统允许的最大加加速度,A是系统允许的最大加速度,as是初始加速度,fs是初始速度,ls是初始位移。Where 0 ≤ t ≤ t 1 is the acceleration acceleration section, t 1 ≤ t ≤ t 2 is the uniform acceleration section, and t 2 ≤ t ≤ t 3 is the deceleration acceleration section, t 3 ≤ t ≤ t 4 Is the uniform velocity segment, τ 1 is the time accumulation of the acceleration acceleration segment, τ 2 is the time accumulation of the uniform acceleration segment, τ 3 is the time accumulation of the deceleration acceleration segment, and τ 4 is the uniform velocity segment Time accumulation, t is the time accumulation of the total running process, t 1 , t 2 , t 3 , t 4 are the respective time points in t, J is the maximum jerk allowed by the system, A is the maximum acceleration allowed by the system, a s is the initial acceleration, f s is the initial velocity, and l s is the initial displacement.
  13. 根据权利要求12所述的装置,其特征在于,所述判断模块包括:The device according to claim 12, wherein the determining module comprises:
    第二确定单元,用于通过所述f(τ)、线段Li的限制速度Fi确定达到所述限制速度Fi所需要的时间ti,并进而确定达到所述限制速度Fi时的位移l和加速度a;Second determining unit, configured to use the f (τ), the speed limit of the line segment L i F i is determined to reach the limit velocity F i of time required t i, thus determining the speed limit reached when F i Displacement l and acceleration a;
    第一结果单元,用于在a>0,且l<li+1时,判断出所述第一S型曲线在所述线段Li存在速度超出所述限制速度Fi的位置点,所述li+1为所述线段Li的终点到所述待加工线段的起点的距离;或,若a<0,且l>li,则判断出所述第一S型曲线在所述线段Li存在速度超出所述限制速度Fi的位置点,所述li为所述线段Li的起点到所述待加工线段的起点的距离。a first result unit, configured to determine, when a>0, and l<l i+1 , that the first sigmoid curve has a speed at which the line segment L i exceeds the limit speed F i l l +1 is the distance from the end point of the line segment L i to the starting point of the line segment to be processed; or, if a < 0, and l > l i , it is determined that the first sigmoid curve is in the The line segment L i has a position point at which the speed exceeds the limit speed F i , and the distance l i is the distance from the start point of the line segment L i to the start point of the line segment to be processed.
  14. 根据权利要求8或9所述的装置,其特征在于,所述调整模块包括:The apparatus according to claim 8 or 9, wherein the adjustment module comprises:
    第三确定单元,用于确定第一时间点tS和第二时间点tE,其中,所述第一时间点tS为所述第一S型曲线的起点时刻t0,所述第二时间点tE为所述第一S型曲线中减加速段的起始时间点;a third determining unit, configured to determine a first time point t S and a second time point t E , wherein the first time point t S is a starting time t 0 of the first S-shaped curve, and the second The time point t E is the starting time point of the deceleration section in the first S-shaped curve;
    第四确定单元,用于确定第三时间点tM,所述第三时间点tM为所述第一时间点tS和所述第二时间点tE的中间时间点tM
    Figure PCTCN2015099244-appb-100008
    a fourth determining unit, configured to determine a third time point t M , wherein the third time point t M is an intermediate time point t M between the first time point t S and the second time point t E ,
    Figure PCTCN2015099244-appb-100008
    调整单元,用于对所述第一S型曲线进行调整,使得减加速段的起始时间点T调整为所述第三时间点tM,并在之后尽可能快地减速到加速度和速度降为0,调整后得到的曲线为第四S型曲线;And an adjusting unit, configured to adjust the first S-shaped curve such that a starting time point T of the deceleration section is adjusted to the third time point t M , and then decelerate to an acceleration and a speed drop as soon as possible thereafter 0, the curve obtained after adjustment is the fourth sigmoid curve;
    第一判断单元,用于判断所述第四S型曲线是否存在速度超出所述限制速度的位置点,如果存在,则进入第一执行单元,否则进入第二判断单元;a first determining unit, configured to determine whether the fourth S-shaped curve has a position where the speed exceeds the limiting speed, if yes, enter the first execution unit, otherwise enter the second determining unit;
    第二判断单元,用于判断所述第四S型曲线是否至少有一条线段存在速度等于限制速度的等速位置点,如果有,则进入第五确定单元,否则进入第二执行单元;a second determining unit, configured to determine whether the fourth S-shaped curve has at least one line segment having a constant speed position point equal to the speed limit, if yes, entering the fifth determining unit, and otherwise entering the second executing unit;
    第一执行单元,用于使所述第二时间点tE的值等于所述第三时间点tM,并返 回所述第四确定单元;a first execution unit, configured to make the value of the second time point t E equal to the third time point t M and return to the fourth determining unit;
    第二执行单元,用于使所述第一时间点tS的值等于所述第三时间点tM,并返回所述第四确定单元;a second execution unit, configured to make the value of the first time point t S equal to the third time point t M , and return to the fourth determining unit;
    第五确定单元,用于确定所述第四S型曲线为所述第二S型曲线。And a fifth determining unit, configured to determine that the fourth S-shaped curve is the second S-shaped curve.
  15. 一种数控机床,其特征在于,所述数控机床包括机床本体和安装在所述机床本体上的数控设备,所述数控设备包括:连接在总线的处理器和存储器;A numerical control machine tool, comprising: a machine tool body and a numerical control device mounted on the machine tool body, the numerical control device comprising: a processor and a memory connected to the bus;
    所述存储器存储有程序,所述处理器用于执行所述程序,所述程序执行时包括如下步骤:The memory stores a program, the processor is configured to execute the program, and the program includes the following steps when executed:
    获取待加工线段各自对应的限制速度;Obtaining a corresponding speed limit of each line segment to be processed;
    计算从所述待加工线段的起点加速到用户期望目标速度、并在之后以所述用户期望目标速度匀速运行的第一S型曲线;Calculating a first S-shaped curve that accelerates from a starting point of the line segment to be processed to a user desired target speed and then runs at a constant speed at the target speed desired by the user;
    判断所述第一S型曲线是否存在速度超出所述限制速度的位置点,如果存在,调整所述第一S型曲线,使得调整后得到的第二S型曲线最终减速到速度和加速度均为零,并且在所述待加工线段上的速度均不超出各自的限制速度,且至少有一条线段存在速度等于限制速度的等速位置点;Determining whether the first S-shaped curve has a position where the speed exceeds the limit speed, and if present, adjusting the first S-shaped curve, so that the second S-shaped curve obtained after the adjustment is finally decelerated to both speed and acceleration Zero, and the speed on the line segment to be processed does not exceed the respective speed limit, and at least one line segment has a constant speed position point whose speed is equal to the speed limit;
    取所述第二S型曲线的部分成为第三S型曲线,其中所述第三S型曲线的起点为所述第二S型曲线的起点,终点为所述等速位置点中首先出现的等速位置点;Taking a portion of the second S-shaped curve into a third S-shaped curve, wherein a starting point of the third S-shaped curve is a starting point of the second S-shaped curve, and an ending point is first appearing in the constant-speed position point Constant velocity position point;
    以所述第三S型曲线的终点为起点再次进行S型曲线规划;S-curve planning is performed again starting from the end point of the third S-shaped curve;
    在所述待加工线段全部规划完毕后,将规划得到的多段第三S形曲线组合形成最终得到的S型曲线规划数据。 After all the planned line segments are completely planned, the planned plurality of third sigmoid curves are combined to form the final S-shaped curve planning data.
PCT/CN2015/099244 2015-12-28 2015-12-28 S-shaped curve planning method and device, and numerically-controlled machine tool WO2017113069A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201580079779.3A CN107850887B (en) 2015-12-28 2015-12-28 S-shaped curve planning method and device and numerical control machine tool
PCT/CN2015/099244 WO2017113069A1 (en) 2015-12-28 2015-12-28 S-shaped curve planning method and device, and numerically-controlled machine tool

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2015/099244 WO2017113069A1 (en) 2015-12-28 2015-12-28 S-shaped curve planning method and device, and numerically-controlled machine tool

Publications (1)

Publication Number Publication Date
WO2017113069A1 true WO2017113069A1 (en) 2017-07-06

Family

ID=59224275

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/099244 WO2017113069A1 (en) 2015-12-28 2015-12-28 S-shaped curve planning method and device, and numerically-controlled machine tool

Country Status (2)

Country Link
CN (1) CN107850887B (en)
WO (1) WO2017113069A1 (en)

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110175339A (en) * 2018-09-20 2019-08-27 北京神工科技有限公司 A kind of the optimal time distribution method and device of the acceleration and deceleration of S type
CN110276134A (en) * 2019-06-24 2019-09-24 国家电网有限公司 The optimum design method of the sulfur hexafluoride pressure gauge rain cover surface curve of transformer
CN110377065A (en) * 2018-08-24 2019-10-25 天津京东深拓机器人科技有限公司 Method for control speed, device and computer readable storage medium
CN111562766A (en) * 2020-05-08 2020-08-21 重庆科技学院 Cross sliding table performance simulation control method and system, storage medium and computer
CN112650145A (en) * 2020-12-24 2021-04-13 苏州谋迅智能科技有限公司 S-shaped speed curve self-adaptive combination evaluation method
CN113156893A (en) * 2021-03-26 2021-07-23 西安交通大学 Five-axis machine tool speed planning method based on S-shaped acceleration and deceleration
CN113359620A (en) * 2021-06-15 2021-09-07 深圳市旗众智能科技有限公司 Soft limit control method for shaft motion and open type motion controller based on RTX64
CN113467368A (en) * 2021-07-15 2021-10-01 苏州谋迅智能科技有限公司 Method for adjusting S-shaped speed curve
CN113534789A (en) * 2021-05-18 2021-10-22 杭州壹悟科技有限公司 Real-time planning method and device for cubic polynomial speed curve of mobile robot
CN113608441A (en) * 2021-08-05 2021-11-05 南京佗道医疗科技有限公司 Position forward-looking self-adaptive puncture control method
CN113941783A (en) * 2021-11-23 2022-01-18 深圳软动智能控制有限公司 Laser axis frog leap implementation method and device, laser equipment and storage medium
CN114019913A (en) * 2021-10-26 2022-02-08 深圳众为兴技术股份有限公司 Speed control method, speed control device, automation equipment, electronic equipment and storage medium
CN114035504A (en) * 2021-11-05 2022-02-11 天津大学 Acceleration and deceleration control method based on time optimization, numerical control system, medium and machine tool
CN114035513A (en) * 2021-09-28 2022-02-11 苏州谋迅智能科技有限公司 S-shaped speed curve look-ahead planning method and device, storage medium and computing device
CN117555291A (en) * 2024-01-11 2024-02-13 佛山德玛特智能装备科技有限公司 Interpolation method, interpolation device, interpolator and medium

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108829044B (en) * 2018-07-27 2020-12-08 山东大学 S-curve acceleration and deceleration planning method for coping with negative values of starting and ending speeds
CN110000794B (en) * 2019-05-06 2022-08-23 江苏集萃智能制造技术研究所有限公司 Truncation type asymmetric speed planning method based on cooperative robot
CN110109491A (en) * 2019-05-30 2019-08-09 深圳市众为创造科技有限公司 Continuous S curve acceleration and deceleration motion control method, system and electronic equipment
CN112327954B (en) * 2020-11-14 2021-11-26 大连理工大学 High-precision positioning method for linear motor controlled by asymmetric S-shaped speed curve
CN115922687B (en) * 2022-05-23 2023-11-17 以诺康医疗科技(苏州)有限公司 Motion trail planning method and device based on S-shaped speed curve
CN115993854B (en) * 2023-03-21 2024-05-10 上海果纳半导体技术有限公司 SMIF (SMIF) open-close device control method, SMIF open-close device control device and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6920363B2 (en) * 2000-10-18 2005-07-19 Fanuc Ltd Acceleration and deceleration control method
CN103076759A (en) * 2012-12-31 2013-05-01 北京配天大富精密机械有限公司 Method and device for acquiring S-shaped curve of numerical control system
CN104950821A (en) * 2015-06-25 2015-09-30 哈尔滨工业大学 Numerical control system velocity planning method based on fractional calculus

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101539769B (en) * 2009-04-28 2010-08-25 中国科学院数学与系统科学研究院 Method for fitting and interpolating G01 code based on quadratic B spline curve
KR100994741B1 (en) * 2010-05-04 2010-11-16 주식회사 덕인 The method of measuring unknown curve with measurement step optimization based on the surface curvature using 3 dimensional coordinate measuring machine
CN102298358B (en) * 2011-04-30 2013-05-01 上海交通大学 NURBS tool path speed planning method for five-axis numerical control machining
CN103760823B (en) * 2014-01-24 2016-05-18 哈尔滨第一机械集团有限公司 The meticulous spiral of Archimedes processing method of sphere based on UG4.0
CN104076742B (en) * 2014-06-20 2016-12-07 北京航空航天大学 A kind of prediction planing method of polymorphic type curved section mixing interpolation cubic polynomial feed speed continuously
CN104181860B (en) * 2014-08-25 2016-09-07 浙江理工大学 Digit Control Machine Tool S type Acceleration-deceleration Control Method
CN104732292B (en) * 2015-03-25 2019-02-01 武汉大学 Principal flow velocity line automatic planning based on profile data

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6920363B2 (en) * 2000-10-18 2005-07-19 Fanuc Ltd Acceleration and deceleration control method
CN103076759A (en) * 2012-12-31 2013-05-01 北京配天大富精密机械有限公司 Method and device for acquiring S-shaped curve of numerical control system
CN104950821A (en) * 2015-06-25 2015-09-30 哈尔滨工业大学 Numerical control system velocity planning method based on fractional calculus

Cited By (24)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110377065A (en) * 2018-08-24 2019-10-25 天津京东深拓机器人科技有限公司 Method for control speed, device and computer readable storage medium
CN110175339A (en) * 2018-09-20 2019-08-27 北京神工科技有限公司 A kind of the optimal time distribution method and device of the acceleration and deceleration of S type
CN110175339B (en) * 2018-09-20 2023-01-10 北京神工科技有限公司 Optimal time distribution method and device for S-type acceleration and deceleration
CN110276134A (en) * 2019-06-24 2019-09-24 国家电网有限公司 The optimum design method of the sulfur hexafluoride pressure gauge rain cover surface curve of transformer
CN110276134B (en) * 2019-06-24 2022-11-29 国家电网有限公司 Optimal design method for surface curve of rain cover of sulfur hexafluoride pressure instrument of transformer
CN111562766A (en) * 2020-05-08 2020-08-21 重庆科技学院 Cross sliding table performance simulation control method and system, storage medium and computer
CN112650145A (en) * 2020-12-24 2021-04-13 苏州谋迅智能科技有限公司 S-shaped speed curve self-adaptive combination evaluation method
CN113156893A (en) * 2021-03-26 2021-07-23 西安交通大学 Five-axis machine tool speed planning method based on S-shaped acceleration and deceleration
CN113156893B (en) * 2021-03-26 2023-08-01 西安交通大学 Five-axis machine tool speed planning method based on S-shaped acceleration and deceleration
CN113534789A (en) * 2021-05-18 2021-10-22 杭州壹悟科技有限公司 Real-time planning method and device for cubic polynomial speed curve of mobile robot
CN113534789B (en) * 2021-05-18 2024-04-05 杭州壹悟科技有限公司 Method and device for real-time planning of three-time polynomial speed curve of mobile robot
CN113359620A (en) * 2021-06-15 2021-09-07 深圳市旗众智能科技有限公司 Soft limit control method for shaft motion and open type motion controller based on RTX64
CN113359620B (en) * 2021-06-15 2022-03-15 深圳市旗众智能科技有限公司 Soft limit control method for shaft motion and open type motion controller based on RTX64
CN113467368A (en) * 2021-07-15 2021-10-01 苏州谋迅智能科技有限公司 Method for adjusting S-shaped speed curve
CN113608441A (en) * 2021-08-05 2021-11-05 南京佗道医疗科技有限公司 Position forward-looking self-adaptive puncture control method
CN114035513A (en) * 2021-09-28 2022-02-11 苏州谋迅智能科技有限公司 S-shaped speed curve look-ahead planning method and device, storage medium and computing device
CN114019913B (en) * 2021-10-26 2024-04-09 深圳众为兴技术股份有限公司 Speed control method, speed control device, automation device, electronic device and storage medium
CN114019913A (en) * 2021-10-26 2022-02-08 深圳众为兴技术股份有限公司 Speed control method, speed control device, automation equipment, electronic equipment and storage medium
CN114035504A (en) * 2021-11-05 2022-02-11 天津大学 Acceleration and deceleration control method based on time optimization, numerical control system, medium and machine tool
CN114035504B (en) * 2021-11-05 2024-03-19 天津大学 Acceleration and deceleration control method based on time optimization, numerical control system, medium and machine tool
CN113941783B (en) * 2021-11-23 2023-11-21 深圳软动智能控制有限公司 Laser axis frog-leaping realization method, device, laser equipment and storage medium
CN113941783A (en) * 2021-11-23 2022-01-18 深圳软动智能控制有限公司 Laser axis frog leap implementation method and device, laser equipment and storage medium
CN117555291A (en) * 2024-01-11 2024-02-13 佛山德玛特智能装备科技有限公司 Interpolation method, interpolation device, interpolator and medium
CN117555291B (en) * 2024-01-11 2024-03-22 佛山德玛特智能装备科技有限公司 Interpolation method, interpolation device, interpolator and medium

Also Published As

Publication number Publication date
CN107850887A (en) 2018-03-27
CN107850887B (en) 2020-06-02

Similar Documents

Publication Publication Date Title
WO2017113069A1 (en) S-shaped curve planning method and device, and numerically-controlled machine tool
CN108549328B (en) Self-adaptive speed planning method and system
CN109623166B (en) Corner processing method and system for laser cutting
CN107505918B (en) Speed planning method of cutting machine
JP6257796B2 (en) Tool path generation method and machine tool
CN107765648B (en) CNC machining feeding speed planning method and device
JP5417392B2 (en) Numerical controller
CN107710084B (en) Machining path planning method, machining path planning device and numerical control machine tool
US9651939B2 (en) Numerical controller having display function of physical data of machine tool
CN104678899A (en) Curve velocity planning method and device, as well as numerical control machining path data processing method
CN110874082B (en) Method, apparatus and storage medium for determining cutting path of workpiece corner
JP2011096077A (en) Method and device for generating tool path
CN105045211B (en) One kind etc. bends high error variable step tangent line interpolating method
CN102375431A (en) Tool path display apparatus with deceleration factor identification means for machine tool
CN112486101B (en) NURBS curve self-adaptive look-ahead interpolation method
CN103801981A (en) Quartic polynomial speed planning algorithm for spline interpolation
WO2020124606A1 (en) Numerical control processing method, system and device having storage function
CN113231735A (en) Cutting head obstacle avoidance method and device, computer equipment and medium
CN105629882A (en) Trigonometric function speed planning method used for spline interpolation
CN111045461B (en) Continuous small line segment discrete speed control method for cutting bed
JP2004058190A (en) Machining time estimation method and device
CN116985136A (en) Quaternion-based mechanical arm node attitude speed look-ahead control method and device
JP2790643B2 (en) Numerical control unit
CN109564417A (en) The interpolating method and relevant device of Spline Path
CN110726511A (en) Centroid calculation method of inertial navigation system with rotating mechanism

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15911700

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15911700

Country of ref document: EP

Kind code of ref document: A1