Numerical control device, identification method, and identification program
The numerical control device and method address inefficiencies in detecting uneven loads by identifying transmission model parameters, stabilizing tool magazine rotation, and optimizing tool changes in machine tools.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- BROTHER KOGYO KK
- Filing Date
- 2022-08-31
- Publication Date
- 2026-07-07
AI Technical Summary
Existing control methods for machine tools require cumbersome execution of operating modes to determine control conditions every time the state of tool storage in the tool magazine changes, leading to inefficiencies in detecting uneven loads.
A numerical control device and method that identifies parameters of a transmission model based on a reference angle, allowing for accurate detection of biased loads without dedicated operating modes, and adjusts motor driving conditions to stabilize tool magazine rotation.
Enables efficient and accurate detection of biased loads in machine tools, stabilizing tool magazine rotation, and optimizing tool attachment/detachment processes.
Smart Images

Figure 0007885638000015 
Figure 0007885638000016 
Figure 0007885638000017
Abstract
Description
[Technical Field]
[0001] The present invention relates to a numerical control device, an identification method, and an identification program. [Background technology]
[0002] In a tool magazine for storing tools, an unbalanced torque (uneven load) is generated in the tool magazine due to the shape and distribution of the stored tools. Patent Document 1 discloses a control method for estimating the unbalanced torque and determining the optimal control. In this control method, the NC device of a machine tool acquires the current value of the motor of the tool magazine when it is stopped and calculates the torque (stop load torque) required to hold the tool magazine in a stopped state against the unbalanced torque. The NC device rotates the tool magazine by 90 degrees. The NC device acquires the current value of the motor at the position where the tool magazine has stopped after rotation and calculates the stop load torque at that rotation position. Based on the two calculated stop load torques, the NC device determines the control conditions for the motor. [Prior art documents] [Patent Documents]
[0003] [Patent Document 1] International Publication No. 2016 / 135958 [Overview of the project] [Problems that the invention aims to solve]
[0004] The control method requires executing the above operating modes to determine the control conditions. In this control method, the above operating modes must be executed every time the state of tool storage in the tool magazine changes, which is cumbersome.
[0005] The object of the present invention is to provide a numerical control device, an identification method, and an identification program that can accurately detect the effects of uneven loads in machine tools more easily than conventional methods. [Means for solving the problem]
[0006] The numerical control device according to claim 1 is a numerical control device that outputs a command indicating the driving conditions of a motor to a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, and comprises an acquisition unit for acquiring input conditions which are predetermined driving conditions, and an identification unit for identifying parameters of the transmission model based on the driving result of driving the tool magazine according to the input conditions acquired by the acquisition unit and a transmission model of the machine tool, wherein the transmission model includes the bias load based on a reference angle in which the bias load of the rotating tool magazine becomes zero, and the parameters include the reference angle.
[0007] In a numerical control system, a transmission model using a biased load based on a reference angle allows for the identification of parameters during tool changes. This enables the numerical control system to accurately detect the effects of biased loads in machine tools more easily than before, without requiring the system to execute a dedicated operating mode to control the effects of biased loads.
[0008] The numerical control device according to claim 2 may include an acceleration calculation unit that calculates the acceleration of the motor based on the parameters identified by the identification unit and the torque output by the motor. By calculating the acceleration of the motor based on the parameters identified by the identification unit, the numerical control device can rotate the tool magazine with an appropriate acceleration according to the state in which the tools are stored in the tool magazine.
[0009] The numerical control device according to claim 3 may include a time constant calculation unit that calculates the acceleration time constant of the motor based on the acceleration calculated by the acceleration calculation unit. By calculating the acceleration time constant of the motor based on the acceleration calculated by the acceleration calculation unit, the numerical control device can rotate the tool magazine with appropriate acceleration and deceleration according to the state in which the tools are stored in the tool magazine.
[0010] In the numerical control device according to claim 4, the time constant calculation unit may calculate the time constant of the motor based on a reference state that serves as a reference for the state in which the tools are stored in the tool magazine, a reference moment of inertia of the tool magazine, and a reference bias load of the tool magazine. By calculating the time constant based on the parameters of the reference state and the identified parameters, the numerical control device can rotate the tool magazine with a more appropriate time constant depending on the state in which the tools are stored in the tool magazine.
[0011] The numerical control device according to claim 5 may further include, in the identification unit, the parameter identified by the identification unit, the eccentric load or the moment of inertia of the tool magazine, a threshold determination unit that determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, a timing unit that starts timing the elapsed time when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is greater than or equal to the threshold, a time determination unit that determines whether the elapsed time measured by the timing unit has elapsed to a predetermined time, and a detachment drive unit that starts driving a detachment mechanism for attaching and detaching the tool to and from the spindle of the machine tool when the time determination unit determines that the elapsed time has elapsed to the predetermined time. When the magnitude of the eccentric load or the moment of inertia is excessively large, the rotational position of the tool magazine may not stabilize after the rotation of the tool magazine has finished. The numerical control device starts driving the detachment mechanism after a predetermined time has elapsed when the magnitude of the eccentric load or the moment of inertia is excessively large. Therefore, the numerical control device can attach and detach the tool to and from the spindle after the rotational position of the tool magazine has stabilized.
[0012] The numerical control device according to claim 6 may further include the parameter identified by the identification unit as the eccentric load or the moment of inertia of the tool magazine, a threshold determination unit that determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, and a speed determination unit that, when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is greater than or equal to the threshold, determines the maximum rotational speed of the attachment / detachment motor that drives the attachment / detachment mechanism for attaching / detaching the tool to and from the spindle of the machine tool to be lower than the maximum rotational speed when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is not greater than or equal to the threshold. When the magnitude of the eccentric load or the moment of inertia is excessively large, the rotational position of the tool magazine may not be stable after the rotation of the tool magazine is completed. The numerical control device reduces the maximum rotational speed of the attachment / detachment motor when the magnitude of the eccentric load or the moment of inertia is excessively large. Therefore, the numerical control device can attach / detach the tool to and from the spindle after the rotational position of the tool magazine has stabilized.
[0013] The numerical control device according to claim 7 may further include the parameter identified by the identification unit as the eccentric load or the moment of inertia of the tool magazine, a threshold determination unit that determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, and a time constant determination unit that, when the threshold determination unit determines that the magnitude of the eccentric load is greater than or equal to the threshold, sets the acceleration / deceleration time constant of the attachment / detachment motor that drives the attachment / detachment mechanism for attaching and detaching the tool to and from the spindle of the machine tool to be greater than the time constant when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is not greater than or equal to the threshold. When the magnitude of the eccentric load or the moment of inertia is excessively large, the rotational position of the tool magazine may not stabilize after the rotation of the tool magazine is completed. The numerical control device increases the acceleration / deceleration time constant of the attachment / detachment motor when the magnitude of the eccentric load or the moment of inertia is excessively large. Therefore, the numerical control device can attach and detach the tool to and from the spindle after the rotational position of the tool magazine has stabilized.
[0014] The numerical control device according to claim 8 further includes the parameter identified by the identification unit as the biased load or the moment of inertia of the tool magazine, a threshold determination unit that determines whether the magnitude of the biased load or the moment of inertia is greater than or equal to a predetermined threshold, and a notification unit that notifies an error when the threshold determination unit determines that the magnitude of the biased load or the moment of inertia is greater than or equal to the threshold. The numerical control device notifies an error by the notification unit when the magnitude of the biased load or the moment of inertia is excessively large. This allows the user to understand that the magnitude of the biased load or the moment of inertia is excessively large.
[0015] The numerical control device according to claim 9 includes a command determination unit that determines whether the input condition acquired by the acquisition unit is a tool change command for exchanging the tool mounted on the spindle of the machine tool with the tool stored in the tool magazine, and the identification unit may identify the parameter when the command determination unit determines that the input condition acquired by the acquisition unit is a tool change command. The numerical control device identifies the parameter when performing a tool change using the tool magazine based on the tool change command. Therefore, the numerical control device can identify the parameter without executing a special mode before machining the workpiece.
[0016] The numerical control device according to claim 10 may include a filter to remove noise included in the drive result. Since the numerical control device removes noise included in the drive result by filtering, the parameters can be identified with high accuracy.
[0017] The numerical control device according to claim 11 may include a drive result acquisition unit that acquires the drive result, and a drive result determination unit that determines whether to use the drive result acquired by the drive result acquisition unit for the identification of the parameter by the identification unit. By determining whether to use the drive result of the magazine's drive for parameter identification, the numerical control device can remove drive results that degrade the accuracy of parameter identification. Therefore, the numerical control device can identify the parameter with high accuracy.
[0018] The identification method of claim 12 is an identification method for identifying parameters for determining a command indicating the driving conditions of a motor in a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, comprising: an acquisition step of acquiring input conditions which are predetermined driving conditions; and an identification step of identifying the parameters of the transmission model based on the driving result of driving the tool magazine according to the input conditions acquired in the acquisition step and the transmission model of the machine tool, wherein the transmission model includes the bias load based on a reference angle in which the bias load of the rotating tool magazine becomes zero, and the parameters include the reference angle. The identification method has the same effect as the numerical control device of claim 1.
[0019] The identification program of claim 13 is an identification program for identifying parameters for determining a command indicating the driving conditions of a motor in a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, comprising: an acquisition process for acquiring input conditions which are predetermined driving conditions; and an identification process for identifying the parameters of the transmission model based on the driving result of driving the tool magazine according to the input conditions acquired by the acquisition process and the transmission model of the machine tool, wherein the transmission model includes the bias load based on a reference angle in which the bias load of the rotating tool magazine becomes zero, and the parameters include the reference angle. The identification program has the same effect as the numerical control device of claim 1. [Brief explanation of the drawing]
[0020] [Figure 1] Front view of machine tool 1. [Figure 2] A partial fractured view of the spindle head 7 as seen from the right side. [Figure 3] This figure shows the tool magazine 21 when the angle θ of the magazine body 22 is 0 degrees. [Figure 4] This figure shows the tool magazine 21 when the angle θ of the magazine body 22 is the reference angle θa. [Figure 5] A block diagram showing the electrical configuration of the numerical control device 40 and the machine tool 1. [Figure 6] A diagram showing the control system of the drive circuit 54. [Figure 7] A functional block diagram showing the functions of the numerical control device 40. [Figure 8] Graphs showing angular velocity and angular acceleration curves when two-stage moving average filters FIR1 and FIR2 are applied. [Figure 9] Flowchart of the main processing. [Figure 10] A flowchart showing the continuation of Figure 9. [Figure 11] Flowchart of the identification process. [Figure 12] A graph showing the evaluation results of the main processing. [Figure 13] Flowchart of the weight identification process. [Figure 14] This flowchart shows the main process in the second embodiment, continuing from Figure 9. [Figure 15] This flowchart shows the main process in the third embodiment, continuing from Figure 9. [Figure 16] This flowchart shows the main process in the fourth embodiment, continuing from Figure 9. [Modes for carrying out the invention]
[0021] A first embodiment of the present invention will be described with reference to the drawings. The following description will use the left / right, front / back, and up / down directions indicated by arrows in the drawings. The left / right direction, front / back direction, and up / down direction of the machine tool 1 are the X-axis direction, Y-axis direction, and Z-axis direction of the machine tool 1, respectively. The right direction, front direction, and up direction are positive directions, respectively, while the left direction, rear direction, and down direction are negative directions, respectively. The machine tool 1 shown in Figure 1 is a machine that performs cutting on a workpiece (not shown) using a tool 3 (see Figure 2). The numerical control device 40 (see Figure 5) controls the operation of the machine tool 1.
[0022] Referring to Figures 1 and 2, the structure of machine tool 1 will be described. Machine tool 1 comprises a base 2, a column 5, a control box 6, a table device 10, a spindle head 7, a spindle 9, and a tool changer 20. The base 2 is a roughly rectangular metal base. The column 5 is fixed to the upper rear of the base 2. The control box 6 is fixed to the rear side of the column 5. The control box 6 houses a numerical control device 40.
[0023] The table device 10 comprises a Y-axis movement mechanism (not shown), a Y-axis table 12, a table 13, and an X-axis movement mechanism. The Y-axis movement mechanism is mounted on the upper part of the base 2 and includes a Y-axis motor 62 (see Figure 5). The Y-axis movement mechanism moves the Y-axis table 12 in the Y-axis direction in response to the drive of the Y-axis motor 62. The X-axis movement mechanism is mounted on the upper part of the Y-axis table 12 and includes an X-axis motor 61 (see Figure 5). The X-axis movement mechanism moves the table 13 in the X-axis direction in response to the drive of the X-axis motor 61. Therefore, the table 13 can move in both the X-axis and Y-axis directions on the base 2 by means of the X-axis movement mechanism and the Y-axis movement mechanism.
[0024] Referring to Figure 2, the structure of the spindle head 7 and spindle 9 will be explained. The spindle head 7 moves up and down in the Z-axis direction by a Z-axis movement mechanism provided on the front of the column 5. The Z-axis movement mechanism is equipped with a Z-axis motor 63 (see Figure 5). The Z-axis movement mechanism moves the spindle head 7 in the Z-axis direction in response to the drive of the Z-axis motor 63. The spindle head 7 is equipped with a spindle motor 65 at its front upper part. The spindle head 7 rotatably supports the spindle 9 inside its front lower part.
[0025] The spindle 9 has a rotation axis in the vertical direction. The spindle 9 is connected to a drive shaft that extends below the spindle motor 65. Therefore, the spindle 9 rotates when driven by the spindle motor 65. The spindle 9 is equipped with a shaft hole 91, a mounting hole 92, a clamping part 93, and a drawbar 94. The shaft hole 91 passes through the center of the spindle 9. The mounting hole 92 is provided at the lower end of the spindle 9 and communicates with the shaft hole 91. The clamping part 93 is provided above the mounting hole 92. The drawbar 94 is provided coaxially inside the shaft hole 91.
[0026] Tool 3 comprises a holder 17 and a cutting tool 4. The holder 17 holds the cutting tool 4 at one end and has a mounting portion 17A and a pull stud 17B at the other end. The mounting portion 17A is conical. The pull stud 17B protrudes axially from the top of the mounting portion 17A. The mounting portion 17A is mounted in the mounting hole 92. When the mounting portion 17A is mounted in the mounting hole 92, the clamping portion 93 clamps the pull stud 17B. When the drawbar 94 presses the clamping portion 93 downward, the clamping portion 93 releases its grip on the pull stud 17B.
[0027] The spindle head 7 is equipped with a crank lever 30 and a tension coil spring (not shown) on the inside of its rear upper section. The crank lever 30 is roughly L-shaped when viewed from the left side and is pivotable around a pivot shaft 31. The pivot shaft 31 extends in the left-right direction and is fixed inside the spindle head 7. The front end of the crank lever 30 engages from above with a pin 95 that protrudes perpendicularly to the drawbar 94. The rear end of the crank lever 30 is equipped with a plate cam 32. The back surface of the plate cam 32 is equipped with a cam surface. The cam surface of the plate cam 32 can move toward and away from a cam follower 34 fixed to the bearing portion 33 of the column 5. The cam follower 34 slides on the cam surface of the plate cam 32. The tension coil spring constantly biases the crank lever 30 clockwise when viewed from the right side. Therefore, the crank lever 30 constantly releases the downward pressure on the pin 95.
[0028] Referring to Figures 1 and 2, the structure of the tool changer 20 will be described. The tool changer 20 is equipped with a tool magazine 21. The tool magazine 21 is of the turret type. The tool magazine 21 comprises a magazine body 22, a support shaft 23, multiple grip arms 8, a support base 24, a reduction gear 25, and a magazine motor 64.
[0029] The magazine body 22 is disc-shaped. The support shaft 23 extends diagonally downward relative to the front of the machine tool 1. The axis of the support shaft 23 passes through the center Q of the magazine body 22, which will be described later. The support shaft 23 rotatably supports the magazine body 22. The magazine body 22 is mounted facing forward relative to the front of the machine tool 1.
[0030] Each grip arm 8 is provided at predetermined intervals around the outer circumference of the magazine body 22. In this embodiment, 28 grip arms 8 (801-828, see Figure 3) are provided on the magazine body 22. Multiple grip arms 8 are provided so as to be able to swing in the front-rear direction of the magazine body 22. Each grip arm 8 has a gripping portion 81 at its tip. The gripping portion 81 detachably grips the holder 17.
[0031] The support base 24 is fixed to the frame (not shown). The frame is fixed to the column 5 and is located near the spindle head 7. The support base 24 rotatably supports the pivot shaft 23. The reduction gear 25 is fixed to the upper part of the support base 24. The reduction gear 25 has multiple gears and cams (not shown). The magazine motor 64 is fixed to the upper part of the reduction gear 25. The rotating shaft of the magazine motor 64 is connected to the reduction gear 25.
[0032] Referring to Figure 2, the operation of attaching and detaching the holder 17 to the mounting hole 92 of the spindle 9 will be explained. With the mounting portion 17A of the holder 17 mounted in the mounting hole 92, the spindle head 7 rises from the workpiece machining position on the table 13 due to the rotation of the Z-axis motor 63. When the spindle head 7 rises, the cam follower 34 slides against the plate cam 32 of the crank lever 30. Therefore, the crank lever 30 rotates counterclockwise around the pivot shaft 31 in a right-side view, and the front end of the crank lever 30 engages with the pin 95 from above, pressing the drawbar 94 downward. The drawbar 94 biases the clamping portion 93 downward, and the clamping portion 93 releases the grip of the pull stud 17B. At the same time, the gripping portion 81 of the grip arm 8 grips the holder 17 of the tool 3.
[0033] The spindle head 7 rises further to the ATC origin. The tool 3 detaches from the mounting hole 92 of the spindle 9. The tool 3 detached from the spindle 9 is referred to as the first tool. Of the multiple grip arms 8 of the tool changer 20, one grip arm 8 at the tool change position (hereinafter referred to as the first grip arm) grips the first tool detached from the spindle 9. The tool change position is at the lowest position of the magazine body 22 and is close to and opposite the spindle 9.
[0034] When the spindle head 7 reaches the ATC origin, the tool changer 20 rotates the magazine body 22 by the rotation of the magazine motor 64 based on the control command of the numerical control device 40. The tool changer 20 positions the tool 3 (hereinafter referred to as the second tool), which includes the cutting tool 4 specified by the control command of the NC program, to the tool change position. At this time, the magazine body 22 rotates from the state where the first tool is in the tool change position to the state where the second tool, which will be newly mounted on the spindle 9, is in the tool change position. The tool magazine 21 also rotates with the first tool held by the first grip arm and the second tool held by the other grip arm 8 (hereinafter referred to as the second grip arm). The second tool, positioned in the tool change position, is located below the spindle head 7, which has moved to the ATC origin.
[0035] Next, the spindle head 7 descends from the ATC origin due to the rotation of the Z-axis motor 63. The mounting portion 17A of the holder 17 of the second tool enters the mounting hole 92 of the spindle 9. With the mounting portion 17A inserted into the mounting hole 92, the spindle head 7 descends further. The cam follower 34 slides against the plate cam 32 of the crank lever 30. Therefore, the crank lever 30 rotates clockwise around the pivot shaft 31 in a right-side view, and the crank lever 30 moves away from the pin 95, releasing the downward pressure on the drawbar 94. The drawbar 94 releases the downward biasing force of the clamping portion 93, and the clamping portion 93 grips the pull stud 17B. Therefore, the gripping portion 81 of the second grip arm releases its grip on the holder 17 of the second tool. The second tool detaches from the second grip arm of the tool changing device 20. The mounting portion 17A of the holder 17 is installed into the mounting hole 92 of the spindle 9, and the mounting of the second tool to the spindle 9 is completed.
[0036] Referring to Figures 3 and 4, the mounting state of the tools 3 in the tool magazine 21 will be explained. In the tool magazine 21, some of the multiple grip arms 8 (grip arms 801 to 828) have tools 3 mounted on them. In the tool magazine 21 shown in Figure 3, 12 grip arms 801 to 811 and 828 have tools 3 mounted on them. Hereinafter, the tools 3 mounted on grip arms 801 to 811 and 828 will be referred to as tools 301 to 311 and 328. The weights G1 to G28 of tools 301 to 311 and 328 may be the same or they may be different. In this embodiment, it will be explained assuming that the weights G1 to G28 are the same. Note that grip arms 812 to 827 do not have tools 3 mounted on them.
[0037] When the tool magazine 21 is in the state shown in Figure 3, most of the tools 3 attached to the grip arm 8 are located on the left side of the magazine body 22. Therefore, an uneven load (rotational moment) acts on the magazine body 22 from all of the tools 301-311 and 328, causing it to rotate around the center Q of the magazine body 22 as the center of rotation. Hereinafter, the uneven load from all of the tools 301-311 and 328 will be referred to as the total uneven load. The total uneven load causes the magazine motor 64 to rotate in a specific direction (counterclockwise in the case of Figure 3).
[0038] The total eccentric load varies based on the position of the grip arm 8 with the tool 3 attached, the weight of the tool 3 attached to the grip arm 8, and the angle θ of the magazine body 22. The angle θ of the magazine body 22 is 0 degrees when the grip arm 801 is in the tool change position (see Figure 3). In this state, if the magazine body 22 rotates clockwise around the center Q as the center of rotation, the angle θ becomes positive. If the magazine body 22 rotates counterclockwise around the center Q as the center of rotation, the angle θ becomes negative.
[0039] When the tool magazine 21 is in the state shown in Figure 4 (angle θ = -58 degrees), the eccentric loads acting on the magazine body 22 by the tools 301-311 and 328, with the center Q as the pivot point, are balanced. At this time, the magnitude of the total eccentric load becomes zero. Hereafter, the angle θ of the magazine body 22 at which the magnitude of the total eccentric load becomes zero is referred to as the reference angle θ. a That's what they say.
[0040] The state of the magazine body 22 in which tool 3 is mounted (hereinafter referred to as the state of tool mounting in the tool magazine 21) changes when tool 3 is changed. Changing tool 3 is the operation in which the user or robot swaps the tool 3 stored in the tool magazine 21 with a tool 3 that is not stored in the tool magazine 21 before the workpiece is processed by the machine tool 1.
[0041] Referring to Figure 5, the electrical configuration of the numerical control device 40 and the machine tool 1 will be explained. The numerical control device 40 includes a CPU 41, ROM 42, RAM 43, storage unit 44, input / output unit 45, and drive circuits 51 to 55. The machine tool 1 includes an X-axis motor 61, a Y-axis motor 62, a Z-axis motor 63, a magazine motor 64, a spindle motor 65, and encoders 71 to 75. Hereinafter, when drive circuits 51 to 55 are not distinguished, they will be collectively referred to as drive circuit 50. When X-axis motor 61, Y-axis motor 62, Z-axis motor 63, magazine motor 64, and spindle motor 65 are not distinguished, they will be collectively referred to as motor 60. When encoders 71 to 75 are not distinguished, they will be collectively referred to as encoder 70.
[0042] The CPU 41 controls the operation of the machine tool 1. The ROM 42 stores control programs and the like for executing the main processing (see Figure 9) described later. The RAM 43 stores various data generated during the execution of various processes. The memory unit 44 stores the NC program and a predetermined angle θ described later. TL , predetermined value θ L (Superscript dot), F θL , J L , reference moment of inertia J b , standard eccentric load coefficient F θb , reference time constant T1 b It stores data such as the above. The input / output unit 45 is electrically connected to the drive circuit 50, encoder 70, operation unit 18, and display unit 19, and performs input and output of various signals between the drive circuit 50, encoder 70, operation unit 18, and display unit 19.
[0043] The operation unit 18 and the display unit 19 are provided on the control panel 15. The control panel 15 is provided on the outer wall of the cover (not shown) that covers the machine tool 1. The operation unit 18 receives input such as various information and operation instructions and outputs them to the CPU 41 via the input / output unit 45. The display unit 19 displays various screens, error information, etc., based on commands from the CPU 41.
[0044] The drive circuit 50 outputs a pulse signal to the motor 60 based on a command output by the CPU 41. The encoder 70 detects the angle of the output shaft of the corresponding motor 60 and outputs the detected signal to the drive circuit 50 and the input / output unit 45. All motors 60 are servo motors. The encoder 70 is a general absolute value encoder.
[0045] Referring to Figure 6, the control system of the drive circuit 54 will be explained. The CPU 41 of the numerical control device 40 generates time-series data (described later) of the target angle at predetermined intervals based on the tool change command of the NC program, and outputs an angle command corresponding to each data to the drive circuit 54. The angle command indicates the rotation angle of the output shaft of the magazine motor 64 when the magazine body 22 is rotated to the target angle indicated by the data.
[0046] The encoder 74 outputs the current rotation angle information of the output shaft of the magazine motor 64 as a return value to the drive circuit 54. Based on the return value and the angle command, the drive circuit 54 controls the drive current output to the magazine motor 64. Specifically, the drive circuit 54 calculates the angle deviation between the return value and the angle command using an adder 54A, and calculates the angular velocity command by multiplying the angle deviation by an angle-proportional gain. Adder 54B calculates the angular velocity deviation between the calculated angular velocity command and the angular velocity return value. The angular velocity return value is the actual angular velocity, and is the value obtained by differentiating the return value with a differentiator 54C. Adder 54D adds a current command obtained by multiplying the calculated angular velocity deviation by an angular velocity-proportional gain and a current command obtained by integrating the angular velocity deviation with an integrator 54E and multiplying the integral result by an angular velocity integral gain to generate a torque command. The drive circuit 54 rotates the magazine motor 64 with a pulse signal indicating the torque command.
[0047] Referring to FIG. 7, the tool change command will be described. The CPU 41 of the numerical control device 40 acquires the NC program from the storage unit 44 and interprets one block from the first line of the NC program (P1). When the control command of the interpreted block is a tool change command, in order to change the tool 3 mounted on the spindle 9 from the first tool to the second tool, the CPU 41 determines the time-series data of the target angle (P2). The tool change position of the first tool is at an angle θ = θ of the magazine body 22 S and the tool change position of the second tool is at an angle θ = θ of the magazine body 22 E When this is the case, the CPU 41 rotates the magazine body 22 by the rotation angle θ T . Note that θ T = θ E - θ S . The CPU 41 outputs the data of the target angle to the drive circuit 54 at a predetermined cycle. This data indicates the drive conditions of the magazine motor 64 for moving the second tool to the target angle.
[0048] Based on the data of the target angle output by the CPU 41, the drive circuit 54 rotates the magazine motor 64. The magazine body 22 rotates about the center Q up to the target angle by the rotation of the magazine motor 64. Each time the CPU 41 inputs the data of the target angle to the drive circuit 54, the drive circuit 54 rotates the magazine motor 64.
[0049] Referring to Figure 8, the method by which the CPU 41 determines the time-series data of the target angle will be explained. As shown in Figures 8(A) and (B), the CPU 41 determines each target angle such that the angular velocity remains constant when the second tool rotates to the tool change position (Figure 8(B)) (Figure 8(A)). Next, the CPU 41 applies a moving average filter (hereinafter referred to as "FIR filter") at least twice to the waveform showing the time-series change of angular velocity shown in Figure 8(B) (hereinafter referred to as "angular velocity waveform") to smooth the change in angular velocity (Figures 8(C) and (D)). The FIR filter applied the first time is called the "first FIR filter" and is represented as "FIR1" in Figure 8. The time constant of the angular velocity when the first FIR filter is applied is called "T1". The FIR filter applied the second time is called the "second FIR filter" and is represented as "FIR2" in Figure 8. The time constant of the angular velocity when the second FIR filter is applied is called "T2".
[0050] When the first FIR filter is applied to the angular velocity waveform shown in Figure 8(B), as shown in Figure 8(C), the angular velocity in the angular velocity waveform changes from 0 to V. max The portion that changes up to (the rising portion), and the angular velocity when V max The slope (angular acceleration) of the portion that changes from zero to zero (falling edge) remains constant. The time of the rising and falling edges of the velocity waveform (hereinafter referred to as "rising edge time" and "falling edge time," respectively) is both t1. t1 corresponds to the time constant T1 when the first FIR filter is applied to the angular velocity waveform.
[0051] When the second FIR filter is applied to the angular velocity waveform with the first FIR filter applied (see Figure 8(C)), as shown in Figure 8(D), the angular velocity changes gradually at the beginning and end of the portion where the slope (angular acceleration) of the rising and falling portions of the angular velocity waveform is constant. At this time, in the waveform showing the time-series change of acceleration (hereinafter referred to as the "angular acceleration waveform"), the slope corresponding to the portion where the angular velocity changes gradually becomes constant.
[0052] The rise and fall times of the angular velocity waveform increase by t2 each, becoming t1 + t2. t2 corresponds to the time constant T2 when the second FIR filter is applied to the angular velocity waveform. As described above, the CPU 41 mitigates the change in the angular velocity of the magazine body 22 during tool changes by applying multiple FIR filters to the angular velocity. The time constant T1 of the first FIR filter and the time constant T2 of the second FIR filter correspond to the acceleration and deceleration time constants of the magazine motor 64 being controlled.
[0053] Based on the tool change command interpreted in step P1 (see Figure 7), the CPU 41 calculates the angular velocity of the tool magazine 21 (see Figure 8(B)) at predetermined intervals. The CPU 41 adjusts the acceleration and deceleration characteristics corresponding to the shape of the angular velocity waveform by applying the first and second FIR filters with time constants T1 and T2 to the calculated angular velocity (Figures 8(C) and (D)). Based on the angular acceleration waveform calculated by applying the first and second FIR filters (see Figure 8(D)), the CPU 41 determines the target angle for each predetermined interval. The CPU 41 outputs the determined target angle data to the drive circuit 51 at predetermined intervals. The CPU 41 optimizes and adjusts the time constants T1 and T2 of the first and second FIR filters in step P9 (see Figure 7), which will be described later. The CPU 41 uses the first and second FIR filters with the adjusted time constants T1 and T2.
[0054] The drive circuit 54 rotates the magazine motor 64 based on target angle data output by the CPU 41 at predetermined intervals. The magazine motor 64 rotates the magazine body 22 to the target angle. The magazine body 22 repeats the operation of rotating to the target angle at predetermined intervals. As a result, the angle θ of the magazine body 22 is set to the tool change position of the second tool specified by the tool change command (angle θ = θ E ) will eventually be reached.
[0055] Refer to Figure 7 for the total eccentric load and the reference angle θ. a The identification of variables will be explained below. Hereinafter, the process of estimating variables by calculating them from the model will be referred to as variable identification. The CPU 41 determines the torque u that the drive circuit 54 outputs to the magazine motor 64.raw (N·m), and the return value θ from encoder 74. raw Using the model to be controlled, the total eccentric load and the reference angle θ are used. a Identify it.
[0056] CPU41 is the total eccentric load and reference angle θ a Before performing the identification, it is determined whether or not to perform the identification in the current tool change command (P3). The CPU 41 determines the swivel angle θ in the current tool change command. T at a predetermined angle θ TL In the above cases, the total eccentric load and the reference angle θ a It is determined that the identification will be performed. TL For example, this is 60 degrees (= π / 3 rad).
[0057] CPU41 controls the torque u output by the drive circuit 54. raw The reduction ratio R of the gearbox 25 E The torque u0 output by the magazine body 22 is calculated by multiplying by the transmission ratio τ using the following equation 1. [Mathematics 1] u0=u raw R E τ The CPU 41 applies a low-pass filter to the torque u0 output by the magazine body 22 to remove noise (P4). After applying the low-pass filter, the torque u output by the magazine body 22 is represented by the following equation 2. [Math 2] u=G LPF u raw R E τ In Math 2, G LPF This is a low-pass filter used to remove noise.
[0058] CPU41 receives the return value θ from encoder74. raw The reduction ratio R of the gearbox 25 E Divide by and calculate the angle θ0 of the magazine body 22 using the following equation 3. [Math 3] θ0 = θ raw / R E CPU41 applies a low-pass filter to the angle of the magazine body 22 to remove noise (P5). After applying the low-pass filter, the angle θ of the magazine body 22 is represented by the following equation 4. [Math 4] θ=G LPF θ raw / R E
[0059] CPU41 is the total eccentric load and reference angle θ a To identify the object, it is determined whether or not to use the torque u and angle θ calculated in steps P4 and P5 (P6). Specifically, CPU 41 performs the first time derivative of the angle θ of the magazine body 22 represented by equation 4. In the following, "θ (superscript dot)" indicates the first time derivative of angle θ (rad) (angular velocity (rad / s)). CPU 41 determines whether or not to use the first time derivative θ (superscript dot) of angle θ as a predetermined value θ L If it is (one superscript dot) or more, the total eccentric load and the reference angle θ a Torque u and angle θ are used to determine the identification.
[0060] CPU41 uses the model to determine the total eccentric load and the reference angle θ. a Identify the model to be controlled. The model to be controlled can be set appropriately using multiple variables, for example, represented by the following equation 5. The total eccentric load at angle θ is F θ sin(θ-θ a It is represented by the eccentric load coefficient F. θ (N·m) is a parameter used to calculate the total eccentric load. In the following, "θ (double dots)" represents the second time derivative of the angle θ (angular acceleration (rad / s²)). 2 )) indicates. J(kg·m 2 ) is the moment of inertia with respect to tool magazine 21.
number
[0061] In equation 5, f satisfies the following relationship in equation 6. Here, F C(N·m) is the Coulomb friction with respect to the tool magazine 21. The sign function is a sign function that returns 1, -1, or 0 depending on the sign of a real number. D(N·m / (rad / s)) is the viscous friction coefficient with respect to the tool magazine 21.
number
[0062] Torque u is expressed by equations 5, 6, and the addition theorem, as shown in equation 7 below. The model in equation 7 is specifically called the transmission model of machine tool 1.
number
[0063] Torque u can be estimated by the transmission model shown in equation 7. The estimation error e(ρ) can be calculated using equation 10 below, where ρ is the parameter to be identified. The superscript T indicates that it is the transpose matrix. For example, ρ T This represents the transpose matrix of ρ. [Number 10] e(ρ) = u - ρ T x In equation 10, ρ and x satisfy the following relationships in equations 11 and 12, respectively.
number
number
[0064] CPU41 is the evaluation function |e(ρ)|2 The ρ that minimizes is calculated using the successive least squares method (P7). The successive least squares method is calculated by taking the parameter being identified in step k as ρ with circumflex (hereinafter denoted as ρ^)(k), the estimated error e(ρ) in step k as ε(k), and the covariance matrix in step k as P(k), then ρ^(k), ε(k), and P(k) are calculated by equations 13, 14, and 15 below.
number
number
number
[0065] ρ^(k), ε(k), and P(k) can all be calculated sequentially using equations 13, 14, and 15, respectively, using ρ^(k-1), ε(k-1), and P(k-1) at step (k-1), and the torque u(k) and angle θ(k) at step k. Therefore, by calculating equations 13, 14, and 15 at each step, the evaluation function |e(ρ)| can be obtained. 2 The value of ρ that minimizes this can be calculated sequentially.
[0066] According to the above successive least squares method, CPU41 has a total eccentric load F θ sin(θ-θ a In a transfer model that takes ) into consideration, the evaluation function |e(ρ)| 2 By calculating the ρ that minimizes this value, we can find the variables (moment of inertia J, viscous friction coefficient D, Coulomb friction F) that minimize the estimation error e. C , coefficient F a F b Identify (P7).
[0067] CPU41 is further determined by equations 16 and 17 derived from equations 8 and 9, and the identified parameters, which gives the eccentric load coefficient F θ , reference angle θ a This calculates the reference angle θ. This allows CPU41 to determine the reference angle θ. a , and the total eccentric load F at angle θθ sin(θ-θ a ) are identified. Below, the moment of inertia J, viscous friction coefficient D, and Coulomb friction F identified using the above evaluation function are described. C , eccentric load coefficient F θ , reference angle θ a These are collectively referred to as "parameters."
number
number
[0068] The CPU 41 stores the identified parameters in the memory unit 44 and updates the parameters (P8). Based on the identified total eccentric load and moment of inertia, the CPU 41 determines whether or not the tool 3 is overloaded in the tool magazine 21 (P9). In step P9, the CPU 41 determines the total eccentric load F at the angle θ where the total eccentric load is maximum. θ sin(θ-θ a ) is a predetermined value F θL Determine whether the following is true: When the magnitude of the total eccentric load is maximum, sin(θ-θ) a ) = 1 or sin(θ - θ) a Since ) = -1, CPU41 is the absolute value of the uneven load coefficient |F θ | is a predetermined value F θL The CPU 41 determines whether the following is true: In process P9, the identified moment of inertia J is a predetermined value J. L Determine whether the following is true or false. CPU41 is the absolute value of the uneven load coefficient |F θ | is a predetermined value F θL When it exceeds a certain value, or when the moment of inertia J is a predetermined value J L When the value exceeds a certain limit, the tool magazine 21 determines that the tool 3 is overloaded. At that time, the CPU 41 notifies the tool magazine 21 of the overloading of the tool 3 via the display unit 19 and stops the operation of the machine tool 1.
[0069] Based on the identified parameters, the CPU 41 updates the time constants T1 and T2 of the FIR filter. The time constants T1 and T2 correspond to the time constants in the acceleration and deceleration of the magazine motor 64. When generating the time series data of the next target position, the CPU 41 applies the updated first FIR filter and second FIR filter with the time constants T1 and T2.
[0070] The first example of the calculation method of the time constant T1 is as follows. The maximum angular acceleration A, which is the maximum of the angular acceleration (θ (double dot upwards)) that the magazine motor 64 can output max is when the magnitude of the total eccentric load is at its maximum at an angle θ (sin(θ - θ a ) = 1 or sin(θ - θ a ) = -1), and is represented by the following number 18 according to numbers 5 and 6. Note that the Coulomb friction force (the second term on the left side) and the viscous force (the third term on the left side) in number 6 are sufficiently small with respect to the magnitude of the total eccentric load (equal to the absolute value of the eccentric load coefficient |F θ |) and are thus ignored. The CPU 41 calculates the maximum angular acceleration A max using number 18 (P11) [Number 18] A max =(u max -F θ ) / J Here, u max is the maximum torque that the magazine motor 64 can output. The storage unit 44 stores the maximum torque u max in advance.
[0071] The time constant T1 (reference time constant) of the magazine motor 64 in the reference mounting state of the tool 3 is represented by the following number 19 (see Fig. 8(C)). The CPU 41 calculates the time constant T1 using number 19 (P11). [Number 19] T1 = V max / A max Here, V max is the maximum angular velocity (maximum rotational speed) that the magazine motor 64 can output. The storage unit 44 stores the maximum angular velocity V max in advance.
[0072] A second example of the method for calculating the time constant T1 is as follows: The CPU 41 calculates the time constant based on the standard mounting state of the tool 3 in the tool magazine 21. The storage unit 44 pre-calculates the eccentric load coefficient F for the standard mounting state of the tool 3. θb (Reference bias load coefficient), moment of inertia J b (Reference moment of inertia), and time constant T1 b The (reference time constant) is stored. The reference loading state is the maximum inertia load and maximum uneven load load state determined by the machine specifications. For example, the reference loading state is when the maximum loadable tools are loaded in a number equal to the maximum total tool weight determined by the machine specifications, with the load unevenly distributed to one side of the magazine as shown in Figure 1. The reference time constant is the time constant at which the magazine motor 64 can operate without exceeding the maximum torque it can output in the reference loading state.
[0073] In the standard mounting state of tool 3, the maximum angular acceleration A that the magazine motor 64 can output is maxb This is represented by the following number 20, which is derived from number 18. [Number 20] A maxb =( u max -F θb ) / J b
[0074] Time constant T1 of the magazine motor 64 in the standard mounting state of tool 3 b The (reference time constant) is represented by the following number 21, which is derived from number 19. [Number 21] T1 b =V max / A maxb
[0075] From equations 18 to 21, the time constant T1 is expressed in equation 22 below. CPU 41 calculates the time constant T1 of the FIR filter using equation 22 based on the identified parameters. CPU 41 uses the reference time constant T1 b The calculated time constant T1 is updated and stored in the memory unit 44.
number
[0076] A third example of a method for calculating the time constant T1 (or T2) is as follows: When accelerating and decelerating the motor 60 using a moving average filter, for example, if the mechanical system is a 1-degree-of-freedom system, the natural vibration period T opt This can be calculated using the following equation 23, where J is the moment of inertia of the identified parameter and K is the torsional stiffness of the mechanical system, which is measured or calculated separately. [Number 23] T opt =2π√(J / K) At that time, the CPU 41 sets the time constant T1 or T2 of the FIR filter to T opt By doing so, the motor 60 can be accelerated and decelerated without exciting its natural frequencies. Therefore, the CPU 41 can suppress the natural vibration of the machine tool 1 by applying the time constant calculated from the identified parameters, thereby canceling out the natural frequencies of the mechanical system.
[0077] Furthermore, in the next tool change command, the CPU 41 determines the time-series data (target angle) of the target position based on the time constants T1 and T2 updated by the previous tool change command.
[0078] Referring to Figures 9 and 10, the main processing performed by the CPU 41 of the numerical control device 40 will be explained. The user operates the operation unit 18 to select the execution of an NC program. Upon receiving confirmation of the execution of the NC program selected by the operation unit 18, the CPU 41 reads the control program stored in the ROM 42 and starts the main processing.
[0079] As shown in Figure 9, the CPU 41 reads the NC program selected by the operation unit 18 (S1). The CPU 41 interprets one block from the read NC program (S2). This process corresponds to step P1 in Figure 7. The CPU 41 determines whether the control command of the interpreted block is a termination command or not (S3).
[0080] When CPU41 determines that the interpreted control command is not a termination command (S3:NO), it determines whether the interpreted control command is a tool change command (S4). When CPU41 determines that the interpreted control command is not a tool change command (S4:NO), it executes various processes according to the interpreted control command (S5) and returns the process to S2.
[0081] When the CPU 41 determines that the interpreted control command is a tool change command (S4: YES), it rotates the Z-axis motor 63 and raises the spindle head 7 from the workpiece machining position to the ATC origin (S11). The CPU 41 generates time-series data of the target angle to output to the drive circuit 54 in accordance with the interpreted tool change command (S12). This process corresponds to step P2 in Figure 7.
[0082] As shown in Figure 10, the CPU 41 rotates at the swivel angle θ specified by the tool change command. T at a predetermined angle θ TL It is determined whether or not the above is true (S13). The CPU 41 determines the rotation angle θ T at a predetermined angle θ TL When it is determined that the value is less than (S13: NO), the drive circuit 54 is output the target angle data based on the time-series data of the target angle generated in S12 (see Figure 9) (S14). The drive circuit 54 rotates the magazine motor 64 based on the target angle data. The magazine body 22 rotates to the target angle by the rotation of the magazine motor 64.
[0083] CPU41 receives the return value θ from encoder74. raw Based on this, the angle θ of the magazine body 22 is the tool change position of the second tool (angle θ = θ E The CPU 41 determines whether the angle θ of the magazine body 22 has reached the tool change position of the second tool (S15: NO). The CPU 41 returns to S14. The CPU 41 repeats the above process until the angle θ of the magazine body 22 reaches the tool change position of the second tool.
[0084] When the CPU 41 determines that the angle θ of the magazine body 22 has reached the tool change position for the second tool (S15: YES), it rotates the Z-axis motor 63 and lowers the spindle head 7 from the ATC origin to the workpiece machining position (S37). While the spindle head 7 is lowering, the spindle 9 mounts the second tool located at the tool change position. After that, the CPU 41 returns to processing S2 (see Figure 9).
[0085] CPU41 has a rotation angle θ T at a predetermined angle θ TL When it is determined that the above is true (S13: YES), the reference angle θ a The CPU 41 performs identification of parameters including the target angle. Based on the time-series data of the target angle generated in S12, the CPU 41 outputs the target angle data to the drive circuit 54 (S16). The CPU 41 performs the identification process (S17).
[0086] Referring to Figure 11, the identification process performed in the main process (see Figure 10) will be explained. The CPU 41 controls the parameters (moment of inertia J, viscous friction coefficient D, Coulomb friction F). C , eccentric load coefficient F θ , reference angle θ a Initialize ) (S21). Initialization means setting the parameters to 0, which is equivalent to setting each component of ρ to 0 as described above.
[0087] The CPU 41 receives the torque u that the drive circuit 54 outputs to the magazine motor 64. raw Based on this, the torque u0 of the magazine body 22 is obtained, and the return value θ from the encoder 75 is obtained. raw Based on this, the angle θ0 of the magazine body 22 is obtained (S22). Based on equations 2 and 4, the CPU 41 applies a low-pass filter to the torque u0 and angle θ0 of the magazine body 22 obtained in S22, respectively, to remove noise from the torque u0 and angle θ0 of the magazine body 22 and calculate the torque u and angle θ (S23). This process corresponds to steps P4 and P5 in Figure 7.
[0088] The CPU 41 calculates the first time derivative θ (superscript dot) of the angle θ of the magazine body 22 by performing a time derivative with respect to equation 4, and the calculated first time derivative of the angle θ of the magazine body 22 is a predetermined value θ L The CPU determines whether the value is greater than or equal to (a single superscript dot) (S24). If the CPU 41 determines that the first time derivative of angle θ is less than a predetermined value (S24: NO), it returns to the main process. If the CPU 41 determines that the first time derivative of angle θ is greater than or equal to a predetermined value (S24: YES), it moves the process to S25. This process corresponds to step P6 in Figure 7.
[0089] CPU41 applies the torque u and angle θ of the magazine body 22, respectively, after applying a low-pass filter in processing S23, to the evaluation function |e(ρ)|. 2 Based on (see Equation 10), the parameters that minimize the estimated error e at angle θ are identified (S25). This process corresponds to step P7 in Figure 7.
[0090] The CPU 41 stores the identified parameters in the storage unit 44 and updates the parameters (S26). This process corresponds to step P8 in Figure 7. The CPU 41 then returns the process to the main process.
[0091] As shown in Figure 10, after the identification process (S17) is completed, the CPU 41 determines whether the angle θ of the magazine body 22 has reached the tool change position of the second tool (S18). This process is the same as the process in S15. If the CPU 41 determines that the angle θ of the magazine body 22 has not reached the tool change position of the second tool (S18: NO), the process returns to S16. The CPU 41 identifies the parameters at angle θ until the angle θ of the magazine body 22 reaches the tool change position of the second tool.
[0092] When the CPU 41 determines that the angle θ of the magazine body 22 has reached the tool change position of the second tool (S18:YES), it determines the total eccentric load at the angle θ where the total eccentric load is maximum (the absolute value of the identified eccentric load coefficient |F). θ | is equal to) a predetermined value F θLThe following is determined (S30): The CPU41 determines the absolute value of the identified bias load coefficient |F θ | is a predetermined value F θL When it is determined to be greater than (S30:NO), the process proceeds to S61. CPU41 is the absolute value of the uneven load coefficient |F θ | is a predetermined value F θL When it is determined that the following is true (S30: YES), the identified moment of inertia J is a predetermined value J. L It is determined whether the following is true (S31). The CPU 41 determines whether the moment of inertia J is a predetermined value J. L When it is determined to be greater than (S31:NO), the process proceeds to S61. The CPU41 determines that the moment of inertia J is a predetermined value J. L When it is determined that the following is true (S31: YES), it is determined whether the weight flag is ON or not (S32). The weight flag is the total weight W, which is the sum of the weights of all the tools 3 attached to the tool magazine 21 in the weight identification process described later. T This is a flag that turns ON when the value is above a threshold, and details will be described later. If the weight flag is ON (S32:YES), the CPU 41 determines that tool 3 is overloaded and starts timing (S61). In S61, the CPU 41 determines whether a predetermined time has elapsed since timing started (S62). If the CPU 41 determines that the predetermined time has not elapsed (S62:NO), it returns to processing S62. If the CPU 41 determines that the predetermined time has elapsed (S62:YES), it moves the process to S37. If the weight flag is OFF (S32:NO), the CPU 41 proceeds to processing S33. This process corresponds to step P9 in Figure 7.
[0093] The CPU 41 reads the time constant setting (S33). The time constant setting is used to determine whether or not to perform the calculation of time constants T1 and T2. The user operates the operation unit 18 to set whether or not to perform the calculation of time constants T1 and T2. The storage unit 44 stores this setting as the time constant setting.
[0094] Based on the time constant setting read from the memory unit 44 in the S33 process, the CPU 41 determines whether or not to calculate the time constant for the current tool change command (S34). If the CPU 41 determines not to calculate the time constant (S34: NO), the process proceeds to S37.
[0095] When CPU41 determines to perform the calculation of the time constant (S34:YES), it uses the identified parameters (J, F) based on equation 20. θ Using ) the maximum angular acceleration A max The result is calculated (S35). This process corresponds to step P10 in Figure 7.
[0096] The CPU 41 calculates the time constants T1 and T2 based on equations 18 to 23 and stores the calculated time constants T1 and T2 in the storage unit 44 (S36). This process corresponds to the step P11 in Figure 7. The CPU 41 then proceeds to S37.
[0097] As shown in Figure 9, when the CPU 41 determines that the interpreted control command is a termination command (S3: YES), it terminates the main process.
[0098] Figure 12 shows the measurement and identification results of the torque u of the magazine body 22 when the magazine body 22 is rotated from 0 degrees to 360 degrees. The tool mounting state is as shown in Figure 3. As shown in Figure 12, the identification result of torque u was very close to the measurement result of torque u. Therefore, it was found that parameters can be identified with high accuracy using the method of this embodiment.
[0099] Since the numerical control device 40 can accurately identify parameters, it uses the moment of inertia J, one of the parameters, to determine the total weight W of the entire tool 3. T It can be identified with high accuracy. Subsequently, the total weight W of the entire tool 3. T The identification of the tools will be explained. Tool 3 as a whole refers to all the tools mounted in tool magazine 21.
[0100] The total weight W of the tool magazine 21 with tool 3 attached is expressed by the following formula 24. [Number 24] W=J / R 2 R is the reference radius (m) used as the basis in tool magazine 21. The reference radius R is represented, for example, by the following number 25. [Number 25] R=R M +(R T / 2) R M R is the radius of rotation from the center Q of the magazine body 22 to the gripping portion 81 of the grip arm 8. The memory unit 44 has a predetermined radius of rotation R M Remember this. R T R is the standard length of the cutting tool 4. The first method for determining the standard length of the cutting tool 4 is to uniquely determine it from the general values of the tool lengths of the cutting tools 4 to be mounted in the tool magazine 21. The second method for determining the standard length of the cutting tool 4 is to use the average value of the tool lengths of the cutting tools 4 stored in the memory unit 44. The memory unit 44 has a pre-set standard length R of the cutting tool 4. T Remember this.
[0101] Total weight of tool magazine 21 without tool 3 attached W N It can be represented by the following number 26. [Number 26] W N =J N / R 2 J N This is the moment of inertia of the tool magazine 21 without tool 3 attached.
[0102] The total weight of tool 3 is expressed by the following number 27. [Number 27] W T =WW N CPU41 calculates the moment of inertia J of the tool magazine 21 with tool 3 attached, and the moment of inertia J of the tool magazine 21 without tool 3 attached. N By identifying the number 27, the total weight W of the entire tool 3 is determined. T Identify it.
[0103] Referring to Figure 13, the weight identification process performed by the CPU 41 of the numerical control device 40 will be explained. The user operates the operation unit 18 to instruct the execution of the weight identification process. Upon receiving the instruction to execute the weight identification process, the CPU 41 reads the control program stored in the ROM 42 and executes the control program. Before the execution of the weight identification process, the user removes the tool 3 from the tool magazine 21.
[0104] The CPU 41 determines whether or not it has received input regarding the mounting status of tool 3 in the tool magazine 21 (S41). The user operates the control unit 18 and inputs a setting indicating that tool 3 has been removed from the tool magazine 21. If the CPU 41 determines that it has not received input regarding the mounting status of tool 3 in the tool magazine 21 (S41: NO), it returns to processing S41. If the CPU 41 determines that it has received input regarding the mounting status of tool 3 in the tool magazine 21 (S41: YES), it determines whether or not the received setting indicates that all tools 3 have been removed from the tool magazine 21 (S42). If the CPU 41 determines that the received setting does not indicate that all tools 3 have been removed from the tool magazine 21 (S42: NO), it returns to processing S41.
[0105] When the CPU 41 determines that the setting it received is that all tools 3 have been removed from the tool magazine 21 (S42: YES), it executes the first feed process (S43). In the first feed process, the CPU 41 rotates the magazine motor 64, for example, rotating the angle θ of the magazine body 22 from 0 (deg) to 360 (deg). The angle θ of the magazine body 22 in the first feed process may be changed as appropriate.
[0106] The CPU 41 performs the identification process (S44). The identification process in S44 is the same as the identification process in Figure 11. In the identification process in S44, the CPU 41 determines the moment of inertia J of the tool magazine 21 without the tool 3 installed. N The CPU 41 identifies the tool 3 identified in S44 and stores it in memory unit 44.N Based on this, the total weight of tool magazine 21 without tool 3 attached is W N Identify (S45).
[0107] After the identification process in S44 is completed, the user places tool 3 into the tool magazine 21. The CPU 41 determines whether or not it has received input regarding the state in which tool 3 is placed in the tool magazine 21 (S46). The user operates the control unit 18 and inputs a setting indicating that tool 3 has been placed in the tool magazine 21. If the CPU 41 determines that it has not received input regarding the state in which tool 3 is placed in the tool magazine 21 (S46: NO), the process returns to S45. If the CPU 41 determines that it has received input regarding the state in which tool 3 is placed in the tool magazine 21 (S46: YES), it determines whether or not the received setting indicates that tool 3 has been placed in the tool magazine 21 (S47). If the CPU 41 determines that the received setting does not indicate that tool 3 has been placed in the tool magazine 21 (S47: NO), the process returns to S45.
[0108] When the CPU 41 determines in S46 that the setting received is that the tool 3 has been attached to the tool magazine 21 (S47: YES), it executes the second feed process (S48). In the second feed process, the CPU 41 rotates the magazine motor 64 in the same way as in the first feed process (S43), for example, rotating the angle θ of the magazine body 22 from 0 (deg) to 360 (deg). The angle θ of the magazine body 22 in the second feed process may be changed as appropriate. The angle θ of the magazine body 22 may be the same or different between the first feed process and the second feed process.
[0109] The CPU 41 performs an identification process (S49). The identification process in S49 is the same as the identification process in Figure 11. In the identification process in S49, the CPU 41 identifies the moment of inertia J of the tool magazine 21 with the tool 3 attached and stores it in the memory unit 44. Based on the number 24 and the moment of inertia J of the tool magazine 21 with the tool 3 attached identified in S49, the CPU 41 identifies the total weight W of the tool magazine 21 with the tool 3 attached (S50).
[0110] CPU41 is the total weight of tool magazine 21 without tool 3, identified in S45. N Based on the total weight W of the tool magazine 21 with tool 3 identified in S50, and number 27, the total weight W of the entire tool 3 T Identify (S51).
[0111] CPU41 identified tool 3 total weight W T The predetermined value W L Determine whether the following is true (S52). CPU41 is the total weight W of the entire tool 3. T The predetermined value W L The weight identification process is terminated when it is determined that the following is true (S52: YES).
[0112] CPU41 is the total weight of tool 3 in W T The predetermined value W L When it is determined to be greater than (S52: NO), the weight flag is turned ON (S53). The weight flag is the total weight W of the entire tool 3. T The predetermined value W L When it is greater than or equal to , the value is set to 1 and it becomes ON. The weight flag is OFF at the start of the weight identification process, with a value of 0. When the weight flag is ON, the main process determines that tool 3 is overloaded (S32: NO, see Figure 10). The CPU 41 terminates the weight identification process.
[0113] A second embodiment of the present invention will be described with reference to Figure 14. In each of the following embodiments, the absolute value of the eccentric load coefficient |F| in the main process is θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. L The processing when it is greater than (S31:NO) or when the weight flag is ON (S32:YES) differs from that of the first embodiment. In the second embodiment, the absolute value of the eccentric load coefficient is |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. LIf the value is greater than (S31: NO), or if the weight flag is ON (S32: YES), the rotational speed of the Z-axis motor 63 is reduced to mount the tool 3. The other configurations of the second embodiment are the same as those of the first embodiment. In the following embodiments, components common to the first embodiment are denoted by the same reference numerals as in the first embodiment, and their descriptions are omitted.
[0114] CPU41 is the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. L If it is greater than (S31: NO), or if the weight flag is ON (S32: YES), the speed determination process is executed (S63). In the process of S63, the CPU 41 determines the maximum angular velocity V set for the Z-axis motor 63 in S37. max A speed that is slower than the maximum angular velocity V 2max The memory unit 44 determines the maximum angular velocity V of the Z-axis motor 63. 2max The CPU 41 stores this information. The CPU 41 then moves the processing to S37. In the processing of S37, the CPU 41 stores the maximum angular velocity V of the Z-axis motor 63 that was decelerated in S61. 2max The spindle head 7 is then lowered from the ATC origin to the workpiece machining position.
[0115] Referring to Figure 15, a third embodiment of the present invention will be described. In the third embodiment, the absolute value of the eccentric load coefficient is |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. L If the value is greater than (S31: NO), or if the weight flag is ON (S32: YES), the acceleration / deceleration time constant of the Z-axis motor 63 is increased to mount the tool 3. The other configurations of the third embodiment are the same as those of the first embodiment.
[0116] CPU41 is the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. LIf it is greater than (S31:NO), or if the weight flag is ON (S32:YES), the time constant determination process is executed (S64). In the process of S64, the CPU 41 determines a time constant that is greater than the preset acceleration / deceleration time constant of the Z-axis motor 63 in S37. The storage unit 44 stores the time constant of the Z-axis motor 63. The CPU 41 then proceeds to process S37. In the process of S37, the CPU 41 lowers the spindle head 7 from the ATC origin to the workpiece machining position using the time constant of the Z-axis motor 63 determined in S64.
[0117] Referring to Figure 16, a fourth embodiment of the present invention will be described. In the fourth embodiment, the absolute value of the eccentric load coefficient is |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. L If the value is greater than (S31: NO), or if the weight flag is ON (S32: YES), the system will notify that the tool 3 is overloaded and stop driving the motor 60. The other configurations of the fourth embodiment are the same as those of the first embodiment.
[0118] CPU41 is the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL If it is greater than (S30:NO), the moment of inertia J is a predetermined value J. L If the value is greater than (S31: NO), or if the weight flag is ON (S32: YES), the notification process is executed (S65). In the process of S65, the CPU 41 notifies the overloading of the tool 3 via the display unit 19. The CPU 41 stops the motor 60 from driving (S66) and terminates the main process.
[0119] As described above, determining the control parameters for high-speed and high-precision control of the machine tool 1 requires physical parameters such as the moment of inertia related to the machine tool 1. Based on the state in which the tool 3 is mounted in the tool magazine 21, the reference angle θ at which the total eccentric load due to the tool 3 balances out is determined. a The value changes. The total eccentric load by tool 3 is the reference angle θ. aIt depends on the magnitude of the tool. Therefore, conventional numerical control devices have had difficulty identifying physical parameters due to the influence of the total eccentric load by tool 3.
[0120] In response to this, the CPU 41 of the numerical control device 40, when changing tools based on a tool change command, uses a reference angle θ a Total eccentric load F based on this θ sin(θ-θ a The parameters are identified using a model based on the above. This allows the CPU 41 to control the effect of the total uneven load in the tool magazine 21 of the machine tool 1 without having to execute a dedicated operating mode for parameter identification. Therefore, the numerical control device 40 can appropriately control the effect of the total uneven load in the machine tool 1 more easily than before.
[0121] CPU41 is the maximum torque that magazine motor 64 can output u max , and the identified parameters (uneven load coefficient F θ Based on the moment of inertia J), the maximum angular acceleration A when the parameters were identified is... max The CPU 41 calculates the maximum angular acceleration A based on the identified parameters (S35, P10). max By calculating this, the magazine body 22 can be rotated with an appropriate angular acceleration depending on the state in which the tools 3 are mounted in the tool magazine 21.
[0122] CPU41 is the maximum angular velocity V that the magazine motor 64 can output. max and maximum angular acceleration A max Based on this, the time constant T1 is calculated using equation 19. CPU41 is the maximum angular acceleration A max Based on this, the acceleration / deceleration time constant T1 in the magazine motor 64 is calculated. Therefore, the CPU 41 can rotate the magazine body 22 with appropriate acceleration / deceleration depending on the state in which the tools 3 are mounted in the tool magazine 21.
[0123] CPU41 is based on the standard load coefficient F θb , reference moment of inertia J b , reference time constant T1 bBased on this, the time constant T1 is calculated using equation 22. The CPU 41 calculates the acceleration / deceleration time constant T1 in the magazine motor 64 based on the parameters of the standard mounting state of the tool 3 and the identified parameters. Therefore, the CPU 41 can rotate the magazine body 22 with appropriate acceleration / deceleration according to the mounting state of the tool 3 in the tool magazine 21.
[0124] CPU41 identifies the total eccentric load at the angle θ where the magnitude of the total eccentric load is maximum. The magnitude of the total eccentric load at this time is the absolute value of the identified eccentric load coefficient |F θ | is equal to |. CPU41 is the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL The CPU 41 determines whether the following conditions apply (S30, P9). The CPU 41 also identifies the moment of inertia J. The CPU 41 determines the absolute value of the identified eccentric load coefficient |F θ | is a predetermined value F θL When it is determined to be greater than (S30:NO), or when the moment of inertia J is a predetermined value J L When it is determined that the value is greater than (S31: NO), timing is started (S61). When the CPU 41 determines that a predetermined time has elapsed since the timing started (S62: YES), it rotates the Z-axis motor 63 and lowers the spindle head 7 from the ATC origin to the workpiece machining position (S37).
[0125] When the total eccentric load or moment of inertia of the entire tool 3 is excessively large, the rotational position of the magazine body 22 may not stabilize after the magazine body 22 has finished rotating. In this case, if the tool 3 is to be mounted, the spindle 9 may not be able to mount the tool 3 properly. The CPU 41 of the numerical control device 40 of the present invention rotates the Z-axis motor 63 after a predetermined time has elapsed, so the mounting of the tool 3 to the spindle 9 can be performed after the rotational position of the magazine body 22 has stabilized.
[0126] CPU41 identifies the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL When it is determined to be greater than (S30:NO), or when the moment of inertia J is a predetermined value J L When it is determined to be greater than (S31:NO), the maximum angular velocity V of the Z-axis motor 632max The speed is reduced (S63). Therefore, the CPU 41 can mount the tool 3 onto the spindle 9 after the rotational position of the magazine body 22 has stabilized.
[0127] CPU41 identifies the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL When it is determined to be greater than (S30:NO), or when the moment of inertia J is a predetermined value J L When it is determined to be greater than (S31: NO), the time constant of the Z-axis motor 63 is set to be greater than the preset acceleration / deceleration time constant (S64). Therefore, the CPU 41 can mount the tool 3 onto the spindle 9 after the rotational position of the magazine body 22 has stabilized.
[0128] CPU41 identifies the absolute value of the eccentric load coefficient |F θ | is a predetermined value F θL When it is determined to be greater than (S30:NO), or when the moment of inertia J is a predetermined value J L When it is determined that the value is greater than (S31: NO), notification processing is performed (S65). In processing S65, the CPU 41 notifies the user via the display unit 19 that the tool 3 is overloaded. As a result, the user can determine the absolute value of the uneven load coefficient |F in the mounted state of the tool 3. θ Alternatively, it can be determined that the magnitude of the moment of inertia J is excessively large.
[0129] When the CPU 41 determines that the control command interpreted from the NC program is a tool change command (S4:YES), it identifies the parameters (S25). Therefore, the CPU 41 can identify the parameters during machining without having to execute a dedicated operating mode for parameter identification before machining the workpiece. Consequently, the numerical control device 40 can appropriately control the effect of the total uneven load on the machine tool 1 more easily than before.
[0130] CPU41 controls the torque u output by the drive circuit 54. rawBased on this, the torque u0 of the magazine body 22 is obtained (S22). The CPU 41 applies a low-pass filter to the torque u0 of the magazine body 22 to remove noise and calculate the torque u (S23, P4). The CPU 41 receives the return value θ from the encoder 74. raw Based on this, the angle θ0 of the magazine body 22 is obtained (S22). The CPU 41 applies a low-pass filter to the angle θ0 of the magazine body 22 to remove noise and calculate the angle θ (S23, P5). The numerical control device 40 removes noise contained in the torque u0 of the magazine body 22 and the angle θ0 of the magazine body 22 by filtering, so the parameters can be identified with high accuracy.
[0131] The CPU 41 obtains the angle θ0 of the magazine body 22 (S22). Based on equation 4, the CPU 41 calculates the first time derivative θ (superscript dot) of the angle θ of the magazine body 22, and the first time derivative of the calculated angle θ is a predetermined value θ. L It is determined whether the value is greater than or equal to (a single superscript dot) (S24, P6). The CPU 41 determines whether the first time derivative of the angle θ of the magazine body 22 is a predetermined value θ. L When it is determined that the above conditions are met, the torque u of the magazine body 22 and the angle θ of the magazine body 22 are used to identify the parameters. As a result, the numerical control device 40 removes the torque u and angle θ that degrade the accuracy of parameter identification, so that the parameters can be identified with high accuracy.
[0132] In the above embodiment, the tool change command is an example of an input condition of the present invention. The CPU 41 that processes S2 is an example of an acquisition unit of the present invention. The torque u of the magazine body 22 and the angle θ of the magazine body 22 are examples of drive results of the present invention. Equation 7 is an example of a transmission model of the present invention. The CPU 41 that processes S25 is an example of an identification unit of the present invention. The CPU 41 that processes S30 and S31 is an example of a threshold determination unit of the present invention. The CPU 41 that processes S61 is an example of a timing unit of the present invention. The CPU 41 that processes S62 is an example of a time determination unit of the present invention. The CPU 41 that processes S37 is an example of a detachable drive unit of the present invention. The CPU 41 that processes S63 is an example of a speed determination unit of the present invention. The CPU 41 that processes S64 is an example of a time constant determination unit of the present invention. The CPU 41 that processes S65 is an example of a notification unit of the present invention. The CPU 41 that processes S4 is an example of a command determination unit of the present invention. The CPU 41 that processes S23 is an example of a filter of the present invention. The CPU 41 that processes S22 is an example of a drive result acquisition unit of the present invention. The CPU 41 that performs the processing in S24 is an example of the drive result determination unit of the present invention.
[0133] The present invention can be modified in various ways from the above embodiments. The various modifications described below can be combined in any way as long as they do not create contradictions. For example, the numerical control device 40 is not limited to being installed on the machine tool 1, but may be installed separately from the machine tool 1. For example, the numerical control device 40 may be a device (PC, dedicated machine, etc.) connected to the machine tool 1. The tool magazine 21 is not limited to a turret type, but may be an arm type, for example.
[0134] The CPU 41 may perform processes other than determining whether the tool 3 is overloaded (S31, S32) based on the identified parameters. For example, the numerical control device 40 may perform feedforward control in addition to feedback control based on the feedback signal output by the encoder 74. In this case, the CPU 41 may optimize the parameters of the feedforward control according to the determined parameters. Furthermore, control parameters such as the position-proportional gain, velocity-proportional gain, and velocity-integral gain of the feedback control may be optimized. In this case, the numerical control device 40 can control the machine tool 1 at high speed and with high precision.
[0135] The parameter identified by the numerical control device 40 is the reference angle θ. a It is sufficient that it includes the above, and the numerical control device 40 may identify other parameters as appropriate.
[0136] In the above embodiment, the numerical control device 40 identified the parameters using the successive least squares method, but the parameters may be identified by other methods. For example, the numerical control device 40 may identify the parameters using the linear least squares method. The method of identifying parameters using the linear least squares method will be described below.
[0137] In the linear least squares model, the estimated error j is represented by the following number 28.
number
number
[0138] The normal equation in equation 28 is expressed in equation 30 below.
number
[0139] CPU41 has a rotation angle θ T at a predetermined angle θ TL The parameters may be identified when the value is less than a certain value. In this case, the CPU 41 may omit the processing in S13 in the main processing. The CPU 41 may also identify the parameters when the command satisfies other conditions. For example, the CPU 41 may identify the parameters when the command is a termination command. Also, for example, the CPU 41 may identify the parameters when the operation of the machine tool 1 based on the command is in one of several stationary states.
[0140] In the above embodiment, the CPU 41 determined whether or not to use the torque u and angle θ for parameter identification based on the magnitude of the first time derivative of angle θ. Alternatively, the CPU 41 may use all acquired torque u and angle θ for parameter identification. Furthermore, the CPU 41 may determine whether or not to use the torque u and angle θ for parameter identification based on other conditions. For example, the CPU 41 may determine whether or not to use the torque u and angle θ for parameter identification based on the magnitude of the second time derivative of angle θ.
[0141] CPU41 acquired torque u raw and return value θ raw After determining whether or not to use it for parameter identification, noise may be removed.
[0142] CPU41 acquired torque u raw and return value θ raw A low-pass filter may be applied. In this case, the CPU 41 should calculate the torque u and angle θ before processing S25.
[0143] The CPU 41 may apply a filter other than a low-pass filter when removing noise from torque u0 and angle θ0. For example, the CPU 41 may remove noise from torque u0 and angle θ0 by applying a high-pass filter. The CPU 41 may remove noise from either torque u0 or angle θ0. The CPU 41 does not need to remove noise from torque u0 or angle θ0. In this case, the CPU 41 may omit the S23 process in the identification process.
[0144] CPU41 identified the eccentric load coefficient F θ The CPU 41 may determine whether the tool 3 is overloaded based on the magnitude of either the tool 3 or the moment of inertia J. θ The CPU 41 may determine whether the tool 3 is overloaded based on the magnitude of both the load and the moment of inertia J. θ Furthermore, it may be determined whether or not the tool 3 is overloaded based on identified parameters other than the moment of inertia J.
[0145] The CPU 41 does not need to determine whether or not the tool 3 is overloaded. In this case, the CPU 41 may omit the processes S30-S32 and S61-S66 in the main process. In the fourth embodiment, the CPU 41 notified via the display unit 19 in the process of S65. Alternatively, the CPU 41 may notify via a speaker, lamp, etc.
[0146] The CPU 41 may correct the target angle when the tool 3 is mounted in the tool magazine 21 based on the identified parameters. Parameters such as the moment of inertia J change due to the effect of mounting the tool 3 in the tool magazine 21. The numerical control device 40 can control the magazine motor 64 taking into account the effect of mounting the tool 3 in the tool magazine 21. [Explanation of symbols]
[0147] 1 Machine tools 3 tools 20 Tool changer 22 Magazine Body 40 Numerical control devices 41 CPU 64 Magazine Motor
Claims
1. A numerical control device that outputs a command indicating the driving conditions of a motor for a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, An acquisition unit that acquires input conditions which are predetermined drive conditions, The system includes an identification unit that identifies the parameters of the transmission model based on the drive result obtained by the acquisition unit, which drives the tool magazine according to the input conditions, and the transmission model of the machine tool. The transmission model includes the eccentric load based on a reference angle in the angle of the rotating tool magazine where the eccentric load is zero, The numerical control device is characterized in that the parameter includes the reference angle.
2. The numerical control device according to claim 1, further comprising an acceleration calculation unit that calculates the acceleration of the motor based on the parameters identified by the identification unit and the torque output by the motor.
3. The numerical control device according to claim 2, further comprising a time constant calculation unit that calculates the acceleration time constant of the motor based on the acceleration calculated by the acceleration calculation unit.
4. The numerical control device according to claim 3, characterized in that the time constant calculation unit calculates the time constant in the motor based on a reference state which is a reference state in which the tools are stored in the tool magazine, the reference moment of inertia of the tool magazine, and the reference bias load of the tool magazine.
5. The parameters identified by the identification unit further include the eccentric load or the moment of inertia of the tool magazine, and the threshold determination unit determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, When the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is greater than or equal to the threshold, the timing unit starts timing the elapsed time. A time determination unit that determines whether the elapsed time measured by the time measurement unit has elapsed to a predetermined time, When the time determination unit determines that the elapsed time has exceeded the predetermined time, the attachment / detachment drive unit starts driving the attachment / detachment mechanism for attaching and detaching the tool to and from the spindle of the machine tool. The numerical control device according to claim 1, characterized in that it is provided for.
6. The parameters identified by the identification unit further include the eccentric load or the moment of inertia of the tool magazine, and the threshold determination unit determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, The numerical control device according to claim 1, further comprising a speed determination unit that, when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is greater than or equal to the threshold, determines the maximum rotational speed of the attachment / detachment motor that drives the attachment / detachment mechanism for attaching / detaching the tool to and from the spindle of the machine tool to be lower than the maximum rotational speed when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is not greater than or equal to the threshold.
7. The parameters identified by the identification unit further include the eccentric load or the moment of inertia of the tool magazine, and the threshold determination unit determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, The numerical control device according to claim 1, further comprising a time constant determination unit that, when the threshold determination unit determines that the magnitude of the eccentric load is greater than or equal to the threshold, sets the acceleration / deceleration time constant of the attachment / detachment motor that drives the attachment / detachment mechanism for attaching / detaching the tool to and from the spindle of the machine tool to be greater than the time constant when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is not greater than or equal to the threshold.
8. The parameters identified by the identification unit further include the eccentric load or the moment of inertia of the tool magazine, and the threshold determination unit determines whether the magnitude of the eccentric load or the moment of inertia is greater than or equal to a predetermined threshold, The numerical control device according to claim 1, further comprising a notification unit that notifies an error when the threshold determination unit determines that the magnitude of the eccentric load or the moment of inertia is greater than or equal to the threshold.
9. The acquisition unit includes a command determination unit that determines whether the input condition acquired by the acquisition unit is a tool change command to exchange the tool mounted on the spindle of the machine tool with the tool stored in the tool magazine. The identification unit identifies the parameter when the command determination unit determines that the input condition acquired by the acquisition unit is the tool change command. A numerical control device according to any one of claims 1 to 8, characterized by the above.
10. The numerical control device according to claim 9, further comprising a filter to remove noise included in the drive result.
11. A drive result acquisition unit that acquires the aforementioned drive result, A drive result determination unit determines whether to use the drive result acquired by the drive result acquisition unit for the identification of the parameters by the identification unit. The numerical control device according to claim 10, characterized by comprising the above.
12. An identification method for identifying parameters for determining a command indicating the driving conditions of a motor in a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, An acquisition step to acquire input conditions which are predetermined driving conditions, The system includes an identification step for identifying the parameters of the transmission model based on the drive result obtained by driving the tool magazine according to the input conditions acquired in the acquisition step and the transmission model of the machine tool, The transmission model includes the eccentric load based on a reference angle in the angle of the rotating tool magazine where the eccentric load is zero, The identification method is characterized in that the parameter includes the reference angle.
13. An identification program for identifying parameters for determining a command indicating the driving conditions of a motor in a machine tool equipped with a motor for rotating a tool magazine that stores tools and has a rotation axis in a direction intersecting the vertical direction, An acquisition process to acquire input conditions which are predetermined driving conditions, The system includes an identification process that identifies the parameters of the transmission model based on the drive result obtained by the acquisition process, which drives the tool magazine according to the input conditions, and the transmission model of the machine tool. The transmission model includes the eccentric load based on a reference angle in the angle of the rotating tool magazine where the eccentric load is zero, An identification program characterized in that the parameters include the reference angle.