Abstract:
A controller for controlling a wire electric discharge machine is configured to monitor the remaining lifetime of a wire electrode and calculates an electric discharge machining time, thereby determining the timing of replacement of the wire electrode, so that it can recognize the timing of interruption of electric discharge machining. Consequently, a program operation can be suspended and the wire electrode can be cut and automatically replaced at that timing. After the replacement of the wire electrode, moreover, the wire electrode can be connected and the program operation can be restarted.

Description:
BACKGROUND OF THE INVENTION 
       [0001]    1. Field of the Invention 
         [0002]    The present invention relates to a wire electric discharge machine controller having a wire electrode replacement function. 
         [0003]    2. Description of the Related Art 
         [0004]    In incorporating a wire electric discharge machine into a mass-production machining line of a manufacturing plant, a prolonged continuous operation is required to improve the productivity. In this case, a wire electric discharge system is employed comprising workpiece replacement means for automatically replacing workpieces. If various consumable parts of the wire electric discharge machine having reached their life limit require replacement, however, the continuous operation must be temporarily stopped and restarted after the consumable parts are manually replaced. This retards the prolonged, continuous automatic operation, thus hindering an improvement in the productivity. 
         [0005]    Conventional techniques have been devised to detect the expiration of the life of a wire electrode of a wire electric discharge machine and the remaining lifetime of the wire electrode. According to these techniques, however, an indication to the effect that the replacement timing for the wire electrode is reached is displayed on a display device to urge an operator to replace the wire electrode. 
         [0006]    Japanese Patent Application Laid-Open No. 2010-179377 discloses a technique for a wire electric discharge machine in which the remaining amount of a wire is detected based on a detected value of the wire tension. According to this technique, a machining program is analyzed to obtain a necessary wire length for workpiece machining before the machining, the necessity of wire bobbin replacement is determined by comparing the obtained wire length and the detected remaining amount of the wire, and the result of the determination is displayed on a display device. 
         [0007]    Japanese Patent Application Laid-Open No. 2003-25155 discloses a wire electric discharge machine configured to calculate the remaining amount of a wire, calculate the consumption of the wire for each machining condition unit by analyzing a machining program, and report the points of wire cutting and wire electrode replacement by comparing the remaining amount and the consumption. 
         [0008]    Japanese Patent Application Laid-Open No. 9-216129 discloses an electric discharge machine furnished with a workpiece handling robot for taking out a workpiece and a core, in which the workpiece handling robot is disposed outside a machining tank. 
         [0009]    Japanese Patent Application Laid-Open No. 8-118151 discloses a wire electric discharge machine configured to automatically replace a head comprising a power feeder (electrode pin) and a wire guide. In this machine, the durable time of the power feeder is previously registered so that the head can be replaced with machining temporarily stopped when the durable time is exceeded by the operating time of the machine. 
         [0010]    Japanese Patent Application Laid-Open No. 7-266137 discloses a wire electric discharge machine comprising a workpiece changer that is provided with drying means and rustproof means for machined workpieces. 
       SUMMARY OF THE INVENTION 
       [0011]    An automatic operation in wire electric discharge machining is hindered by the problem that if the electric discharge machining is suspended, a machined surface is inevitably streaked and hence reduced in quality at the restart of machining. This is a problem caused by a discontinuous electric discharge state due to, for example, a temporary short circuit between a wire electrode and a workpiece at the restart of the machining. Because of this problem, the wire electrode cannot be easily replaced even when the timing of its replacement is reached. As a matter of fact, therefore, an operator used to replace the wire electrode by appropriately estimating the timing when the electric discharge machining is interrupted, with reference to the display on the display device. Thus, the replacement of the wire electrode requires a manual operation, which retards the prolonged, continuous automatic operation and hinders an improvement in the productivity. 
         [0012]    In the wire electric discharge machine described in Japanese Patent Application Laid-Open No. 2010-179377, the wire length is obtained by analyzing the machining program to determine the necessity of the wire bobbin replacement. Since the wire bobbin is supposed to be replaced by an operator, the necessity of the wire bobbin replacement is determined before the machining. If the wire bobbin is replaced at this timing, the wire electric discharge machining that often takes 10 hours or more suffers a substantial wire disposal loss and lacks in efficiency. Due to the operator&#39;s replacement, moreover, this system is not suitable for the prolonged, continuous automatic operation and has no effect to improve the productivity. 
         [0013]    In the wire electric discharge machine described in Japanese Patent Application Laid-Open No. 2003-25155, the machining program is analyzed and the wire electrode replacement point is reported for each machining condition unit. In contrast, in the present invention, as described later, the wire electrode replacement timing is determined for each electric discharge interval, so that the technique of the invention is different from that described in this patent document. Since the technique of this patent document is based on the assumption that the wire is replaced by an operator, moreover, it is neither designed to replace the wire electrode nor to restart a program operation after the replacement. Since this system is not suitable for the prolonged, continuous automatic operation, therefore, it has no significant effect to improve the productivity. 
         [0014]    Although the electric discharge machine described in Japanese Patent Application Laid-Open No. 9-216129 comprises means for replacing a workpiece, it is not configured to replace a wire electrode. 
         [0015]    The wire electric discharge machine described in Japanese Patent Application Laid-Open No. 8-118151, unlike that of the present invention described later, is configured to determine the head replacement timing from its operating time and the previously registered durable time of the power feeder. Specifically, a problem occurs that if the head is replaced, the electric discharge machining is temporarily stopped in the middle, so that the machined surface is streaked and reduced in quality at the restart of the machining. Since the wire electric discharge machine of the present invention described later is configured so that the electric discharge machining cannot be stopped in the middle, it can solve the problem that the machined surface is streaked and reduced in quality at the restart of the machining. 
         [0016]    Although the wire electric discharge machine described in Japanese Patent Application Laid-Open No. 7-266137 comprises the drying means, rustproof means, and replacement means for workpieces, it is not configured to replace a wire electrode. 
         [0017]    Accordingly, the object of the present invention is to provide a wire electric discharge machine controller having a wire electrode replacement function such that a wire electrode can be replaced without stopping a continuous operation and without requiring a manual operation when the timing of replacement of the wire electrode is reached, based on attention to the wire electrode among the other consumable parts of a wire electric discharge machine. 
         [0018]    In order to achieve the above object, a wire electric discharge machine controller according to the present invention comprises a wire remaining lifetime monitoring unit, electric discharge machining time calculation unit, and wire electrode replacement timing determination unit, whereby the timing of interruption of electric discharge machining can be recognized. Thus, the controller can order suspension of a program operation, cutting of the wire electrode, and automatic replacement of the wire electrode by wire electrode replacement unit at that timing. After the replacement of the wire electrode, moreover, connection of the wire electrode and restart of the program operation can be ordered. 
         [0019]    The electric discharge machine controller according to the present invention is configured to create a machining path based on an axis movement command from a machining program and perform a program operation according to the machining program to move a wire electrode and a workpiece relative to each other along the created machining path, and comprises a program operation control unit configured to execute the machining program, a wire remaining lifetime monitoring unit configured to monitor the remaining lifetime of the wire electrode, an electric discharge machining time calculation unit configured to analyze the machining program and calculate, before the start of electric discharge, an electric discharge machining time in a machining interval before the electric discharge is stopped, a wire electrode replacement timing determination unit configured to compare the remaining lifetime and the electric discharge machining time and determine that the timing of replacement of the wire electrode is reached if the remaining lifetime of the wire electrode is shorter than the electric discharge machining time, a program operation stop command unit configured to output a stop command for the program operation to the program operation control unit when the replacement timing for the wire electrode is reached, a wire cutting control unit configured to output a cutting command for the wire electrode to a wire cutting unit and monitor the completion of cutting of the wire electrode, a wire electrode replacement control unit configured to output a replacement command for the wire electrode to a wire electrode replacement unit and monitor the completion of replacement of the wire electrode, a wire connection control unit configured to output a connection command for the wire electrode to a wire connection unit and monitor the completion of connection of the wire electrode when the replacement of the wire electrode is completed, and a program operation restart command unit configured to output a restart command for the program operation to the program operation control unit when the connection of the wire electrode is completed. 
         [0020]    The wire electrode replacement timing determination unit may calculate the ratio between the remaining lifetime and the electric discharge machining time and determine that the timing of replacement of the wire electrode is reached if the calculated ratio is smaller than a predetermined value. 
         [0021]    The wire electrode replacement timing determination unit may calculate the difference between the remaining lifetime and the electric discharge machining time and determine that the timing of replacement of the wire electrode is reached if the calculated difference is smaller than a predetermined value. 
         [0022]    The wire electrode replacement unit may be a robot. 
         [0023]    According to the present invention, there can be provided a wire electric discharge machine controller having a wire electrode replacement function such that automatic wire replacement by wire electrode replacement unit can be achieved without the fear of degrading the machined surface quality, no operator is required for the wire electrode replacement, and a program operation can be restarted after the wire electrode replacement, so that a dramatic improvement can be expected of the productivity of wire electric discharge machining. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0024]    The above and other objects and features of the present invention will be obvious from the ensuing description of embodiments with reference to the accompanying drawings, in which: 
           [0025]      FIG. 1  is a block diagram showing one embodiment of a wire electric discharge machine controller having a wire electrode replacement function according to the present invention; 
           [0026]      FIG. 2  is a diagram showing workpiece machining based on machining programs shown in  FIG. 3 ; 
           [0027]      FIG. 3  is a diagram showing examples of the machining programs such that machining is repeated three times; 
           [0028]      FIG. 4  is a diagram showing workpiece machining based on machining programs shown in  FIG. 5 ; 
           [0029]      FIG. 5  is a diagram showing alternative examples of the machining programs such that machining is repeated three times; and 
           [0030]      FIG. 6  is a flowchart showing control of the wire electric discharge machine controller of  FIG. 1 . 
       
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS 
       [0031]    One embodiment of a wire electric discharge machine controller having a wire electrode replacement function according to the present invention will be described with reference to  FIG. 1 . 
         [0032]    A wire electric discharge machine controller  10  creates a machining path based on an axis movement command from a machining program and operates a wire electric discharge machine according to the machining program to move a wire electrode and a workpiece relative to each other along the created machining path, thereby machining the workpiece. 
         [0033]    The wire electric discharge machine controller  10  comprises a program operation control unit  16 , wire remaining lifetime monitoring unit  11 , electric discharge machining time calculation unit  12 , wire electrode replacement timing determination unit  13 , program operation stop command unit  14 , wire cutting control unit  17 , wire electrode replacement control unit  18 , wire connection control unit  19 , and program operation restart command unit  15 . The program operation control unit  16  executes the machining program. The wire remaining lifetime monitoring unit  11  monitors the remaining lifetime of the wire electrode. The electric discharge machining time calculation unit  12  analyzes the machining program and calculates, before the start of electric discharge, an electric discharge machining time in a machining interval before the electric discharge is stopped. The wire electrode replacement timing determination unit  13  determines that the timing of replacement of the wire electrode is reached if the remaining lifetime of the wire electrode is found by comparison to be shorter than the electric discharge machining time. The program operation stop command unit  14  outputs a command for stopping a program operation to the program operation control unit  16  when the replacement timing is reached. The wire cutting control unit  17  outputs a command for cutting the wire electrode to a wire cutting unit  20  and monitors the completion of cutting of the wire electrode. The wire electrode replacement control unit  18  outputs a command for replacing the wire electrode to wire electrode replacement unit  21  and monitors the completion of replacement of the wire electrode. The wire connection control unit  19  outputs a command for connecting the wire electrode to a wire connection unit  22  and monitors the completion of connection of the wire electrode when the replacement of the wire electrode is completed. The program operation restart command unit  15  outputs a command for restarting the program operation to the program operation control unit  16  when the connection of the wire electrode is completed. 
         [0034]    The wire electrode replacement timing determination unit  13  has a function of calculating the ratio between the remaining lifetime of the wire electrode and the electric discharge machining time and determining that the timing of replacement of the wire electrode is reached if the calculated ratio is smaller than a predetermined value. 
         [0035]    Alternatively, the wire electrode replacement timing determination unit  13  may have a function of calculating the difference between the remaining lifetime of the wire electrode and the electric discharge machining time and determining that the timing of replacement of the wire electrode is reached if the calculated difference is smaller than a predetermined value. Further, a robot may be employed as the wire electrode replacement unit. 
         [0036]    The following is a description of elements of the wire electric discharge machine controller  10 . 
       &lt;Wire Electrode&gt; 
       [0037]    The wire electrode used in the wire electric discharge machine is a wire-like electrode that serves to generate electric discharge. A wire wound on a bobbin in the wire electric discharge machine is drawn out, electrically discharged, and collected directly into a collection box or the like for disposal. The remaining lifetime of the wire electrode can be monitored according to the operating time of the machine. Since the weight, length, and diameter of the wire wound on the bobbin are settled, the remaining lifetime of the wire electrode can be more strictly monitored based on these data and the feed rate of the wire that varies depending on each machining condition. 
       &lt;Wire Remaining Lifetime Monitoring Unit  11 &gt; 
       [0038]    The wire remaining lifetime monitoring unit  11  monitors the remaining lifetime and remaining amount of the wire electrode and outputs the remaining lifetime. The remaining lifetime of the wire electrode may be monitored in the following manner. 
         [0039]    (1) The preset lifetime of the wire electrode is compared with the operating time of the machine after replacement with a new wire electrode. 
         [0040]    (2) The consumption of the wire electrode is measured based on various set values (weight, length, diameter, feed rate, etc., of the wire) of the wire electric discharge machine, and the time for the full consumption of the wire electrode is estimated. 
         [0041]    Further, the remaining lifetime and remaining amount of the wire electrode may be monitored by using the means disclosed in Japanese Patent Application Laid-Open No. 2010-179377 or 2003-25155. 
       &lt;Electric Discharge Machining Time Calculation Unit  12 &gt; 
       [0042]    The electric discharge machining time calculation unit  12  analyzes the machining program, calculates, before the start of electric discharge, the electric discharge machining time in the machining interval before the electric discharge is stopped next, and outputs the electric discharge machining time. The analysis of the machining program and the calculation of the electric discharge machining time are performed in the following manner. 
       Example 1 
       [0043]      FIG. 2  is a diagram showing workpiece machining based on machining programs shown in  FIG. 3 .  FIG. 3  is a diagram showing examples of the machining programs such that machining is repeated three times. 
         [0044]    The wire electrode is moved relative to the workpiece along a machining path  31  from a machining start point  30  as the machining is performed. When the wire electrode returns to the machining start point  30 , the wire is cut, and the workpiece and a wire guide supporting the wire electrode are relatively moved by rapid traverse  32  and positioned at the next machining point. Thereupon, the machining is started. 
         [0045]    In the case where the machining is repeated three times, as shown in  FIGS. 2 and 3 , electric discharge machining is performed in an interval for cutting feed in which G 01  is commanded in the machining program. problem occurs that the machined surface quality is degraded if electric discharge is suspended in this interval. Therefore, the machining time in this interval is calculated before G 01  is commanded. 
         [0046]    Specifically, the length of this interval can be obtained from a movement command by G 01 , and the machining time in this interval can be calculated based on a set machining speed included in machining conditions ordered by an S-code command and the interval length. It is necessary, therefore, only that this processing be repeated every time this interval is called. 
         [0047]    In this example, moreover, the G 01  command is monitored as the machining time is calculated. Alternatively, however, a dedicated M code may be provided such that machining times in subsequent electric discharge machining intervals can be calculated. 
         [0048]    In the case of such machining, an operator conventionally replaces the wire electrode with the program operation suspended after the end of the electric discharge machining interval by using an optional stop command of M 01  while monitoring the remaining lifetime of the wire electrode. 
       Example 2 
       [0049]    In another example, machining based on machining programs set up in the manner shown in  FIGS. 4 and 5  is repeated three times. 
         [0050]    Although the machining shape is the same as that in Example 1, the machining programs may be set up in this manner depending on the machining content. The wire electrode is moved relative to the workpiece along the machining path  31  from the machining start point  30  as the machining is performed. When the wire electrode returns to the machining start point  30 , the wire is cut, and the workpiece and the wire guide supporting the wire electrode are relatively moved by the rapid traverse  32  and positioned at the next machining point. Thereupon, the machining is started. When the machining of the last region is finished, the wire electrode returns to the first machining start point  30  by rapid traverse  33 . 
         [0051]    Also in this case, electric discharge machining is performed in the interval for cutting feed in 1  which G 01  is commanded in the machining program. The problem occurs that the machined surface quality is degraded if electric discharge is suspended in this interval. Therefore, the machining time in this interval is calculated before G 01  is commanded. 
         [0052]    Specifically, the length of this interval can be obtained from the movement command by G 01 , and the machining time in this interval can be calculated based on the set machining speed included in the machining conditions ordered by the S-code command and the interval length. It is necessary, therefore, only that this processing be repeated every time this interval is called. In this example, moreover, the G 01  command is monitored as the machining time is calculated. As in the case of Example 1, however, the dedicated M code may be provided such that the machining times in the subsequent electric discharge machining intervals can be calculated. 
         [0053]    Also in the case of such machining, the operator conventionally replaces the wire electrode with the program operation suspended after the end of the electric discharge machining interval by using the optional stop command of M 01  while monitoring the remaining lifetime of the wire electrode. 
       &lt;Wire Electrode Replacement Timing Determination Unit  13 &gt; 
       [0054]    The wire electrode replacement timing determination unit  13  compares the remaining lifetime of the wire electrode received from the wire remaining lifetime monitoring unit  11  and the electric discharge machining time received from the electric discharge machining time calculation unit  12  to determine the timing of replacement of the wire electrode and outputs the result of the determination. Specifically, it may be determined that the timing of replacement of the wire electrode is reached if (remaining lifetime)/(electric discharge machining time)&lt;a (a is a constant) is given, or that the timing of replacement of the wire electrode is not reached if (remaining lifetime)/(electric discharge machining time)&gt;a is given. Although a is normally 1, it may be a predetermined value obtained by multiplication by a safety factor. 
         [0055]    Alternatively, it may be determined that the replacement timing for the wire electrode is reached if (remaining lifetime)&lt;(electric discharge machining time) is given, or that the replacement timing for the wire electrode is not reached if (remaining lifetime)&gt;(electric discharge machining time) is given. Alternatively, moreover, it may be determined that the replacement timing for the wire electrode is reached if (remaining lifetime)−(electric discharge machining time)&lt;b (b is a constant) is given, or that the replacement timing for the wire electrode is not reached if (remaining lifetime)−(electric discharge machining time)&gt;b. Although b is normally 0, it may be set to a value other than 0 in anticipation of safety. 
       &lt;Program Operation Stop Command Unit  14 &gt; 
       [0056]    The program operation stop command unit  14  outputs a program operation stop command to the program operation control unit  16  if the determination result received from the wire electrode replacement timing determination unit  13  indicates that the replacement timing is reached. 
       &lt;Program Operation Restart Command Unit  15 &gt; 
       [0057]    The program operation restart command unit  15  outputs a program operation restart command to the program operation control unit  16  after the connection of the wire electrode is completed. 
       &lt;Program Operation Control Unit  16 &gt; 
       [0058]    The program operation control unit  16  executes the machining program to control the program operation. On receiving the program operation stop command from the program operation stop command unit  14 , the program operation control unit  16  stops the program operation. On receiving the program operation restart command, it restarts the program operation. 
       &lt;Wire Cutting Control Unit  17 &gt; 
       [0059]    If the determination result received from the wire electrode replacement timing determination unit  13  indicates that the replacement timing is reached, the wire cutting control unit  17  outputs a wire electrode cutting command to the wire cutting unit  20  and confirms the completion of cutting of the wire electrode. The cutting command may alternatively be output after the stop of the program operation is confirmed. 
       &lt;Wire Electrode Replacement Control Unit  18 &gt; 
       [0060]    If the determination result received from the wire electrode replacement timing determination unit  13  indicates that the replacement timing for the wire electrode is reached, the wire electrode replacement control unit  18  outputs a wire electrode replacement command to the wire electrode replacement unit  21  and confirms the completion of replacement of the wire electrode. The replacement command may alternatively be output after the cutting of the program operation is confirmed. 
       &lt;Wire Connection Control Unit  19 &gt; 
       [0061]    The wire connection control unit  19  outputs the wire electrode connection command to the wire connection unit  22  and confirms the completion of connection of the wire electrode after the replacement of the wire electrode is completed. 
       &lt;Wire Cutting Unit  20 &gt; 
       [0062]    The wire cutting unit  20  cuts the wire electrode on receiving the wire electrode cutting command from the wire cutting control unit  17 . 
       &lt;Wire Electrode Replacement Unit  21 &gt; 
       [0063]    The wire electrode replacement unit  21  replaces the wire electrode on receiving the wire electrode replacement command from the wire electrode replacement control unit  18 . An industrial robot may be used as the wire electrode replacement unit  21 . 
       &lt;Wire Connection Unit  22 &gt; 
       [0064]    The wire connection unit  22  connects the wire electrode on receiving the wire electrode connection command from the wire connection control unit  19 . 
         [0065]      FIG. 6  is a flowchart showing control of the wire electric discharge machine controller of  FIG. 1 . The following is a sequential description of various steps of operation. 
         [0066]    [Step sa 01 ] Monitoring of the remaining lifetime of the wire electrode is started. 
         [0067]    [Step sa 02 ] The machining program is analyzed and executed. 
         [0068]    [Step sa 03 ] It is determined whether or not a block in the machining program is a start block for electric discharge machining. If the block is the start block for electric discharge machining (YES), the processing proceeds to Step sa 04 . If not (NO), the processing proceeds to Step sa 14 . 
         [0069]    [Step sa 04 ] The electric discharge machining time is calculated. 
         [0070]    [Step sa 05 ] It is determined whether or not the wire electrode replacement timing is reached. If it is determined that the replacement timing is reached (YES), the processing proceeds to Step sa 06 . If not (NO), the processing proceeds to Step sa 14 . 
         [0071]    [Step sa 06 ] The program operation is paused. 
         [0072]    [Step sa 07 ] The wire cutting command is output. 
         [0073]    [Step sa 08 ] It is determined whether or not the wire electrode cutting is completed. If the cutting is completed (YES), the processing proceeds to Step sa 09 . If not (NO), the processing proceeds to Step sa 09  after completion of the wire electrode cutting is awaited. 
         [0074]    [Step sa 09 ] The wire electrode replacement command is output. 
         [0075]    [Step sa 10 ] It is determined whether or not the wire electrode replacement is completed. If the replacement is completed (YES), the processing proceeds to Step sa 11 . If not (NO), the processing proceeds to Step sa 11  after completion of the wire electrode replacement is awaited. 
         [0076]    [Step sa 11 ] The wire electrode connection command is output. 
         [0077]    [Step sa 12 ] It is determined whether or not the wire electrode connection is completed. If the connection is completed (YES), the processing proceeds to Step sa 13 . If not (NO), the processing proceeds to Step sa 13  after completion of the wire electrode connection is awaited. 
         [0078]    [Step sa 13 ] The program operation is restarted. 
         [0079]    [Step sa 14 ] It is determined whether or not the machining program is terminated. If the machining program is terminated (YES), this control processing ends. If not (NO), the processing returns to Step sa 01 , whereupon the control processing is continued.