Machining program generation device and machining program generation method
The machining program generation device optimizes machining order and allocation between spindles in automatic lathes, addressing inefficiencies in existing technologies and reducing preparation time.
Patent Information
- Application Number
- JP2025016781
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-08-16
- Filing Date
- 2025-02-04
- Publication Date
- 2026-02-27
AI Technical Summary
Existing technologies for generating machining programs are not suitable for automatic lathes, leading to reduced efficiency in reducing preparation time for machining processes.
A machining program generation device that includes a machining area acquisition unit, a machining area division unit, and an order determination unit to determine the machining order for elements based on their position relative to the spindle, allowing for efficient allocation of machining processes between multiple spindles in an automatic lathe.
Reduces preparation time for machining by generating machining programs that optimize the machining order and allocation of processes between spindles, improving efficiency and stability regardless of operator skill level.
Smart Images

Figure 2026034352000001_ABST
Abstract
Description
[Technical Field]
[0001] The present invention relates to a machining program generating device and a machining program generating method. [Background technology]
[0002] In machining using machine tools, machining can be performed by operating the machine tools according to 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. [Prior art documents] [Patent documents]
[0005] [Patent Document 1] Japanese Patent Application Publication No. 2018-136928 Summary of the Invention [Problem to be solved by the invention]
[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. [Means for solving the problem]
[0008] (Aspect 1) In order to solve the above-mentioned problems, a machining program generation device according to a first aspect 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 machining program generation device includes: a machining area acquisition unit that acquires a difference between a 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 a machining order for the plurality of elements, and the order determination unit determines an order for machining the plurality of elements by determining an order for machining the plurality of elements, and ... The processing order is determined so that the processing is performed in the order of the most important items.
[0009] (Aspect 2) In the above-mentioned aspect 1, when there are elements having the same position of the tip end in the feed direction, the order determination unit may determine the machining order so that these elements are machined in order of the rear end position opposite the tip end in the feed direction that is farthest from the spindle.
[0010] (Aspect 3) In the above-mentioned aspect 1, when the spindle is a first spindle, the machine tool may include a second spindle arranged to face the first spindle and to which the workpiece to be cut is attached, and may further include an allocation unit that allocates 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 above-mentioned aspect 3, the order determination unit may determine the machining order so that the second element is machined after the first element, and 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.
[0012] (Aspect 5) In the above-mentioned aspect 3, a calculation unit may be provided that calculates the time difference between the total processing time of the first element and the total processing time of the second element, and the allocation unit may allocate the multiple elements to the first element and the second element so as to minimize the time difference.
[0013] (Aspect 6) In the above-mentioned 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-mentioned 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 dividing unit may divide the machining area corresponding to the through hole into two at the boundary surface.
[0015] (Aspect 8) In the above-mentioned first aspect, the machining apparatus 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 the central axis of the three-dimensional model coincides with the 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-mentioned aspect 1, when the spindle is a first spindle, the machine tool further includes a second 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 may set the drilling process before the external turning process when the workpiece to be cut is supported by the first spindle, and 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-mentioned 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 dividing unit may divide the element in the feed direction to generate a plurality of elements.
[0018] (Aspect 11) In the above-mentioned first aspect, the machining area acquisition unit may add a machining allowance for machining the end face 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-mentioned 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 equipped with a spindle to which a workpiece to be cut is attached, a rotation mechanism for rotating the spindle, a workpiece feed mechanism for moving the workpiece to be cut 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 including: a machining area acquisition process 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 process for dividing the machining area into a plurality of elements; and an order determination process for determining the machining order of the plurality of elements, wherein in the order determination process, the machining order is determined so that, among the plurality of elements, 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 the above-mentioned aspect 13, the machine tool is provided with a second spindle configured to be able to face the first spindle when the spindle is a first spindle, and on 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. [Effects of the Invention]
[0022] According to the present invention, the preparation time for machining can be reduced. [Brief explanation of the drawings]
[0023] [Figure 1] FIG. 1 is a schematic configuration diagram of a machine tool. [Figure 2] FIG. 2 is a block diagram showing an example of a configuration of a machining program generating device. [Figure 3] FIG. 2 is an explanatory diagram of functional parts of the machining program generating device. [Figure 4] FIG. 10 is an explanatory diagram of a method for obtaining a processing feature. [Figure 5] 1 is a flowchart of a machining program generation method. [Figure 6] FIG. 10 is an explanatory diagram of a machining program generation method. [Figure 7] 10A and 10B are explanatory diagrams of a method for generating a machining primitive for a through hole. [Figure 8] FIG. 2 is a diagram showing an example of a material shape and a target shape. [Figure 9] FIG. 10 is a diagram showing a processing step of the first element. [Figure 10] FIG. 10 is a diagram showing a processing step of a second element. [Figure 11] 10 shows an example of a target shape with chamfers formed. [Figure 12] FIG. 10 is an explanatory diagram of a functional unit of a machining program generating device according to a first modified example. [Figure 13] 10 is a flowchart of coordinate conversion according to Modification 1. [Figure 14] 10 is an explanatory diagram of a processed feature according to Modification 2. FIG. [Figure 15] 10 is an explanatory diagram of a method for adding a machining allowance for end face machining according to Modification 4. FIG. DETAILED DESCRIPTION OF THE INVENTION
[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, we will explain an automatic lathe device that has two spindles and can simultaneously machine workpieces held by each spindle, as well as a machining process suitable for this automatic lathe device, and a machining program generation device and generation method.
[0026] (machine tools) 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] 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 first spindle 101 to second spindle 102 is referred to as the +Z direction, and the direction from second spindle 102 to first spindle 101 is referred to as the -Z direction.
[0028] 1(a) and (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 fitted 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 movement in the axial direction is restricted). The workpiece holding hole is open axially toward the second spindle 102, and the portion of the workpiece W exposed through the opening is the portion that is machined by a cutting tool 301 supported by the 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 force applied from a fluid cylinder (not shown) driven by hydraulic pressure, air, or the like, which 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) that intersects the feed direction of the first spindle 101 (material supply unit 200). The tool rest 300 is provided so as to be 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] Based on the machining steps and machining program generated by an external machining program generation device 50, the machine tool 10 controls each unit, such as the first spindle 101, the second spindle 102, the tool rest 300, and the material supply unit 200, to perform cutting machining in accordance with the machining program. The machine tool 10 is also provided with an output unit, such as an operation unit 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 may be configured to include the machining program generation device 50.
[0036] As shown in FIG. 1(a), the machine tool 10 is capable of gripping a workpiece W with each of the first spindle 101 and the second spindle 102, and simultaneously performing cutting on each of the workpieces W. In the machine tool 10, before the machining process for machining the workpiece W into a desired ideal shape, After cutting (cutting off) the workpiece W while the first half is held by the first spindle 101, the latter half of the machining process can be performed while the workpiece W is held by the second spindle 102. At this time, to improve machining efficiency, machining of the first half of the workpiece W held by the first spindle 101 and machining of the latter half of the workpiece W held by the second spindle 102 after the first half has been machined can be performed simultaneously. Furthermore, cutting of the workpiece W can be performed with one end of the workpiece W held by the first spindle 101 and the other end held by the second spindle 102, with the axis of the first spindle 101 and the axis of the second spindle 102 concentric, as shown in FIG. 1(b).
[0037] (machining program generator) The machining program generation 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, post-machining 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 generation device 50. The machining program generation device 50 is, for example, a general-purpose computer. The machining program generation 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 random access memory (RAM) or a read-only memory (ROM), and an auxiliary storage device (secondary storage device) such as a hard-disk drive (HDD), a solid-state drive (SSD), or a flash memory. The main storage device temporarily stores programs read by the processor 54 and information exchanged with other computers, and secures a working area for the processor 54. The auxiliary storage device stores programs executed by the processor 54 and information exchanged with other computers. The auxiliary storage device may also include removable media (portable recording media). Removable media are, for example, USB memory, SD cards, or disc recording media such as CD-ROMs, DVD discs, or Blu-ray discs. 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 this embodiment by executing a program. The processor 54 can realize various processes by loading a program stored in an auxiliary storage device of the storage device 52 into a 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 generation device 50 will be described using an operation example. Fig. 3 is an explanatory diagram of the functional units of the machining program generation device 50. The machining program generation device 50 includes a machining area acquisition unit 61, a machining area division unit 62, an order 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 blank shape BS to the target shape TS. FIG. 4(a) is a perspective view of the blank shape BS. In this example, the blank 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 blank shape BS is generally cylindrical. The axial length of the blank 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 a shape formed by a cylinder with a diameter D2 and a length L2, and two other cylinders with a diameter D3 and a length L3, lined up in the axial direction. 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. The target shape TS can be obtained by completely removing this machining area MA from the material shape BS.
[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 processing order (work order) for the multiple processing primitives MP divided (obtained) by the processing area division unit 62. The order determination unit 63 determines the processing order of all processing 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. 4(e) is a perspective view of a processing feature MF. In this example, each of the two processing primitives MP is recognized as a processing feature MF. One of the processing features MF is The machining feature MF is cylindrical with an outer diameter D1, an inner diameter D2, and a length L2, and has the same shape as the machining primitive MP. The other machining feature MF is cylindrical with an outer diameter D1, an inner diameter D3, and a length L3. In other words, this machining feature MF is formed by deleting the overlapping area between the cylindrical machining primitive MP with the outer diameter D1, the inner diameter D2, and the length L2 and the cylindrical machining primitive MP with the outer diameter D1, the inner diameter D2, and the length L2 from the cylindrical machining primitive MP with the outer diameter D1, the inner diameter D3, and the length L1. However, the machining features MF that can be recognized from the machining primitive MP are not limited to one pattern, and multiple patterns of machining features MF can be recognized. Furthermore, the machining area MA of FIG. 4(c) may be configured so that a machining primitive MP having the same shape as the machining feature MF of FIG. 4(e) is divided from the machining area MA of FIG.
[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 generation method) A method for generating a machining program will now be described. Fig. 5 is a flowchart of the machining program generation method performed by the machining program generation device 50.
[0055] First, a machining area acquisition step for acquiring a machining area MA is performed in step (hereinafter referred to as S) 401. In the machining area acquisition step, 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 process 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 process here is synonymous with the feature recognition process 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 machining features MF by assigning machining orders to 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 machining features MF by assigning machining orders to these 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 by way of example with reference to Figs. 6(a) to (d). Figs. 6(a) to (d) are explanatory diagrams of a machining program generation method. Fig. 6(a) shows a target shape TS. Fig. 6(b) shows a machining primitive MP obtained by dividing a machining area MA obtained from a cylindrical material shape BS and the target shape TS of Fig. 6(a). In this example, the target shape TS comprises 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. In addition, the +Z direction of the outer diameter portion TSa A chamfer TSc is formed at the tip of the outer diameter portion TSb, and a chamfer TSd is formed at the rear end in the +Z direction of the outer diameter portion TSb (the tip 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 assumed to be 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 Z coordinates, and the fourth machining primitive MPd has the smallest. Among 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 that is machined while attached to the first spindle 101, and a second element that is 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. 6(c), 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 in which the machining features MF are re-recognized. 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, the machining feature MF of the second element is first recognized as a machining primitive M P. 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 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 assigns a machining order in ascending order of the minimum Z coordinate and recognizes the machining features MF. 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] In the example shown in Figure 6(c), in the feature re-recognition process, the second processing feature MFb and fourth processing feature MFd, which are the second elements, are returned to the processing primitive MP. Then, with their Z coordinates inverted, the processing order is reassigned based on the Z coordinates. The second processing primitive MPb and the fourth processing primitive MPd have the same leading end position in the second protrusion direction Z2, and the fourth processing primitive MPd has a rear end position farther from the second spindle 102. Therefore, they are recognized as processing features MF so that the processing order is the fourth processing primitive MPd first, followed by the second processing primitive MPb.
[0068] FIG. 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, in that order. 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, in that order. 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 intuition or skills of the operator, 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 possible that the drill may not be long enough to machine the through hole. Therefore, an example of a method for generating a machining primitive 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 of the through-hole 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 of the through-hole direction and is perpendicular to the through-hole direction. The machining primitives MPf have the same length in the through-hole direction.
[0074] 7(b) 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 with the boundary surface S2 as the boundary. In other words, the machining primitive MPg is divided into a machining primitive MPh and a machining primitive MPi with the boundary surface S2 perpendicular to the penetration direction as the boundary.
[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. In addition, 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] (Processing process example) 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 lined up 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 Fig. 9 and Fig. 10. Fig. 9 is a diagram showing the machining process of the first element, i.e., the machining process in which the workpiece W is machined while attached to the first spindle 101. Fig. 10 is a diagram showing the machining process of the second element, i.e., the machining process in which the workpiece W is machined while attached to the second spindle 102. In Fig. 9 and Fig. 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 face 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 face on the side of the fourth chamfer CP4) is cut off. It is cut by cutting.
[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 that realizes each function can be flexibly changed.
[0084] (Method for determining the chamfering processing 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, 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 different 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, in order 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 holes of the same diameter are formed and each hole 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] 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 are performed after the material around the chamfer has been removed. Therefore, the processing order for other chamfering processes such as chamfer Cc may be determined so that they are performed immediately after the processing process 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 of determining the machining sequence taking into account the orientation of the target shape after coordinate transformation) The machining program generating 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 generating 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: one is to set one end in the axial direction as the tip in the first protrusion direction Z1, and the other end opposite the one end is to set the other end 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. There are various factors that cause the total machining time to differ depending on the orientation of the three-dimensional model, such as differences in the machining order of each machining feature MF and differences in 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 consideration. Below, a coordinate conversion method taking the total machining time into consideration will be described as Modification 1. In the description of Modification 1, only differences from the above-described embodiment will be described, and the same reference numerals will be used to denote parts similar to those in the embodiment, and description thereof will be omitted.
[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 a 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 element and second element 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 function as the calculation unit as in the above-mentioned embodiment.
[0093] Fig. 13 is a flowchart of coordinate conversion by the machining program generation 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 generation 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 3D 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 defined as the first total machining time, and the total machining time calculated based on the second data is defined 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, and the allocation unit 64 allocates the multiple machining features MF to first elements and second elements, and then 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 Modification 1, the total machining time is calculated based on both the first data obtained by coordinate-transforming the 3D 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] (How to determine the 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 a machining program being generated in which machining is performed with low support rigidity of the workpiece W, 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 refer to the same parts as in the embodiment, and description thereof will be omitted.
[0099] In the second modification, a guide bush (not shown) is disposed 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] Fig. 14 is an explanatory diagram of a machining feature MF according to Modification 2. A method for determining the machining order will be described using as an example a target shape TS having a cylindrical portion TSe and a hole portion TSf opening into the end face of the cylindrical portion TSe as shown in Fig. 14. The machining program generation device 50 acquires a fifth machining feature MFe corresponding to the cylindrical portion TSe and a sixth machining feature MFf corresponding to the hole portion TSf from such a target shape TS.
[0101] When 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 turning, and the sixth machining feature MFf is machined by drilling. When drilling is performed before external turning, a hole portion TSf is formed in the workpiece W, resulting in lower rigidity of the workpiece W during external turning compared to when drilling is performed after external turning. On the other hand, when machining is performed while supported by a guide bush, performing external 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 turning are performed with the same tool, it is more efficient to perform end face machining and external turning consecutively. Therefore, in Comparative Example 2, the machining order of external turning and drilling is determined so that the order of machining differs depending on whether the workpiece W is supported by a guide bush or not.
[0103] After acquiring the machining feature MF, the order determination unit 63 determines the order 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 order 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 order 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 external diameter turning and 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. Also, 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 external 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 a guide bush is used 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] (Axial direction division method for machining primitives with 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 in which the machining primitive MP is divided 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, the protrusion amount of the workpiece W from the first spindle 101 must be set to be equal to or greater than the length L2 of the machining feature MF. However, if the protrusion amount becomes too large, the risk of a decrease in machining accuracy due to the whirling of the tip of the workpiece W increases.
[0110] Therefore, in the third modification, when the axial length of the machining primitive MP to be machined by external diameter turning exceeds a predetermined length among the plurality of machining primitives MP obtained by dividing the machining area MA, the machining area dividing unit 62 divides the machining primitive MP in the axial direction and divides it into a plurality of primitives. By configuring in this way, it is possible to generate a machining program in which the first external turning is performed with the protrusion amount of the workpiece W kept to a minimum, and then the workpiece W is moved in the feed direction to perform the next external turning.
[0111] A specific example will be given of a method for dividing a machining primitive MP in the axial direction according to Modification 3. Below, an example will be explained 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 a 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, for example, three machining primitives MP with a total length of 50 mm. 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, for example. 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, and 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 the 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 adds 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 the same reference numerals will be used to denote parts similar to those in the embodiment, and description thereof will be omitted.
[0116] A method for adding a machining allowance for end face machining will be described below using as an example a case where the overall lengths of the material shape BS and target shape TS are each length L4. Fig. 15 is an explanatory diagram of a method for adding a machining allowance for end face machining according to Modification 4. In Fig. 15, the material shape BS before the addition of the machining allowance is shown in a solid line, and the target shape TS is shown in a two-dot chain line 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 machining the end faces to both ends of the material shape BS. Then, the machining area acquisition unit 61 acquires the machining allowance BSa based on the material shape BS to which the machining allowance BSa has been added and the target shape TS. By acquiring the machining area MA, a machining allowance for end face machining is assigned to the machining area MA. The predetermined distance, which is the threshold, may be a value sufficient for end face machining, such as 0.5 mm to 1.0 mm. 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, the machining allowance can be automatically provided to the machining area MA. As a result, the machined product can be finished with higher precision and quality.
[0119] (Method of dividing the machining area when the machining allowance increases stepwise) An example of a specific method for generating a processing primitive MP by the processing area dividing unit 62 will be described as an example of Modification 5. In the description of Modification 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 the 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 volume) 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 parts with different machining allowances are generated as one machining feature MF, the machining path will be generated to match the part with the larger diameter, which may reduce machining efficiency.
[0122] Therefore, the machining area dividing unit 62 according to the fifth modification is configured so that, when the machining allowance in external turning changes stepwise in the axial direction, the machining primitives MP are divided at the boundaries of the faces where the machining allowance changes. 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 configuring in this way, 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 turning increases stepwise in the axial direction, the machining area MA is divided at the surface where the machining allowance changes, which in turn makes it possible to prevent 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 according to 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. [Explanation of symbols]
[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 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, a machining area acquisition unit that acquires a difference between a material shape and a target shape of the object to be cut as a machining area to be machined by the cutting tool; a machining area dividing unit that divides the machining area into a plurality of elements; an order determination unit that determines an order of machining the plurality of elements; Equipped with The machining program generation device is characterized in that the order determination unit determines the machining order so that, among the plurality of elements, elements that are machined while the cutting object is attached to the spindle are machined in order starting from the element whose tip position in the feed direction is farthest from the spindle.
2. The machining program generation device according to claim 1, characterized in that, when there are elements having 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 spindle.
3. When the main spindle is defined as a first main spindle, the machine tool includes a second main spindle that is arranged to be opposed to the first main spindle and to which the workpiece to be cut is attached, 2. The machining program generation device according to claim 1, further comprising an allocating unit that allocates 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.
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 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 calculation unit that calculates a time difference between a total machining time of the first element and a total machining time of the second element; 4. The machining program generating device according to claim 3, wherein the allocating unit allocates the plurality of elements to the first element and the second element so as to minimize the time difference.
6. The machining program generation device according to claim 1, characterized in that, when a through hole is formed in the target shape that penetrates in a direction intersecting 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 according to 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. First data obtained by converting the coordinates of 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 shaft, and second data obtained by inverting the first data in the axial direction. a coordinate transformation unit for generating the coordinate data; a calculation unit that calculates a first total processing time of the first data and a second total processing time of the second data; Further provided with The machining program generation device according to claim 1, characterized in that 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. When the main spindle is defined as a first main spindle, the machine tool further includes: a second main spindle arranged to be able to face the first main spindle and to which the workpiece to be cut is attached; and a support structure arranged in front of the first main spindle and supporting the workpiece together with the first main spindle, 2. The machining program generation device according to claim 1, wherein the order determination unit sets the drilling process before the external turning process when the workpiece is supported by the first spindle, and sets the drilling process after the external turning process when the workpiece is supported by the second spindle.
10. The machining program generation device according to 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 according to 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 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, comprising: a machining area acquisition step of acquiring a machining area to be machined by the cutting tool, the machining area being a difference between a material shape of the object to be cut and a target shape; a machining area dividing step of dividing the machining area into a plurality of elements; an order determination step of determining an order of machining the plurality of elements; Including, a machining program generation method characterized in that, in the order determination step, the machining order is determined such that, among the plurality of elements, elements to be machined while the cutting object is attached to the spindle are machined in order starting from the element whose tip position in the feed direction is farthest from the spindle.
14. When the spindle is defined as a first spindle, the machine tool includes a second spindle configured to be opposed to the first spindle and to which the workpiece to be cut is attached, the machining program generation method further includes a sorting step of sorting the plurality of elements into first elements to be machined in a state where the workpiece is attached to the first spindle and second elements to be machined in a state where the workpiece is attached to the second spindle, In the allocating step, the plurality of elements are allocated to the first elements and the second elements so that the time difference between the total machining time of the first elements and the total machining time of the second elements is minimized.
14. The machining program generating method according to claim 13.
Citation Information
Patent Citations
Method for supporting mechanical working, system for supporting mechanical working, and program for supporting mechanical working
JP2018136928A