Processing program generation device and processing program generation method

The machining program generation device optimizes machining sequences for automatic lathes by dividing areas into elements and allocating tasks between multiple spindles, addressing inefficiencies in existing methods and reducing preparation time.

WO2026038431A1PCT designated stage Publication Date: 2026-02-19CITIZEN MASCH CO LTD +1
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
PCT/JP2025/024770
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2025-02-04
Filing Date
2025-07-10
Publication Date
2026-02-19

AI Technical Summary

Technical Problem

Existing machining program generation methods for automatic lathes are inefficient, as they do not adequately account for the continuous machining process, leading to increased preparation time and reduced effectiveness when compared to multi-tasking machines.

Method used

A machining program generation device and method that divides machining areas into elements, determines a machining order based on distance from the spindle, and allocates elements to multiple spindles to minimize time differences, generating a suitable machining program for automatic lathes.

Benefits of technology

Reduces preparation time for machining by optimizing the machining sequence and allocating tasks efficiently between multiple spindles, resulting in stable and efficient machining processes regardless of operator skill level.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure JP2025024770_19022026_PF_FP_ABST
    Figure JP2025024770_19022026_PF_FP_ABST
Patent Text Reader

Abstract

Provided is a processing program generation device for generating a processing process and a processing program for a machine tool, the device comprising a spindle to which a cutting object is attached, a rotation mechanism for rotating the spindle, a cutting object feeding mechanism for moving the cutting object in a feeding direction with respect to the spindle, a tool holding unit for holding a cutting tool that cuts the cutting object, and a movement mechanism for moving the cutting tool in a direction intersecting the feeding direction of the spindle. The processing program generation device is provided with a processing area acquisition unit that acquires the difference between a material shape of the cutting object and a target shape as a processing area to be processed with the cutting tool, a processing area division unit that divides the processing area into a plurality of elements, and an order determination unit that determines a processing order of the plurality of elements, wherein the order determination unit determines the processing order such that, among the plurality of elements, the elements to be processed in a state in which the cutting object is attached to the spindle are processed in order starting from the element whose tip position in the feeding direction is farthest from the spindle.
Need to check novelty before this filing date? Find Prior Art

Description

Machining program generation device and machining program generation method

[0001] The present invention relates to a machining program generating device and a machining program generating method.

[0002] In machining using a machine tool, machining can be performed by operating the machine tool in accordance with NC (numerical control) data based on a machining program. The machining program is converted into a machining program for controlling the operation of the machine tool by manually inputting a separately designed machining process into, for example, CAM (Computer Aided Manufacturing) software.

[0003] When creating a machining program, it is necessary to first determine the machining process, including elements such as the machining locations, machining order, machining conditions, and tools to be used, which requires time for preparation, including the know-how of skilled workers and man-hours. Therefore, in order to resolve the lack of know-how in machining and reduce preparation time, there has been an accelerating trend in recent years to utilize computer-aided process planning (CAPP) systems that can automatically plan machining processes.

[0004] Patent Document 1 discloses a method for automatically generating machining steps that can be used in machine tools, such as multi-tasking machines that perform turning and milling.

[0005] Japanese Patent Application Laid-Open No. 2018-136928

[0006] However, the above-mentioned technology is applied to machine tools such as multi-tasking machines, and is based on the premise that a new workpiece is attached to the machine tool each time machining of a product is completed. Therefore, when this technology is applied to machine tools such as automatic lathes, in which the workpiece is pushed out appropriately and machining is performed continuously, it is not necessarily possible to generate machining processes and machining programs suitable for the automatic lathe. If the machining processes and machining programs need to be adjusted to be suitable for the automatic lathe, the effect of reducing the preparation time for machining will be reduced.

[0007] In view of the above-mentioned problems, an object of the present invention is to reduce the preparation time for machining.

[0008] (Aspect 1) In order to solve the above problem, a machining program generation device according to Aspect 1 of the present invention is a machining program generation device that generates machining steps and machining programs for a machine tool that includes a spindle to which a workpiece is attached, a rotation mechanism that rotates the spindle, a workpiece feed mechanism that moves the workpiece in a feed direction relative to the spindle, a tool holding unit that holds a cutting tool that cuts the workpiece, and a movement mechanism that moves the cutting tool in a direction intersecting the feed direction of the spindle, and the device includes: a machining area acquisition unit that acquires a difference between a material shape and a target shape of the workpiece as a machining area to be machined by the cutting tool; a machining area division unit that divides the machining area into a plurality of elements; and an order determination unit that determines a machining order for the plurality of elements, and the order determination unit determines the machining order such that, for elements to be machined while the workpiece is attached to the spindle, elements whose tip ends in the feed direction are farthest from the spindle are machined in order.

[0009] (Aspect 2) In the aspect 1, when there are elements having the same position of the leading end in the feed direction, the sequence determination unit may determine the machining sequence such that the elements are machined in order of the position of the rear end opposite to the leading end in the feed direction that is farthest from the spindle.

[0010] (Aspect 3) In Aspect 1 above, the machine tool may include a second spindle arranged to face the first spindle when the spindle is a first spindle, and on which the workpiece to be cut is attached, and may further include a sorting unit that sorts the plurality of elements into first elements that are machined with the workpiece attached to the first spindle and second elements that are machined with the workpiece attached to the second spindle.

[0011] (Aspect 4) In the aspect 3, the sequence determination unit may determine the processing sequence such that the second element is processed after the first element, and the second elements are processed in order starting from the element whose tip end position in the direction opposite to the feed direction is farthest from the second spindle.

[0012] (Aspect 5) In the above aspect 3, a calculation unit may be provided that calculates a time difference between a total processing time of the first element and a total processing time of the second element, and the allocation unit may allocate the plurality of elements to the first element and the second element so as to minimize the time difference.

[0013] (Aspect 6) In the above aspect 1, when a through hole is formed in the target shape that penetrates in a direction that intersects the feed direction, the machining area dividing unit may divide the machining area corresponding to the through hole into two at the center of the through hole's penetration direction.

[0014] (Aspect 7) In the above aspect 1, when a through hole is formed in the target shape that penetrates in a direction parallel to the feed direction and whose hole diameter changes at a boundary surface perpendicular to the feed direction, the machining area division unit may divide the machining area corresponding to the through hole into two at the boundary surface.

[0015] (Aspect 8) In the above aspect 1, the machining center may further include a coordinate conversion unit that generates first data obtained by coordinate-converting the three-dimensional model of the target shape so that a central axis of the three-dimensional model coincides with a central axis of the spindle, and second data obtained by inverting the first data in the axial direction, and a calculation unit that calculates a first total machining time of the first data and a second total machining time of the second data, and the machining area acquisition unit may acquire either the first data or the second data as the machining area based on the first total machining time and the second total machining time.

[0016] (Aspect 9) In the above aspect 1, the machine tool further includes a second spindle, when the spindle is a first spindle, arranged to be able to face the first spindle and to which the workpiece to be cut is attached, and a support structure arranged in front of the first spindle and supporting the workpiece together with the first spindle, wherein the sequence determination unit may set the drilling process before the external turning process when the workpiece to be cut is supported by the first spindle, and may set the drilling process after the external turning process when the workpiece to be cut is supported by the second spindle.

[0017] (Aspect 10) In the above aspect 1, if the length in the feed direction of an element among the plurality of elements that is machined by external diameter turning exceeds a predetermined length, the machining area division unit may divide the element in the feed direction to generate a plurality of elements.

[0018] (Aspect 11) In the above aspect 1, the machining area acquisition unit may add a machining allowance for end face machining to the machining area when the distance from the end face of the material shape to the end face of the target shape is shorter than a predetermined distance.

[0019] (Aspect 12) In the above aspect 1, when the machining area includes a shape in which the machining allowance of the external diameter turning increases stepwise in a direction parallel to the feed direction, the machining area dividing unit may divide the machining area at a surface where the machining allowance changes.

