1. Field of Invention
The invention relates to a motion command reshaping technology, and more particularly to a motion command reshaping method with analog input for position s curve.
2. Related Art
Due to the differences of friction and load inertia, the servo modules usually need different time settings for acceleration and deceleration during a motion control period; accordingly, the motion command is usually reshaped by a command generator in motion to satisfy the physical properties when operating. Nowadays, the dominant reshaping method for motion command is the way of equation.
Generally speaking, a point-to-point motion is operated by an upper controller or a dedicated controller to reshape the motion command, and then positioned by inputting in the form of pulse wave. However, the required position equation should be deduced through parameters planed previously; therefore a high mathematic operation is still necessary in use. Alternatively, it should be combined with a pulse wave generating device, for example, a digital differential analyzer, to generate a point-to-point positioning pulse wave.
However, in order to obtain the position command, users need to set architecture with dedicated functions, or to utilize high-speed operation units and mathematical calculator of high resolution, to make a high mathematic operation. Otherwise, such a function cannot be realized. In addition, when the position command generator has to be combined with a pulse wave generating device, it indicates that the resolution provided by the position command generator is insufficient. Furthermore, the digital differential analyzer is mainly used for providing output of uniform pulse wave during a time period, thus the users have to construct it with the combination of other hardware to realize this function, such that a zero-error output is obtained. However, in this case, users have to afford the cost of said hardware additionally.
In view of the above-mentioned problems, it is the main object of the invention to provide a motion command reshaping method with analog input for position s curve, thereby the problems in the prior art is substantially solved.
The motion command reshaping method with analog input for position s curve disclosed in the present invention adopts an accumulating and asymmetric architecture and processing of reference point to construct various motion command reshaping devices for position s curve.
The motion command reshaping method with analog input for position s curve disclosed in the present invention utilizes architecture of post-acceleration/deceleration, to be applied in the servo driver.
The motion command reshaping method with analog input for position s curve disclosed in the present invention may keep the velocity and the acceleration continual, and have the velocity changed uniformly during acceleration or deceleration.
The motion command reshaping method with analog input for position s curve disclosed in the present invention may avoid the delayed arrival of the motion command when the complete time setting is satisfied.
The motion command reshaping method with analog input for position s curve disclosed in the present invention has a velocity modifying process after completing the acceleration.
Therefore, to achieve the above objects, the motion command reshaping method with analog input for position s curve disclosed in the present invention comprises the steps of: first defining a first position reference point and calculating the basic accumulation of acceleration and deceleration according to the time setting; then checking the state of the internal command, to initialize the state when the acceleration and the velocity is zero; determining the processing program according to the external input command and the moving direction; next performing calculation of acceleration; then performing calculation of velocity according to the calculated acceleration; and thereby generating a motion command for position s curve; finally, going on to carry out state processing.
In which, when the external input command is an increment position command, if it moves in a positive direction, a second position reference point will be recalculated; otherwise, if the increment position command moves in a negative direction, the processing program is set to enter into the third block. When the external input command is an absolute position command, if the external position command and the moving direction are the same, the second position reference point will be recalculated; otherwise, when in the first block, it enters into the second block, while in the second block, into the third block.
Further, if the state of the velocity is acceleration, the calculation of the acceleration will be made through the basic accumulation of acceleration; if the state of the velocity is deceleration, the calculation of the acceleration will be made through the basic accumulation of deceleration; and when in the first block, the operation will be made through the basic accumulation of deceleration to calculate the mirror acceleration of the third block, in the same calculation method with the calculation of the acceleration.
Thus, the calculation method of velocity is the sum of the last velocity command and the acceleration. And the mirror velocity of the third block (i.e. sum of the last mirror velocity and mirror acceleration) is calculated when in the first block.
In addition, the motion command for position s curve is the sum of the last motion command for position s curve and the velocity value. And the mirrored position of the third block (i.e. sum of the last mirrored position and mirror velocity) is calculated when in the first block.
The state process is performed as follows. At first, a velocity command reference point is calculated with reference to a moving velocity or a target velocity, to ensure whether the velocity reaches the velocity command reference point or not. After that, when in the first block, the predetermined position is calculated to see whether it reaches half of the first position command reference point or not, to determine whether the velocity should enter into the end section of the first block symmetrically about the center. Then, when the velocity reaches the velocity command reference point or the predetermined position reaches half of the first position command reference point, the velocity and the acceleration enter into the end section of the first block symmetrically about the center; when the mirrored position reaches the first position command reference point, the second position command reference point is calculated; when the position reaches the second position command reference point, it enters into the third block; and when in the third block, when the velocity reaches half of the moving velocity, the velocity and the acceleration symmetrically enter into the end section of the third block.
The present invention and practice will be described in detail accompanying with the most preferable embodiment.
Further scope of applicability of the present invention will become apparent from the detailed description given hereinafter. However, it should be understood that the detailed description and specific examples, while indicating preferred embodiments of the invention, are given by way of illustration only, since various changes and modifications within the spirit and scope of the invention will become apparent to those skilled in the art from this detailed description.
The present invention will become more fully understood from the detailed description given herein below for illustration only, and thus are not limitative of the present invention, and wherein:
First, the main conception of the present invention is illustrated. In the present invention, the calculation of low mathematical operation and high resolution is provided by accumulating operation, to reshape the motion command, thereby satisfying the required response time during acceleration/deceleration. Furthermore, in the present invention, the conception of a motion command reshaping generator for velocity s curve is used for reshaping the position command, to be applied in reshaping any kind of position command, for example the way of inputting command of analog type, pulse wave type or register type.
Hereinafter, specific embodiments will be given to describe the content of the present invention in details, with the assistance of the drawings. The symbols referred in the description are referred to the symbols in the drawings.
As shown in
According to the principle of the present invention, the accumulating and asymmetric architecture is adopted with the velocity or the position as a reference point, to decide whether the block to be entered has been arrived or not, and the velocity curve and the acceleration curve are set to be symmetric about the center. Therefore, the velocity and the acceleration may be continuous in any state. In other words, the velocity curve in the acceleration block (i.e., the first block BLOCK1) is symmetric about the center, while in the deceleration block (i.e., the third block BLOCK3) is symmetric; and, the acceleration curve in the front and back sections in the acceleration block and the deceleration block (i.e., the initial section SECT1and the end sectionSECT3) is symmetric about the center respectively.
With reference to
In fact, Step120 through Step170 are carried out repeatedly before the operation is stopped to keep the reshaping of the motion command for position s curve.
In this embodiment, the acceleration/deceleration is set according to the state of the motor velocity, and the basic accumulation of acceleration is used during acceleration, while the basic accumulation of deceleration is used during deceleration. The basic accumulation of acceleration is (rated velocity/accelerated time constant TACC)/TSL, while the basic accumulation of deceleration is (rated velocity/decelerated time constant TDEC)/TSL.
In Step110, the first position reference point may be set to a quarter of the displacement.
The processing program is determined according to the external input command and the moving direction (Step130). When the external input command is an increment position command, if the increment position command moves in the positive direction, the second position reference point P2 will be recalculated. On the other hand, if the increment position command moves in the negative direction, the processing program will be set to enter into the third block BLOCK3. In addition, when the external input command is an absolute position command, if the external position command and moving direction are the same, the second position reference point P2 will be recalculated. On the other hand, the processing program is decided according to the block it belongs. Namely, when in the first block BLOCK1, the processing program is set to enter into the second block BLOCK2, while in the second block BLOCK2, into the third block BLOCK3.
During the step of the calculation of the acceleration (Step 140), the acceleration is increasing in the initial section SECT1, and is decreasing in the end section SECT3. The section it presents is determined depending on the calculated value. In which, when the calculated value is larger than the smooth time constant TSL, it indicates that the processing program has entered in the intermediate section SECT2; when the velocity command reaches the first velocity command reference point S1, it indicates that the processing program has not entered in the end section SECT3 yet.
As shown in
In the step of making the calculation of the velocity according to the acceleration calculated (Step 150), the velocity is the sum of the last velocity command and the acceleration. And when in the first block BLOCK1, the mirrored velocity of the third block BLOCK3, the sum of the last mirror velocity and the mirror acceleration, is calculated.
In which, the step of reshaping motion command for position s curve according to velocity (Step 160) is the sum of the last motion command for position s curve and the velocity value. And when in the first block BLOCK1, the mirrored position of the third block BLOCK3, the sum of the last mirrored position and the mirrored velocity, is calculated.
After the motion command for position s curve is reshaped, the state processing is continued (Step 170) in the following steps as shown in
With reference to
Then, when in the first block BLOCK1, whether the predetermined position reaches half of the first position command reference point P1 is calculated, to decide whether the velocity should enter into the end section SECT3 of the first block BLOCK1 symmetrically about the center (Step 172). In which, when the accelerated time constant TACC is larger than the decelerated time constant TDEC, the predetermined position is transformed with the mirrored position; on the other hand, when the decelerated time constant TDEC is larger than the accelerated time constant TACC, the predetermined position is transformed with the position command. Namely, when the accelerated time constant TACC is lager than the decelerated time constant TDEC, the mirrored position will be reckoned through the velocity, and the reckoned value is added with the position command, then compared to half of the first position command reference point P1; on the other hand, when the decelerated time constant TDEC is larger than the accelerated time constant TACC, the position command is reckoned through the velocity, and the reckoned value is add with the mirrored position, then compared to half of the first position command reference point P1.
When the state processing meets Step 171 or Step 172, the velocity and the acceleration enter into the end section SECT3 of the first block BLOCK1 symmetrically about the center (Step 173)
When the mirrored position reaches the first position command reference point P1, the second position command reference point P2 is calculated, which is difference between the target value and the first position command reference point P1 (Step 174).
When the position, i.e., the position of the practical movement, reaches the second position command reference point P2, the processing program is entering into the third block BLOCK3 (Step 175).
In the third block BLOCK3, if the velocity reaches half of the moving velocity, the velocity and the acceleration will enter into the end section SECT3 of the third block BLOCK3 symmetrically about the center (Step 176).
With reference to
According to the principle of the present invention, the motion command reshaping method with analog input for position s curve disclosed in the present invention adopts an accumulating and asymmetric architecture and processing of reference point to construct various motion command reshaping devices for velocity s curve; and it utilizes architecture of post-acceleration/deceleration to apply in the servo driver; and it keeps the velocity and the acceleration continual, and have the velocity changed uniformly during acceleration or deceleration. In addition, the motion command reshaping method with analog input for position s curve disclosed in the present invention may avoid the delayed arrival of the motion command when satisfying the time setting. Further, it has a velocity changing process after completing the acceleration.
The present invention is applied in the servo driver to provide a complete and simplified motion command reshaping unit for position s curve, which provides functions comprising: a motion command reshaping device for position s curve with analog input, a motion command reshaping device for position s curve with pulse wave input, a motion command reshaping device for position s curve with absolute input, a motion command reshaping device for s position with increment register, and a fixed-point number calculator of low operation and low bit. The servo driver may offer a complete solution with various command processing modes even without the support of an upper controller.
The invention being thus described, it will be obvious that the same may be varied in many ways. Such variations are not to be regarded as a departure from the spirit and scope of the invention, and all such modifications as would be obvious to one skilled in the art are intended to be included within the scope of the following claims.
Number | Date | Country | Kind |
---|---|---|---|
94127224 | Aug 2005 | TW | national |