Controller of rotary axis

A controller of a rotary axis includes: a storage unit that stores data of a braking distance for each rotation number of the rotary axis and provides a current braking distance S3 corresponding to a current rotation number of the rotary axis; and a deceleration command calculating unit that calculates a speed command V2 of the rotary axis on a basis of the remaining movement amount S2 and the current braking distance S3; in which the deceleration command calculating unit maintains the current rotation number of the rotary axis in a case in which a difference S4 between the remaining movement amount S2 and the current braking distance S3 is equal to or greater than a predetermined value, and starts deceleration of the rotary axis in a case in which the difference S4 is less than the predetermined value.

This application is based on and claims the benefit of priority from Japanese Patent Application No. 2019-101388, filed on 30 May, 2019, the content of which is incorporated herein by reference.

BACKGROUND OF THE INVENTION

Field of the Invention

The present invention relates to a controller of a rotary axis in a machine such as a machine tool.

Related Art

For example, in a machine tool, it has been demanded to stop a spindle (rotary axis) which is rotating at high speed, at any rotational position at high precision according to its purpose. For example, in order to perform tapping machining at a predetermined position on a workpiece by lathe, it is necessary to stop the spindle at a predetermined position. In addition, in a case of milling or contour control, the spindle is set to be in the positioning mode to command the position with a machining program, thereby automatically controlling the spindle position (the motion control during spindle positioning). When switching to the positioning mode, the spindle is rotating in many cases, and sometimes rotates at high speeds exceeding 10000 rpm. Japanese Patent Nos. 4099503 and 5925066 disclose technology for stopping the spindle (rotary axis) rotating at a high speed, at a desired position (predetermined position), for example, in the machine tool.

SUMMARY OF THE INVENTION

Thus, in the field of a controller of the rotary axis, it is desirable to reduce the time required for the rotary axis to decelerate to a predetermined speed at a predetermined position.

A controller of a rotary axis according to the disclosure that decelerates the rotary axis to a predetermined speed at a predetermined position, includes: a total movement command calculating unit that calculates a remaining movement amount S2by subtracting a movement command M1for each control cycle in every control cycle from a total movement amount S1from a current position until the predetermined position, in a case in which a positioning request to decelerate the rotary axis to the predetermined speed at the predetermined position is issued; a movement command calculating unit that calculates the movement command M1for each control cycle from the remaining movement amount S2; a storage unit that stores in advance data of a braking distance for each rotation number of the rotary axis, the data of the braking distance being based on a maximum torque characteristic with respect to a rotation number of a motor for driving the rotary axis, refers to the data of the braking distance, and provides a current braking distance S3corresponding to a current rotation number of the rotary axis; a deceleration command calculating unit that calculates a speed command V2of the rotary axis on a basis of the remaining movement amount S2and the current braking distance S3; and a speed control unit that causes a speed of the motor to follow the speed command V2, in which the deceleration command calculating unit calculates the speed command V2to maintain the current rotation number of the rotary axis in a case in which a difference S4between the remaining movement amount S2and the current braking distance S3is equal to or greater than a predetermined value, and calculates the speed command V2to start deceleration of the rotary axis in a case in which the difference S4is less than the predetermined value.

According to the present disclosure, in the field of a controller of a rotary axis, it is possible to reduce the time required for the rotary axis to decelerate to a predetermined speed at a predetermined position.

DETAILED DESCRIPTION OF THE INVENTION

Hereinafter, a description will be given of an example of an embodiment of the present invention with reference to the attached drawings. It should be noted that the same reference numerals will be given to the same or equivalent parts in the drawings.

FIG. 1is a diagram showing the configuration of a controller of a spindle (rotary axis) in a machine tool according to the present embodiment. A controller10shown inFIG. 1is, for example, a numerical control apparatus for controlling a spindle61(hereinafter, also referred to as a rotary axis) by controlling the spindle motor60in the machine tool. Some machine tools have a reduction mechanism by gears or a belt between the spindle motor and the spindle. However, in this example, for simplicity of explanation, it is assumed that the spindle motor and the spindle are directly connected, and the speed of the spindle motor and the spindle speed are equal.

In such a machine tool, the motor60may be, for example, a servo motor. Furthermore, for such a machine tool, for example, a speed detecting unit32for detecting the speed of the rotary axis61and a position detecting unit33for detecting a position with respect to the mechanical origin on the rotary axis61are provided.

The controller10includes a spindle speed command calculating unit12, a stop position command calculating unit20, a total movement command calculating unit21, a movement command calculating unit22, a position loop control unit (position control unit)25, a speed command selecting unit30, a speed loop control unit (speed control unit)35, a data storage unit41of the braking distance, and a deceleration command calculating unit43.