[0020] (Aspect 13) In order to solve the above problem, a machining program generation method according to Aspect 13 of the present invention is a machining process and machining program generation method for generating a machining program for a machine tool including a spindle to which a workpiece is attached, a rotation mechanism that rotates the spindle, a workpiece feed mechanism that moves the workpiece in a feed direction relative to the spindle, a tool holding unit that holds a cutting tool that cuts the workpiece, and a movement mechanism that moves the cutting tool in a direction intersecting the feed direction of the spindle, the method including: a machining area acquisition step of acquiring a machining area to be machined by the cutting tool, which is a difference between a material shape of the workpiece and a target shape; a machining area division step of dividing the machining area into a plurality of elements; and an order determination step of determining an order of machining of the plurality of elements, wherein in the order determination step, the machining order is determined such that, for elements to be machined while the workpiece is attached to the spindle, elements whose tip positions in the feed direction are farthest from the spindle are machined in order.

[0021] (Aspect 14) In Aspect 13 above, the machine tool includes a second spindle configured to be able to face the first spindle when the spindle is a first spindle, and to which the workpiece to be cut is attached, and the machining program generation method further includes an allocation step of allocating the plurality of elements into first elements to be machined with the workpiece to be cut attached to the first spindle and second elements to be machined with the workpiece to be cut attached to the second spindle, and in the allocation step, the plurality of elements may be allocated to the first elements and the second elements so as to minimize the time difference between the total machining time of the first elements and the total machining time of the second elements.

[0022] According to the present invention, the preparation time for machining can be reduced.

[0023] 1 is a schematic configuration diagram of a machine tool. FIG. 2 is a block diagram showing an example of the configuration of a machining program generation device. FIG. 3 is an explanatory diagram of the functional units of the machining program generation device. FIG. 4 is an explanatory diagram of a method for acquiring machining features. FIG. 5 is a flowchart of the machining program generation method. FIG. 6 is an explanatory diagram of the machining program generation method. FIG. 7 is an explanatory diagram of a method for generating machining primitives for through holes. FIG. 8 is a diagram showing an example of a material shape and a target shape. FIG. 9 is a diagram showing a machining process for a first element. FIG. 10 is a diagram showing a machining process for a second element. FIG. 11 is an example of a target shape with chamfering formed. FIG. 12 is an explanatory diagram of the functional units of the machining program generation device according to Modified Example 1. FIG. 13 is a flowchart of coordinate transformation according to Modified Example 1. FIG. 14 is an explanatory diagram of machining features according to Modified Example 2. FIG. 15 is an explanatory diagram of a method for adding machining allowance for end face machining according to Modified Example 4.

[0024] Hereinafter, with reference to the drawings, a detailed description will be given of exemplary embodiments of the present invention. Note that the dimensions, materials, shapes, and relative positions of the components described in the embodiments may be changed as appropriate depending on the configuration of the device to which the invention is applied and various conditions. In other words, the scope of the present invention is not limited to the following embodiments.

[0025] <Embodiment> As an embodiment of the present invention, an automatic lathe device equipped with two spindles and capable of simultaneously machining workpieces held by each spindle, a machining process suitable for the automatic lathe device, and a machining program generation device and generation method will be described.

[0026] (Machine Tool) The configuration of a machine tool 10 according to an embodiment of the present invention will be described. The machine tool 10 is a so-called automatic lathe device. The machine tool 10 is a device that performs cutting (turning) by rotating a workpiece W, which is, for example, a long bar, as an object to be cut (a workpiece), and applying a cutting tool (a processing tool) to the workpiece.

[0027] The machine tool 10 includes a first spindle (front spindle) 101 and a second spindle (rear spindle) 102 arranged opposite each other on a base, a material supply unit 200, and a tool rest 300. The two spindles, the first spindle 101 and the second spindle 102, are arranged so that their axes are substantially concentric or parallel to each other. In the following description and drawings, the axial direction of the two spindles is referred to as the Z direction, the direction perpendicular to the axial direction that is parallel to the vertical direction is referred to as the X direction, and the direction parallel to the horizontal direction is referred to as the Y direction. Furthermore, within the Z direction, the direction from the first spindle 101 to the second spindle 102 is referred to as the +Z direction, and the direction from the second spindle 102 to the first spindle 101 is referred to as the −Z direction.

[0028] 1(a) and 1(b) are schematic diagrams of the machine tool 10, showing the configuration of the machine tool 10 as viewed in the Y direction. Fig. 1(a) shows a state in which the first spindle 101 and the second spindle 102 each hold a different workpiece W. Fig. 1(b) shows a state in which the first spindle 101 and the second spindle 102 hold the same workpiece W.

[0029] The machine tool 10 also includes a spindle mechanism for driving each spindle. The spindle mechanism is composed of, for example, a headstock that rotatably supports the spindle, a rotation mechanism that rotates the spindle together with the workpiece W, and a drive mechanism for moving the spindle in a predetermined direction. In this embodiment, the second spindle 102 is provided so as to be movable in the X and Z directions by the drive mechanism. As the drive mechanism, for example, a ball screw drive mechanism constituted by a motor as a drive source, a ball screw, a guide rail, etc. may be used. Note that the first spindle 101 may be provided so as to be movable by the drive mechanism, and the second spindle 102 may be provided so as to be movable in the Y direction.

[0030] The first spindle 101 has a hollow structure with a workpiece holding hole for holding or gripping the workpiece W, and is equipped with a chuck or chuck sleeve (not shown) for holding the workpiece W (a state in which the axial center of the workpiece W in the first spindle 101 is determined and axial movement is restricted). The workpiece holding hole opens axially toward the second spindle 102, and the portion of the workpiece W exposed from the opening is the portion that is machined by a cutting tool 301 supported by a tool rest 300. In addition, a guide bush (not shown) that serves as a support structure for the workpiece W is arranged in front of the first spindle 101.

[0031] The configuration on the second spindle 102 side is similar to the configuration on the first spindle 101 side, and is capable of gripping and rotating the workpiece W. The workpiece holding hole of the second spindle 102 opens axially toward the first spindle 101 side. If the protruding direction of the workpiece W from the first spindle 101 is defined as a first protruding direction Z1, then the protruding direction of the workpiece W from the second spindle 102 is a second protruding direction Z2 that is opposite to the first protruding direction Z1. The first protruding direction Z1 and the second protruding direction Z2 are directions parallel to the axial directions of the respective spindles, and in this embodiment, the first protruding direction Z1 is the +Z direction, and the second protruding direction Z2 is the -Z direction.

[0032] The chuck and chuck sleeve (not shown) are configured such that the chuck sleeve is axially joined to the chuck from behind via a tapered surface, with the chuck's axial movement restricted. The chuck sleeve attempts to move axially in response to a force applied from a fluid cylinder (not shown) driven by hydraulic pressure, air, or the like, and applies a force to the chuck, including a component force directed toward the axis, generating a clamping force in the chuck that closes the slits provided in the chuck. This creates a state in which the workpiece W is gripped.

[0033] The material supply unit 200 is a cutting workpiece feed mechanism that moves the workpiece W relative to the first spindle 101 in a feed direction parallel to the axial direction of the first spindle 101. The material supply unit 200 can be configured, for example, by a holding unit that holds the rear end of the workpiece W and a drive rod that drives the holding unit in the Z direction. The feed direction of the workpiece W is the direction in which the workpiece W is transported toward the second spindle 102, and in this embodiment is synonymous with the first protrusion direction Z1. The material supply unit 200 may be provided with an independent control unit that controls the operation of each unit of the material supply unit 200.

