Numerical controller, machine tool, numerical control method, and numerical control program
By adopting the reverse interpolation processing in the numerical control device, the problem of large amount of acceleration and deceleration calculation and long movement time in the prior art is solved, and the effect of maximum speed deceleration at the command point of the target block is achieved.
Patent Information
- Application Number
- CN202380065031.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2022-09-12
- Filing Date
- 2023-08-29
- Publication Date
- 2025-04-18
AI Technical Summary
During the acceleration and deceleration process, the conventional numerical control device has a large calculation amount and may cause the movement time of the moving part to become longer. Especially when the interval width is large, it is difficult to accurately match the allowable values of velocity and acceleration.
By introducing a reverse interpolation process into the numerical control device, the reverse interpolation point is calculated and the corresponding acceleration and deceleration process is performed to maximize the speed of the moving part, while ensuring that the speed can be decelerated to the target speed at the command point of the target block.
The increase in the calculation amount before the acceleration and deceleration process is effectively suppressed, and the movement time of the moving part is avoided to be longer, ensuring that the moving part can decelerate at the command point of the target block at the maximum speed.
Smart Images

Figure CN119856123A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a numerical control device, a working machine, a numerical control method and a numerical control program. Background Art
[0002] For example, a machine sometimes causes a moving part to move based on a numerical control (NC) program. In such a case, when the machine causes the speed or acceleration of the moving part to change drastically, for example, the machine may fail or the moving part may vibrate, which may cause an undesirable condition such as deviation from the ideal moving path. Similarly, when the machine causes the moving part to move at high speed, an undesirable condition may occur. Therefore, in order to suppress the occurrence of undesirable conditions, limits are set on the speed, acceleration, and jerk (acceleration) of the moving part. The machine performs acceleration and deceleration processing on the moving part so that the actual speed, acceleration, and jerk of the moving part do not exceed the set limits.
[0003] For example, the numerical control device described in Patent Document 1 performs acceleration and deceleration processing before interpolation in the front end point control. In the numerical control device, in the programming coordinate system and the mechanical coordinate system on the path, the allowable value is set for the speed, acceleration and jerk of each axis. The numerical control device calculates the allowable values of the speed, acceleration and jerk of the front end point on each interval after the moving path is divided. The numerical control device calculates a speed curve that does not exceed the calculated allowable value on the moving path, and performs acceleration and deceleration processing according to the calculated speed curve.
[0004] Prior art literature
[0005] Patent Literature
[0006] Patent Document 1: Japanese Patent Application Publication No. 2013-97736 Summary of the invention
[0007] Problems to be solved by the invention
[0008] In the numerical control device, the permissible values of speed and acceleration in each interval are fixed by the calculated permissible values. The ideal permissible values of speed and acceleration are not necessarily constant in each interval. Therefore, if the width of the interval is wide, there may be a difference between the calculated permissible value and the ideal permissible value. That is, since the speed has not risen to the ideal speed, or it takes time for the speed to reach the ideal speed, the moving time of the moving part may be longer. On the other hand, when the width of the interval is reduced in order to reduce the difference between the calculated permissible value and the ideal permissible value, the amount of calculation used to calculate the speed curve before the acceleration and deceleration process may increase.
[0009] The object of the present invention is to provide a numerical control device, a working machine, a numerical control method and a numerical control program, which help to suppress the amount of calculation used to calculate the speed curve before acceleration and deceleration processing while suppressing the advantage of increasing the moving time of the moving part.
[0010] Technical means of solving problems
[0011] The numerical control device of technical solution 1 reads an NC program including a plurality of blocks representing instruction points in a moving path of a moving part that moves relative to an object, and processes the plurality of blocks in sequence, thereby controlling the position and speed of the moving part. The numerical control device is characterized in that it includes: a reading unit that reads a current block that becomes a processing object among the plurality of blocks, and a pre-read block that is processed later than the current block among the plurality of blocks; a determination unit that determines a target block that becomes a target among the current block and the pre-read block read by the reading unit, and determines a target speed of the moving part at the instruction point of the determined target block, that is, a target speed. a first calculation unit, which calculates the speed of the moving unit at a first rising point, i.e., a first rising speed, based on a maximum jerk as an upper limit of an allowable jerk, a current speed of the moving unit, and a current acceleration of the moving unit in the moving path of the moving unit, wherein the first rising point is a position where the acceleration of the moving unit changes from the current acceleration of the moving unit to a first specified acceleration; and a reverse interpolation unit, which performs reverse interpolation processing, wherein the reverse interpolation processing is to sequentially calculate the reverse interpolation points as the positions where the moving unit moves, from the instruction point of the target block determined by the determination unit toward the starting point of the current block in the moving path of the moving unit. The reverse interpolation point calculated initially, i.e., the initial reverse interpolation point, the speed of the moving part at the initial reverse interpolation point, and the acceleration of the moving part at the initial reverse interpolation point are respectively the instruction point of the target block, the target speed, and the second prescribed acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is a position where the moving part moves an amount during a prescribed time based on the speed of the moving part and the acceleration of the moving part at the current reverse interpolation point, the maximum acceleration as the upper limit of the permissible acceleration, and the speed of the maximum jerk; and a second calculation unit calculates, in the moving path of the moving part, , whenever the reverse interpolation unit calculates the reverse interpolation point, from the reverse interpolation point toward the starting point of the current block, based on the maximum jerkiness, the speed of the moving part at the reverse interpolation point calculated by the reverse interpolation unit, and the acceleration of the moving part at the reverse interpolation point, the speed of the moving part at a second rising point, i.e., a second rising speed, is calculated, the second rising point being a position where the acceleration of the moving part becomes a third specified acceleration from the acceleration of the moving part at the reverse interpolation point, and the reverse interpolation unit calculates the reverse interpolation point until the second rising speed calculated by the second calculation unit becomes greater than the first rising speed calculated by the first calculation unit.
[0012] According to the numerical control device of technical solution 1, the reverse interpolation unit calculates the reverse interpolation point until the second rising speed becomes greater than the first rising speed. By performing the acceleration and deceleration processing corresponding to the reverse interpolation unit, even if the speed of the moving part is increased to the maximum on the moving path, the moving part can be prevented from not decelerating to the target speed at the instruction point of the target block. Therefore, the numerical control device can easily move the moving part at the maximum speed at which the moving part can decelerate to the target speed at the instruction point of the target block. Furthermore, the reverse interpolation unit calculates the reverse interpolation point while performing the acceleration and deceleration processing, and calculates the speed curve of the moving part. Therefore, in the case of performing the acceleration and deceleration processing using the reverse interpolation unit, it is easier to suppress the amount of calculation obtained by the numerical control device before the acceleration and deceleration processing, compared with the case of calculating the speed curve of the moving part for the acceleration and deceleration processing. Therefore, the reverse interpolation unit helps to suppress the amount of calculation used to calculate the speed curve before the acceleration and deceleration processing, while suppressing the advantage of the moving time of the moving part becoming longer.
[0013] The numerical control device of technical solution 2 may also include: a third calculation unit, which calculates the starting speed, wherein the starting speed is the upper limit of the allowable speed of the moving unit at the starting point of the pre-read block; and a first judgment unit, which judges whether there is a transfer block whose starting speed is less than the second rising speed in the pre-read block in the processing order between the pre-read block that is later than the current block in the processing order and the pre-read block to which the second rising point belongs. When the first judgment unit judges that the transfer block exists, the decision unit determines the block that is earlier than the transfer block with the smallest starting speed in the processing order as the target block, and determines the smallest starting speed of the transfer block as the target speed.
[0014] In the above case, reverse interpolation is performed at the command point of the newly determined target block so that the moving unit can be decelerated to the starting speed of the pre-read block after the target block, which is newly determined as the target speed. Therefore, the decision unit complies with the upper limit of the allowable speed of the moving unit at the command point of the block, which contributes to the advantage of suppressing the amount of calculation for calculating the speed curve of the moving unit before the acceleration and deceleration process, and suppressing the movement time of the moving unit from being prolonged.
[0015] The numerical control device of technical solution 3 may also include: a second judgment unit, when the moving distance of the moving unit in the direction from the current position of the moving unit in the current block toward the instruction point of the target block is set to positive, and the moving distance of the moving unit in the direction from the instruction point of the target block toward the current position of the moving unit in the current block is set to negative, the moving distance of the moving unit from the current position of the moving unit in the current block to the first rising point, the moving distance of the moving unit from the second rising point to the reverse interpolation point, and the moving distance from the reverse A first speed control unit is configured to control the speed of the moving part by a maximum deceleration as an upper limit of the allowable deceleration and a deceleration based on the maximum jerk, so that the speed of the moving part will not be less than the target speed, when the second judgment unit judges that the total distance is greater than the moving margin.
[0016] In the above case, the first speed control unit controls the speed of the moving unit to the maximum within the range of the permissible deceleration and jerk, and controls the speed of the moving unit in a manner of decelerating to the target speed at the command point of the target block, thereby suppressing the deceleration time of the moving unit from becoming longer. Therefore, the numerical control device can easily ensure a long acceleration time of the moving unit. Therefore, the first speed control unit has the advantage of helping to suppress the moving time of the moving unit from becoming longer.
[0017] The numerical control device of technical solution 4 may also include: a second judgment unit, which, when the moving distance of the moving unit in the direction from the current position of the moving unit in the current block toward the instruction point of the target block is set to positive and the moving distance of the moving unit in the direction from the instruction point of the target block toward the current position of the moving unit in the current block is set to negative, calculates the total distance of the moving unit from the current position of the moving unit in the current block to the first rising point, the moving distance of the moving unit from the second rising point to the reverse interpolation point, and the moving distance of the moving unit from the reverse interpolation point to the instruction point of the target block. A fourth calculation unit is used to calculate a speed limit, wherein the speed limit is a maximum speed that complies with an upper limit of an allowable speed of the moving part at each interpolation point on the moving path; and a second speed control unit is used to control the speed of the moving part with the maximum acceleration and the acceleration based on the maximum jerk, when the second judgment unit determines that the total distance is not greater than the moving margin, so that the speed of the moving part at the first rising point does not exceed the speed limit at the first rising point calculated by the fourth calculation unit.
[0018] In the above case, the second speed control unit controls the speed of the moving unit to the maximum within the range of the permissible acceleration and jerk so that the speed of the moving unit at the first ascending point does not exceed the limit speed at the first ascending point. Therefore, the second speed control unit helps to suppress the moving time of the moving unit from being prolonged.
[0019] In the numerical control device of technical solution 5, it may also be that, when the number of the multiple blocks is greater than the number corresponding to the prescribed order, the reading unit reads in as the pre-read blocks in sequence from the block that is one block later in the processing order than the current block to the block that is after the current block in the processing order after the prescribed order, i.e., the pre-read end block, and when the reading unit reads in the pre-read end block, the reverse interpolation unit calculates the reverse interpolation point.
[0020] In this case, the reverse interpolation unit does not calculate the reverse interpolation point every time the reading unit reads the pre-read blocks one by one. Therefore, the reverse interpolation unit has the advantage of suppressing an increase in the processing load required for calculating the reverse interpolation point.
[0021] The numerical control device of technical solution 6 may also include a block processing unit, which controls the position and speed of the moving unit by processing the current block read by the reading unit. When the block processing unit processes up to the instruction point of the current block, the reading unit newly reads a next block whose processing order is later than the block processed by the block processing unit as the current block as the current block, and newly reads the block after the next block through the prescribed order as the pre-read end block. When the reading unit newly reads the pre-read end block, the determination unit newly determines the target block and newly determines the target speed.
[0022] In the above case, each time the block processing unit processes the current block, the reading unit reads a new block as a pre-read block. That is, the reading unit does not always read all of the multiple blocks at once as pre-read blocks. Therefore, the reading unit contributes to the advantage of suppressing the control load required for reading the pre-read blocks.
[0023] The working machinery of Technical Solution 7 is characterized in that it includes: a numerical control device according to Technical Solution 1; a holding portion for holding a workpiece; and a spindle equipped with a tool for processing the workpiece, and the workpiece held by the holding portion is processed using at least three linear axes and one rotating axis, the moving path is determined according to the relative position of the front end of the tool relative to the workpiece, the maximum jerk is the upper limit of the relative jerk of the front end of the tool relative to the workpiece, the maximum acceleration is the upper limit of the relative acceleration of the front end of the tool relative to the workpiece when the respective accelerations of the linear axis and the rotating axis are respectively below the respective allowable accelerations of the linear axis and the rotating axis, and the speed of the moving portion is determined according to the relative speed of the front end of the tool relative to the workpiece.
[0024] The working machine of technical solution 7 contributes to the same advantages as the numerical control device of technical solution 1.
[0025] The machine tool of claim 8 may include the three linear axes and two rotation axes for rotating the holding portion.
[0026] In such cases, the machine tool contributes to the advantage of performing complex processing.
[0027] The machine tool of claim 9 may include the three linear axes and two rotation axes for changing the posture of the spindle relative to the workpiece.
[0028] In such cases, the machine tool contributes to the advantage of performing complex processing.
[0029] The machine tool according to claim 10 may include the three linear axes, one rotation axis for changing the posture of the spindle relative to the workpiece, and one rotation axis for rotating the holding portion.
[0030] In such cases, the machine tool contributes to the advantage of performing complex processing.
[0031] The numerical control method of technical solution 11 is performed by a numerical control device, which reads an NC program including multiple blocks representing instruction points in a moving path of a moving part that moves relative to an object, and processes the multiple blocks in sequence, thereby controlling the position and speed of the moving part. The numerical control method is characterized in that it includes: a reading process, reading a current block that becomes a processing object among the multiple blocks, and a pre-read block among the multiple blocks whose processing order is later than the current block; a determination process, determining a target block that becomes a target among the current block and the pre-read block read by the reading process, and determining the instruction point of the determined target block. The target speed of the moving unit at the command point is the target speed; the first calculation processing is to calculate the speed of the moving unit at the first rising point, that is, the first rising speed, based on the maximum jerkiness as the upper limit of the allowable jerkiness, the current speed of the moving unit, and the current acceleration of the moving unit in the moving path of the moving unit. The first rising point is the position where the acceleration of the moving unit changes from the current acceleration of the moving unit to the first specified acceleration; the reverse interpolation processing is to sequentially calculate the reverse interpolation points as the positions where the moving unit moves, from the command point of the target block determined by the determination processing toward the starting point of the current block in the moving path of the moving unit. Processing, and the initially calculated reverse interpolation point, that is, the initial reverse interpolation point, the speed of the moving part at the initial reverse interpolation point, and the acceleration of the moving part at the initial reverse interpolation point are respectively the instruction point of the target block, the target speed, and the second specified acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is the following position: the amount of movement of the moving part during the specified time based on the speed of the moving part and the acceleration of the moving part at the current reverse interpolation point, the maximum acceleration as the upper limit of the allowable acceleration, and the speed movement of the maximum jerk; and the second calculation processing, in the moving path of the moving part, Whenever the reverse interpolation process calculates the reverse interpolation point, the speed of the moving part at the second rising point, i.e., the second rising speed, is calculated from the reverse interpolation point toward the starting point of the current block based on the maximum jerkiness, the speed of the moving part at the reverse interpolation point calculated by the reverse interpolation process, and the acceleration of the moving part at the reverse interpolation point. The second rising point is the position where the acceleration of the moving part becomes a third specified acceleration from the acceleration of the moving part at the reverse interpolation point. The reverse interpolation process calculates the reverse interpolation point until the second rising speed calculated by the second calculation process becomes greater than the first rising speed calculated by the first calculation process.
[0032] The numerical control method of technical solution 11 contributes to the same advantages as the numerical control method of technical solution 1.
[0033] The numerical control program of technical solution 12 is characterized in that a computer of the numerical control device that reads an NC program including a plurality of blocks representing instruction points in a moving path of a moving part that moves relative to an object and processes the plurality of blocks in sequence, thereby controlling the position and speed of the moving part, executes the following processing: a reading process of reading a current block that becomes a processing object among the plurality of blocks and a pre-read block that is processed later than the current block among the plurality of blocks; a determination process of determining a target block that becomes a target among the current block and the pre-read block read by the reading process, and determining the instruction point of the determined target block a first calculation process, in the moving path of the moving unit, based on the maximum jerkiness as the upper limit of the permissible jerkiness, the current speed of the moving unit, and the current acceleration of the moving unit, to calculate the speed of the moving unit at the first rising point, that is, the first rising speed, the first rising point being the position where the acceleration of the moving unit changes from the current acceleration of the moving unit to the first prescribed acceleration; a reverse interpolation process, in the moving path of the moving unit, to sequentially calculate reverse interpolation points as the positions where the moving unit moves, from the instruction point of the target block determined by the determination process toward the starting point of the current block. , and the reverse interpolation point initially calculated, i.e., the initial reverse interpolation point, the speed of the moving part at the initial reverse interpolation point, and the acceleration of the moving part at the initial reverse interpolation point are respectively the instruction point of the target block, the target speed, and the second specified acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is the following position: the amount of movement of the moving part during the specified time based on the speed of the moving part and the acceleration of the moving part at the current reverse interpolation point, the maximum acceleration as the upper limit of the allowable acceleration, and the speed of the maximum jerk; and the second calculation processing, in the moving path of the moving part, at each time When the reverse interpolation processing calculates the reverse interpolation point, the speed of the moving part at the second rising point, i.e., the second rising speed, is calculated from the reverse interpolation point toward the starting point of the current block based on the maximum jerkiness, the speed of the moving part at the reverse interpolation point calculated by the reverse interpolation processing, and the acceleration of the moving part at the reverse interpolation point. The second rising point is the position where the acceleration of the moving part becomes a third specified acceleration from the acceleration of the moving part at the reverse interpolation point. In the reverse interpolation processing, the reverse interpolation point is calculated until the second rising speed calculated by the second calculation processing becomes greater than the first rising speed calculated by the first calculation processing.
[0034] The numerical control program of technical solution 12 contributes to the same advantages as the numerical control device of technical solution 1. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] [ Figure 1 ] is a three-dimensional view of the working machine 1.
[0036] [ Figure 2 ] is a block diagram showing the electrical structure of the working machine 1.
[0037] [ Figure 3 ] is a diagram used to illustrate NC program 441.
[0038] [ Figure 4 ] is a diagram used to illustrate the block information storage area 431.
[0039] [ Figure 5 ] is a graph showing the front end speed in each block relative to time when the front end point control starts.
[0040] [ Figure 6 ] is to indicate Figure 5 The subsequent chart.
[0041] [ Figure 7 ] is to indicate Figure 6 The subsequent chart.
[0042] [ Figure 8 ] is to indicate Figure 7 The subsequent chart.
[0043] [ Fig. 9 ] is to indicate Figure 8 The subsequent chart.
[0044] [ Fig.10 ] is to indicate Fig. 9 The subsequent chart.
[0045] [ Fig.11 ] is to indicate Fig.10 The subsequent chart.
[0046] [ Fig.12 ] is to indicate Fig.11 The subsequent chart.
[0047] [ Fig.13 ] is to indicate Fig.12 The subsequent chart.
[0048] [ Fig.14 ] is to indicate Fig.13 The subsequent chart.
[0049] [ Fig.15 ] is to indicate Fig.14 The subsequent chart.
[0050] [ Fig.16 ] is to indicate Fig.15 The subsequent chart.
[0051] [ Fig.17 ] is to indicate Fig.16 The subsequent chart.
[0052] [ Fig.18 ] is to indicate Fig.17 The subsequent chart.
[0053] [ Fig.19 ] is to indicate Fig.18 The subsequent chart.
[0054] [ Fig. 20 ] is to indicate Fig.19 The subsequent chart.
[0055] [ Fig.21 ] is to indicate Fig. 20 The subsequent chart.
[0056] [ Fig. 22 ] is a graph showing the front end speed in each block relative to time when the front end point control is completed, and a graph showing the front end acceleration or front end deceleration in each block relative to time.
[0057] [ Fig.23 ] is the flow chart of the main processing.
[0058] [ Fig.24 ] is the flow chart of the main processing.
[0059] [ Fig.25 ] is a flowchart of the reverse interpolation process.
[0060] [ Fig.26 ] is a flow chart of the first speed control process.
[0061] [ Fig. 27 ] is a flow chart of the first speed control process.
[0062] [ Fig.28 ] is a flowchart of the second speed control process. DETAILED DESCRIPTION
[0063] The embodiments of the present invention are described with reference to the drawings. The following description uses left and right, front and back, and up and down directions indicated by arrows in the drawings. The left and right directions, front and back directions, and up and down directions of the machine tool 1 are the X-axis direction, Y-axis direction, and Z-axis direction of the machine tool 1, respectively. Figure 1 The illustrated machine tool 1 is a complex machine capable of performing cutting and turning of a workpiece W.
[0064] Reference Figure 1 The structure of the working machine 1 is described. The working machine 1 includes a base 2, a Y-axis moving mechanism (illustration omitted), an X-axis moving mechanism (illustration omitted), a Z-axis moving mechanism (illustration omitted), a moving body 15, a column 5, a spindle head 6, a spindle 9, a support device 8, etc. The base 2 includes a gantry 11, a spindle base 12, a right side base 13, a left side base 14, etc. The gantry 11 is a roughly rectangular parallelepiped structure that is long in the front-to-back direction. The spindle base 12 is formed in a roughly rectangular parallelepiped shape that is long in the front-to-back direction and is arranged at the rear of the upper surface of the gantry 11. The right side base 13 is arranged at the right front of the upper surface of the gantry 11. The left side base 14 is arranged at the left front of the upper surface of the gantry 11. The right side base 13 and the left side base 14 support the support device 8 on their respective upper surfaces.
[0065] The Y-axis moving mechanism is disposed on the upper surface of the spindle base 12 and includes a Y-axis motor 62 (see Figure 2 ) etc. The Y-axis moving mechanism moves the substantially flat moving body 15 along the Y-axis direction by driving the Y-axis motor 62. The X-axis moving mechanism is disposed on the moving body 15 and includes an X-axis motor 61 (see Figure 2 ) etc. The X-axis moving mechanism drives the column 5 along the X-axis direction by driving the X-axis motor 61. The column 5 can move along the X-axis direction and the Y-axis direction on the base 2 through the Y-axis moving mechanism, the moving body 15, and the X-axis moving mechanism. The Z-axis moving mechanism is provided on the front surface of the column 5 and includes a Z-axis motor 63 (refer to Figure 2 ) etc. The Z-axis moving mechanism is driven by the Z-axis motor 63 to move the spindle head 6 along the Z-axis direction.
[0066] The spindle 9 is arranged inside the spindle head 6. A tool mounting hole (not shown) is provided at the lower portion of the spindle 9. The tool 3 is mounted in the tool mounting hole. Hereinafter, the front end of the tool 3 is referred to as the "tool front end". In the present embodiment, when the tool 3 extends downward from the tool mounting hole, the tool front end is the lower end of the tool 3. The X-axis moving mechanism, the Y-axis moving mechanism, and the Z-axis moving mechanism respectively move the tool 3 mounted on the spindle 9 relative to the workpiece W in the X-axis direction, the Y-axis direction, and the Z-axis direction. The spindle 9 is driven by a spindle motor 66 (see Figure 2 ) is driven to rotate.
[0067] The support device 8 is fixed to the upper surface of the right base 13 and the left base 14. The support device 8 includes an A-axis table 20, a left support table 27, a right drive mechanism 28, a rotating table 29, a C-axis drive unit 30, etc. The A-axis table 20 is a plate-like portion having a substantially rectangular shape in a plan view, with an inclination angle of 0 degrees when the upper surface of the A-axis table 20 is horizontal. The left support table 27 supports a support shaft (not shown) parallel to the X-axis direction in a rotatable manner. The bottom of the left support table 27 is fixed to the upper surface of the left base 14.
[0068] The right side drive mechanism 28 is located on the right side of the A-axis stage 20. The right side drive mechanism 28 stores the A-axis motor 64 (see Figure 2 ) etc. When the A-axis motor 64 rotates, the A-axis table 20 rotates around the support axis. The axis that rotates the A-axis table 20 is the A-axis. The right-side drive mechanism 28 rotates the workpiece W relative to the tool 3 around the A-axis. The A-axis table 20 tilts at any angle around the A-axis, so that the workpiece W can be tilted in any direction relative to the tool 3 mounted on the spindle 9.
[0069] The rotating table 29 is rotatably disposed at the approximate center of the upper surface of the A-axis table 20. The rotating table 29 has a disc shape. The C-axis drive unit 30 is disposed on the lower surface of the A-axis table 20 and is connected to the rotating table 29 via a hole (not shown) disposed at the approximate center of the A-axis table 20. The C-axis drive unit 30 includes a rotating shaft (not shown), a C-axis motor 65 (see Figure 2 ) etc. The rotating shaft extends in a direction perpendicular to the rotating table 29. The rotating shaft is fixed to the rotating table 29. The C-axis motor 65 is fixed to the rotating shaft. Therefore, when the C-axis motor 65 rotates the rotating shaft, the rotating table 29 rotates around the C-axis. The C-axis extends in a manner perpendicular to the upper surface of the rotating table 29. The direction in which the C-axis extends rotates according to the rotation of the A-axis. The rotating table 29 holds the workpiece W via the fixture 200. The fixture 200 is fixed to the upper surface of the rotating table 29. The C-axis drive unit 30 rotates the workpiece W relative to the tool 3 around the C-axis.
[0070] According to the above structure, the machine tool 1 moves the tool 3 linearly along the X-axis, Y-axis, and Z-axis relative to the workpiece W, and rotates the tool 3 relative to the workpiece W about the A-axis and the C-axis. In this way, the machine tool 1 changes the position and posture of the tool 3 relative to the workpiece W. The machine tool 1 rotates the tool 3 while changing the position and posture of the tool 3 relative to the workpiece W, and processes the workpiece W.
[0071] Hereinafter, the X-axis, Y-axis, Z-axis, A-axis, and C-axis are collectively referred to as the “driving axis”. The relative movement path of the tool tip relative to the workpiece W, the relative movement distance of the tool tip relative to the workpiece W, the relative position of the tool tip relative to the workpiece W, the relative speed of the tool tip relative to the workpiece W, the relative acceleration of the tool tip relative to the workpiece W, the relative deceleration of the tool tip relative to the workpiece W, and the relative jerk of the tool tip relative to the workpiece W are referred to as the “tip path”, “tip movement amount”, “tip point”, “tip speed”, “tip acceleration”, “tip deceleration”, and “tip jerk”, respectively. The speed of the drive shaft, the acceleration of the drive shaft, and the deceleration of the drive shaft are referred to as the “shaft speed”, “shaft acceleration”, and “shaft deceleration”, respectively.
[0072] In the present embodiment, the positive and negative of the axis speed, axis acceleration and axis deceleration are defined by the positive and negative of the coordinates. Furthermore, in the present embodiment, the positive and negative of the speed is defined by setting the moving distance close to the destination as "positive" based on the current position, and setting the moving distance away from the destination (moving distance traced back to the past) as "negative" based on the current position. The destination will be described in detail later, but it is an instruction point for a block after the current block in the processing order, such as an instruction point for a pre-read block. The positive and negative of the speed is defined by setting the speed close to the destination as "positive" based on the current position, and setting the speed away from the destination as "negative" based on the current position. The positive and negative of the acceleration is defined by setting the acceleration that increases in the positive direction as "positive" and setting the acceleration that approaches "0 mm / min" from "positive" as "negative".
[0073] In principle, the acceleration of "positive" or "0m / s^2" is simply referred to as "acceleration", and the absolute value of "negative" acceleration is referred to as "deceleration". For example, the so-called "increase in deceleration" or "increase in deceleration" means that the negative acceleration increases in the negative direction. That is, the so-called "increase in deceleration" or "increase in deceleration" means that the change in speed during deceleration increases. However, in order to simplify the description, the description of "negative" acceleration and "negative" or "0" deceleration is allowed, and sometimes simply directly referred to as acceleration or deceleration. However, for the reverse interpolation speed Vrev and the second rising speed V2 described later, the speed approaching the current position is set to "positive" based on the destination. Regarding the reverse interpolation acceleration Arev described later, the acceleration that increases the reverse interpolation speed Vrev in the positive direction is set to "positive". The reverse interpolation speed Vrev, the second rising speed V2, and the reverse interpolation acceleration Arev will not be "negative". Furthermore, in the present embodiment, the jerk (m / s^3) refers to the absolute value of the amount of change in acceleration or the absolute value of the amount of change in deceleration.
[0074] Reference Figure 2The electrical structure of the working machine 1 is described. The working machine 1 includes a numerical control device 40. The numerical control device 40 is stored inside the control box. The numerical control device 40 controls the operation of the working machine 1 based on the NC program. An operation panel 10 is set on the outer wall surface of the cover covering the working machine 1. The operation panel 10 includes an operation unit 17, a display unit 18, and a connection port 19. The operation unit 17 performs various settings of the numerical control device 40. The display unit 18 displays various screens, messages, alarms, etc. The connection port 19 includes a terminal for installing an external storage medium 46A. An example of the external storage medium 46A is a Universal Serial Bus (USB) memory.
[0075] The numerical control device 40 includes a central processing unit (CPU) 41, a read only memory (ROM) 42, a random access memory (RAM) 43, a flash memory 44, an input / output unit 45, an external interface (I / F) 46, and a drive circuit 51 to a drive circuit 56. The CPU 41 controls the operation of the working machine 1. The CPU 41 executes the control program stored in the flash memory 44. Hereinafter, the operation cycle based on the CPU 41 is referred to as a "cycle". The ROM 42 stores various setting information. The RAM 43 stores various data generated in the execution of various processes. The flash memory 44 stores the control program, the allowable value described later, the NC program, etc.
[0076] The input / output unit 45 performs input / output of various signals between the drive circuits 51 to 56, the operation unit 17, and the display unit 18. The drive circuit 51 is connected to the X-axis motor 61, the drive circuit 52 is connected to the Y-axis motor 62, the drive circuit 53 is connected to the Z-axis motor 63, the drive circuit 54 is connected to the A-axis motor 64, the drive circuit 55 is connected to the C-axis motor 65, and the drive circuit 56 is connected to the spindle motor 66. The drive circuits 51 to 56 output pulse signals output by the CPU 41 to the X-axis motor 61, the Y-axis motor 62, the Z-axis motor 63, the A-axis motor 64, the C-axis motor 65, and the spindle motor 66, respectively. The X-axis motor 61, the Y-axis motor 62, the Z-axis motor 63, the A-axis motor 64, and the C-axis motor 65 are all servo motors. The external I / F 46 is an interface element for reading information from the external storage medium 46A installed in the connection port 19. For example, the CPU 41 reads out a control program stored in the external storage medium 46A through the external I / F 46 .
[0077] Reference Figure 3The NC program is described. The NC program is composed of multiple blocks arranged in the order of block numbers. The block number indicates the processing order of each block. Hereinafter, unless otherwise specified, multiple blocks refer to multiple blocks included in the NC program. Multiple blocks respectively contain codes such as G codes, at least indicating the front end point. Hereinafter, the front end point indicated by each block, that is, the position where the tool front end passes based on the NC program is referred to as the "instruction point".
[0078] In each block, the presence or absence of the instruction of the front end speed varies depending on the type of code. For example, each block does not indicate the front end speed when the code is G0 (positioning), but indicates the front end speed when the code is G1 (linear interpolation). Hereinafter, the front end speed indicated by each block, that is, the front end speed based on the NC program, is referred to as the "instructed feed speed".
[0079] For example, NC program 441 includes eight blocks with block numbers N1 to N8. The codes of each of the eight blocks indicate G1 (linear interpolation). The command points of each of the eight blocks are indicated by X-coordinates, Y-coordinates, Z-coordinates, A-coordinates, and C-coordinates. The command feed speeds of the seven blocks other than block number N5 are all shown as 10000 mm / min. The command feed speed of the block with block number N5 is shown as 7000 mm / min.
[0080] In the following, N is sometimes used as a natural number, and a block with block number N is expressed as block N, and a parameter corresponding to block N is expressed as parameter (N). For example, the command feed speed "7000 mm / min" of block N5 is sometimes expressed as command feed speed (N5). Furthermore, the command point of a block is sometimes expressed as "the end point of the block". The end point (command point) of block N-1 is connected to the start point of block N.
[0081] The CPU 41 reads the NC program from the flash memory 44. The CPU 41 processes the plurality of blocks in the order of the block numbers, and controls the front end point and the front end speed based on at least the instruction point among the instruction points and the instruction feed speed. Hereinafter, the block whose processing order is the last among the plurality of blocks is referred to as the "final block". In the NC program 441, the block N8 whose processing order is the last becomes the final block. Any one of the plurality of blocks that becomes the current control object is referred to as the "current block". That is, the current block is the block to which the current front end point among the plurality of blocks belongs. For example, when the execution of the NC program 441 starts, the block N1 becomes the current control object, so the block N1 becomes the current block. Furthermore, among the plurality of blocks, the direction in which the processing order advances is referred to as the "forward direction", and the direction in which the processing order returns is referred to as the "reverse direction". In the NC program 441, the direction from the starting point of the block N1 toward the end point of the block N8 is the forward direction, and the direction from the end point of the block N8 toward the starting point of the block N1 is the reverse direction.
[0082] The allowable value is explained. The allowable value is a constant and is determined based on the load required by the tool 3 when processing the workpiece W. In the present embodiment, the allowable value includes the maximum shaft speed difference of each drive axis, the maximum front end jerk, the maximum shaft acceleration of each drive axis, and the maximum shaft speed of each drive axis. The maximum shaft speed difference represents the upper limit (the maximum allowable value) of the difference between the shaft speed at the end point (N-1) and the shaft speed at the starting point (N) for each drive axis. For example, the maximum shaft speed difference of the X axis is the upper limit of the allowable difference between the shaft speed of the X axis at the end point (N-1) and the shaft speed of the X axis at the starting point (N). The maximum front end jerk is the upper limit of the allowable front end jerk in the front end path. That is, the maximum front end jerk is the upper limit of the relative jerk of the tool front end relative to the workpiece W in each cycle. Hereinafter, the maximum front end jerk per unit time (one cycle in the present embodiment) is referred to as the "unit maximum front end jerk". That is, the unit maximum front end jerk is the amount by which the front end acceleration or front end deceleration changes during one cycle. The maximum axis acceleration indicates the upper limit of the axis acceleration or axis deceleration allowed for each drive axis. For example, the maximum axis acceleration of the X axis is the upper limit of the axis acceleration allowed for the X axis. The maximum axis speed indicates the upper limit of the speed allowed for the drive axis for each drive axis. For example, the maximum axis speed of the X axis is the upper limit of the speed allowed for the X axis.
[0083] As calculation objects in this embodiment, the maximum front end acceleration, the maximum front end deceleration, the permissible speed, the speed limit, the first connection speed, the second connection speed, the connection speed, and the starting speed are described. The maximum front end acceleration is the upper limit of the permissible front end acceleration in the front end path. In detail, the maximum front end acceleration is the upper limit of the front end acceleration where the absolute value of the axis acceleration becomes less than the maximum axis acceleration of the corresponding drive axis for all drive axes among the interpolation points on the front end path and the front end speed at the interpolation points. In addition, the maximum front end acceleration is affected by the rotation axis (A axis and C axis). Therefore, the maximum front end acceleration depends not only on the interpolation point, but also on the front end speed at the interpolation point.
[0084] The maximum front end deceleration is the upper limit of the allowable front end deceleration in the front end path. Specifically, the maximum front end deceleration is the upper limit of the front end deceleration at which the absolute value of the axis deceleration becomes less than the maximum axis acceleration of the corresponding drive axis for all drive axes among the interpolation points on the front end path and the front end speed at the interpolation points. In addition, the maximum front end deceleration is affected by the rotation axis (A axis and C axis). Therefore, the maximum front end deceleration depends not only on the interpolation point but also on the front end speed at the interpolation point.
[0085] The allowable speed is the upper limit of the front end speed at which the absolute value of the axis acceleration becomes less than the maximum axis acceleration of the corresponding drive axis for all drive axes at each interpolation point on the front end path, and the absolute value of the axis speed becomes less than the maximum axis speed of the corresponding drive axis for all drive axes. The limited speed is the upper limit of the front end speed allowed at each interpolation point on the front end path. In this embodiment, the limited speed is the minimum value between the command feed speed (N) and the allowable speed. That is, the limited speed is the speed after the allowable speed is limited by the command feed speed (N). In addition, in the case where the code is G0 (positioning), etc., when the command feed speed is not indicated by the NC program, the limited speed is not limited by the command feed speed, and therefore becomes the same value as the allowable speed.
[0086] The first connection speed (N) is the upper limit of the front end speed at the starting point (N) for all drive shafts, where the absolute value of the difference between the shaft speed at the end point (N-1) and the shaft speed at the starting point (N) is less than the maximum shaft speed difference of the corresponding drive shaft. The second connection speed (N) is the upper limit of the front end speed at the starting point (N) where the absolute value of the difference between the maximum front end acceleration at the end point (N-1) and the maximum front end acceleration at the starting point (N) is less than the unit maximum front end jerk. The connection speed (N) is the minimum value of the first connection speed (N) and the second connection speed (N).
[0087] In addition, the first connection speed of the block whose processing order is the first among the multiple blocks is set to 0 mm / min. The second connection speed of the block whose processing order is the first among the multiple blocks is set to 0 mm / min. Therefore, the connection speed of the block whose processing order is the first among the multiple blocks becomes 0 mm / min.
[0088] The starting speed (N) is the upper limit of the allowable front end speed at the starting point (N). In the present embodiment, the starting speed (N) is the minimum value among the connection speed (N), the command feed speed (N) and the command feed speed (N-1). That is, the starting speed (N) is the speed after the connection speed (N) is limited by the command feed speed (N). In addition, in the case where the code is G0 (positioning), etc., when the command feed speed is not indicated by the NC program, the starting speed (N) is not limited by the command feed speed (N) and the command feed speed (N-1), and therefore becomes the same value as the connection speed (N). The processing order in multiple blocks is that the starting speed of the initial block is set to 0 mm / min.
[0089] Reference Figure 4, the block information storage area 431 is described. The block information storage area 431 is set in the RAM 43. In the block information storage area 431, the front end movement amount (mm), the starting point speed (mm / min), and the command feed speed (mm / min) are stored in correspondence with the block number.
[0090] The front end movement amount (N) is the movement distance of the tool front end from the starting point (N) to the end point (N). The CPU 41 calculates the distance between the command point (N-1) and the command point (N) as the front end movement amount (N). In addition, the front end movement amount (N1) is the movement distance of the tool front end from the current front end point (e.g., the origin) to the command point (N1).
[0091] Reference Figure 5 to Figure 21 For the overview of the front-end control in this embodiment, the CPU 41 is based on Figure 3 The case where the NC program 441 shown performs the front end point control will be described as an example. Figure 5 to Figure 21 N1 to N8 in the figure represent blocks N1 to N8 respectively. Figure 5 to Figure 21 In the speed curve of the tool tip, the solid line extending from the starting point Ps (N1) represents the speed curve of the tool tip actually moving, and the dotted line and the solid line extending from the end point Pe of the target block Nd represent the virtual speed curve calculated by the CPU 41. The CPU 41 stores the information in each area of the block information storage area 431 before performing the acceleration and deceleration processing and reverse interpolation described later.
[0092] Specifically, the CPU 41 reads the block N1 as the current block Nnow. The CPU 41 calculates the front end movement amount (N1), the starting point speed (N1) and the command feed speed (N1), and stores the calculated front end movement amount, starting point speed and command feed speed in the block information storage area 431 in correspondence with the block N1.
[0093] Hereinafter, one or more blocks in a plurality of blocks whose processing order is later than the current block Nnow are referred to as pre-read blocks. The CPU 41 reads the pre-read blocks. The upper limit of the number of pre-read blocks that the CPU 41 can read is referred to as a "pre-read upper limit value". The pre-read upper limit value is stored in the flash memory 44. The pre-read upper limit value is not limited to a specific value, but is five in the present embodiment.
[0094] The CPU 41 reads five blocks N2 to N6 as pre-read blocks of the number of pre-read upper limit values (five in this embodiment). In the case, block N6 becomes the pre-read end block Nend. The pre-read end block Nend is the block whose processing order is the last among the pre-read blocks. That is, when the pre-read upper limit value (five) is set to a prescribed order (five orders), the pre-read end block Nend is a block whose processing order is after the current block Nnow through the prescribed order (after five orders).
[0095] The CPU 41 calculates the front end movement amount (N2 to N6), the starting point speed (N2 to N6) and the command feed speed (N2 to N6) for each of the read-in blocks N2 to N6, and stores the calculated front end movement amount, starting point speed and command feed speed in correspondence with blocks N2 to N6 in the block information storage area 431.
[0096] like Figure 5 As shown, the CPU 41 determines the target block Nd as the block N6 of the pre-read end block Nend, and determines the target speed Vd at the end point Pe (N6) as "0 mm / min". The target block Nd is any one of the current block and the pre-read block, and is the block to be targeted. The target speed Vd is the target front end speed. Thus, the CPU 41 ensures that the front end of the tool stops at the end point Pe (N6).
[0097] like Figure 6 As shown, the CPU 41 performs acceleration and deceleration processing from the starting point Ps (N1) to move the front end point from the starting point Ps (N1) to the current front end point (hereinafter referred to as "current position Pf"). The acceleration and deceleration processing of this embodiment includes a first speed control processing and a second speed control processing. It will be described in detail later, but in the first speed control processing, the processing related to the acceleration or deceleration of the tool front end is mainly performed, and in the second speed control processing, the processing related to the deceleration of the tool front end is mainly performed.
[0098] When the total distance of the front end movement amount L1, the front end movement amount L2 and the front end movement amount L3 is less than the movement margin, the CPU 41 performs the first speed control process. When the total distance of the front end movement amount L1, the front end movement amount L2 and the front end movement amount L3 is greater than the movement margin, the CPU 41 performs the second speed control process. The front end movement amount L1 is the front end movement amount from the current position Pf to the first rising point P1 described later. In the front end path, the front end movement amount L1 becomes "positive" when the first rising point P1 is located in a positive position relative to the current position Pf, and becomes "negative" when the first rising point P1 is located in a reverse position relative to the current position Pf. When the front end acceleration is 0m / s^2, the first rising point P1 coincides with the current position Pf, so the front end movement amount L1 becomes 0mm.
[0099] The front end movement amount L2 is the front end movement amount from the second rising point P2 described later to the reverse interpolation point Prev described later. It will be described in detail later, but the reverse interpolation point Prev will not be located in the reverse position relative to the second rising point P2 in the front end path. Therefore, the front end movement amount L2 will not become "negative". The front end movement amount L3 is the front end movement amount from the end point Pe of the target block Nd to the reverse interpolation point Prev. It will be described in detail later, but the end point Pe of the target block Nd will not be located in the reverse position relative to the reverse interpolation point Prev in the front end path. Therefore, the front end movement amount L3 will not become "negative". The movement margin is the front end movement amount from the current position Pf to the end point Pe of the target block Nd.
[0100] For example, in Figure 6 In the above example, the total distance of the front end movement amount L1, the front end movement amount L2 and the front end movement amount L3 is less than the movement margin. Therefore, the first speed control process is performed, and the current front end speed Vf increases. In this case, the CPU 41 calculates the speed limit Vp at each interpolation point.
[0101] The first rising point P1 is defined as one of the interpolation points. The first rising point P1 is a position in the front end path that is more positive than the current position Pf, and is a position where the front end acceleration changes from the current front end acceleration to the first prescribed acceleration, or a position in the front end path that is more reverse than the current position Pf, and is a position where the front end deceleration changes from the current front end deceleration to the first prescribed deceleration. The first prescribed acceleration and the first prescribed deceleration are not limited to specific values, respectively, but are preferably values that can be substantially described as 0 m / s^2, and in this embodiment, are 0 m / s^2. Hereinafter, the position in the first rising point P1 that is more positive than the current position Pf in the front end path, and the front end acceleration changes from the current front end acceleration to 0 m / s^2 is expressed as "the first rising point P1 (positive)", and the position in the first rising point P1 that is more reverse than the current position Pf in the front end path, and the front end deceleration changes from the current front end deceleration to 0 m / s^2 is expressed as "the first rising point P1 (reverse)". When there is no particular distinction between the first rising point P1 (positive direction) and the first rising point P1 (negative direction), it is simply expressed as "the first rising point P1". Figure 6 In the diagram, since the first rising point P1 (positive direction) is located in the positive direction relative to the current position Pf, the front end movement amount L1 becomes a positive value.
[0102] Furthermore, the front end speed at the first rising point P1 is referred to as the "first rising speed V1". The first rising speed V1 at the first rising point P1 (forward) is expressed as the "first rising speed V1 (forward)", and the first rising speed V1 at the first rising point P1 (reverse) is expressed as the "first rising speed V1 (reverse)". When there is no special distinction between the first rising speed V1 (forward) and the first rising speed V1 (reverse), it is simply expressed as the "first rising speed V1".
[0103] exist Figure 6 In the first speed control process, the speed limit Vp at the first rising point P1 is, for example, 10000 mm / min. Therefore, in the first speed control process, the tip speed is controlled so that the first rising speed V1 does not exceed the speed limit Vp (10000 mm / min) at the first rising point P1.
[0104] The CPU 41 performs reverse interpolation from the end point Pe (N6) in the reverse direction while performing acceleration based on the first speed control processing. In detail, the CPU 41 calculates the reverse interpolation point Prev, the reverse interpolation speed Vrev, and the reverse interpolation acceleration Arev in sequence until the conditions described later are met. Hereinafter, the reverse interpolation point Prev calculated initially is referred to as the "initial reverse interpolation point Prev". The initial reverse interpolation point Prev, the reverse interpolation speed Vrev at the initial reverse interpolation point Prev, and the reverse interpolation acceleration Arev at the initial reverse interpolation point Prev are respectively set as the instruction point of the target block Nd (i.e., the end point Pe (N6)), the target speed Vd, and the second prescribed acceleration. The second prescribed acceleration is not limited to a specific value, but is preferably a value that is substantially 0 m / s^2, and in the present embodiment is 0 m / s^2. The reverse interpolation point Prev calculated after the current reverse interpolation point Prev is the following position: in the front end path, the tool front end moves from the current reverse interpolation point Prev to the reverse direction, based on the current reverse interpolation speed Vrev, the current reverse interpolation acceleration Arev, the maximum front end acceleration and the maximum front end jerk during the specified time. In more detail, the CPU 41 virtually increases the front end acceleration from 0m / s^2 so that the front end jerk does not exceed the maximum front end jerk, and accelerates the front end speed from the target speed Vd to the reverse direction from the end point Pe of the target block Nd for a specified time so that the front end acceleration does not exceed the maximum front end acceleration. The specified time is the length of one or more cycles, and in this embodiment, it is the length of one cycle. The specified time may not be a certain length. In addition, in this embodiment, as long as there is no special limitation, the reverse interpolation point Prev, the reverse interpolation speed Vrev, and the reverse interpolation acceleration Arev respectively represent the current reverse interpolation point Prev, the current reverse interpolation speed Vrev, and the current reverse interpolation acceleration Arev.
[0105] By calculating the reverse interpolation point Prev, the speed curve of the tool tip from the end point Pe (N6) to the reverse interpolation point Prev is calculated. CPU 41 calculates the second rising speed V2. The second rising speed V2 is the front speed at the second rising point P2. The second rising point P2 is the position in the front end path from the reverse interpolation point Prev to the reverse direction, and the front end acceleration becomes the third prescribed acceleration from the front end acceleration at the reverse interpolation point Prev. The third prescribed acceleration is not limited to a specific value, but is preferably a value that can be substantially described as 0m / s^2, and in this embodiment, it is 0m / s^2. After calculating the first rising speed V1, CPU 41 repeatedly performs reverse interpolation and calculation of the second rising speed V2 until the second rising speed V2 becomes greater than the first rising speed V1.
[0106] like Figure 7 As shown, when the acceleration based on the first speed control process is repeated, the current position Pf reaches the end point Pe (N1). Thus, the acceleration and deceleration process of the block N1 (acceleration based on the first speed control process) is completed. In the above case, the current block Nnow is transferred from the block N1 to the block N2. That is, the block N2 is switched from the pre-read block to the current block Nnow.
[0107] like Figure 8 As shown, the CPU 41 reads block N7 as the pre-read block so that the number of pre-read blocks reaches the pre-read upper limit (five). As a result, the pre-read end block Nend is transferred from block N6 to block N7. The CPU 41 calculates the front end movement amount (N7), the starting point speed (N7) and the command feed speed (N7). Figure 4 In the block information storage area 431 shown, the calculated front end movement amount, starting point speed and command feed speed are stored in correspondence with block N7. The CPU 41 sets block N7 as the target block Nd instead of block N6. As a result, the target speed Vd at the end point Pe (N7) becomes "0 mm / min".
[0108] like Fig. 9 As shown in FIG. 1 , when the acceleration and reverse interpolation based on the first speed control process are repeatedly performed, the second rising speed V2 sometimes reaches 5000 mm / min. In the case, the starting speed Vs(N5) is 5000 mm / min, so the second rising speed V2 is the same as the starting speed Vs(N5). The transfer block is defined. The transfer block is one or more blocks in the pre-read block in the processing order between the block that is one block later than the current block Nnow and the arrival block, and the starting speed Vs is less than the second rising speed V2.
[0109] The arrival block is the block to which the second rising point P2 in the pre-read block belongs. Fig. 9 , block N6 becomes the arrival block. Block N5 is a pre-read block in the processing order between block N3 and block N6, which are processed one block later than block N2. The starting speed Vs (N5) is less than the second rising speed V2. Therefore, block N5 becomes the transfer block. The block with the smallest starting speed Vs among the transfer blocks is called the "transfer object block". Since there is only block N5 among the transfer blocks, block N5 becomes the transfer object block. Furthermore, in the case where there are multiple transfer blocks with the smallest starting speed Vs, the block with the first processing order among the multiple transfer blocks with the smallest starting speed Vs becomes the transfer object block.
[0110] like Fig.10As shown, the CPU 41 sets the block N4 that is one block ahead of the transfer target block in the processing order as the target block Nd. The CPU 41 sets "5000 mm / min" as the starting point speed Vs (N5) as the target speed Vd at the end point Pe (N4). The CPU 41 repeatedly performs acceleration based on the first speed control process.
[0111] like Fig.11 As shown in FIG. 1 , when the acceleration of block N2 based on the first speed control process is completed, the current block Nnow is transferred from block N2 to block N3, and the CPU 41 reads block N8 as a pre-read block. As a result, the pre-read end block Nend is transferred from block N7 to block N8. The CPU 41 calculates the front end movement amount (N8), the starting point speed (N8), and the command feed speed (N8). Figure 4 In the block information storage area 431 shown, the calculated front end movement amount, starting point speed, and command feed speed are stored in association with the block N8.
[0112] When the acceleration and reverse interpolation based on the first speed control process are repeatedly performed, the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 becomes greater than the movement margin. In the above case, the CPU 41 performs deceleration based on the second speed control process. As a result, the front end acceleration decreases. The target speed Vd is 5000 mm / min. Therefore, in the second speed control process, at each interpolation point, the front end speed is controlled so that the descending speed V3 described later will not be less than the target speed Vd (5000 mm / min).
[0113] like Fig.12 As shown in FIG. 1 , when the deceleration based on the second speed control process is repeated, the current position Pf reaches the end point Pe (N3). In the above case, block N8 is the final block, so block N9 is not read. Fig.13 As shown in FIG. 1 , when the deceleration based on the second speed control process is further repeated, the current position Pf reaches the end point Pe (N4) of the target block Nd. Thus, at the end point Pe (N4) of the target block Nd, the current front end speed Vf becomes the target speed Vd (5000 mm / min). Therefore, the acceleration and deceleration process from the target block Nd to the block N4 is completed.
[0114] like Fig.14 As shown, the CPU 41 sets the target block Nd to the block N8 of the pre-read end block Nend. The CPU 41 sets the target speed Vd at the end point Pe (N8) of the target block Nd to 0 mm / min. The CPU 41 repeatedly performs reverse interpolation and acceleration / deceleration processing. Fig.14In this case, the total distance of the tip movement amount L1, the tip movement amount L2, and the tip movement amount L3 is less than the movement margin. In this case, the CPU 41 performs acceleration based on the first speed control process to accelerate the tool tip.
[0115] like Fig.15 As shown in FIG. 1 , the speed limit Vp at each interpolation point up to the middle of the block N5 is 7000 mm / min. Therefore, in the acceleration based on the first speed control process, at each interpolation point up to the middle of the block N5, the front end speed is controlled so that the first rising speed V1 does not exceed the speed limit Vp (7000 mm / min) at the first rising point P1. That is, in the first speed control process, when the front end speed is accelerated to reach the speed limit Vp (7000 mm / min), thereafter, until the speed limit Vp changes from 7000 mm / min, the front end speed is controlled by the speed limit Vp.
[0116] like Fig.16 As shown, from the middle of block N5, the speed limit Vp at each interpolation point gradually decreases from 7000 mm / min. Since the command feed speed (N5) is constant at 7000 mm / min, the so-called "the speed limit Vp at each interpolation point gradually decreases from the middle of block N5" means that the passing allowable speed at each interpolation point gradually decreases to less than 7000 mm / min from the middle of block N5. In this case, the CPU 41 performs deceleration based on the first speed control process.
[0117] Then, the CPU 41 calculates the first rising speed V1 (reverse). The calculated first rising speed V1 is equal to the front end speed at the time when the deceleration based on the first speed control process is started. That is, the second rising speed V2 is already equal to the first rising speed V1 (reverse). Therefore, the CPU 41 does not update the reverse interpolation point Prev.
[0118] like Fig.17 As shown in FIG. 1 , when the deceleration based on the first speed control process is repeated, the current position Pf reaches the end point Pe ( N5 ). Thus, the acceleration and deceleration process of the block N5 is completed.
[0119] like Fig.18As shown, when deceleration based on the first speed control process is repeatedly performed and the current front end deceleration is equal to the maximum front end deceleration, the CPU 41 performs deceleration based on the first speed control process while performing reverse interpolation rewinding from the reverse interpolation point Prev to the positive direction. In detail, the first rising speed V1 (reverse) is smaller than the front end speed at the time point when the deceleration based on the first speed control process is started. The reason is that when the speed is increased by the current front end speed Vf and the first rising speed V1 (reverse) is calculated, the speed change in the interval in which the front end deceleration is equal to the maximum front end deceleration is not added to the current front end speed Vf. That is, the first rising speed V1 (reverse) is smaller than the front end speed at the time point when the deceleration based on the first speed control process is started by an amount corresponding to the size of the speed change in the interval in which the front end deceleration is equal to the maximum front end deceleration.
[0120] In the reverse interpolation rewinding, the CPU 41 obtains the reverse interpolation points Prev that have been calculated one by one in the forward direction. The CPU 41 obtains the second rising speed V2 corresponding to the obtained reverse interpolation point Prev from the second rising speed V2 that has been calculated. As a result, the second rising speed V2 is reduced. In addition, the CPU 41 can also recalculate the reverse interpolation point Prev and the second rising speed V2. The CPU 41 repeatedly rewinds the reverse interpolation to the maximum extent within the range where the second rising speed V2 is not less than the first rising speed V1. However, when the reverse interpolation point Prev becomes the end point Pe of the target block Nd, the CPU 41 ends the repetition of the reverse interpolation rewinding.
[0121] exist Fig.18 In the figure, since the first rising point P1 (reverse direction) is located in the reverse direction relative to the current position Pf, the front end movement amount L1 becomes a negative value. The total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 is less than the movement margin. Therefore, deceleration based on the first speed control process is performed.
[0122] The descent point P3 is defined as one of the interpolation points. The descent point P3 is a position in the front end path that is more positive than the current position Pf, and is a position where the front end deceleration changes from the current front end deceleration to the second prescribed deceleration. The second prescribed deceleration is not limited to a specific value, but is preferably a value that is substantially 0 m / s^2, and is 0 m / s^2 in the present embodiment. Furthermore, the front end speed at the descent point P3 is referred to as "descent speed V3". In the first speed control process, the front end speed is controlled so that the descent speed V3 does not exceed the limit speed Vp at the descent point P3. In addition, in the description that is also allowed when the acceleration is negative, the first rising point P1 (positive direction) when the acceleration is negative actually means the descent point P3, and the first rising speed V1 means the descent speed V3. It will not be mentioned again later.
[0123] like Fig.19 As shown in FIG. 1 , when switching from deceleration based on the first speed control process to acceleration, the CPU 41 switches to Fig.18 The first rising speed V1 is calculated from the falling speed V3 shown. The speed limit Vp at each interpolation point of block N6 is 10000 mm / min. In the first speed control process, the CPU 41 accelerates the tool tip again so that the calculated first rising speed V1 does not exceed the speed limit Vp (10000 mm / min) at the first rising point P1.
[0124] like Fig. 20 As shown, when the acceleration by the first speed control process is repeated, the total distance of the front end movement amount L1, the front end movement amount L2 and the front end movement amount L3 becomes greater than the movement margin. In this case, the deceleration by the second speed shift process is performed.
[0125] like Fig.21 As shown, by repeatedly performing the deceleration based on the second speed control process, the current position Pf becomes the end point Pe (N8), and the front end speed at the end point Pe (N8) becomes the target speed Vd (0 mm / min). Thus, the acceleration and deceleration process up to the final block N8 is completed. Figure 3 The front end point control of the NC program 441 shown is completed.
[0126] Reference Fig. 22 , for CPU 41 based Figure 3 The following describes the change in the front end acceleration over time when the front end point control is performed by the NC program 441 shown. Fig. 22 In the description of , negative acceleration (deceleration) is sometimes referred to as acceleration. Fig. 22 In the figure, the upper graph represents the velocity curve of the tool tip with a solid line R1, the lower graph represents the acceleration curve of the tool tip with a solid line R2, the maximum front acceleration with a dotted line R3, and the maximum front deceleration with a dotted line R4. In addition, the "curve" is a concept that also includes straight lines. The front acceleration is 0m / s^2 at Ps(N1). The front acceleration increases from Ps(N1) and reaches the maximum front acceleration in the middle of block N2. Thereafter, the front acceleration decreases and reaches 0m / s^2 in the middle of block N3. The front speed is 0mm / min at Ps(N1). The front speed increases from Ps(N1) and reaches a peak value at the time point when the front acceleration reaches 0m / s^2 in the middle of block N3.
[0127] The front acceleration further decreases from the time point when it reaches 0m / s^2 in the middle of block N3, and switches to rising from the end point Pe(N3). Thereafter, the front acceleration reaches 0m / s^2 at the end point Pe(N4). The front speed decreases from the peak value in the middle of block N3, and reaches 5000mm / min at the end point Pe(N4). The front speed reaches the peak value at the time point when the front acceleration reaches 0m / s^2 at the end point Pe(N4). As described above, block N4 is the target block Nd.
[0128] The front acceleration further increases from the end point Pe (N4) and switches to decrease from the middle of block N5. Thereafter, the front acceleration reaches 0m / s^2 in the middle of block N5 and maintains 0m / s^2. After the front speed reaches 5000mm / min, it increases to 7000mm / min. The front speed is maintained at 7000mm / min (limit speed Vp) while the front acceleration is maintained at 0m / s^2.
[0129] The front acceleration decreases after being maintained at 0m / s^2, and reaches the maximum front deceleration just before the end point Pe (N5). The front acceleration is maintained at the maximum front deceleration, and starts to rise in the middle of block N6. Thereafter, the front acceleration reaches 0m / s^2 in the middle of block N6. The front speed is maintained at 7000mm / min (limited speed Vp), and then decreases with the decrease of the limit speed Vp. Thereafter, the front speed reaches the peak at the time point when the front acceleration reaches 0mm / min in the middle of block N6.
[0130] After the front acceleration reaches 0m / s^2 in the middle of block N6, it further increases. The front acceleration reaches the maximum front acceleration in the middle of block N6 and is maintained at the maximum front acceleration. After being maintained at the maximum front acceleration, the front acceleration decreases and reaches 0m / s^2 at the end point Pe(N6). The front speed increases from the peak in the middle of block N6 and reaches the peak at the time when the front acceleration reaches 0m / s^2 at the end point Pe(N6).
[0131] The front acceleration further decreases from the end point Pe(N6) and reaches the maximum front deceleration in the middle of block N8. The front acceleration rises after being maintained at the maximum front deceleration. The front acceleration reaches 0m / s^2 at the end point Pe(N8). The front speed decreases from the peak value at the end point Pe(N6). The front speed reaches 0mm / min at the time when the front acceleration reaches 0m / s^2 at the end point Pe(N8).
[0132] Reference Fig.23 , Fig.24The main processing is described below. In order to realize the front end point control, the CPU 41 performs the main processing. The user specifies the NC program to be controlled, and inputs a start instruction for starting control based on the specified NC program to the numerical control device 40 via the operating unit 17. When the CPU 41 detects the start instruction via the operating unit 17, it starts the main processing by executing the control program stored in the flash memory 44. In addition, in the main processing, the CPU 41 appropriately stores various values obtained by calculation, setting, etc., the current front end speed, the front end acceleration, etc. in the RAM 43. The following lists the main processing of the CPU 41 based on Figure 3 The case where the NC program 441 shown performs the front end point control is described as a suitable example.
[0133] like Fig.23 As shown, when the main processing starts, the CPU 41 sets "1" to the current block Nnow (S11). The CPU 41 sets "1" to the pre-read end block Nend (S11). The CPU 41 reads the current block Nnow from the NC program (S12). The CPU 41 calculates the front end movement amount (Nnow) based on the current position Pf and the instruction point (Nnow) (S13). The CPU 41 obtains the instruction feed speed (Nnow) from the read current block Nnow (S13).
[0134] The CPU 41 sets the pre-read end block Nend to the target block Nd (S14). The CPU 41 sets "0 mm / min" to the target speed Vd (S14). The CPU 41 sets the end point Pe (Nend) to the reverse interpolation point Prev (S20). The CPU 41 sets "0 mm / min" to the reverse interpolation speed Vrev (S20). The reverse interpolation speed Vrev is the front end speed at the reverse interpolation point Prev. The CPU 41 sets "0 m / s^2" to the reverse interpolation acceleration Arev (S20). The reverse interpolation acceleration Arev is the front end acceleration at the reverse interpolation point Prev.
[0135] The CPU 41 determines whether Nend is greater than the sum of Nnow and Npara (S21). Npara represents the pre-reading upper limit. When the number of pre-read blocks is less than the pre-reading upper limit Npara, Nend is less than the sum of Nnow and Npara (S21: NO). In this case, the CPU 41 determines whether there is a block Nend+1 in the NC program (S22).
[0136] When the pre-read end point block Nend is not the final block, there is a block Nend+1 in the NC program (S22: YES). In this case, the CPU 41 reads the block Nend+1 from the NC program (S23). The CPU 41 calculates the front end movement amount (Nend+1) based on the instruction point (Nend) and the instruction point (Nend+1) (S24). The CPU 41 obtains the instruction feed speed (Nend+1) from the read block Nend+1 (S24).
[0137] The CPU 41 calculates the starting speed Vs (Nend+1) (S24). Specifically, the CPU 41 calculates the first connection speed (Nend+1) based on the shaft speed of each drive shaft when the front end speed at the end point Pe (Nend) is assumed to be the specified front end speed, the shaft speed of each drive shaft when the front end speed at the starting point Ps (Nend+1) is assumed to be the specified front end speed, and the maximum shaft speed difference of each drive shaft. The CPU 41 calculates the second connection speed (Nend+1) based on the shaft acceleration of each drive shaft when the front end speed and front end acceleration at the end point Pe (Nend) are assumed to be the specified front end speed and 0m / s^2, the shaft acceleration of each drive shaft when the front end speed and front end acceleration at the starting point Ps (Nend+1) are assumed to be the specified front end acceleration and 0m / s^2, the maximum shaft acceleration of each drive shaft, and the maximum front end jerk. The CPU 41 calculates the minimum value of the first connection speed (Nend+1) and the second connection speed (Nend+1) as the connection speed (Nend+1). When the block Nend+1 does not indicate the command feed speed, the CPU 41 sets the calculated connection speed as the starting speed Vs(Nend+1). When the block Nend+1 indicates the command feed speed, the CPU 41 calculates the minimum value of the calculated connection speed (Nend+1) and the command feed speed (Nend+1) as the starting speed Vs(Nend+1).
[0138] The CPU 41 determines whether the target block Nd is the pre-read end block Nend (S25). In the reverse interpolation process (S31) described later, if the CPU 41 does not set the block Ntmp-1 as the target block Nd in S72, the target block Nd becomes the pre-read end block Nend (S25: Yes). In this case, the CPU 41 sets the block Nend+1 as the target block Nd (S26). The CPU 41 sets the block Nend+1 as the pre-read end block Nend (S27). The CPU 41 returns the process to S20.
[0139] The CPU 41 repeats S27, and the pre-read end block Nend is incremented by "1". When the number of pre-read blocks is greater than the pre-read upper limit value Npara, in S21, Nend becomes greater than Nnow+Npara (S21: Yes). In this case, the CPU 41 transfers the processing to Fig.24 S31 shown.
[0140] exist Figure 4 In the block information storage area 431 shown, by performing S13, the calculated values are stored in the respective areas corresponding to the block N1, and by repeatedly performing S20 to S28, the calculated values are stored in the respective areas corresponding to the blocks N2 to N6 in the order of block N2, block N3, block N4, block N5, and block N6.
[0141] like Fig.24 As shown, the CPU 41 performs reverse interpolation processing (S31). In the reverse interpolation processing, the CPU 41 calculates the reverse interpolation point Prev, the first rising speed V1, the second rising speed V2, the arrival block, and the transfer block.
[0142] Reference Fig.25 The details of the reverse interpolation processing are explained. When the reverse interpolation processing is started, the CPU 41 calculates the first rising speed V1 (S51) based on the maximum front end jerkiness, the current front end speed Vf, and the current front end acceleration or the current front end deceleration. In detail, when the current front end acceleration is a positive value, when the current front end acceleration is reduced to 0m / s^2 by the maximum front end jerkiness, the CPU 41 calculates the front end speed increased from the current front end speed Vf as the first rising speed V1 (forward). When the current front end acceleration is a negative value (i.e., front end deceleration), when the current front end deceleration is reduced to 0m / s^2 by the maximum front end jerkiness, the CPU 41 calculates the front end speed increased from the current front end speed Vf as the first rising speed V1 (reverse).
[0143] The CPU 41 calculates the second rising speed V2 (S53) based on the maximum front end jerk, the reverse interpolation speed Vrev, and the reverse interpolation acceleration Arev. Specifically, when the reverse interpolation acceleration Arev is reduced to 0 m / s^2 by the maximum front end jerk, the CPU 41 calculates the front end speed increased from the reverse interpolation speed Vrev as the second rising speed V2.
[0144] Then, the CPU 41 calculates the arrival block (S54). The CPU 41 calculates the front end movement amount from the second rising point P2 to the reverse interpolation point Prev based on the reverse interpolation speed Vrev, the reverse interpolation acceleration Arev, and the maximum front end jerk. The CPU 41 calculates the arrival block based on the calculated front end movement amount and the front end movement amount of each block.
[0145] The CPU 41 determines whether the current front end acceleration is greater than or equal to 0 m / s^2 (S60). For example, immediately after the acceleration based on the first control process begins, the current front end acceleration becomes greater than or equal to 0 m / s^2 (S60: Yes). In this case, the CPU 41 determines whether the second ascending speed V2 is greater than or equal to the first ascending speed V1 (S61). If the second ascending speed V2 is greater than or equal to the first ascending speed V1 (S61: Yes), the CPU 41 returns the process to Fig.24 The main process shown.
[0146] When the second rising speed V2 is less than the first rising speed V1 (S61: No), the CPU 41 performs one cycle of reverse interpolation (S62). Specifically, the CPU 41 calculates the maximum front end acceleration at the reverse interpolation point Prev based on the reverse interpolation speed Vrev and the maximum axis acceleration. The CPU 41 calculates the position in the front end path that moves one cycle from the reverse interpolation point Prev toward the current block Nnow as the reverse interpolation point Prev based on the reverse interpolation speed Vrev, the reverse interpolation acceleration Arev, the calculated maximum front end acceleration, and the maximum front end jerk stored in the flash memory 44. The CPU 41 transfers the processing to S63.
[0147] For example, after the acceleration based on the first control process is started, when the first rising speed V1 reaches the speed limit Vp at the first rising point P1, and thereafter, the speed limit Vp decreases, etc., the current front end acceleration is less than 0 m / s^2 (S60: No). In the above case, the CPU 41 determines whether the reverse interpolation point Prev is the end point Pe of the target block Nd (S65).
[0148] When the reverse interpolation point Prev is not the end point Pe of the target block Nd (S65: No), the CPU 41 performs a rewind of the reverse interpolation for one cycle (S66). Specifically, the CPU 41 obtains the reverse interpolation point Prev of the previous cycle from the RAM 43. The CPU 41 obtains the second rising speed V2 corresponding to the reverse interpolation point Prev of the previous cycle, that is, the second rising speed V2 of the previous cycle from the RAM 43 (S67).
[0149] The CPU 41 determines whether the second rising speed V2 of the previous cycle obtained in S67 is greater than the first rising speed V1 calculated in S51 (S68). When the second rising speed V2 is greater than the first rising speed V1 (S68: Yes), the CPU 41 returns the processing to S65. That is, the CPU 41 repeatedly performs S66 and S67 until the second rising speed V2 becomes less than the first rising speed V1, or until the reverse interpolation point Prev becomes the end point Pe of the target block Nd. In addition, when S66 and S67 are repeatedly performed, the CPU 41 obtains the reverse interpolation point Prev or the second rising speed V2 that is closer to the previous cycle than the reverse interpolation point Prev or the second rising speed V2 obtained in the previous S66 and S67. When the second rising speed V2 becomes less than the first rising speed (S68: No), or when the reverse interpolation point Prev becomes the end point Pe of the target block Nd (S65: Yes), the CPU 41 transfers the processing to S61.
[0150] For example, in S61, when the second rising speed V2 calculated in S53 is greater than the first rising speed V1 calculated in S51, the CPU 41 does not perform reverse interpolation (S62). That is, in this embodiment, the CPU 41 sometimes does not perform reverse interpolation (S62) even if it calculates the first rising speed V1 once.
[0151] The first rising speed V1 is fixed to the value calculated in S51. The second rising speed V2 is periodically calculated in S63 described later, and when reverse interpolation is performed, the second rising speed V2 becomes larger each time it is calculated. For example, the second rising speed V2 is calculated once or multiple times in S63 by the CPU 41, and the second rising speed V2 sometimes becomes greater than the first rising speed V1 in S61. That is, in this embodiment, the CPU 41 sometimes performs reverse interpolation (S62) once or multiple times each time the first rising speed V1 is calculated.
[0152] The first rising speed V1 is fixed to the value calculated in S51. The second rising speed V2 is periodically calculated in S63 described later, and in the case of reverse interpolation rewinding, the second rising speed V2 becomes smaller each time it is calculated. For example, the second rising speed V2 is calculated once or multiple times by the CPU 41 in S63, and the first rising speed V1 sometimes becomes greater than the second rising speed V2 in S68. That is, in this embodiment, the CPU 41 sometimes performs one or more reverse interpolation rewinding (S66) each time the first rising speed V1 is calculated.
[0153] CPU 41 calculates the second rising speed V2 (S63) based on the reverse interpolation point Prev calculated in S62. The reverse interpolation acceleration Arev based on the reverse interpolation point Prev calculated in S62 will not be less than the front end acceleration after reducing the reverse interpolation acceleration Arev of the reverse interpolation point Prev based on S53 or the time point of the previous S63 by an amount corresponding to the unit maximum front end jerkiness. Therefore, when reverse interpolation (S62) is performed, the second rising speed V2 calculated in S63 becomes greater than the second rising speed V2 calculated in S53 or the previous S63. The reverse interpolation speed Vrev based on the reverse interpolation point Prev obtained in S66 is less than the reverse interpolation speed Vrev of the reverse interpolation point Prev based on S53 or the time point of the previous S63. Therefore, when the reverse interpolation is performed ( S66 ), the second rising speed V2 calculated in S63 is smaller than the second rising speed V2 calculated in S53 or the previous S63 .
[0154] Furthermore, the CPU 41 calculates the arrival block based on the reverse interpolation speed Vrev calculated in S62, the reverse interpolation acceleration Arev calculated in S62, and the maximum front end jerk stored in the flash memory 44 (S64). The CPU 41 determines whether there is a transfer block in the pre-read block based on the current block and the arrival block, and the second rising speed V2 and the starting speed Vs of the pre-read block (S71). When there is no transfer block (S71: No), the CPU 41 returns the process to S61.
[0155] If there is a transfer block (S71: Yes), the CPU 41 sets the starting speed Vs (Ntmp) as the target speed Vd (S72). In addition, Ntmp represents the block number of the transfer target block. The CPU 41 sets the block Ntmp-1 as the target block Nd (S72). For example, if the block N5 is the transfer target block Ntmp, the block N4 becomes the target block Nd (see Fig.10 ).
[0156] The CPU 41 sets the starting point Ps(Ntmp) as the reverse interpolation point Prev (S73). The CPU 41 sets the starting point speed Vs(Ntmp) as the reverse interpolation speed Vrev (S73). The CPU 41 sets "0 m / s^2" as the reverse interpolation acceleration Arev (S73). The CPU 41 returns the process to S61.
[0157] Back to Fig.24After the reverse interpolation process, the CPU 41 calculates the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 and the movement margin (S32). The CPU 41 calculates the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 based on the current position Pf, the first rising point P1, the second rising point P2, and the position of the end point Pe of the target block Nd on the front end path. The CPU 41 calculates the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 based on the current position Pf, and the first rising point P1, the second rising point P2, and the position of the end point Pe of the target block Nd on the front end path. Fig.23 The movement margin is calculated based on the front end movement amount of each block calculated in S13 and S17 shown.
[0158] The CPU 41 determines whether the total distance calculated in S32 is greater than the movement margin calculated in S32 (S33). Figure 6 or Fig. 20 As shown in FIG. 4 , when the total distance is less than the moving margin (S34: No), even if the second speed control process along the speed curve of the tool tip from the end point Pe of the target block Nd to the second rising point P2 is not performed, the CPU 41 can decelerate the tip speed to the target speed Vd at the end point Pe of the target block Nd. Therefore, the CPU 41 performs the first speed control process (S34). In the first speed control process, the CPU 41 controls the tip speed (acceleration, deceleration or speed maintenance) with the maximum tip acceleration and the tip acceleration based on the maximum tip jerk so that the first rising speed V1 does not exceed the limit speed Vp at the first rising point P1.
[0159] When the first speed control process is repeated, the total distance becomes larger and the movement margin becomes smaller. Fig.11 As shown in FIG. 4 , when the total distance becomes greater than the moving margin (S34: Yes), if the second speed control process along the speed curve of the tool tip from the end point Pe of the target block Nd to the second rising point P2 is not performed, the CPU 41 may not be able to decelerate the tip speed to the target speed Vd at the end point Pe of the target block Nd. Therefore, the CPU 41 performs the second speed control process (S35). In the second speed control process, the CPU 41 controls the tip speed (acceleration, deceleration or speed maintenance) at the maximum tip deceleration and the tip deceleration based on the maximum tip jerk so that the first rising speed V1 will not be less than the target speed Vd.
[0160] Reference Fig.26 , Fig. 27 The details of the first speed control process are described below. In the first speed control process, the CPU 41 performs different processes depending on whether the tool tip is accelerating. Fig.26As shown, when the first speed control process is started, the CPU 41 determines whether the current front end acceleration is greater than or equal to 0 m / s^2 (S80).
[0161] First, the processing of the case where the current front end acceleration is greater than 0 m / s^2 (S80: Yes), that is, the case where the tool front end is accelerating, is described. In the case, the CPU 41 determines whether the front end acceleration when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerkiness exceeds the maximum front end acceleration (S81). In S81, the CPU 41 calculates the maximum front end acceleration at the first rising point P1 based on the first rising speed V1 and the maximum shaft acceleration. The CPU 41 calculates the front end acceleration when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerkiness based on the maximum front end jerkiness stored in the flash memory 44. The CPU 41 makes the determination of S81 based on the calculated front end acceleration and the maximum front end acceleration.
[0162] For example, when the current front end acceleration is relatively small, even if the CPU 41 increases the current front end acceleration by an amount corresponding to the unit maximum front end jerk, the increased front end acceleration will not exceed the maximum front end acceleration (S81: No). In this case, the CPU 41 determines whether the first ascending speed V1 when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerk exceeds the limit speed Vp at the first ascending point P1 (S82).
[0163] In S82, the CPU 41 calculates the passing allowable speed at the first rising point P1 based on the maximum shaft speed and the maximum shaft acceleration. In the case where the command feed speed is not indicated by the current block Nnow, the CPU 41 sets the calculated passing allowable speed as the limit speed Vp at the first rising point P1. In the case where the command feed speed is indicated by the current block Nnow, the CPU 41 sets the smaller one of the calculated passing allowable speed and the command feed speed (Nnow) as the limit speed Vp at the first rising point P1. Furthermore, based on the maximum front end jerk stored in the flash memory 44, the CPU 41 calculates the first rising speed V1 when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerk. The CPU 41 makes a judgment in S82 based on the calculated first rising speed V1 and the limit speed Vp.
[0164] For example, when the current front end speed Vf is relatively smaller than the speed limit Vp, even if the CPU 41 increases the current front end acceleration by an amount corresponding to the unit maximum front end jerk, the first rising speed V1 will not exceed the speed limit Vp (Nnow) at the first rising point P1 (S82: No). In this case, the CPU 41 increases the current front end acceleration by an amount corresponding to the unit maximum front end jerk (S83). As a result, the front end speed rapidly approaches the speed limit Vp as time passes. The CPU 41 transfers the process to S88.
[0165] For example, when the current front end acceleration is close to the maximum front end acceleration, when the CPU 41 increases the current front end acceleration by an amount corresponding to the unit maximum front end jerk, the increased front end acceleration exceeds the maximum front end acceleration (S81: Yes). Furthermore, for example, when the current front end speed Vf is close to the limit speed Vp at the first rising point P1 when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerk, when the CPU 41 increases the current front end acceleration by an amount corresponding to the unit maximum front end jerk, the first rising speed V1 exceeds the limit speed Vp (S82: Yes). In these cases, after the CPU 41 maintains the current front end acceleration during the current cycle, it is determined whether the maintained front end acceleration exceeds the maximum front end acceleration at the first rising point P1 (S84). In S84, the CPU 41 calculates the maximum front end acceleration at the first rising point P1 in the same way as S81. The CPU 41 makes the determination of S84 based on the current front end acceleration and the calculated maximum front end acceleration.
[0166] When the maximum front end acceleration is maintained or increased during the period from the current position Pf to the first rising point P1, even if the CPU 41 maintains the current front end acceleration during the current cycle, the maintained front end acceleration will not exceed the maximum front end acceleration (S84: No). In the case, the CPU 41 determines whether the first rising speed V1 when the current front end acceleration is maintained during the current cycle exceeds the limit speed Vp (S85). In S85, the CPU 41 calculates the limit speed Vp at the first rising point P1 when the current front end acceleration is maintained in the same way as S82. The CPU 41 calculates the first rising speed V1 when the current front end acceleration is maintained based on the current front end speed in the current cycle. The CPU 41 makes the judgment of S85 based on the calculated limit speed Vp and the first rising speed V1.
[0167] For example, when the current front end speed Vf is relatively far away from the speed limit Vp at the first rising point P1 when the current front end acceleration is maintained, even if the CPU 41 maintains the current front end acceleration during the current cycle, the first rising speed V1 will not exceed the speed limit Vp at the first rising point P1 (S85: No). In this case, the CPU 41 maintains the current front end acceleration during the current cycle (S86). As a result, the front end speed approaches the speed limit Vp linearly as time passes. The CPU 41 transfers the process to S88.
[0168] Since the maximum front end acceleration is lower than the current maximum front end acceleration during the period from the current position Pf to the first rising point P1, the maintained front end acceleration sometimes exceeds the maximum front end acceleration during the current cycle (S84: Yes). Furthermore, for example, when the current front end speed Vf is close to the limit speed Vp at the first rising point P1 when the current front end acceleration is maintained, after the CPU 41 maintains the current front end acceleration during the current cycle, the first rising speed V1 exceeds the limit speed Vp at the first rising point P1 (S85: Yes). In these cases, the CPU 41 reduces the current front end acceleration by an amount corresponding to the unit maximum front end jerk (S87). As a result, the front end speed slowly approaches the limit speed Vp as time passes. The CPU 41 transfers the processing to S88.
[0169] After S83, S86 or S87, the CPU 41 performs speed update processing (S88). In the speed update processing of S88, the CPU 41 calculates the front end speed by adding the speed change amount of one cycle when the front end acceleration is accelerated by the front end acceleration calculated in S83, S86 or S87 to the current front end speed Vf. The CPU 41 outputs a signal to each of the X-axis motor 61, the Y-axis motor 62, the Z-axis motor 63, the A-axis motor 64 and the C-axis motor 65 in such a way that the actual front end speed in the machine tool 1 becomes the calculated front end speed, and controls each drive axis during the current cycle. In this way, the CPU 41 controls the front end point and the front end speed. The CPU 41 returns the processing to Fig.24 The main process shown.
[0170] In S80, the processing of the case where the current tip acceleration is less than 0 m / s^2 (S80: No), that is, the case where the tool tip is decelerating, is described. Fig. 27As shown, after the CPU 41 maintains the current front end deceleration during the current cycle, it is determined whether the maintained front end deceleration exceeds the maximum front end deceleration (S101). In S101, the CPU 41 calculates the maximum front end deceleration at the descending point P3 based on the descending speed V3 and the maximum shaft acceleration. The CPU 41 makes the determination of S101 based on the current front end deceleration and the calculated maximum front end deceleration.
[0171] In the case where the maximum front end deceleration is maintained or increased during the period from the current position Pf to the descent point P3, even if the CPU 41 maintains the current front end deceleration during the current cycle, the maintained front end deceleration will not exceed the maximum front end deceleration (S101: No). In the above case, the CPU 41 determines whether the descent speed V3 when the current front end deceleration is reduced by an amount corresponding to the unit maximum front end jerk is less than the limit speed Vp at the descent point P3 (S102). In S102, the CPU 41 calculates the descent speed V3 when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerk based on the current front end speed Vf. The CPU 41 calculates the limit speed Vp at the descent point P3 in the same manner as S82. The CPU 41 makes the determination in S102 based on the calculated descent speed V3 and the limit speed Vp.
[0172] For example, since the maximum front end deceleration is lower than the current maximum front end deceleration during the period from the current position Pf to the descent point P3, the maintained front end deceleration sometimes exceeds the maximum front end deceleration during the current cycle (S101: Yes). Furthermore, for example, when the current front end speed Vf is close to the limit speed Vp at the descent point P3 when the current front end deceleration is reduced by an amount corresponding to the unit maximum front end jerk, even if the CPU 41 reduces the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the descent speed V3 becomes less than the limit speed Vp at the descent point P3 (S102: Yes). In these cases, the CPU 41 reduces the current front end deceleration by an amount corresponding to the unit maximum front end jerk (S103). As a result, the front end speed slowly approaches the limit speed Vp as time passes. The CPU 41 transfers the processing to S108.
[0173] For example, when the current front end speed Vf is relatively larger than the limit speed Vp at the descent point P3 when the current front end deceleration is reduced by an amount corresponding to the unit maximum front end jerk, when the CPU 41 reduces the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the descent speed V3 will not become less than the limit speed Vp at the descent point P3 (S102: No). In the above case, the CPU 41 determines whether the front end deceleration when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerk exceeds the maximum front end deceleration (S104). In S104, the CPU 41 calculates the maximum front end deceleration at the descent point P3 in the same manner as S101. The CPU 41 calculates the front end deceleration when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerk based on the maximum front end jerk stored in the flash memory 44. The CPU 41 makes the determination in S104 based on the calculated front end deceleration and the maximum front end deceleration.
[0174] For example, when the current front end deceleration is relatively small, even if the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the increased front end deceleration will not exceed the maximum front end deceleration (S104: No). In the above case, the CPU 41 determines whether the descent speed V3 when the current front end deceleration is maintained during the current cycle is less than the limit speed Vp at the descent point P3 (S105). In S105, the CPU 41 calculates the limit speed Vp at the descent point P3 in the same way as S102. The CPU 41 calculates the descent speed V3 when the current front end deceleration is maintained based on the current front end speed Vf in the current cycle. The CPU 41 makes the determination in S105 based on the calculated limit speed Vp and descent speed V3.
[0175] For example, when the current front end speed Vf is relatively far away from the speed limit Vp at the descent point P3 when the current front end deceleration is maintained, even if the CPU 41 maintains the current front end deceleration during the current cycle, the descent speed V3 will not be less than the speed limit Vp at the descent point P3 (S105: No). In this case, the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerk (S106). As a result, the front end speed rapidly approaches the speed limit Vp as time passes. The CPU 41 transfers the process to S108.
[0176] For example, when the current front end deceleration is close to the maximum front end deceleration, when the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the increased front end deceleration exceeds the maximum front end deceleration (S104: Yes). Furthermore, for example, when the current front end speed Vf is close to the limit speed Vp at the descent point P3 when the current front end deceleration is maintained, when the CPU 41 maintains the current front end deceleration during the current cycle, the descent speed V3 becomes less than the limit speed Vp at the descent point P3 (S105: Yes). In these cases, the CPU 41 maintains the current front end deceleration during the current cycle (S106). As a result, the front end speed approaches the limit speed Vp linearly as time passes. The CPU 41 transfers the process to S108.
[0177] After S103, S106 or S107, the CPU 41 performs speed update processing (S108). In the speed update processing of S108, the CPU 41 calculates the front end speed by reducing the speed change in one cycle when the front end deceleration is decelerated by the front end deceleration calculated in S103, S106 or S107 from the current front end speed Vf. The CPU 41 outputs a signal to each of the X-axis motor 61, the Y-axis motor 62, the Z-axis motor 63, the A-axis motor 64 and the C-axis motor 65 in such a way that the actual front end speed in the machine tool 1 becomes the calculated front end speed, and controls each drive axis during the current cycle. Thus, the CPU 41 controls the front end point and the front end speed. The CPU 41 returns the processing to Fig.24 The main process shown.
[0178] Reference Fig.28 The details of the second speed control process are described. When the second speed control process is started, the CPU 41 determines whether the current front end acceleration is greater than "0m / s^2" (S91). For example, shortly after the first speed control process is transferred to the second speed control process, and the tool front end is still accelerating, the current front end acceleration is greater than "0m / s^2" (S91: Yes). In the case, the CPU 41 reduces the current front end acceleration by an amount corresponding to the unit maximum front end jerk (S92). As a result, the speed curve of the tool front end shifts in a manner that forms a peak. The CPU 41 transfers the process to S100.
[0179] For example, whenever the CPU 41 reduces the front acceleration in S92, the front acceleration approaches 0m / s^2, and the current front acceleration is less than "0m / s^2" (S91: No). In the case, the CPU 41 determines whether the front deceleration when the current front deceleration is increased by an amount corresponding to the unit maximum front jerkiness exceeds the maximum front deceleration (S93). In S93, the CPU 41 calculates the maximum front deceleration at the descent point P3 based on the descent speed V3 and the maximum shaft acceleration. The CPU 41 calculates the front deceleration when the current front deceleration is increased by an amount corresponding to the unit maximum front jerkiness based on the maximum front jerkiness stored in the flash memory 44. The CPU 41 makes the determination in S93 based on the calculated front deceleration and the maximum front deceleration.
[0180] For example, when the current front end deceleration is relatively far from the maximum front end deceleration, even if the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerkiness, the increased front end deceleration will not exceed the maximum front end deceleration (S93: No). In the above case, the CPU 41 determines whether the descent speed V3 when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerkiness is less than the target speed Vd (S94). In S94, the CPU 41 calculates the descent speed V3 when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerkiness based on the maximum front end jerkiness stored in the flash memory 44. The CPU 41 makes the determination of S94 based on the calculated descent speed V3 and the target speed Vd.
[0181] For example, when the current front end speed Vf is relatively far from the target speed Vd, even if the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerkiness, the descent speed V3 will not be less than the target speed Vd (S94: No). In the above case, the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerkiness (S95). Thus, the front end speed rapidly approaches the target speed Vd as time passes. The CPU 41 transfers the process to S100.
[0182] For example, when the current front end deceleration is close to the maximum front end deceleration, when the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the increased front end deceleration exceeds the maximum front end deceleration (S93: Yes). Furthermore, for example, when the current front end speed Vf is close to the target speed Vd, when the CPU 41 increases the current front end deceleration by an amount corresponding to the unit maximum front end jerk, the descent speed V3 is less than the target speed Vd (S94: Yes). In these cases, the CPU 41 determines whether the front end deceleration exceeds the maximum front end deceleration during the current cycle while maintaining the current front end deceleration during the current cycle (S96). The CPU 41 makes the determination of S96 based on the current front end deceleration and the calculated maximum front end deceleration.
[0183] In the case where the maximum front end deceleration is maintained or increased during the period from the current position Pf to the descent point P3, even if the CPU 41 maintains the current front end deceleration during the current cycle, the maintained front end deceleration will not exceed the maximum front end deceleration (S96: No). In the above case, the CPU 41 determines whether the descent speed V3 when the current front end deceleration is maintained during the current cycle is less than the target speed Vd (S97). In S97, the CPU 41 calculates the descent speed V3 when the current front end deceleration is maintained based on the current front end speed in the current cycle. The CPU 41 makes the determination of S97 based on the target speed Vd and the calculated descent speed V3.
[0184] For example, when the current front end speed Vf is relatively far from the target speed Vd, even if the CPU 41 maintains the current front end deceleration during the current cycle, the descent speed V3 will not be less than the target speed Vd (S97: No). In this case, the CPU 41 maintains the current front end deceleration during the current cycle (S98). As a result, the front end speed approaches the target speed Vd linearly as time passes. The CPU 41 transfers the process to S100.
[0185] Since the maximum front end deceleration is lower than the current maximum front end deceleration during the current cycle, the front end deceleration maintained sometimes exceeds the maximum front end deceleration during the current cycle (S96: Yes). Furthermore, for example, when the current front end speed Vf is close to the target speed Vd, when the CPU 41 maintains the current front end deceleration during the current cycle, the first rising speed V1 is less than the target speed Vd (S97: Yes). In these cases, the CPU 41 reduces the current front end deceleration by an amount corresponding to the unit maximum front end jerk (S99). As a result, the front end speed slowly approaches the target speed Vd as time passes. The CPU 41 transfers the process to S100.
[0186] After S92, S95, S98 or S99, the CPU 41 performs a speed update process (S100). In the speed update process of S100, the CPU 41 reduces the speed change amount of one cycle when decelerating at the front end deceleration calculated in S92, S95, S98 or S99 from the current front end speed Vf. In addition, when the value calculated in S92 is a positive value (i.e., acceleration), the CPU 41 adds the speed change amount of one cycle when accelerating at the calculated front end acceleration to the current front end speed Vf. The CPU 41 outputs a signal to each of the X-axis motor 61, the Y-axis motor 62, the Z-axis motor 63, the A-axis motor 64 and the C-axis motor 65 in such a way that the actual front end speed in the working machine 1 becomes the calculated front end speed, and controls each drive axis during the current cycle. Thus, the CPU 41 controls the front end point and the front end speed. The CPU 41 returns the processing to Fig.24 The main process shown.
[0187] Back to Fig.24 After the first speed control process (S34) or the second speed control process (S35), the CPU 41 determines whether the current position Pf has reached the end point Pe (Nnow) (S36). If the current position Pf has not reached the end point Pe (Nnow) (S36: No), the CPU 41 returns the process to S31. Whenever the CPU 41 repeatedly performs the first speed control process or the second speed control process, the current position Pf moves toward the end point Pe (Nnow). If the current position Pf has reached the end point Pe (Nnow) (S36: Yes), the CPU 41 determines whether Nnow is less than Nend (S41).
[0188] When the block Nnow+1 exists in the pre-read blocks, Nnow is smaller than Nend (S41: Yes). In this case, the CPU 41 determines whether the target block Nd is the current block Nnow (S42).
[0189] When the pre-read destination block is the target block Nd, if Nnow is smaller than Nend, the target block Nd will not become the current block Nnow. On the other hand, when the transfer target block is the target block Nd, even if Nnow is smaller than Nend, the target block Nd may become the current block Nnow.
[0190] When the pre-read destination block is the target block Nd, the target block Nd is not the current block Nnow (S42: No). Furthermore, when the transfer object block is the target block Nd and the current block Nnow has not reached the target block Nd, the target block Nd is not the current block Nnow (S42: No). In these cases, the CPU 41 transfers the processing to S44 without performing S43.
[0191] When the transfer object block Ntmp is the target block Nd, and the acceleration and deceleration process is repeated, the target block Nd reaches the current block Nnow (S42: Yes). In this case, the CPU 41 sets the pre-read end block Nend as the target block Nd (S43). The CPU 41 sets "0 mm / min" as the target speed Vd (S43). The CPU 41 transfers the process to S44.
[0192] The CPU 41 sets Nnow+1 to Nnow (S44). The CPU 41 returns the process to Fig.23 S22 shown. Whenever the current position Pf reaches the end point Pe (Nnow) (S36: Yes), if there is a block Nend+1 in the NC program (S22: Yes), the CPU 41 reads the block Nend+1 (S23). Thus, for example, when the current position Pf reaches the end point Pe (N1), the CPU 41 reads the block N7 from the NC program. The CPU 41 stores the calculated values in each area corresponding to the block N7 in the block information storage area 431. Similarly, when the current position Pf reaches the end point Pe (N2), the CPU 41 stores the calculated values in each area corresponding to the block N8 in the block information storage area 431. Thus, Figure 4 The tile information storage area 431 shown is in a state where calculated numerical values are stored in all of the areas corresponding to the tiles N1 to N8 .
[0193] like Fig.23 As shown, in S22, when the pre-read end block Nend becomes the final block of the NC program, there is no block Nend+1 in the NC program (S22: No). For example, when block N8 is the pre-read end block Nend, there is no block N9 in the NC program (S22: No). In this case, the CPU 41 transfers the processing to Fig.24 S31 shown.
[0194] In the previous reverse interpolation process (S31), the CPU 41 Fig.25In the case where the block Ntmp-1 is set as the target block Nd in S72 shown in the figure, the target block Nd is not the pre-read end block Nend (S25: No). In this case, the CPU 41 sets Nend+1 as Nend (S29). The CPU 41 transfers the processing to the state where the target block Nd is reset (S26) and the reverse interpolation point Prev, the reverse interpolation speed Vrev, and the reverse interpolation acceleration Arev are reset (S20). Fig.24 Thus, the target block Nd, the reverse interpolation point Prev, the reverse interpolation speed Vrev and the reverse interpolation acceleration Arev are fixed to Fig.25 The value set in S72 or S73 shown.
[0195] When the final block becomes the pre-read end block Nend (S22: No), no more pre-read blocks are read. In this case, the pre-read end block is fixed in the final block. On the other hand, the current block is transferred to the blocks at the end of the processing order by performing acceleration and deceleration processing. Fig.24 As shown, by repeating the acceleration and deceleration process, the current block Nnow reaches the pre-read end block Nend, and then the current position Pf reaches the end point Pe (Nend) (S41: No). In this case, since there is no block Nnow+1 in the NC program, the CPU 41 ends the main process.
[0196] <Function and Effect of the Present Embodiment>
[0197] As described above, in the present embodiment, the CPU 41 determines the target block Nd and determines the target speed Vd at the command point of the determined target block Nd. The CPU 41 calculates the first rising speed V1 based on the maximum front end jerk, the current front end speed Vf, and the current front end acceleration. The CPU 41 calculates the reverse interpolation point Prev in sequence. Whenever the CPU 41 calculates the reverse interpolation point Prev, the CPU 41 calculates the second rising speed V2 based on the maximum front end jerk, the reverse interpolation speed Vrev, and the reverse interpolation acceleration Arev. The CPU 41 calculates the reverse interpolation point Prev until the second rising speed V2 becomes greater than the first rising speed V1. Accordingly, by performing the acceleration and deceleration processing corresponding to the reverse interpolation based on the CPU 41, even if the front end speed is increased to the maximum on the front end path, it is possible to prevent the tool front end from decelerating to the target speed Vd at the command point of the target block Nd. Therefore, the numerical control device 40 can easily move the tool tip at the command point of the target block Nd at the maximum tip speed at which the tool tip can be decelerated to the target speed Vd. Furthermore, the CPU 41 calculates the reverse interpolation point Prev while performing the acceleration and deceleration process to calculate the speed curve of the tool tip. Therefore, compared with the case where the speed curve of the tool tip is calculated and the acceleration and deceleration process is performed, the CPU 41 can easily suppress the amount of calculation obtained by the numerical control device 40 before the acceleration and deceleration process. Therefore, the CPU 41 contributes to the advantage of suppressing the increase in the moving time of the tool tip while suppressing the amount of calculation for calculating the speed curve before the acceleration and deceleration process.
[0198] In the case where there is a transfer block, the CPU 41 determines the block that is one block before the transfer target block in the processing order as the target block Nd, and sets the minimum starting speed Vs of the transfer block as the target speed Vd. Therefore, at the command point of the newly determined target block Nd, reverse interpolation is performed so that the tool tip can be decelerated to the starting speed Vs of the pre-read block that is one block after the target block that is newly determined as the target speed Vd. Therefore, the CPU 41 complies with the upper limit of the allowable tip speed at the command point of the block, which contributes to the advantage of suppressing the increase in the moving time of the tool tip while suppressing the amount of calculation for calculating the speed curve of the tool tip before the acceleration and deceleration processing.
[0199] When the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 is greater than the movement margin, the CPU 41 decelerates the front end of the tool at the maximum front end deceleration and the front end deceleration based on the maximum front end jerk, so that the front end speed (first rising speed V1) is not less than the target speed Vd. Accordingly, the CPU 41 decelerates the front end of the tool to the maximum extent within the range of the allowable front end deceleration and the front end jerk, and decelerates the front end of the tool in a manner that decelerates to the target speed Vd at the instruction point of the target block Nd. Therefore, the deceleration time of the front end of the tool is suppressed from becoming longer. Therefore, the numerical control device 40 easily ensures that the acceleration time of the front end of the tool is long. Therefore, the CPU 41 helps to suppress the advantage of the movement time of the front end of the tool from becoming longer.
[0200] When the total distance of the front end movement amount L1, the front end movement amount L2, and the front end movement amount L3 is not greater than the movement margin, the CPU 41 accelerates the front end of the tool with the maximum front end acceleration and the front end acceleration based on the maximum front end jerk so that the front end speed (first rising speed V1) at the first rising point P1 does not exceed the limit speed Vp at the first rising point P1. Accordingly, the CPU 41 accelerates the front end of the tool to the maximum extent within the range of the allowable front end acceleration and the front end jerk so that the first rising speed V1 does not exceed the limit speed Vp at the first rising point P1. Therefore, the CPU 41 contributes to the advantage of suppressing the movement time of the front end of the tool from becoming longer.
[0201] The CPU 41 reads the blocks sequentially as the pre-read blocks until the pre-read end block Nend. The CPU 41 calculates the reverse interpolation point Prev when the pre-read end block Nend is read. In this case, the reverse interpolation point Prev is not calculated every time the pre-read blocks are read one by one. Therefore, the CPU 41 contributes to the advantage of suppressing the increase of the processing load required for calculating the reverse interpolation point Prev.
[0202] When the CPU 41 completes the acceleration / deceleration processing up to the instruction point of the current block Nnow, the CPU 41 newly reads a block that is one block after the current pre-read end block Nend in the processing order as the pre-read end block Nend. When the CPU 41 newly reads the pre-read end block Nend, the CPU 41 newly determines the target block Nd and the target speed Vd. Accordingly, whenever the CPU 41 completes the acceleration / deceleration processing of the current block Nnow, the CPU 41 newly reads a block as the pre-read end block Nend. That is, the CPU 41 does not always read all of the multiple blocks at once as the pre-read blocks. Therefore, the CPU 41 contributes to the advantage of suppressing the control load required for reading the pre-read blocks.
[0203] The machine tool 1 has three linear axes (X axis, Y axis, Z axis), and two rotation axes (A axis, C axis). Therefore, the machine tool 1 has the advantage of being able to perform complex processing such as changing the posture (tilt) of the tool 3 relative to the workpiece W. On the other hand, the movement of the tool 3 relative to the workpiece W becomes complicated, and accordingly it may be difficult to analytically calculate the speed limit and the maximum front end acceleration. Therefore, before the acceleration and deceleration process, it may be difficult to determine the entire speed curve of the tool front end. In contrast, in the present embodiment, the CPU 41 dynamically performs reverse interpolation processing in parallel with the acceleration and deceleration process. Thus, the speed curve of the tool front end is calculated in parallel with the acceleration and deceleration process. Therefore, the CPU 41 helps to suppress the control load required to calculate the speed curve of the tool front end. Therefore, the CPU 41 helps to suppress the control load required to calculate the speed curve of the tool front end while being able to perform the advantage of complex processing performed by the machine tool 1.
[0204] <Correspondence between the above-described embodiment and the present invention>
[0205] In the above embodiment, the workpiece W corresponds to the "object" of the present invention. The tool 3 corresponds to the "moving unit" of the present invention. Fig.23 The CPU 41 in S12 and S23 shown in the figure corresponds to the "reading unit" of the present invention. Fig.23 The S14 shown is Fig.24 The S43 and Fig.25 The CPU 41 of S72 shown in FIG. 1 corresponds to the "determining unit" of the present invention. Fig.25 The CPU 41 of S51 shown in FIG. 1 corresponds to the "first calculation unit" of the present invention. Fig.25 The CPU 41 of S62 shown in FIG. 1 corresponds to the "reverse interpolation unit" of the present invention. Fig.25 The CPU 41 in S53 and S63 shown corresponds to the "second calculation unit" of the present invention.
[0206] conduct Fig.23 The CPU 41 of S24 shown in FIG. 1 corresponds to the "third calculation unit" of the present invention. Fig.25 The CPU 41 of S71 shown in FIG. 1 corresponds to the "first determination unit" of the present invention. Fig.24 The CPU 41 in S33 shown in FIG. 1 corresponds to the "second determination unit" of the present invention. Fig.28 The CPU 41 in S100 shown in FIG. 1 corresponds to the "first speed control unit" of the present invention. Fig.26 The CPU 41 in S82 or S85 shown in the figure corresponds to the "fourth calculation unit" of the present invention. Fig.26 S88 or Fig. 27The CPU 41 in S108 shown in FIG. 1 corresponds to the "second speed control unit" of the present invention. Fig.26 The S88 shown, Fig. 27 S108 or Fig.28 The CPU 41 in S100 shown corresponds to the "block processing unit" of the present invention.
[0207] The rotating table 29 corresponds to the "holding unit" of the present invention. The main shaft 9 corresponds to the "main shaft" of the present invention. Fig.23 S12 and S23 shown correspond to the "reading process" of the present invention. Fig.23 The S14 shown is Fig.24 The S43 and Fig.25 S72 shown corresponds to the "determination process" of the present invention. Fig.25 S51 shown corresponds to the "first calculation process" of the present invention. Fig.23 The S20 and Fig.25 S62 and S73 shown correspond to the "reverse interpolation processing" of the present invention. Fig.25 S53 and S63 shown correspond to the "second calculation process" of the present invention. The CPU 41 corresponds to the "computer" of the present invention.
[0208] <Modification>
[0209] The present invention can be modified in various ways from the above-described embodiment. For example, the drive shafts of the machine tool 1 are not limited to five shafts, but may be one shaft, two shafts, three shafts, four shafts, or six shafts or more. The driving method based on the drive shafts of the machine tool 1 is not limited to the above-described embodiment. The machine tool 1 may also be a lathe, a robot, a parallel kinematic machine, etc.
[0210] In the above-described embodiment, the machine tool 1 rotates the rotary table 29 through two drive shafts, namely the A-axis and the C-axis. In contrast, the machine tool 1 may also change the posture of the spindle 9 relative to the workpiece W so that the spindle 9 rotates through two drive shafts, namely the A-axis and the C-axis. The machine tool 1 may also change the posture of the spindle 9 relative to the workpiece W so that the spindle 9 rotates through one of the drive shafts, namely the A-axis and the C-axis, and the rotary table 29 rotates through the other drive shaft, namely the A-axis and the C-axis. In these cases, the machine tool 1 also has the advantage of being able to perform complex processing by changing the posture (tilt) of the tool 3 relative to the workpiece W.
[0211] The NC program may not directly indicate the command point based on the coordinate value. For example, in the NC program, the tool posture vector may be indicated instead of the coordinate value of the A-axis and the C-axis. In this case, the CPU 41 may also calculate the coordinate value of the command point of the A-axis and the C-axis based on the tool posture vector.
[0212] The CPU 41 may not calculate the first rising speed V1, the reverse interpolation point Prev, and the second rising speed V2 for all of the plurality of blocks. For example, the CPU 41 may calculate the first rising speed V1, the reverse interpolation point Prev, and the second rising speed V2 for only one of the plurality of blocks (for example, the block with code G0).
[0213] The pre-read upper limit Npara may not be set. That is, before the reverse interpolation process (S31), the CPU 41 may read in the final block as the pre-read block regardless of the number of the blocks. The CPU 41 may determine the target block Nd and the target speed Vd each time it reads in a pre-read block.
[0214] The method for determining the front end acceleration in the first speed control process is not limited to the above-described embodiment. For example, the CPU 41 may omit a part or all of the judgments of S81, S82, S84, and S85. For example, in the case where all of the judgments of S81, S82, S84, and S85 are omitted, the CPU 41 may always increase the amount corresponding to the unit maximum front end jerk. In the first speed control process, the CPU 41 may perform a judgment related to the front end speed and front end acceleration at the current position Pf or a point (e.g., an intermediate point) between the current position Pf and the first rising point P1 instead of or based on the judgments of S81, S82, S84, and S85.
[0215] The CPU 41 may impose a restriction greater than that in the above-described embodiment on one or both of the maximum front end acceleration and the speed limit Vp in the judgment of a part or all of S81, S82, S84, and S85. The method for determining the deceleration in the second speed control process is also the same as the method for determining the acceleration in the first speed control process, and is not limited to the above-described embodiment. For example, the CPU 41 may omit a part or all of the judgments of S93, S94, S96, and S97. The CPU 41 may impose a restriction greater than that in the above-described embodiment on the maximum front end deceleration in the judgment of one or both of S93 and S96.
[0216] Furthermore, for example, when the current front end acceleration is increased by an amount corresponding to the unit maximum front end jerk, when the increased front end acceleration exceeds the maximum front end acceleration and the current front end acceleration is maintained, sometimes the maintained front end acceleration is less than the maximum front end acceleration. In the above case, the CPU 41 may also make the front end acceleration consistent with the maximum front end acceleration. Similarly, when the current front end deceleration is increased by an amount corresponding to the unit maximum front end jerk, when the increased front end deceleration exceeds the maximum front end deceleration and the current front end deceleration is maintained, when the maintained front end deceleration is less than the maximum front end deceleration, the CPU 41 may also make the front end deceleration consistent with the maximum front end deceleration. In S81, S84, S93, S96, S101 or S104, the CPU 41 may make a judgment based on the maximum front end acceleration or the maximum front end deceleration at the current position Pf instead of the maximum front end acceleration at the first ascending point P1 or the maximum front end deceleration at the descending point P3. For example, in S84, the CPU 41 may determine whether the maintained front end acceleration exceeds the maximum front end acceleration at the current position Pf while maintaining the current front end acceleration during the current cycle.
[0217] In the above embodiment, the CPU 41 calculates the arrival block (S54, S64) and performs processing corresponding to whether there is a transfer block. In contrast, the CPU 41 may not calculate the arrival block and may not determine whether there is a transfer block. In the above case, the CPU 41 may also omit S72 and S73 and always use the target block Nd as the pre-read end block Nend.
[0218] In the embodiment, the maximum shaft acceleration represents the upper limit of the allowable shaft acceleration or shaft deceleration. In contrast, the maximum shaft acceleration may represent the upper limit of the allowable shaft acceleration. In the case, the maximum shaft deceleration speed representing the upper limit of the allowable shaft deceleration may be stored in the flash memory 44 separately from the maximum shaft acceleration.
[0219] In the embodiment, the first prescribed acceleration, the second prescribed acceleration, the third prescribed acceleration, the first prescribed deceleration, or the second prescribed deceleration may be, for example, a unit maximum front end jerk.
[0220] In the above-described embodiment, for simplicity of description, positive acceleration is referred to as “acceleration” and negative acceleration is referred to as “deceleration”. However, the acceleration in the present invention is a concept that also includes negative acceleration.
[0221] Explanation of symbols
[0222] 1: Working machinery
[0223] 9: Spindle
[0224] 29: Rotating table
[0225] 40: Numerical control device
[0226] 41: CPU
Claims
1. A numerical control device, which reads a numerical control program including a plurality of blocks representing instruction points in a moving path of a moving part that moves relative to an object, and sequentially processes the plurality of blocks, thereby controlling the position and speed of the moving part, the numerical control device being characterized in that it comprises: a reading unit that reads a current block to be processed among the plurality of blocks and a pre-read block that is processed later than the current block among the plurality of blocks; a determination unit that determines a target block among the current block and the pre-read block read by the reading unit, and determines a target speed, that is, a target speed, of the moving unit at the instruction point of the determined target block; A first calculation unit calculates a first rising speed, which is a speed of the moving unit at a first rising point in the moving path of the moving unit, based on a maximum jerk that is an upper limit of an allowable jerk, a current speed of the moving unit, and a current acceleration of the moving unit, wherein the first rising point is a position where the acceleration of the moving unit changes from the current acceleration of the moving unit to a first specified acceleration; a reverse interpolation unit for performing reverse interpolation processing, wherein the reverse interpolation processing is a process of sequentially calculating reverse interpolation points as positions where the moving unit moves, from the instruction point of the target block determined by the determination unit toward the starting point of the current block in the moving path of the moving unit, and the reverse interpolation point initially calculated, i.e., the initial reverse interpolation point, the speed of the moving unit at the initial reverse interpolation point, and the acceleration of the moving unit at the initial reverse interpolation point are respectively the instruction point of the target block, the target speed, and a second prescribed acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is a position where the moving unit moves an amount during a prescribed time based on the speed of the moving unit and the acceleration of the moving unit at the current reverse interpolation point, the maximum acceleration as the upper limit of the permissible acceleration, and the speed movement of the maximum jerk; as well as A second calculation unit calculates the speed of the moving unit at a second rising point, i.e., a second rising speed, in the moving path of the moving unit, each time the reverse interpolation unit calculates the reverse interpolation point, from the reverse interpolation point toward the starting point of the current block, based on the maximum jerkiness, the speed of the moving unit at the reverse interpolation point calculated by the reverse interpolation unit, and the acceleration of the moving unit at the reverse interpolation point, wherein the second rising point is a position where the acceleration of the moving unit changes from the acceleration of the moving unit at the reverse interpolation point to a third specified acceleration, The reverse interpolation unit calculates the reverse interpolation point until the second rising speed calculated by the second calculation unit becomes equal to or higher than the first rising speed calculated by the first calculation unit.
2. The numerical control device according to claim 1, characterized in that: include: a third calculating unit, calculating a starting point speed, the starting point speed being an upper limit of an allowable speed of the moving unit at the starting point of the pre-read block; as well as The first judgment unit judges whether there is a transfer block whose starting point speed is less than the second rising speed in the pre-read blocks in the processing order between the pre-read block that is one block later than the current block in the processing order and the pre-read block to which the second rising point belongs, When the first determination unit determines that the transfer block exists, the determination unit determines the block that is one block before the transfer block with the smallest starting speed in the processing order as the target block, and determines the smallest starting speed of the transfer block as the target speed.
3. The numerical control device according to claim 1 or 2, characterized in that: include: a second judgment unit, which judges whether the total of the moving distance of the moving unit from the current position of the moving unit in the current block to the first rising point, the moving distance of the moving unit from the second rising point to the reverse interpolation point, and the moving distance of the moving unit from the reverse interpolation point to the instruction point of the target block is greater than a moving margin, when the moving distance of the moving unit in the direction from the current position of the moving unit in the current block to the instruction point of the target block is set to positive and the moving distance of the moving unit in the direction from the instruction point of the target block to the current position of the moving unit in the current block is set to negative. The moving margin is the moving distance of the moving unit from the current position of the moving unit in the current block to the instruction point of the target block. as well as The first speed control unit controls the speed of the moving unit with a maximum deceleration as an upper limit of an allowable deceleration and a deceleration based on the maximum jerk so that the speed of the moving unit does not fall below the target speed when the second judgment unit judges that the total distance is greater than the moving margin.
4. The numerical control device according to claim 1 or 2, characterized in that: include: a second judgment unit, which judges whether the total of the moving distance of the moving unit from the current position of the moving unit in the current block to the first rising point, the moving distance of the moving unit from the second rising point to the reverse interpolation point, and the moving distance of the moving unit from the reverse interpolation point to the instruction point of the target block is greater than a moving margin, when the moving distance of the moving unit in the direction from the current position of the moving unit in the current block to the instruction point of the target block is set to positive and the moving distance of the moving unit in the direction from the instruction point of the target block to the current position of the moving unit in the current block is set to negative. The moving margin is the moving distance of the moving unit from the current position of the moving unit in the current block to the instruction point of the target block. a fourth calculation unit that calculates a speed limit, the speed limit being a maximum speed that complies with an upper limit of an allowable speed of the moving unit at each interpolation point on the moving path; as well as The second speed control unit controls the speed of the moving unit with the maximum acceleration and the acceleration based on the maximum jerk, when the second judgment unit determines that the total distance is not greater than the moving margin, so that the speed of the moving unit at the first rising point does not exceed the limit speed at the first rising point calculated by the fourth calculation unit.
5. The numerical control device according to claim 1, characterized in that: When the number of the plurality of blocks is greater than the number corresponding to the prescribed order, the reading unit sequentially reads in as the pre-read blocks a block which is one block later in the processing order than the current block to a block which is a pre-read end block after the current block in the processing order after the prescribed order. The reverse interpolation unit calculates the reverse interpolation point when the reading unit has read the pre-reading end point block.
6. The numerical control device according to claim 5, characterized in that: Including block processing unit, The block processing unit controls the position and speed of the moving unit by processing the current block read by the reading unit. In a case where the block processing unit processes up to the instruction point of the current block, the reading unit newly reads a next block which is one block later in the processing order than the block processed by the block processing unit as the current block as the current block, and newly reads a block which is after the next block through the prescribed order in the processing order as the pre-read end block, When the reading unit newly reads the pre-reading end block, the determination unit newly determines the target block and newly determines the target speed.
7. A working machine, characterized in that: include: The numerical control device according to claim 1; a holding portion for holding the workpiece; and a spindle equipped with a tool for processing the workpiece, The workpiece held by the holding portion is processed using at least three linear axes and one rotation axis, The movement path is defined according to the relative position of the front end of the tool with respect to the workpiece. The maximum jerk is the upper limit of the relative jerk of the front end of the tool relative to the workpiece. The maximum acceleration is an upper limit of a relative acceleration of the tip of the tool with respect to the workpiece, at which the accelerations of the linear axis and the rotary axis are respectively less than the allowable accelerations of the linear axis and the rotary axis. The speed of the moving portion is defined by a relative speed of the tip of the tool with respect to the workpiece.
8. The working machine according to claim 7, characterized in that: The three linear axes and two rotation axes for rotating the holding portion are provided.
9. The working machine according to claim 7, characterized in that: The three linear axes and two rotation axes for changing the posture of the spindle relative to the workpiece are provided.
10. The working machine according to claim 7, characterized in that: The device includes the three linear axes, one rotation axis for changing the posture of the spindle relative to the workpiece, and one rotation axis for rotating the holding portion.
11. A numerical control method, performed by a numerical control device, wherein the numerical control device reads a numerical control program including a plurality of blocks representing instruction points in a moving path of a moving part that moves relative to an object, and sequentially processes the plurality of blocks, thereby controlling the position and speed of the moving part, wherein the numerical control method is characterized in that it includes: Reading processing, reading a current block to be processed among the plurality of blocks and a pre-read block whose processing order is later than that of the current block among the plurality of blocks; a determination process of determining a target block to be targeted among the current block and the pre-read block read in the read process, and determining a target speed, that is, a target speed, of the moving part at the instruction point of the determined target block; A first calculation process is to calculate the speed of the moving part at a first ascending point, i.e., a first ascending speed, based on a maximum jerk as an upper limit of an allowable jerk, a current speed of the moving part, and a current acceleration of the moving part in the moving path of the moving part, wherein the first ascending point is a position where the acceleration of the moving part changes from the current acceleration of the moving part to a first prescribed acceleration; A reverse interpolation process is a process of sequentially calculating reverse interpolation points as positions where the moving unit moves, from the command point of the target block determined by the determination process toward the starting point of the current block in the moving path of the moving unit, and the reverse interpolation point initially calculated, i.e., the initial reverse interpolation point, the speed of the moving unit at the initial reverse interpolation point, and the acceleration of the moving unit at the initial reverse interpolation point are respectively the command point of the target block, the target speed, and a second prescribed acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is a position where the moving unit moves an amount during a prescribed time at a speed based on the speed of the moving unit and the acceleration of the moving unit at the current reverse interpolation point, the maximum acceleration as the upper limit of the permissible acceleration, and the maximum jerk; as well as The second calculation process is to calculate the speed of the moving part at a second rising point, i.e., a second rising speed, from the reverse interpolation point toward the starting point of the current block, each time the reverse interpolation process calculates the reverse interpolation point, based on the maximum jerkiness, the speed of the moving part at the reverse interpolation point calculated by the reverse interpolation process, and the acceleration of the moving part at the reverse interpolation point, in the moving path of the moving part, wherein the second rising point is a position where the acceleration of the moving part changes from the acceleration of the moving part at the reverse interpolation point to a third specified acceleration, The reverse interpolation process calculates the reverse interpolation point until the second rising speed calculated by the second calculation process becomes equal to or higher than the first rising speed calculated by the first calculation process.
12. A numerical control program, characterized in that: A computer of a numerical control device for controlling the position and speed of a moving part by reading a numerical control program including a plurality of blocks indicating instruction points in a moving path of a moving part that moves relative to an object and sequentially processing the plurality of blocks is caused to execute the following processing: Reading processing, reading a current block to be processed among the plurality of blocks and a pre-read block whose processing order is later than that of the current block among the plurality of blocks; a determination process of determining a target block to be targeted among the current block and the pre-read block read in the read process, and determining a target speed, that is, a target speed, of the moving part at the instruction point of the determined target block; A first calculation process is to calculate the speed of the moving part at a first ascending point, i.e., a first ascending speed, based on a maximum jerk as an upper limit of an allowable jerk, a current speed of the moving part, and a current acceleration of the moving part in the moving path of the moving part, wherein the first ascending point is a position where the acceleration of the moving part changes from the current acceleration of the moving part to a first prescribed acceleration; A reverse interpolation process is a process of sequentially calculating reverse interpolation points as positions where the moving unit moves, from the command point of the target block determined by the determination process toward the starting point of the current block in the moving path of the moving unit, and the reverse interpolation point initially calculated, i.e., the initial reverse interpolation point, the speed of the moving unit at the initial reverse interpolation point, and the acceleration of the moving unit at the initial reverse interpolation point are respectively the command point of the target block, the target speed, and a second prescribed acceleration, and the reverse interpolation point calculated after the current reverse interpolation point is a position where the moving unit moves an amount during a prescribed time based on the speed of the moving unit and the acceleration of the moving unit at the current reverse interpolation point, the maximum acceleration as the upper limit of the permissible acceleration, and the speed movement of the maximum jerk; as well as The second calculation process is to calculate the speed of the moving part at a second rising point, i.e., a second rising speed, from the reverse interpolation point toward the starting point of the current block, each time the reverse interpolation process calculates the reverse interpolation point, based on the maximum jerkiness, the speed of the moving part at the reverse interpolation point calculated by the reverse interpolation process, and the acceleration of the moving part at the reverse interpolation point, in the moving path of the moving part, wherein the second rising point is a position where the acceleration of the moving part changes from the acceleration of the moving part at the reverse interpolation point to a third specified acceleration, In the reverse interpolation process, the reverse interpolation point is calculated until the second rising speed calculated in the second calculation process becomes equal to or higher than the first rising speed calculated in the first calculation process.
Citation Information
Patent Citations
Numerical controller for controlling speed by command route speed condition
JP2013097736A