The controller10(except for the data storage unit41) is, for example, composed of an arithmetic processor such as DSP (Digital Signal Processor) and FPGA (Field-Programmable Gate Array). Various functions of the controller10(except for the data storage unit41) are realized by executing predetermined software (programs and applications) stored in the storage unit, for example. Various functions of the controller10(except for the data storage unit41) may be realized by cooperation between hardware and software, or only by hardware (electronic circuits).

The data storage unit41in the controller10may be rewritable memory, e.g., EEPROM, or a rewritable disk, e.g., an HDD (Hard Disk Drive) or an SSD (Solid State Drive).

The controller10normally controls the speed of the spindle61on the basis of the speed command V0calculated by the spindle speed command calculating unit12. More specifically, the speed command selecting unit30normally selects the speed command V0supplied from the spindle speed command calculating unit12. The spindle speed command calculating unit12calculates, for example, the rotation number designated by the machining program or the rotation number of the spindle instructed by the PLC (Programmable Logic Controller) as the speed command V0.

The speed loop control unit35controls the speed of the spindle motor60so that the speed of the spindle61follows the speed command on the basis of the error between the speed command selected by the speed command selecting unit30and the speed FB signal detected by the speed detecting unit32. More specifically, the speed loop control unit35calculates a drive current of the spindle motor60.

Furthermore, the controller10has, for example, a function of stopping the rotary axis at a predetermined position (predetermined rotational position). More specifically, the speed command selecting unit30first selects the speed command V2calculated by the deceleration command calculating unit43when a positioning request for stopping the rotary axis61at a predetermined position is issued. Thereafter, in a case in which the rotation number of the rotary axis61is equal to or less than a base rotation number of the motor60and it is in the phase matching completion state (details will be described later), the speed command selecting unit30selects the speed command V1calculated by the position loop control unit25.

The stop position command calculating unit20, for example, calculates the total movement amount S1from the current position to a predetermined position on the basis of a predetermined position given on the basis of the machining program and the position FB signal detected by the position detecting unit33.

The total movement command calculating unit21calculates the remaining movement amount S2on the basis of the total movement amount S1and a movement command M1for each control cycle, which will be described later. More specifically, the total movement command calculating unit21takes in the total movement amount S1by closing a switch21bonly when the positioning request is issued. Furthermore, in the total movement command calculating unit21, a subtractor subtracts the movement command M1for each control period, and an integrating unit21aand an adder add the remaining movement amount S2in the previous control cycle for each control cycle. The total movement command calculating unit21calculates the remaining movement amount S2in the present control cycle in this way.

The movement command calculating unit22calculates the movement command M1for each control cycle from the remaining movement amount S2. The movement command calculating unit22uses the speed FB signal as an initial value of the speed command, for example. Alternatively, in a case in which the speed command is switched from V2to V1by the speed command selecting unit30, the movement command calculating unit22uses V2as the initial value of the speed command. For example, it is desirable for the movement command M1to cause the waveform of the speed and the acceleration to continuously vary and the waveform is smoothed to suppress the mechanical vibration of the spindle.

The position loop control unit25calculates the speed command V1so that the position of the rotary axis61coincides with a predetermined position on the basis of the positional error between the movement command M1for each control cycle calculated by the movement command calculating unit22and the position feedback signal (the position FB signal) of the rotary axis61detected by the position detection unit33. In order to increase the responsiveness of the position, position feed forward is generally used. The movement command M2becomes the position feed forward as it is. The sum of the speed command and the position feed forward calculated by the position loop control unit25becomes the speed command V1based on the position control.

Here, with reference toFIGS. 2 to 5, a description will be given of the positioning operation of the rotary axis described in Japanese Patent Nos. 4099503 and 5925066.

FIG. 2is a diagram showing the positioning operation of the rotary axis described in Japanese Patent No. 4099503. As shown inFIG. 2, in the positioning operation of the rotary axis described in Japanese Patent No. 4099503,(i) when the positioning request is issued during the motor rotation (i.e., during the rotation of the rotary axis) (time T11), the deceleration of the motor (i.e., the rotary axis) to the predetermined rotation number V1is performed at the full torque deceleration by the maximum acceleration based on the maximum torque characteristic with respect to the rotation number of the motor (the details will be described later inFIG. 3);(ii) when the motor (i.e., the rotary axis) is lowered to the predetermined rotation number V1(time T12), control is switched from the speed control to the position control, and the phase matching at a constant speed of the predetermined rotation number V1(i.e., the rotation angle matching of the rotary axis) is performed; and(iii) the final deceleration is started at time T13, the deceleration of the motor at a constant deceleration based on the maximum torque characteristic (i.e., the rotary axis) is performed, and the rotary axis is stopped at a predetermined position at time T14.Here, the phase matching refers to establishing the state of the remaining movement distance=the braking distance. When the phase matching is completed, it is possible to set the rotary axis at a predetermined speed at a predetermined position by decelerating the motor (i.e., the rotary axis) at the maximum acceleration based on the maximum torque characteristic. Here, it is assumed that the predetermined speed includes 0, i.e. the stop state.