[0034] The tool rest 300 is a tool holding unit to which a plurality of cutting tools 301, which are selectable depending on the type of machining to be performed, can be attached. The machine tool 10 also includes a movement mechanism (drive mechanism) that drives the tool rest 300 to move the cutting tools 301 held by the tool rest 300 in a direction (e.g., the X direction or the Y direction) intersecting the feed direction of the first spindle 101 (material supply unit 200). The tool rest 300 is movable forward and backward in each direction relative to the workpiece W by a movement mechanism (not shown). A selected cutting tool 301 is applied to the rotating workpiece W to perform a desired cutting process (turning process) on the workpiece W. In this embodiment, two tool rests 300 are provided, each capable of mounting a plurality of cutting tools 301. For simplicity, only one cutting tool 301 attached to the tool rest 300 is shown in FIGS. 1( a) and 1(b).

[0035] The machine tool 10 controls each section, such as the first spindle 101, the second spindle 102, the tool rest 300, and the material feeder 200, based on the machining steps and machining program generated by an external machining program generation device 50, to perform cutting machining in accordance with the machining program. The machine tool 10 is also provided with an output section, such as an operation section and a monitor, that the user operates to determine whether the machining program is executable and to adjust machining conditions, etc. In this embodiment, the machining program generation device 50 is a separate device independent of the machine tool 10, but the machine tool 10 may have the same functions as the machining program generation device 50, and the machine tool 10 may also be configured to include the machining program generation device 50.

[0036] As shown in FIG. 1( a), machine tool 10 is capable of gripping a workpiece W with each of first spindle 101 and second spindle 102 and simultaneously performing cutting on each workpiece W. In machine tool 10, the first half of the machining process for machining workpiece W into a desired ideal shape is performed while held by first spindle 101, and after cutting (cutting off) the workpiece W, the second half of the machining process can be performed while held by second spindle 102. In this case, to improve machining efficiency, machining of the first half of the workpiece W held by first spindle 101 and machining of the second half of the workpiece W held by second spindle 102 after the first half has been machined can be performed simultaneously. Furthermore, cutting of workpiece W can be performed while one end of the workpiece W is held by first spindle 101 and the other end is held by second spindle 102, with the axes of first spindle 101 and second spindle 102 being concentric, as shown in FIG. 1( b).

[0037] (Machining program generating device) The machining program generating device 50 is a device that generates machining steps and a machining program (machining instruction data) for machining the workpiece W into a desired target shape (ideal shape, machined shape). The machining program is converted into NC (numerical control) data, for example, by CAM, and each part of the machine tool 10 is controlled by the NC data.

[0038] 2 is a block diagram showing an example of the configuration of the machining program generating device 50. The machining program generating device 50 is, for example, a general-purpose computer. The machining program generating device 50 includes a communication interface (communication I / F) 51, a storage device 52, an input / output device 53, and a processor 54, which are connected via a communication bus 55.

[0039] The communication I / F 51 may be, for example, a network card or a communication module, and communicates with the machine tool 10, other computers, devices, etc. based on a predetermined protocol. The machining program generation device 50 can send a machining program to the machine tool 10 via the communication I / F 51. Transmission of machining instruction data from the machining program generation device 50 to the machine tool 10 may be performed by either wired communication or wireless communication.

[0040] The storage device 52 includes, for example, a main storage device such as a RAM (Random Access Memory) or a ROM (Read Only Memory), and an auxiliary storage device (secondary storage device) such as a HDD (Hard-Disk Drive), an SSD (Solid State Drive), or a flash memory. The main storage device temporarily stores programs read by the processor 54 and information sent and received between other computers, and secures a working area for the processor 54. The auxiliary storage device stores programs executed by the processor 54 and information sent and received between other computers. The auxiliary storage device may also include removable media (portable recording media). Removable media is, for example, a USB memory, an SD card, or a disc recording media such as a CD-ROM, a DVD disc, or a Blu-ray disc. The storage device 52 (e.g., the auxiliary storage device) stores an operating system (OS), various programs, various information tables, and the like.

[0041] The input / output device 53 is a user interface, such as an input device such as a keyboard or a mouse, an output device such as a monitor, an input / output device such as a touch panel, etc. Through the input / output device 53, an operator can input control parameters for setting a machining path for cutting.

[0042] The processor 54 is an arithmetic processing device such as a CPU (Central Processing Unit) or a DSP (Digital Signal Processor), and performs each process according to the present embodiment by executing a program. The processor 54 can realize various processes by loading a program stored in the auxiliary storage device of the storage device 52 into the main storage device and executing the program.

[0043] The machining program generating device 50 does not necessarily have to be realized by a single physical configuration, but may be configured by a plurality of computers that cooperate with each other.

[0044] Next, the functional units of the machining program generating device 50 will be described using an operation example. Fig. 3 is an explanatory diagram of the functional units of the machining program generating device 50. The machining program generating device 50 includes a machining area acquisition unit 61, a machining area division unit 62, a sequence determination unit 63, and an allocation unit 64 as functional units for generating a machining program.

[0045] The machining program generating device 50 uses each functional unit to acquire machining features MF to be used in the machining program from the material shape BS and target shape TS of the workpiece W. Figures 4(a) to 4(e) are explanatory diagrams of a method for acquiring machining features MF by the machining program generating device 50.

[0046] The machining area acquisition unit 61 acquires a machining area (removal area) MA to be machined when machining the workpiece W from the material shape BS to the target shape TS. FIG. 4( a) is a perspective view of the material shape BS. In this example, the material shape BS is a cylinder with a diameter D1 and a length L1. In the machine tool 10, which is an automatic lathe device, the workpiece W is generally a bar stock, and the material shape BS is generally cylindrical. The axial length of the material shape BS may be set to be the same as or longer than the target shape TS. FIG. 4( b) is a perspective view of the target shape TS. In this example, the target shape TS is formed by axially arranging a cylinder with a diameter D2 and a length L2 and two other cylinders with a diameter D3 and a length L3. Note that in this example, L1 = L2 + L3, and D1 > D3 > D2.

[0047] The machining area acquisition unit 61 acquires the difference between the material shape BS and the target shape TS as the machining area MA. Fig. 4(c) is a perspective view of the machining area MA. In this example, the machining area MA has a shape in which a space equivalent to the target shape TS is provided inside a cylinder. By completely removing this machining area MA from the material shape BS, the target shape TS can be obtained.

[0048] The machining area dividing unit 62 divides the machining area MA acquired by the machining area acquisition unit 61 into a plurality of elements. The elements obtained by dividing the machining area MA are referred to as machining primitives MP in the following description. The machining area dividing unit 62 can, for example, extend the boundary surface that is the boundary between the machining area MA and the target shape TS, and divide the machining area MA into a plurality of machining primitives MP based on the boundary surface. The machining area MA may be divided so that the plurality of machining primitives MP have overlapping areas.

[0049] 4(d) is a perspective view of the machining primitive MP. In this example, two machining primitives MP are obtained from the machining area MA. Specifically, the machining area MA is divided into a cylindrical machining primitive MP with an outer diameter D1, an inner diameter D3, and a length L1, and a cylindrical machining primitive MP with an outer diameter D1, an inner diameter D2, and a length L2.

[0050] The order determination unit 63 determines a machining order (work order) for the multiple machining primitives MP divided (obtained) by the machining area division unit 62. The order determination unit 63 determines the machining order of all machining primitives MP in accordance with a predetermined rule. The order determination method by the order determination unit 63 will be described in detail later.

[0051] The order determination unit 63 is a processing feature recognition unit that recognizes (determines) processing primitives MP as processing features MF by assigning a processing order to the processing primitives MP. When a processing feature MF is determined, an overlapping area of ​​one processing primitive MP is deleted from the other processing primitive MP. In other words, the order determination unit 63 converts the processing primitives MP divided from the processing area MA into processing features MF.

[0052] FIG. 4E is a perspective view of the processing feature MF. In this example, each of the two processing primitives MP is recognized as a processing feature MF. One processing feature MF is cylindrical with an outer diameter D1, an inner diameter D2, and a length L2, and has the same shape as the processing primitive MP. The other processing feature MF is cylindrical with an outer diameter D1, an inner diameter D3, and a length L3. In other words, this processing feature MF is formed by deleting an overlapping region between the cylindrical processing primitive MP with the outer diameter D1, the inner diameter D2, and the length L2 and the cylindrical processing primitive MP with the outer diameter D1, the inner diameter D2, and the length L2 from the cylindrical processing primitive MP with the outer diameter D1, the inner diameter D3, and the length L1. However, the processing features MF that can be recognized from the processing primitive MP are not limited to one pattern, and multiple patterns of processing features MF can be recognized. Furthermore, a processing primitive MP having the same shape as the processing feature MF of FIG. 4E may be divided from the processing area MA of FIG. 4C.

[0053] The allocating unit 64 allocates the multiple machining features MF into first elements that are machined when the workpiece W is attached to the first spindle 101, and second elements that are machined when the workpiece W is attached to the second spindle 102. In this embodiment, the allocating unit 64 allocates the multiple machining features MF to the first elements and the second elements so as to minimize the time difference between the total machining time of the first elements and the total machining time of the second elements.

[0054] (Machining Program Generating Method) A machining program generating method will be described below. Fig. 5 is a flowchart of a machining program generating method performed by the machining program generating device 50.

[0055] First, a machining area acquisition process for acquiring a machining area MA is performed in step (hereinafter referred to as S) 401. In the machining area acquisition process, the machining area acquisition unit 61 acquires the differential shape of the material shape BS and the target shape TS as the machining area MA based on these.

[0056] Next, in S402, a machining area dividing step is performed to divide the machining area MA. In the machining area dividing step, the machining area dividing unit 62 divides the machining area MA into a plurality of elements to obtain machining primitives MP.

[0057] Next, in S403, an order determination step is performed to determine a machining order. The order determination unit 63 assigns a machining order to the machining primitives MP acquired in S402. By determining the machining order, the machining primitives MP are recognized as machining features MF by the machining program generation device 50. In other words, the order determination step here is synonymous with the feature recognition step for recognizing them as machining features MF. When the machining primitives MP are recognized as machining features MF, the tools to be used, machining conditions, etc. are assigned to each machining feature MF.

[0058] In this embodiment, the order determination unit 63 recognizes the machining feature MF by assigning a machining order to the machining primitives MP in descending order of the maximum Z coordinate. That is, the machining order is assigned starting from the machining primitive MP whose tip end position in the +Z direction (first protrusion direction Z1) is farthest from the first main spindle 101. Furthermore, if there are machining primitives MP with the same maximum Z coordinate, the order determination unit 63 recognizes the machining feature MF by assigning a machining order to those machining primitives MP in ascending order of the minimum Z coordinate. That is, the machining order is assigned starting from the machining primitive MP whose rear end position in the +Z direction is farthest from the first main spindle 101.

[0059] The steps after the sequence determination step will be described using FIGS. 6(a) to 6(d). FIGS. 6(a) to 6(d) are explanatory diagrams of a machining program generation method. FIG. 6(a) shows a target shape TS. FIG. 6(b) shows a cylindrical material shape BS and machining primitives MP obtained by dividing the machining area MA obtained from the target shape TS of FIG. 6(a). In this example, the target shape TS includes a cylindrical outer diameter portion TSa and a cylindrical outer diameter portion TSb that is larger in diameter than the outer diameter portion TSa and is connected to the outer diameter portion TSa on the −Z direction side. A chamfer TSc is formed at the tip of the outer diameter portion TSa in the +Z direction, and a chamfer TSd is formed at the rear end (tip in the −Z direction) of the outer diameter portion TSb in the +Z direction.

[0060] In generating the machining program, machining primitives MP corresponding to each portion of the target shape TS are obtained, and machining features MF are recognized. Hereinafter, the one corresponding to the outer diameter portion TSa will be referred to as the first machining primitive MPa and first machining feature MFa, the one corresponding to the outer diameter portion TSb will be referred to as the second machining primitive MPb and second machining feature MFb, the one corresponding to the chamfer TSc will be referred to as the third machining primitive MPc and third machining feature MFc, and the one corresponding to the chamfer TSd will be referred to as the fourth machining primitive MPd and fourth machining feature MFd. In this example, the shapes of the machining primitive MP and machining feature MF are the same.

[0061] Of the four machining primitives MP, the first machining primitive MPa, the second machining primitive MPb, and the third machining primitive MPc have the largest maximum Z coordinates, and the fourth machining primitive MPd has the smallest. Of the first machining primitive MPa, the second machining primitive MPb, and the third machining primitive MPc, the smallest Z coordinates are the third machining primitive MPc, the first machining primitive MPa, and the second machining primitive MPb, in that order. Therefore, the order determination unit 63 determines the machining order as follows: third machining primitive MPc, first machining primitive MPa, second machining primitive MPb, and fourth machining primitive MPd. Figure 6(c) shows the machining order of the machining features MF after the order determination step.

[0062] Next, in S404, an allocation step is performed in which the machining feature MF is allocated to a first element to be machined while attached to the first spindle 101, and a second element to be machined while attached to the second spindle 102. In the cutting process for machining the workpiece W from the material shape BS to the target shape TS, the first element is machined first, and then the second element is machined.

[0063] In this embodiment, the allocating unit 64 allocates the processing features MF so that the time difference between the total processing time of the first element and the total processing time of the second element is minimized. The processing time of each processing feature MF can be acquired based on the processing conditions, etc., assigned when the feature is recognized as the processing feature MF. However, the allocation method is not limited to this method. For example, the allocating unit 64 may allocate the processing features MF so that the time difference between the total processing time of the first element and the total processing time of the second element is a predetermined threshold value. Note that the allocating unit 64 may be configured to be able to calculate the processing time of each processing feature MF, the total processing time of the first element, and the total processing time of the second element, or a calculation unit separate from the allocating unit 64 may be provided. Furthermore, the processing time of each processing feature MF may be roughly calculated based on the volume of the processing feature MF rather than the processing conditions.

[0064] In the example shown in FIG. 6C, the third processing feature MFc and the first processing feature MFa are classified as the first element, and the second processing feature MFb and the fourth processing feature MFd are classified as the second element.

[0065] Next, in S405, a feature re-recognition step is performed to re-recognize the machining features MF. For the machining features MF assigned to the second element in the allocation step, the machining order is determined in the order determination step so that they are machined in descending order of the maximum Z coordinate, i.e., in descending order of proximity to the second spindle 102. This machining order is not suitable for automatic lathe turning because the root portion of the workpiece W closest to the second spindle 102 is cut first, meaning that subsequent machining is performed in a state where the rigidity of the workpiece W is low. Therefore, in this embodiment, a feature re-recognition step is performed after the allocation step, and the machining order is reassigned and the machining features MF are re-recognized for the second element.

[0066] In the feature re-recognition process, first, the machining features MF of the second element are returned to machining primitives MP. The process of returning the machining features MF to machining primitives MP may be configured to be executable by, for example, the allocating unit 64, or may be configured to be executable by another functional unit. Then, with the Z coordinate of each machining primitive MP inverted, the order determination unit 63 reassigns a machining order and re-recognizes them as machining features MF. In other words, for the second element, the machining order is assigned starting from the machining primitive MP whose tip position in the -Z direction (second protrusion direction Z2) is farthest from the second main spindle 102. Furthermore, if there are machining primitives MP with the same maximum Z coordinate, the order determination unit 63 recognizes the machining features MF by assigning a machining order in ascending order of the minimum Z coordinate. In other words, the machining order is assigned starting from the machining primitive MP whose rear end position in the -Z direction is farthest from the second main spindle 102.