FIG. 3is a diagram showing an example of the maximum torque characteristic and the maximum output characteristic with respect to the rotation number of the spindle motor. InFIG. 3, the torque and output of the motor are represented as follows.Torque [Nm]=Moment of Inertia [kgm2]×Acceleration [rad/s2]Output [kW]=Torque [Nm]×Speed [rad/s]/1000Speed [rad/s]=Rotation Number [RPM]×2π/60It should be noted that the speed is an angular velocity and the acceleration is an angular acceleration.

InFIG. 3, the torque is constant in the low rotation region from the rotation speed of 0 rpm to 3000 rpm (hereinafter referred to as the constant torque region R1), the output is constant in the high rotation region from the rotation speed of 3000 rpm to 8000 rpm (hereinafter referred to as the constant output region R2), and the output and torque are reduced in the higher rotation region from the rotation speed of 8000 rpm (hereinafter referred to as the output gradually-decreasing region R3). The rotation number at the boundary between the constant torque region R1and the constant output region R2is the base rotation number. In the constant output region R2and the output gradually-decreasing region R3, since the torque decreases as the rotation number increases, the acceleration is limited to a lower value as the rotation number becomes higher according to the above formula.

FIG. 4is a diagram for explaining the positioning operation of the rotary axis described in Japanese Patent No. 4099503 shown inFIG. 2. InFIG. 4, the sum of the area A1from time T11to time T12and the area A2from time T13to time T14corresponds to the braking distance required for stopping at the maximum torque (the full torque) (or decelerating to a predetermined speed).

The period from time T11to time T12corresponds to the motor characteristic of the constant output region R2or output gradually-decreasing region R3shown inFIG. 3, and the slope of the rotation number characteristic continuously changes. Therefore, the calculation of the braking distance becomes complicated in the period from time T11to time T12, and the calculation of the braking distance in the control cycle (in the order of milliseconds) increases the calculation load on the controller.

In a case of setting the predetermined rotation number V1equal to or less than the base rotation number, the period from time T13to time T14corresponds to the motor characteristic of the constant torque region R1shown inFIG. 3, and the slope of the rotation number characteristic is constant. Therefore, the braking distance can be easily and accurately calculated in the period from time T13to time T14.

However, in the positioning operation of the rotary axis described in Japanese Patent No. 4099503, since the phase matching is performed at a relatively low predetermined rotation number V1, it takes time for the rotary axis to stop at a predetermined position. It should be noted that, when performing deceleration at a constant acceleration using a small acceleration at high rotation at the time of positioning request (time T11), the deceleration time is further increased (refer to the dotted straight line inFIG. 4).

Furthermore, in the positioning operation of the rotary axis described in Japanese Patent No. 5925066, in the constant output region R2shown inFIG. 3, the rotary axis is stopped at a predetermined position while the deceleration of the rotary axis from the time of the positioning request is adjusted. However, in the spindle motor of the machine tool, sometimes a high rotation-type motor as shown inFIG. 5is used. In such a high rotation-type motor, the output gradually-decreasing region R3is widened, and the constant output region R2is relatively narrowed. Japanese Patent No. 5925066 does not take into consideration the positioning operation of the rotary axis in the output gradually-decreasing region R3, and in the positioning operation of the rotary axis described in Japanese Patent No. 5925066, it is difficult to handle such a high rotation-type motor.

On the contrary, in the positioning operation of the rotary axis of the present embodiment, as shown inFIG. 6,(i) when the positioning request is issued during the rotation of the motor60(i.e., during the rotation of the rotary axis61) (time T1), the rotation number of the rotary axis61at the time of the positioning request is maintained until the remaining movement amount S2becomes the current braking distance S3(i.e., the phase matching (the rotation angle matching of the rotary axis61) is performed at a constant speed of the current high rotation number);(ii) when the remaining movement amount S2becomes the current braking distance S3(time T2), the deceleration of the motor60(i.e., the rotary axis61) is started at the full torque deceleration by the maximum acceleration based on the maximum torque characteristic; and(iii) in a case in which the rotation number of the rotary axis61is equal to or less than the base rotation number of the motor60, and it is in the phase matching completion state, the final deceleration is started, the deceleration of the motor60(i.e., the rotary axis61) is performed at a constant deceleration speed based on the maximum torque characteristic, and the rotary axis61is stopped at a predetermined position at time T3.

Thus, as shown in the lower figure ofFIG. 7, for example, as compared with the upper figure which is a technique described in Japanese Patent No. 4099503, it is possible to reduce the time required for the rotary axis61is stopped at a predetermined position.

Hereinafter, a description will be given of the data storage unit41and the deceleration command calculating unit43for achieving this.

As shown by the solid line inFIG. 8, the data storage unit41stores, in advance, data of the braking distance for each rotation number of the rotary axis61, that is, the data of the braking distance based on the maximum torque characteristic with respect to the rotation number of the motor60for driving the rotary axis61. It should be noted that the data of the braking distance may be set larger than the braking distance based on the maximum torque characteristic of the motor60. The braking distance is, for example, assumed to be stored in a table format of the rotation number of the rotary axis61and its braking distance. The braking distance data may be obtained from a database, simulation or test run. For example, by performing a test run to decelerate and stop the rotary axis61from the maximum rotation number at the maximum torque (the full torque) to calculate from the maximum torque characteristic and the moment of inertia with respect to the rotation number, the braking distance for each rotation number of the rotary axis61is obtained.

Furthermore, the data storage unit41refers to the data of the braking distance to calculate the current braking distance S3corresponding to the current rotation number of the rotary axis61. For example, the data storage unit41calculates the current braking distance S3by interpolation by a straight line or quadratic or higher curve from the data of the braking distance in the table format on the basis of the speed FB signal from the speed detecting unit32.

Furthermore, as shown inFIG. 3orFIG. 5, the data storage unit41stores in advance the maximum torque characteristic with respect to the rotation number of the motor60for driving the rotary axis61.

The deceleration command calculating unit43performs the following operations:(i) when the positioning request is issued during the rotation of the rotary axis61(during the speed control), if the difference S4between the remaining movement amount S2and the current braking distance S3is equal to or greater than a predetermined value, the speed command V2is calculated so as to maintain the current rotation number of the rotary axis; and(ii) if the difference S4between the remaining movement amount S2and the current braking distance S3is less than a predetermined value, the speed command V2is calculated so as to start deceleration of the rotary axis61on the basis of the maximum torque characteristic of the motor60. More specifically, in the case of (ii), the deceleration command calculating unit43performs the following operations:when the difference S4is less than or equal to zero (the phase matching completion status), the speed command V2is calculated so as to perform full torque deceleration by the maximum acceleration based on the maximum torque characteristic of the motor60; andif the difference S4is greater than zero and less than a predetermined value, the speed command V2is calculated so as to make the acceleration weaker than full torque deceleration.

Assuming that the speed command when decelerating at the maximum acceleration based on the maximum torque characteristic is V2′, the speed command of the previous control cycle is Vold, and the control cycle is T, the predetermined values are set as follows, for example.S5=(Vold−V2′)×TIn this case, when S4>0 and S4<S5, if the acceleration is weakened as follows, the next control cycle is S4=0.V2=V2′+S4/T

As described above, when the positioning request is issued, the speed command selecting unit30first selects the speed command V2calculated by the deceleration command calculating unit43, the deceleration of the rotary axis61starts on the basis of the speed command V2.

After that,(iii) in a case in which the rotation number of the rotary axis61is equal to or less than the base rotation number of the motor60and it is in the phase matching completion state (S2=S3, that is, S4=0), the speed command selecting unit30selects the speed command V1calculated by the position loop control unit25, that is, the speed command V1whose acceleration based on the maximum torque characteristic of the motor is constant. Thus, the final deceleration starts, the deceleration of the motor60is performed at a constant deceleration based on the maximum torque characteristic (i.e., the rotary axis61), and the rotary axis61is stopped at a predetermined position.

As described above, according to the controller10of the rotary axis of the present embodiment, it is possible to directly position the spindle (the rotary axis)61, which is rotating at high speed, at a predetermined position. Since the deceleration is generally made at the maximum torque (the full torque), the deceleration time becomes shorter as compared to the prior art. Thus, when switching from the spindle mode in which the rotation number of the spindle in rotation is a control target to the positioning mode in which the stop at a predetermined position is a control target, the deceleration time of the spindle is shortened. Therefore, it is particularly effective in shortening the machining time for the machining in which the switching from the spindle mode to the positioning mode is frequently performed.