[0067] 6(c), in the feature re-recognition process, the second element, the second machining feature MFb and the fourth machining feature MFd, are returned to the machining primitive MP. Then, with their Z coordinates inverted, the machining order is reassigned based on the Z coordinates. The second machining primitive MPb and the fourth machining primitive MPd have the same leading end position in the second protrusion direction Z2, and the fourth machining primitive MPd has a rear end position farther from the second spindle 102. Therefore, they are recognized as machining features MF so that the machining order is the fourth machining primitive MPd first, followed by the second machining primitive MPb.

[0068] 6(d) shows the machining order of the machining features MF after the feature re-recognition process. After the feature re-recognition process, the machining order becomes the third machining feature MFc, the first machining feature MFa, the fourth machining feature MFd, and the second machining feature MFb. According to this machining order, with the workpiece W held by the first spindle 101, the chamfer TSc and the outer diameter portion TSa can be machined in a single cut. Also, with the workpiece W held by the second spindle 102, the chamfer TSd and the outer diameter portion TSb can be machined in a single cut. Furthermore, the workpiece W held by the first spindle 101 and the workpiece W held by the second spindle 102 can be machined at the same time.

[0069] Through the above steps, a machining program in which the machining sequence, machining conditions, etc. are set is generated. The machining program is then converted into a form such as NC data that drives each part of the machine tool 10, and sent to the machine tool 10. The machining program conversion may be configured to be executable by the machining program generation device 50, or another device may receive and convert the machining program.

[0070] The above-described machining program generation method allows for automatic generation of a machining program suitable for an automatic lathe device, thereby reducing the preparation time for machining. Furthermore, since the machining program can be generated without relying on the operator's intuition or knack, a stable and appropriate machining program can be generated regardless of the operator's skill level. Furthermore, machining processes are allocated so that the machining times of the first spindle 101 and the second spindle 102 are uniform, thereby realizing efficient machining.

[0071] (Method for generating machining primitives for through holes) In machining, if the through hole formed in the target shape TS is long, a drill with a long overall length must be used, which can easily make the machining unstable. Furthermore, depending on the length of the through hole, it is conceivable that the drill may not be long enough to machine the through hole in the first place. Therefore, an example of a method for generating machining primitives MP for a through hole will be described.

[0072] 7(a) and (b) are explanatory diagrams of a method for generating a machining primitive MP for a through hole. Fig. 7(a) shows a method for generating a machining primitive MP corresponding to a through hole Ha that penetrates in a direction intersecting the axial direction. The diameter of the through hole Ha is constant in the penetration direction.

[0073] After acquiring the machining primitive MPe corresponding to the through hole Ha, the machining area dividing unit 62 further divides the machining primitive MPe into two at the center in the piercing direction. In other words, the machining primitive MPe is divided into two machining primitives MPf at the boundary of a cross section S1 that passes through the center in the piercing direction and is perpendicular to the piercing direction. The machining primitives MPf have the same length in the piercing direction.

[0074] 7B shows a method for generating a machining primitive MP corresponding to a through-hole Hb penetrating in a direction parallel to the axial direction. The diameter of the through-hole Hb changes in the penetrating direction with a boundary surface S2 as the boundary.

[0075] After acquiring the machining primitive MPg corresponding to the through hole Hb, the machining area dividing unit 62 further divides the machining primitive MPg into two at the boundary surface S2. In other words, the machining primitive MPg is divided into a machining primitive MPh and a machining primitive MPi at the boundary surface S2 that is perpendicular to the penetration direction.

[0076] In this way, by dividing the machining primitive MP for a through hole, it is possible to form the through hole by drilling from both sides of the through hole's penetration direction. In other words, the drilling depth in one drilling operation can be kept small. Furthermore, for through holes whose diameters change in the penetration direction, it is possible to generate machining primitive MPs so that they can be drilled with drills appropriate for each diameter.

[0077] (Example of machining process) An example of a machining process created using the machining program generation method described above will be shown below. Figures 8(a) and 8(b) are diagrams showing an example of a material shape BS and a target shape TS. Figure 8(a) is a perspective view of the material shape BS. Figure 8(b) is a perspective view of the target shape TS. In this example, the total length (axial length) of the material shape BS is longer than the total length of the target shape TS.

[0078] In this example, the target shape TS is composed of three cylinders with different diameters arranged in the axial direction in ascending order. The target shape TS is divided into a first portion P1, a second portion P2, and a third portion P3 in ascending order of diameter. The second portion P2 has a through-hole H1 formed therethrough in a direction intersecting the axial direction. The third portion P3 has a hole H2 formed from the end face in a direction parallel to the axial direction. A first chamfer CP1 is formed on the end face of the first portion P1, a second chamfer CP2 is formed on the end face of the second portion P2, a third chamfer CP3 and a fourth chamfer CP4 are formed on both end faces of the third portion P3, and a fifth chamfer CP5 is formed at the end of the hole H2. The third chamfer CP3 is formed on the end face connected to the second portion P2, and the fourth chamfer CP4 is formed on the end face of the target shape TS.

[0079] An example of a machining process generated by the machining program generation method according to this embodiment is shown in Figures 9 and 10. Figure 9 is a diagram showing a machining process for a first element, i.e., a machining process in which a workpiece W is machined while attached to the first spindle 101. Figure 10 is a diagram showing a machining process for a second element, i.e., a machining process in which a workpiece W is machined while attached to the second spindle 102. In Figures 9 and 10, the parts machined in each machining process are shown hatched.

[0080] First, the first element is machined while the workpiece W is held by the first spindle 101. In this example, machining is performed in the following order: the end face of the first portion P1, the first chamfer CP1, the outer diameter of the first portion P1 and the end face of the second portion P2, the second chamfer CP2, the outer diameter of the second portion P2 and the end face of the third portion P3 (the surface on the side of the third chamfer CP3), and the third chamfer CP3. Thereafter, the workpiece W is held by the first spindle 101 and the second spindle 102, and the end face of the third portion P3 (the surface on the side of the fourth chamfer CP4) is cut off by cut-off machining.

[0081] Next, the second element is machined while the workpiece W is held by the second spindle 102. In this example, machining is performed in the following order: the end face (cut-off surface side) of the third portion P3, the fifth chamfer CP5, the fourth chamfer CP4, the outer diameter of the third portion P3, the hole H2, and the through hole H1. Machining of the through hole H1 is performed in two steps: machining from one end side of the through hole and machining from the other end side. Through the above machining steps, a target shape TS is formed from the material shape BS.

[0082] Other Embodiments The above-described embodiment is merely an example, and the present disclosure may be modified as appropriate within the scope of the present disclosure. Furthermore, the processes and means described in the present disclosure may be freely combined and implemented as long as no technical contradiction occurs.

[0083] Furthermore, a process described as being performed by one device may be shared and executed by multiple devices. Alternatively, a process described as being performed by different devices may be executed by a single device. In a computer system, the hardware configuration for realizing each function can be flexibly changed.

[0084] (Method for Determining the Chamfering Machining Order) In the above-described embodiment, the order determination unit 63 determines the machining order based on the Z coordinate of the machining primitive MP. However, in chamfering using an automatic lathe device, determining the machining order based only on the Z coordinate may not be optimal. Therefore, as another embodiment, an example of a method for determining the chamfering machining order that differs from the above-described embodiment will be described.

[0085] FIG. 11 is a perspective view showing an example of a target shape TS on which chamfers have been formed. The target shape TS in this example has three types of chamfers: Ca, Cb, and Cc. The chamfer Ca is a chamfer formed on the outer diameter portion (outer edge) of the target shape TS. Automatic lathe machines often machine relatively small diameter machine parts. Therefore, to enable outer diameter chamfering and outer diameter turning to be performed in a single cut using the same cutting tool, the machining order may be determined so that outer diameter chamfering such as chamfer Ca is performed immediately before outer diameter turning of the outer diameter portion on which the chamfer has been formed.

[0086] The chamfer Cb is a chamfer formed on the inner diameter portion of a through hole drilled in the axial direction of the target shape TS. It is assumed that the chamfer formed on the end of a through hole or a blind hole will be machined using a center drill as a cutting tool. Therefore, the machining order may be determined so that the inner diameter chamfer such as the chamfer Cb is performed immediately before the drilling of the hole portion (inner diameter portion) where the chamfer is formed.

[0087] 11 shows an example in which a chamfer is formed on a through hole that penetrates parallel to the axial direction, but the machining sequence can be set in a similar manner for chamfers formed on through holes that penetrate in a direction intersecting the axial direction. Also, in a configuration in which multiple hole portions of the same diameter are formed and each hole portion is chamfered, the machining sequence may be set so that the holes are drilled consecutively with the same drill and then the chamfers are performed all at once.

[0088] The chamfer Cc is a chamfer formed at the end of a cutout portion formed in the target shape TS. It is preferable that other chamfering processes that do not fall under the category of outer diameter chamfering or inner diameter chamfering be performed after the material around the chamfer has been removed. Therefore, the processing order for other chamfering processes such as the chamfer Cc may be determined so that they are performed immediately after the processing step around the chamfer (in this example, after the cutout portion has been processed).

[0089] As described above, for chamfering, by configuring the program so that different order determination methods are applied depending on the type of chamfer and the location where the chamfer is formed, the machining program can be further optimized.

[0090] (Method for determining machining sequence taking into account orientation of target shape after coordinate transformation) The machining program generation device 50 acquires a target shape TS, which is the shape of the final product, based on a three-dimensional model created using, for example, 3D CAD (Computer Aided Design). At this time, the machining program generation device 50 performs coordinate transformation on the received three-dimensional model so that the central axis of the three-dimensional model coincides with the central axis of the first spindle 101 of the machine tool 10.

[0091] When converting the coordinates of a three-dimensional model, two methods are possible: either setting one end in the axial direction as the tip in the first protrusion direction Z1, or setting the other end opposite the one end as the tip in the first protrusion direction Z1. If the target shape TS is asymmetric in the axial direction, the total machining time of the machining program generated by the machining program generation device 50 may differ depending on the orientation of the coordinate-converted three-dimensional model. Various factors contribute to the difference in total machining time depending on the orientation of the three-dimensional model, such as differences in the machining order of each machining feature MF and the number of tool changes. Therefore, in order to generate a machining program with a shorter total machining time, it is preferable to perform coordinate conversion taking the total machining time into account. Below, a coordinate conversion method taking the total machining time into account will be described as Modification 1. In the description of Modification 1, only differences from the above-described embodiment will be described, and parts similar to those in the embodiment will be designated by the same reference numerals and will not be described again.

[0092] 12 is an explanatory diagram of the functional units of the machining program generation device 50 according to Modification 1. The machining program generation device 50 according to Modification 1 further includes a coordinate conversion unit 65 that performs coordinate conversion of a three-dimensional model of the received target shape TS, and a calculation unit 66 that calculates a total machining time based on the three-dimensional model coordinate-converted by the coordinate conversion unit 65. The calculation unit 66 may be configured to be able to calculate the machining time of each machining feature MF and the total machining time of each of the first and second elements assigned by the assignment unit 64. However, the configuration is not limited to this, and the assignment unit 64 may be configured to have the same functions as the calculation unit as in the above-described embodiment.

[0093] Fig. 13 is a flowchart of coordinate conversion by the machining program generating device 50 according to Modification 1. The coordinate conversion method according to Modification 1 will be described with reference to the flowchart of Fig. 13. First, in S1301, the machining program generating device 50 receives a three-dimensional model of a target shape TS from an external device.

[0094] Next, in S1302, the coordinate conversion unit 65 generates first data and second data obtained by performing coordinate conversion on the received three-dimensional model. The first data is data that has been coordinate converted so that the central axis of the target shape TS coincides with the central axis of the first main spindle 101. The second data is data that has been obtained by inverting the first data in the Z direction, i.e., data that has been obtained by inverting the Z coordinate of the first data.

[0095] Next, in S1303, the calculation unit 66 calculates the total machining time for machining the material shape BS into the target shape TS based on each of the first data and the second data. The total machining time calculated by the calculation unit 66 based on the first data is referred to as the first total machining time, and the total machining time calculated based on the second data is referred to as the second total machining time. At this time, it is preferable that the order determination unit 63 determines a tentative machining order for each of the first data and the second data, the allocation unit 64 allocates the multiple machining features MF to first elements and second elements, and the calculation unit 66 is configured to be able to calculate each total machining time.

[0096] Next, in S1304, the machining area acquisition unit 61 determines whether to acquire the first data or the second data as the machining area MA based on the first total machining time and the second total machining time. That is, in this process, it is determined whether the data to be used in creating the machining program will be the first data or the second data. In this example, if the first total machining time is less than the second total machining time, the first data is adopted, and if the first total machining time is greater than the second total machining time, the second data is adopted. Then, the machining program generation device 50 acquires the machining area MA based on the determined data and generates the machining program. Note that the decision as to whether to adopt the first data or the second data may be made by another functional unit, rather than the machining area acquisition unit 61.

[0097] As described above, according to the configuration of the first modification, the total machining time is calculated based on both the first data obtained by coordinate transformation of the three-dimensional model of the target shape TS and the second data obtained by inverting the first data in the Z-axis direction, and a machining program can be generated based on the data that results in the shortest total machining time. Therefore, machining can be made more efficient.

[0098] (Method for determining the machining order of external turning and drilling) In the above-described embodiment, the machining order was determined based on the Z coordinate of each machining feature MF. However, when the machining order is determined based only on the position of the machining feature MF, the rigidity of the workpiece W during machining is not taken into account. This may result in the generation of a machining program in which machining is performed in a state in which the support rigidity of the workpiece W is low, which may not necessarily result in optimal machining. Therefore, a machining order method that changes the machining order of external turning and drilling depending on the presence or absence of a guide bush will be described as an example as Modified Example 2. In the description of Modified Example 2, only the differences from the above-described embodiment will be described, and the same reference numerals will be used to denote the same parts as in the embodiment, and description thereof will be omitted.

[0099] In the second modification, a guide bush (not shown) is arranged in front of the first spindle 101 as in the above embodiment, and serves as a support structure for supporting the workpiece W together with the first spindle 101.

[0100] 14 is an explanatory diagram of processing features MF according to Modification 2. A method for determining the processing order will be described using as an example a target shape TS having a cylindrical portion TSe and a hole portion TSf opening at an end face of the cylindrical portion TSe as shown in Fig. 14. The processing program generation device 50 acquires a fifth processing feature MFe corresponding to the cylindrical portion TSe and a sixth processing feature MFf corresponding to the hole portion TSf from such a target shape TS.

[0101] In determining the machining order of the fifth machining feature MFe and the sixth machining feature MFf, the order determination unit 63 of the machining program generation device 50 first compares the maximum Z coordinates of the respective machining features MF, as in the above-described embodiment. In this example, the maximum Z coordinates of the fifth machining feature MFe and the sixth machining feature MFf are the same.

[0102] The fifth machining feature MFe is machined by external diameter turning, and the sixth machining feature MFf is machined by drilling. When drilling is performed before external diameter turning, a hole portion TSf is formed in the workpiece W, and the rigidity of the workpiece W during external diameter turning is lower than when drilling is performed after external diameter turning. On the other hand, when machining is performed while supported by a guide bush, performing external diameter turning first increases the gap between the machined portion and the guide bush, reducing the support rigidity of the workpiece W during drilling. Furthermore, for example, when end face machining and external diameter turning are performed using the same tool, it is more efficient to perform end face machining and external diameter turning consecutively. Therefore, in Comparative Example 2, the machining order of external diameter turning and drilling is determined so that the machining order differs depending on whether the workpiece W is supported by a guide bush or not.