In the controller of the rotary axis described above, although the configuration of stopping the rotary axis at a predetermined position is exemplified, it may be a configuration decelerating the rotary axis to a predetermined speed at a predetermined position. For example, as shown inFIGS. 2 and 4, the Applicant devises a configuration to decelerate at a constant acceleration from the base rotation number in the period from time T13to time T14on the basis of the constant torque region R1of the maximum torque characteristic shown inFIG. 3. Thus, in a case in which the braking distance data for decelerating at a constant acceleration from the base rotation number has already been calculated, as shown by the dotted line inFIG. 8, the braking distance data to be newly calculated may be the braking distance data until the rotary axis decelerates to the base rotation number (a predetermined speed) at a predetermined position.

According to this, it is possible to reduce the time required for the rotary axis to decelerate to a predetermined speed at a predetermined position.

Modification Example 1

The braking distance data may be overestimated so that the rotary axis does not move past a predetermined position (a predetermined rotational position). That is, the braking distance data may be further set larger than the braking distance based on the maximum torque characteristic of the motor shown inFIG. 3, for example.

In this case, the deceleration of only the maximum torque (the full torque) may complete the deceleration before the predetermined position. Therefore, as shown inFIG. 9, the deceleration command calculating unit43sequentially verifies the remaining movement amount S2and the current braking distance S3even after the deceleration starts at time T2, and in a case in which the difference S4between the remaining movement amount S2and the current braking distance S3is greater than zero and less than a predetermined value, an adjustment may be sequentially performed so as to temporarily weaken the acceleration of the deceleration of the rotary axis (inFIG. 9, a dotted→solid line).

Modification Example 2

As shown inFIG. 10, in a case in which, when the positioning request is issued (time T1), the current rotation number of the rotary axis61is low (e.g., in the case of being equal to or lower than a predetermined value (a second predetermined value) that is set to 80% or less of the maximum rotation number in the braking distance data), the deceleration command calculating unit43may perform the phase matching while accelerating the rotary axis61at the maximum acceleration based on the maximum torque characteristic of the motor60. In this case, the deceleration command calculating unit43may provide an upper limit value to the rotation number of the rotary axis61that can be accelerated, for example. For example, examples of the upper limit value include the maximum rotation number in the braking distance data.

It should be noted that, although the example of the deceleration starting before reaching the upper limit value is shown inFIG. 10, after reaching the upper limit value, similarly to the period from time T1to time T2inFIG. 6orFIG. 9, it is sufficient to maintain the rotation number of the rotary axis61at the time of the positioning request (i.e., it is sufficient to perform the phase matching at a constant speed of the current high rotation number (rotation angle matching of the rotary axis61)) until the difference S4between the remaining movement amount S2and the current braking distance S3becomes less than a predetermined value at a constant speed.

According to this, it is possible to further reduce the time required for the rotary axis61to be stopped at a predetermined position.

Modification Example 3

In a case in which there is no braking distance corresponding to the current rotation number of the rotary axis61in the braking distance data, as shown in the period from the time T1to time T4inFIG. 11, the position loop control unit25may perform the phase matching while performing the deceleration of the rotary axis61at a maximum acceleration based on the maximum torque characteristic of the motor60up to the rotation number corresponding to the braking distance present in the braking distance data.

In this case, the braking distance data stored in the data storage unit41may be updated so as to add the braking distance based on the maximum torque characteristic with prespect to the rotation number at the deceleration of the rotary axis61of the period from time T1to time T4. Thus, in the second and subsequent times, it is possible to perform the phase matching with the rotation number at the time of the positioning request.

Although embodiments of the present invention have been described above, the present invention is not to be limited to the embodiments described above, and various modifications and variations are possible. For example, although the above-described embodiment exemplifies a controller for stopping a spindle (a rotary axis) in a machine tool at a predetermined position, the present disclosure is not limited thereto and is applicable to a controller for stopping the rotary axis in various machines at a predetermined position. In addition, the present disclosure is applicable to a controller that decelerates a rotary axis in various machines to a predetermined speed at a predetermined position.

EXPLANATION OF REFERENCE NUMERALS

10controller12spindle speed command calculating unit20stop position command calculating unit21total movement command calculating unit22movement command calculating unit25position loop control unit (position control unit)30speed command selecting unit32speed detecting unit33position detecting unit35speed loop control unit (speed control unit)41data storage unit of braking distance43deceleration command calculating unit60motor61rotary axis