[0103] After acquiring the machining feature MF, the sequence determination unit 63 determines the sequence of outer diameter turning and drilling based on whether the machining of the fifth machining feature MFe and the sixth machining feature MFf is performed with the workpiece W attached to the first spindle 101 or the second spindle 102. Specifically, when the machining of the fifth machining feature MFe and the sixth machining feature MFf is performed with the workpiece W attached to the first spindle 101, the sequence determination unit 63 sets the drilling (machining of the sixth machining feature MFf) before the outer diameter turning (machining of the fifth machining feature MFe). On the other hand, when the machining of the fifth machining feature MFe and the sixth machining feature MFf is performed with the workpiece W attached to the second spindle 102, the sequence determination unit 63 sets the drilling after the outer diameter turning.

[0104] Various methods can be used to determine whether the fifth machining feature MFe and the sixth machining feature MFf are machined when the workpiece W is attached to either the first spindle 101 or the second spindle 102. For example, the determination may be made based on the orientation of the end face where the hole portion TSf opens. Alternatively, the determination may be made based on whether the fifth machining feature MFe and the sixth machining feature MFf have been assigned to either the first element or the second element by the assigning unit 64. In this case, after the assigning step by the assigning unit 64, the machining order of the outer diameter turning and the drilling is switched as necessary by the order determining unit 63.

[0105] Note that if the machine tool 10 does not have the second spindle 102 and is configured with only the first spindle 101, allocation by the allocation unit 64 is not performed. Therefore, when the order determination unit 63 determines the machining order of the machining features MF, the order may be determined depending on the presence or absence of a guide bush, without performing the above-mentioned judgment. Furthermore, if the machine tool 10 is configured not to have a guide bush, the order determination unit 63 may be configured to determine the machining order from the beginning so that the drilling machining is set after the outer turning machining.

[0106] As described above, according to the configuration of Modification 2, it is possible to generate a machining program that optimizes the machining order depending on whether or not the guide bush is present during machining. As a result, it is possible to efficiently machine the workpiece W while preventing a decrease in the support rigidity of the workpiece W.

[0107] (Method of Axial Dividing Machining Primitives of the Same Diameter) In turning, it is preferable to reduce the amount of protrusion of the workpiece W from the spindle during machining, taking into account the support rigidity of the workpiece W. Therefore, a configuration for dividing the machining primitive MP in the axial direction when the length of the machining primitive MP exceeds a predetermined length will be described as an example as Modified Example 3. In the description of Modified Example 3, only the points that differ from the above-described embodiment will be described, and the same reference numerals will be used to denote the same parts as in the embodiment, and description thereof will be omitted.

[0108] In the third modification, a method of generating machining primitives MP when machining a target shape TS shown in FIG. 4(b) from a material shape BS shown in FIG. 4(a) will be described.

[0109] In the embodiment described above, a machining feature MF such as that shown in Fig. 4(e) was generated based on a machining primitive MP such as that shown in Fig. 4(d) for a cylindrical portion having a diameter D2. When machining such a machining feature MF, it is necessary to set the protrusion amount of the workpiece W from the first spindle 101 to be equal to or greater than the length L2 of the machining feature MF. However, if the protrusion amount is large, there is an increased risk of a decrease in machining accuracy due to the whirling of the tip of the workpiece W.

[0110] Therefore, in Modification 3, if the axial length of a machining primitive MP to be machined by external diameter turning, among the multiple machining primitives MP obtained by dividing the machining area MA, exceeds a predetermined length, the machining area dividing unit 62 divides the machining primitive MP in the axial direction to generate multiple machining primitives MP. With this configuration, it is possible to generate a machining program in which the initial external diameter turning is performed with the protrusion amount of the workpiece W minimized, and then the workpiece W is moved in the feed direction to perform the next external diameter turning.

[0111] A specific example of the method for dividing the machining primitive MP in the axial direction according to Modification 3 will be described below. The following describes an example in which the length L2 of the workpiece W shown in Fig. 4(b) is 150 mm and the predetermined length serving as the threshold is 60 mm. First, the machining area dividing unit 62 generates a cylindrical machining primitive MP (on the right side of Fig. 4(d)) with an outer diameter D1, an inner diameter D2, and a length L2 corresponding to the cylindrical portion with a diameter D2.

[0112] Since the length L2 of the generated machining primitive MP exceeds the predetermined length of 60 mm, the machining area dividing unit 62 then divides the machining primitive MP in the axial direction so that the total length is less than the predetermined length. In this example, a machining primitive MP with a length L2 of 150 mm is divided into three machining primitives MP with a total length of 50 mm, for example. According to this method of generating machining primitives MP, it is possible to generate a machining program that performs machining corresponding to the first machining primitive MP with a protrusion amount of 60 mm, machining corresponding to the second machining primitive MP with a protrusion amount of 110 mm, and machining corresponding to the third machining primitive MP with a protrusion amount of 160 mm.

[0113] The predetermined length, which is the threshold value, may not be a single value, but may be set separately for each material of the workpiece W. The predetermined length may also be arbitrarily set by the user. The total length of the machining primitives MP after division does not need to be uniform; for example, in the above example, the three machining primitives MP may be divided so that their lengths are 60 mm, 60 mm, and 30 mm.

[0114] As described above, according to the configuration of variant example 3, machining primitives MP that are long in the axial direction can be automatically divided in the axial direction, which prevents the generation of machining programs that perform machining with excessively long protrusion amounts, thereby improving machining quality.

[0115] (Setting of Machining Allowance for End Face Machining) In machining using an automatic lathe, the workpiece may be separated from the workpiece W by cut-off. Because burrs or the like may remain on the end face of the workpiece W remaining after cut-off, it is preferable to perform end face machining. On the other hand, if the end faces of the material shape BS and the target shape TS coincide, there is no machining allowance for end face machining, and end face machining cannot be performed. Therefore, a configuration in which the machining program generation device 50 automatically assigns a machining allowance for end face machining when the end faces of the material shape BS and the target shape TS coincide or when the machining allowance for end face machining is insufficient will be described as an example in Modification 4. In the description of Modification 4, only the differences from the above-described embodiment will be described, and parts similar to those in the embodiment will be designated by the same reference numerals and will not be described again.

[0116] A method of adding a machining allowance for end face machining will be described below using an example in which the overall lengths of the material shape BS and target shape TS are each length L4. Figure 15 is an explanatory diagram of a method of adding a machining allowance for end face machining according to Modification 4. In Figure 15, the material shape BS before the addition of the machining allowance is shown in solid lines, and the target shape TS is shown in two-dot chain lines superimposed on the material shape BS.

[0117] When acquiring the machining area MA based on the material shape BS and the target shape TS, the machining area acquisition unit 61 acquires the distance (zero in this example) from the end face of the material shape BS to the end face of the target shape TS. If the acquired distance is below a predetermined distance as a threshold, the machining area acquisition unit 61 adds a machining allowance BSa of length L5 for end face machining to both ends of the material shape BS. Then, by acquiring the machining area MA based on the material shape BS to which the machining allowance BSa has been added and the target shape TS, the machining allowance for end face machining is added to the machining area MA. Note that the predetermined distance as the threshold may be any value sufficient for end face machining, such as 0.5 mm to 1.0 mm. Furthermore, the length L5 may also be a length sufficient for end face machining and minimize the machining time.

[0118] As described above, according to the configuration of Modification 4, when the material shape BS does not have enough machining allowance for end face machining, it is possible to automatically add machining allowance to the machining area MA, thereby enabling the machined product to be finished with higher precision and quality.

[0119] (Method of dividing machining area when machining allowance increases stepwise) An example of a specific method of generating machining primitives MP by the machining area dividing unit 62 will be described as an example of modified example 5. In the description of modified example 5, only the differences from the above-described embodiment will be described, and the same reference numerals will be used to denote the same parts as in the embodiment, and description thereof will be omitted.

[0120] In variant example 5, an example of a method for dividing the machining area MA and generating machining primitives MP when machining the target shape TS shown in Figure 4(b) from the material shape BS shown in Figure 4(a) is described.

[0121] The target shape TS is a shape whose outer diameter changes in the axial direction, and the machining allowance (machining amount) of the outer diameter turning of the machining area MA changes in the axial direction, as shown in Fig. 4(c) . In such a case, if the portions with different machining allowances are generated as one machining feature MF, a machining path is generated to match the portion with a larger diameter, which may reduce machining efficiency.

[0122] Therefore, the machining area dividing unit 62 according to the fifth modification is configured to divide the machining primitives MP at the boundaries of the faces where the machining allowance changes when the machining allowance in external diameter turning changes stepwise in the axial direction. That is, in the fifth modification, a machining primitive MP having the same shape as the machining feature MF shown in Fig. 4(e) is generated from the machining area MA shown in Fig. 4(c). By adopting such a configuration, it is possible to reliably prevent locations with different machining allowances from being recognized as the same machining feature MF, and to suppress a decrease in machining efficiency.

[0123] As described above, according to the configuration of Modification 5, when the machining area MA (target shape TS) includes a portion where the machining allowance (machining amount) of the external diameter turning increases stepwise in the axial direction, the machining area MA is divided at the surface where the machining allowance changes, thereby preventing a decrease in machining efficiency.

[0124] It should be noted that not all of the functions specific to each of the main modifications described above necessarily need to be provided in the machine tool, and it is preferable that they be set appropriately depending on the configuration of the machine tool and the machining conditions. Therefore, various functions may be provided as standard on the machine tool 10 so that they cannot be disabled, or may be configured so that the user can selectively switch between enabling and disabling the functions.

[0125] 10...machine tool, 50...machining program generating device, 61...machining area acquiring unit, 62...machining area dividing unit, 63...sequence determining unit, 101...first spindle (spindle), 300...tool rest (tool holding unit), 301...cutting tool

Claims

1. A machining program generation device that generates machining processes and machining programs for a machine tool that includes a spindle to which a workpiece is attached, a rotation mechanism that rotates the spindle, a workpiece feed mechanism that moves the workpiece in a feed direction relative to the spindle, a tool holding unit that holds a cutting tool that cuts the workpiece, and a movement mechanism that moves the cutting tool in a direction intersecting the feed direction of the spindle, the machining program generation device comprising: a machining area acquisition unit that acquires the difference between the material shape of the workpiece and a target shape as a machining area to be machined by the cutting tool; a machining area division unit that divides the machining area into a plurality of elements; and an order determination unit that determines the machining order of the plurality of elements, wherein the order determination unit determines the machining order for elements that are machined while the workpiece is attached to the spindle, such that elements whose tip positions in the feed direction are farthest from the spindle are machined in order.

2. The machining program generation device of claim 1, characterized in that, when there are elements with the same tip position in the feed direction, the order determination unit determines the machining order so that these elements are machined in order starting from the element whose rear end position on the opposite side of the tip in the feed direction is farthest from the main spindle.

3. The machining program generation device according to claim 1, characterized in that the machine tool is provided with a second spindle, which is arranged to face the first spindle when the spindle is a first spindle and to which the workpiece to be cut is attached, and further provided with a distribution unit that distributes the plurality of elements into first elements that are machined with the workpiece to be cut attached to the first spindle and second elements that are machined with the workpiece to be cut attached to the second spindle.

4. The machining program generation device according to claim 3, characterized in that the order determination unit determines the machining order so that the second element is machined after the first element, and that the second elements are machined in order starting from the element whose tip position in the direction opposite to the feed direction is farthest from the second spindle.

5. A machining program generation device as described in claim 3, characterized in that it is provided with a calculation unit that calculates the time difference between the total machining time of the first element and the total machining time of the second element, and the allocation unit allocates the multiple elements to the first element and the second element so as to minimize the time difference.

6. The machining program generation device of claim 1, characterized in that when a through hole is formed in the target shape that penetrates in a direction that intersects the feed direction, the machining area division unit divides the machining area corresponding to the through hole into two at the center of the through hole's penetration direction.

7. The machining program generation device of claim 1, characterized in that when a through hole is formed in the target shape that penetrates in a direction parallel to the feed direction and whose hole diameter changes at a boundary surface perpendicular to the feed direction, the machining area division unit divides the machining area corresponding to the through hole into two at the boundary surface.

8. The machining program generation device according to claim 1, further comprising: a coordinate transformation unit that generates first data obtained by coordinate-transforming the three-dimensional model of the target shape so that the central axis of the three-dimensional model coincides with the central axis of the main spindle, and second data obtained by inverting the first data in the axial direction; and a calculation unit that calculates a first total machining time for the first data and a second total machining time for the second data, wherein the machining area acquisition unit acquires either the first data or the second data as the machining area based on the first total machining time and the second total machining time.

9. The machining program generation device according to claim 1, characterized in that the machine tool further comprises: a second spindle, when the spindle is a first spindle, arranged to face the first spindle and to which the workpiece to be cut is attached; and a support structure arranged in front of the first spindle and supporting the workpiece together with the first spindle; and the sequence determination unit, when the workpiece to be cut is supported by the first spindle, sets the drilling process before the external turning process, and when the workpiece to be cut is supported by the second spindle, sets the drilling process after the external turning process.

10. The machining program generation device of claim 1, characterized in that if the length in the feed direction of an element among the plurality of elements that is machined by external diameter turning exceeds a predetermined length, the machining area division unit divides the element in the feed direction to generate a plurality of elements.

11. The machining program generation device described in claim 1, characterized in that the machining area acquisition unit adds a machining allowance for end face machining to the machining area when the distance from the end face of the material shape to the end face of the target shape is less than a predetermined distance.

12. The machining program generation device according to claim 1, characterized in that, when the machining area includes a shape in which the machining allowance of external diameter turning increases stepwise in a direction parallel to the feed direction, the machining area is divided at a surface where the machining allowance changes.

13. A machining program generation method for generating machining steps and machining programs for a machine tool equipped with a spindle to which a workpiece is attached, a rotation mechanism for rotating the spindle, a workpiece feed mechanism for moving the workpiece in a feed direction relative to the spindle, a tool holding unit for holding a cutting tool that cuts the workpiece, and a movement mechanism for moving the cutting tool in a direction intersecting the feed direction of the spindle, the method comprising: a machining area acquisition step for acquiring a machining area to be machined by the cutting tool, which is the difference between the material shape of the workpiece and a target shape; a machining area division step for dividing the machining area into a plurality of elements; and an order determination step for determining the order in which the plurality of elements are to be machined, wherein in the order determination step, the machining order is determined so that, for elements to be machined while the workpiece is attached to the spindle, elements whose tip positions in the feed direction are farthest from the spindle are machined in order.

14. The machining program generation method according to claim 13, characterized in that the machine tool is configured to be able to face the first spindle when the spindle is a first spindle, and is equipped with a second spindle to which the workpiece to be cut is attached, the machining program generation method further includes an allocation step of allocating the plurality of elements into first elements to be machined with the workpiece to be cut attached to the first spindle and second elements to be machined with the workpiece to be cut attached to the second spindle, and in the allocation step, the plurality of elements are allocated to the first elements and the second elements so as to minimize the time difference between the total machining time of the first elements and the total machining time of the second elements.

Citation Information

Patent Citations

  • Numerical controller

    JP1990012403A

  • Automatic deciding method for working area and recognition method for recessed part in machining NC data

    JP1990216504A

  • Numerical control information preparation device

    JP1992256547A

  • Numerical control information composer

    JP1993169350A

  • Intermediate body shape data generating device, tool locus generating device, and data generating system for producing final body

    JP2004272837A