Abstract:
A numerical control (NC) machine tool is controlled by a machining program, which gives the machine tool instructions with respect to the machining of a locus on a workpiece, machining conditions and the like, and responds to a variety of input data which may be stored or registered in a manner that comprises a schedule run, and includes a schedule skip capability. The schedule skipping capability permits portions of the scheduled run to be skipped at the occurrence of an event, such as an alarm, but allows machining to be continued without stopping the schedule run. The scheduled run may skip to a new program, to commands for changing tools, pallets, workpieces and the like, or to conduct a measurement schedule run in association with the machining run. The memory for storing a measurement schedule corresponding to a machining schedule allows any measurement schedule to be utilized without impairing machining productivity greatly. The memory is capable of registering two or more schedule elements as one group, thereby allowing a complicated schedule, such as the repeated machining of multiple sets of workpiece machining, to be made out easily with a small-capacity memory. A clock and the memory for storing run start time corresponding to a schedule allow run start time of day and run interval time to be set for unattended operation. Schedule data may be displayed for schedule specification and editing.

Description:
BACKGROUND OF THE INVENTION 
     1. Field of the Invention 
     The present invention relates to a numerical control unit for controlling the schedule run of an NC machine tool. 
     2. Description of the Conventional Art 
     The automatic timed control of scheduled events is a goal desired in many fields. For example, as disclosed in Laid Open Japanese Patent Publication 1-96003, the scheduling control of various units of lighting areas, energizing motors and operating various systems in buildings or factories is provided. Such goal also is desired in the automatic manufacture of products comprising one or more workpieces, including manufacture by numerical control. 
     Conventionally, a NC machine tool is controlled by a machining program, which gives the machine tool instructions with respect to the machining of a locus on a workpiece, machining conditions and the like, and responds to a variety of input data which may be stored or registered. The sequence of reading registered information concerning the program run sequence, the number or run times, run start time, etc. for the machining program (hereinafter &#34;machining schedule data&#34;), the reading of registered information for a measurement program which gives a machine tool instructions in regards to measurement locus and measurement conditions and the like (hereinafter &#34;measurement schedule data&#34;), and the running of the machine tool in accordance with the machining schedule data and measurement schedule data is commonly called a &#34;schedule run&#34; of the program. 
     FIG. 16 is a hardware configuration diagram of a conventional numerical control unit for performing a schedule run process, as disclosed in Japanese Patent Publication No. 200409 of 1989. FIG. 17 shows an example of a machining program file directory screen for the conventional numerical control unit. FIG. 18 illustrates a scheduling data screen example of the conventional numerical control unit. 
     An embodiment of the conventional art may be described in accordance with the drawings. First the hardware configuration example may be described with reference to FIG. 16, illustrating the hardware configuration of the known numerical control unit. In FIG. 16, a processor (CPU) 111 is used for controlling the whole numerical control unit via a common bus 126 in a conventional system architecture. A ROM 112 storing a control program, a RAM 113 storing various types of data, and a non-volatile storage 114, such as a bubble memory, storing various types of data, parameters, etc, are all accessible by the CBU via the system bus 126. Within memory 114 is scheduling data 114a for determining the machining programs that are to be employed for scheduling runs and the sequence of program execution. 
     Also connected to the system bus is a tape reader 115, used for reading a machining program, etc. from a paper tape, a display control circuit (CRTC) 116 for converting a digital signal into a display signal, a display device 116a, such as a CRT or a liquid crystal display device, and a keyboard 117 for entering various types of data. 
     The operational elements connected to the bus include a position control circuit 118 for controlling a servo motor. Circuit 118 connects to a servo amplifier 119 for controlling servo motor velocity, of a servo motor 120. A tacho-generator 121 is used for velocity feedback, and a position detector 122, such as a pulse coder or an optical scale, receives or inputs from generator 121 and outputs a signal to control circuit 118. While these elements are required for control of each of the machine axes, only those elements used for one axis are mentioned herein. 
     An I/O circuit 123 also connects to the bus 126 for transferring a digital signal to and from an external device, and a manual pulse generator 124 is connected into the system for moving each axis digitally. 
     An interface circuit 125 connects to bus 126 for transferring a signal to and from the external device. An external storage device 130, which may be a hard disk unit, is coupled with the interface 125 via a communication line 131. The external storage device is not limited to the hard disk unit but may be a floppy disk unit or a card reader unit which transfers data to and from an IC card. 
     In this configuration, a plurality of machining programs are stored in the external storage device 130, the sequence of executing the machining programs and the number of execution times are set and stored in-the non-volatile memory 114 as scheduling data 114a, and workpieces are machined according to the scheduling data 114a to allow the job shop type production of complicated workpieces. 
     FIG. 17 provides an example of a machining program file directory screen, wherein 140 indicates a file directory screen, 141 an indication denoting the file directory screen, 142 a file number section, 143 a file name section, and 144 represents file tape lengths. By setting a cursor on the screen to the file number 0000 and pressing a &#34;SELECT&#34; key 145, the screen progresses to a scheduling data screen. 
     FIG. 18 gives an example of the scheduling data screen, wherein 150 indicates a schedule data screen, 151 an indication denoting the schedule data screen, 152 a run sequence section, and 153 a run program file section. 154 indicates a program file run count section, meaning the number of workpieces to be machined. 155 indicates a currently run program file count section, meaning the number of workpieces already machined. 
     In a preferred order for programming the machining of several work pieces, the scheduling data screen 150 is first selected and the data of the run sequence 152, the program file 153 and the run count 154 are entered to complete the scheduling data. This scheduling data is then stored into the non-volatile memory 114 as the scheduling data 114a. By later selecting and executing this scheduling data 114a, a plurality of workpieces can be machined on a predetermined number basis. Multiple pieces of such scheduling data may be created and registered in the non-volatile memory 114. 
     The conventional numerical control unit configured as described above only executes the scheduling data in sequence and cannot achieve a scheduled run meeting complicated conditions in a practical machining environment, as described in several examples given below. 
     In one example, an alarm condition such as tool wear, machine-generated heat, consumable part wear or a machining program error may occur during actual, long-time unattended machining. Without a schedule changing function at the occurrence of alarm, the conventional numerical control unit stops its operation on occurrence of the alarm. Hence, if a schedule command is given to machine 100 workpieces during an unattended operation at night, the occurrence of alarm at the 10th workpiece leaves the remaining 90 workpieces unmachined until the morning, when the operators return to their assigned stations. 
     In another example, machining accuracy tends to deteriorate as the number of workpieces machined increases. This is due to the thermal deformation of the machine, tool wear, etc. in actual long-period unmanned operation. To prevent this, it is desired to add a compensation factor to the original machining data by executing a tool measurement program every time several workpieces have been machined. Since the schedule run function of the known numerical control unit does not allow the measurement program to be registered independently of the machining program, the measurement program is registered together with the machining program. Therefore, the measurement program is called every time only one workpiece has been machined, increasing wasteful non-machining time and reducing productivity. 
     In a further example, assume that two types of parts, part A and part B, are machined by a machine tool which performs a schedule run. Also assume that two pieces of part B will be assembled to one piece of part A in a postprocess. In such a case, it is desired to machine one piece of part A and two pieces of part B as a set in order to decrease an intermediate stock between the machining process of the machine tool and the assembling postprocess. When one piece of part A and two pieces of part B cannot be mounted on one workpiece, a long list of schedule must be registered, e.g. one piece of part A and two pieces of part B, one piece of part A and two pieces of part B, . . . , in the schedule run function of the conventional numerical control unit. However, such registration is not practical because the number of schedule elements that can be registered is limited. 
     Hence, the parts are registered in blocks, e.g. 100 pieces of part A and 200 pieces of part B. This procedure produces an intermediate stock of 100 pieces of part A between the machining process of the machine tool and the assembling postprocess. Such a large intermediate stock requirement reduces the production efficiency of the whole manufacturing line. 
     In another example, when considering how to improve the productivity of a plant, which is not automatic in setup and chip removal work and requires an operator for machining, the warm-up time of a machine is non-production time. It is desired to have finished such warm-up in early morning, before the operator arrives at work. 
     In addition, for example, long-time continuous machining tends to deteriorate machining accuracy due to heat generation. To prevent this, it is desired to provide predetermined machine cooling time between schedules. However, since the schedule run function of the known numerical control unit cannot provide time-of-day information for the schedule, a desirable schedule run cannot be achieved. 
     Finally, the schedule data registration/display function known in the art is an independent function. Therefore, for example, if it is desired to correct the tool numbers of the following machining programs because tool breakage has taken place during the run of a machining program registered to the schedule, a memorandum of all the machining program numbers that follow must be made, a transition made to an edit screen from the keyboard, then the machining program numbers entered, and the machining programs corrected in the sequence written in the memorandum. Hence, a corrected machining program number error is apt to occur. 
     SUMMARY OF THE INVENTION 
     The present invention will overcome the aforementioned disadvantages in the conventional numerical control unit. 
     It is an object of the present invention to provide a numerical control unit which will not stop a schedule run if an alarm occurs during the run but will change the schedule in response to the alarm to continue the schedule run. 
     It is a further object of the present invention to provide a numerical control unit which has a schedule run function allowing a measurement program to be scheduled in addition to the scheduling of workpiece machining to ensure that the schedule run may be made for optimum measurement program execution. 
     It is a further object of the present invention to provide a numerical control unit which will allow the machining of a plurality of workpieces to be scheduled as one set. 
     It is a further object of the present invention to provide a numerical control unit which will allow time-of-day information to be included in the schedule and a run to be performed at desired time of day. 
     It is a further object of the present invention to provide a numerical control unit which will allow a direct transition to be made from a schedule data display screen to a machining program edit screen, without needing to take a memorandum. 
     The numerical control unit concerned with the first, second, third, fourth, fifth, sixth and tenth embodiments is designed to achieve the first goal and includes schedule skipping means for causing a schedule skip at the occurrence of an alarm. 
     The numerical control unit concerned with the seventh embodiment is designed to achieve the second goal and includes a memory for storing a measurement schedule. 
     The numerical control unit concerned with the eighth and ninth embodiments is designed to achieve the third goal and includes a memory allowing at least two or more schedule elements to be registered as one group. 
     The numerical control unit concerned with the eleventh and twelfth embodiments is designed to achieve the fourth goal and includes a memory for storing schedules and run start time of day corresponding to the schedule, a clock and time-of-day reading means. 
     The numerical control unit concerned with the thirteenth embodiment is designed to achieve the fifth goal and includes machining schedule specifying means, schedule display-to-edit transition means and edit-to-schedule display transition means. 
     The schedule skipping means in the first embodiment stops current machining when an alarm occurs, skips to an executable schedule, and resumes the schedule run. 
     The schedule skipping means in the second embodiment stops current machining when an alarm occurs, skips to a next machining program, and resumes the schedule run. 
     The schedule skipping means in the third embodiment stops current machining when an alarm occurs, skips to a next tool change command, and resumes the schedule run. 
     The schedule skipping means in the fourth embodiment stops current machining when an alarm occurs, skips to a next workpiece change command, and resumes the schedule run. 
     The schedule skipping means in the fifth embodiment stops current machining when an alarm occurs, skips to a next pallet change command, and resumes the schedule run. 
     Alarm type determining means in the sixth embodiment identifies an alarm type when an alarm occurs and activates the schedule skipping means associated with the identified alarm type. The schedule skipping means that is activated will stop the current machining, skip .to an executable schedule, and resume the schedule run. 
     The schedule skipping means in the tenth embodiment stops current machining when an alarm occurs, skips to a specified layer, and resumes the schedule run. 
     The memory in the seventh embodiment stores a measurement schedule corresponding to a machining schedule. In the schedule run, not only the machining schedule but the measurement schedule as well is referenced to execute a measurement cycle. 
     The memory in the eighth embodiment allows a plurality of schedule elements to be stored as one group of schedule data. In the schedule run, the schedule elements belonging to the group are executed in sequence. 
     The memory in the ninth embodiment allows at least one or more groups of schedule elements to be stored as one higher-level group of schedule data. In the schedule run, the lowest-level schedule elements belonging to the group are executed in sequence. 
     The memory in the eleventh embodiment stores a schedule and run start time of day corresponding to that schedule. The clock counts the current time of day. A time of day reading means reads the current time of day from the clock, compares it with the run start time of day, and starts a schedule run when the current time of day has passed the run start time of day. 
     The memory in the twelfth embodiment stores a schedule and run start time of day corresponding to that schedule. The run start time of day is stored as a time increment referenced from a particular time of day, for example, the preceding machining end time of day. The clock counts the current time of day. The time-of-day reading means reads the current time of day from the clock, compares it with the run start time of day, and starts a schedule run when the current time of day has passed the run start time of day. 
     The machining schedule specifying means in the thirteenth embodiment is capable of reading the name of a machining schedule block at the cursor. The schedule display-to-edit transition means calls a machining program corresponding to the name of the machining schedule block and activates the editing means. The edit-to-schedule display transition means searches for a schedule block wherein the machining program called on the edit screen has been registered and activates the machining schedule displaying means. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a hardware block diagram of a numerical control unit according to a first embodiment of the present invention. 
     FIG. 2 is a table diagram showing a single-block structure of machining schedule data and that of measurement schedule data according to an embodiment of the present invention. 
     FIG. 3 is a table diagram illustrating registration examples of the machining schedule data and the measurement schedule data according to an embodiment of the present invention, in connection with blocks. 
     FIGS. 4(a) and 4(b) show main function and single-schedule block run processing flowcharts, respectively, according to an embodiment of the present invention. 
     FIGS. 5(a), 5(b) and 5(c) show skip completion check, run start time of day wait, and machining program skip search processing flowcharts, respectively, according to an embodiment of the present invention. 
     FIGS. 6(a) and 6(b) illustrate skip condition flag set and measurement block call processing flowcharts, respectively, according to an embodiment of the present invention. 
     FIG. 7 shows a main schedule run setting display screen displayed on a CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 8 illustrates a &#34;PART AB&#34; schedule run setting display screen displayed on a CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 9 illustrates a &#34;PART B&#34; schedule run setting display screen displayed on the CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 10 shows a setting display screen, wherein &#34;PART B MEASUREMENT&#34; has been selected for the &#34;PART AB&#34; schedule run, displayed on the CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 11 shows a measurement schedule setting display screen displayed on the CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 12 illustrates an &#34;O103(DRILLING)&#34; edit screen displayed on the CRT/MDI unit according to an embodiment of the present invention. 
     FIG. 13 is a specified block change processing flowchart according to an embodiment of the present invention. 
     FIG. 14 is an open processing flowchart according to an embodiment of the present invention. 
     FIG. 15 is a close processing flowchart according to an embodiment of the present invention. 
     FIG. 16 is a hardware configuration diagram of a numerical control unit known in the art. 
     FIG. 17 provides an example of a machining program file directory screen of the known numerical control unit. 
     FIG. 18 gives an example of a scheduling data screen of the prior art numerical control unit. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENT 
     A first embodiment of the present invention will now be described in reference to the appended drawings. In FIG. 1, a CPU 1 of a microprocessor is incorporated in a numerical control unit for executing a command in accordance with a control program written in a ROM 4, reading time of day from a clock LSI 8, transferring data to and from an SRAM 2, carrying out machine control by entering signals of a CRT/MDI unit 7 and a machine operation board 9, conducting machining locus control by sending a command to a servo control unit 5, transmitting and displaying data on the CRT/MDI unit 7, generating a voice by sending a command to a voice output device 10, transmitting various data by sending data to a communication unit 11, and receiving from a communication control unit data sent through a communication line and a modem. All of these operations are conducted via a data bus 14 that connects the CPU to other units. 
     Specifically, a random access memory 2 for storing machining command programs, machining schedules, measurement schedules, run start time of day, etc, is backed up by a battery 3 so that the memory 2 allows the data to be stored while the power of the numerical control unit is off. The servo control unit 5 is operative for driving a motor 6, in accordance with a command from the CPU 1, which effects the operation of a machine. 
     The CRT/MDI unit 7 is employed in the interactive control and monitoring of the numerical control unit by an operator and comprises a display for visually providing relevant information. A voice output device 10 is used for similar purposes and generates a voice or other audible message according to commands from the CPU 1. A machine operation board is operative to generate machine operation signals, such as automatic start and reset, according to the activity of the operator. 
     The clock LSI 8 provides the current time of day and allows it to be read. 
     The communication control unit 11 is used for transmitting data from the CPU 1 to a communication line 12 and a modem 13 in accordance with a communication protocol and transferring to the CPU 1 data sent through the communication line and the modem. Specifically, the modem 13 is connected between a telephone line and the communication control unit 11 for bidirectional communication protocol conversion, allowing data to be transferred via the telephone line to a host computer (not shown) or the like. 
     FIG. 2 is a table illustrating the structure of one block 21 of machining schedule data and one block 22 of measurement schedule data in the first embodiment of the present invention. These blocks of data are stored in the SRAM 2. In the structure of the one block of machining schedule data: 
     &#34;name&#34; indicates the name of a schedule element, wherein a part name or a program number is set. In this example, a part name &#34;Part A&#34; has been set; 
     &#34;numb&#34; indicates the number of machining operations to be repeated. In this example, 2 has been set, representing that two pieces of part A will be machined in this schedule; 
     &#34;cnumb&#34; indicates the number of machining operations already repeated. In the example, it is 1, indicating that one piece of part A has already been machined; 
     &#34;time&#34; indicates time information and &#34;t type&#34; a type of time information If &#34;t type&#34; is &#34;ABS,&#34; &#34;time&#34; is the absolute time of day, and if it is &#34;INC,&#34; &#34;time&#34; is incremental time from a preceding schedule element. &#34;t type&#34; of &#34;ABS&#34; in this example indicates that this schedule is started at 18 o&#39;clock; 
     &#34;skip&#34; indicates a skip destination at the occurrence of alarm. &#34;0&#34; does not cause a skip. &#34;NEXT&#34; causes a skip to a next machining program, &#34;TOOL&#34; to a next tool change command, &#34;WORK&#34; to a next workpiece change command, &#34;PALLET&#34; to a next pallet change command, &#34;CONDITION&#34; to a skip destination specified by a condition, and &#34;CLASS&#34; to a program scheduled to be run most recently in a specified layer. &#34;NEXT&#34; has been set in this example; 
     &#34;class&#34; specifies a layer of a skip destination when the &#34;skip&#34; element is specified as &#34;CLASS&#34;. A &#34;class&#34; of 0 indicates an identical layer, 1 one layer up, and -1 one layer down. Since &#34;skip&#34; is not specified to be &#34;CLASS&#34; in the example, &#34;class&#34; is insignificant. 
     &#34;sub&#34; indicates a pointer denoting a block of schedule one layer down. &#34;sub&#34; is 0 when there is no lower layer. The example indicates that a block &#34;sdata10&#34; is in a lower layer. 
     &#34;mes&#34; indicates a pointer representing a block of measurement schedule. &#34;mes&#34; is 0 when there is no block of measurement schedule. The example shows that there is a block of measurement schedule named &#34;mdata1.&#34; 
     &#34;next&#34; indicates a pointer denoting a block of schedule to be run next. &#34;next&#34; is 0 when there is no schedule to be run next (i.e. a final block). The example indicates that a block &#34;sdata&#34; 2 will be run next. 
     The structure of one block of measurement schedule data will now be described. 
     &#34;name&#34; indicates a name of a measurement program, wherein &#34;O9000&#34; has been set in the example. 
     &#34;numb&#34; indicates how many times a parent block of the measurement schedule block will be run before the measurement program is run once. 5 has been set in this example, indicating that 09000 is executed once every time 5 pieces of part A are machined. 
     &#34;cnumb&#34; indicates a cyclic counter which counts up each time the parent block of the measurement schedule block is run and is cleared to zero every time the number set to &#34;numb&#34; is reached or exceeded. 1 has been set in the example, indicating that 1 piece of part A has been machined after the preceding measurement. 
     FIG. 3 illustrates the registered examples of machining schedule data and measurement schedule data in the first embodiment of the present invention, organized in connection with the performance of their constituent blocks. In FIG. 3, &#34;sdata1&#34; indicates a block that is run first. &#34;sdata1&#34; consists of two blocks, &#34;sdata10&#34; and &#34;sdata11,&#34; and further &#34;sdata11&#34; is made up of two blocks, &#34;sdata110&#34; and &#34;sdata111.&#34; Accordingly, &#34;sdata1&#34; is terminated after the blocks &#34;sdata 10,&#34; &#34;sdata110&#34; and &#34;sdata111&#34; are run several times. 
     &#34;mdata10&#34; is a measurement schedule block connected to &#34;sdata1&#34; and is provided with a counter which counts up every time &#34;sdata1&#34; is executed. A measurement program is run once every set number of times. &#34;sdata2&#34; indicates a machining schedule block connected to &#34;sdata1&#34; and is run after &#34;sdata1&#34; is terminated. Similarly, &#34;sdata2&#34; is connected to &#34;sdata3&#34; and linked up to final &#34;sdatan.&#34; 
     As seen in the illustrated example, there are three classes of blocks and the various blocks are shown to exist in up to three layers. The first layer block is conventionally identified as a &#34;parent&#34; block while the derivative or dependent blocks in lower layers are called &#34;child&#34; blocks. In the illustrated example, sdata1 block 21A is a parent machining block that itself would not be machined but its derivative block sdata10 21B is a child block that is machined while its derivative block sdata11 21C is a child block that is not machined, although it further derivative blocks 21D and 21E at the lowest layer are machined. 
     Operation of the first embodiment will now be described in connection with FIG. 4(a), which is a processing flowchart of a main function for schedule run control. This function is called when the schedule run is started, at step 400. 
     Step 401: First, an address (&amp;sdata1) of a first schedule block (sdata1) is assigned to a pointer local variable (point) indicating the address of the schedule block. 
     Step 402: A &#34;single-schedule block run&#34; subroutine is then called using the &#34;point&#34; as an argument. While tracing the schedule blocks one after another, this subroutine will run all schedule blocks according to the schedule. 
     Step 403: The schedule run is terminated. 
     FIG. 4(b) is a processing flowchart of the single-schedule block run and begins at step 409. To this subroutine, the parent program passes the pointer local variable (point) indicating the address of the schedule block to be run. 
     Step 410: The number of run times is first cleared to zero (cnumb=0). 
     Step 411: A &#34;skip completion check&#34; subroutine is called to check if a schedule skip is complete or not. 
     Step 412: A check is made to see if the schedule skip is being made or not. The skip is being made if a skip flag is on. Since it is not necessary to wait until the run start time of day during a skip, the processing branches to step 414. 
     Step 413: A &#34;wait until run start time of day&#34; subroutine is called and the processing waits until the current time of day passes the run start time of day. 
     Step 414: A check is made to see if there is a child block or not. There is a child block unless &#34;sub&#34; of the machining schedule block is 0 . If there is no child block, the processing branches to step 418 and performs a machining program run. If there is a child block, the processing progresses to step 415 and performs a child block run. 
     Step 415: Since the child block is to be run, a global variable (classno), used to count layers for checking a layer skip, is counted up. 
     Step 416: To run the child block, the address of the child block (point) is read from &#34;sub&#34; and set to the argument of the &#34;single-schedule block run&#34; subroutine. 
     Step 417: The &#34;single-schedule block run&#34; subroutine is called and the child block and all subsequent blocks are run according to the schedule. As described above, the &#34;single-schedule block run&#34; subroutine is a recursive function capable of calling itself, which logically allows the blocks in an infinitely deep layer to be run according to the schedule if there is no limit to the memory size. 
     Step 418: When there is no child block, the processing branches from the step 414. In this case, a program set to the &#34;name&#34; of this block is run. Hence, a &#34;beginning of machining program search&#34; subroutine is called and the beginning of the program set to the &#34;name&#34; is searched for. 
     Step 419: If a skip is being made, the processing advances to step 420 to perform a skip search. 
     Step 420: A &#34;machining program skip search&#34; subroutine is called and a search is made within the machining program found by searching for the beginning of the machining program. For example, a tool change command or a pallet change command is searched for and the skip flag is switched off. 
     Step 421: A check is made to see if the skip is being made or not. If the skip is being made, the processing branches to step 428 since it is not necessary to run. 
     Step 422: If a skip is not being made, a &#34;machining program run&#34; subroutine is called and a run is made up to the end of the machining program or until an alarm stop occurs. 
     Step 423: A check is made to see if the run has been stopped by alarm or not. If the run has been terminated without fault, the processing branches to step 427 to run a next schedule, and the current time of day is read from the clock and assigned to a global variable (timer) for storing the run end time of day. The processing then branches to step 428. 
     Step 424: When the run has been stopped by alarm, a &#34;skip condition flag set&#34; subroutine is called to set a global variable skip mode indicating a skip type and the skip flag. 
     Step 425: To resume the schedule, the alarm is reset. 
     Step 426: The current time of day is read from the clock and assigned to the global variable (timer) for storing the run end time of day. The processing then returns to the step 419, makes the machining program skip search, and resumes the run when the skip has been found. If it has not been found, the processing branches to step 428 during the skip and moves on to the next block. 
     Step 428: The number of run times (cnumb) of this schedule block is counted up. 
     Step 429: A check is made to see if the skip is being made or not. If the skip is being made, the processing branches to step 431 because measurement need not be conducted. 
     Step 430: A &#34;measurement block call&#34; subroutine is called to run the measurement block. 
     Step 431: A comparison is made between the specified number of runs to be made (numb) and the number of runs actually made (cnumb) for this schedule block to check whether the run has been made the specified number of times. If the run has not yet been performed the specified number of times, the processing branches to the step 411 to run this block again. 
     Step 432: When the run has been made the specified number of times, a check is made to see if a next block exists or not. When &#34;next&#34; is 0, there is no next block. When there is a next block, the address of the next block is read from &#34;next&#34; and assigned to the pointer local variable (point) indicating the block address (at step 433), and the processing branches to the step 410, thereby running the next block. 
     Step 434: Since the processing returns to the parent block when the next block does not exist, the global variable (classno) employed to count layers for checking the layer skip is counted down. 
     Step 435: The processing returns to the function of the parent program. 
     FIG. 5(a) is a skip completion ,check processing flowchart that begins at START step 500. 
     Step 501: Since the skip is complete if the skip is not being made, the processing branches to step 507 and returns to the parent program. 
     Step 502: If the skip mode is &#34;NEXT,&#34; reaching the beginning of the single-schedule block run should cause the next program to be run. Hence, the skip flag is switched off at step 503 to complete the skip. 
     Step 504: If the skip mode is &#34;CLASS&#34; and (step 505) &#34;classno&#34; is 0, the layer skip is complete. The skip flag is therefore switched off at step 506 to complete the skip. 
     Step 507: The processing returns to the parent program. 
     FIG. 5(b) is a &#34;wait until run start time of day&#34; processing flowchart that begins at START step 510. 
     Step 511: A check is made to see if the time of day has been set or not. If &#34;time&#34; of the schedule block is not 0, the time of day has been set. Since it is not necessary to wait until the start time of day if the time of day has not been set, the processing branches to step 517 and returns to the parent program. 
     Step 512: The &#34;time&#34; of the schedule block is assigned to a local variable (start-time) indicating the run start time of day. 
     Step 513: A check is made to see if the time of day set value is an increment or an absolute value. The set value is an increment if &#34;t-type&#34; of the schedule block is &#34;INC.&#34; If it is an increment, run end time of day is added to the &#34;start-time&#34; at step 514 to find the &#34;start-time&#34; on an absolute time of day basis. Since the &#34;start-time&#34; is already the absolute time of day if the set value is not an increment, the processing branches to step 515. 
     Step 515: The current time of day is read from the clock. 
     Step 516: The current time of day is compared with the &#34;start-time&#34; to check whether it is past the run start time of day. If the run start time of day is not yet reached, the processing branches to the step 515 and waits until the run start time of day is reached. When it is past the run start time of day, the processing advances to step 517 and returns to the parent program. 
     FIG. 5(c) is a machining program skip search processing flowchart that begins with START step 520. 
     Step 521: A check is made to see if the skip mode is &#34;TOOL&#34; or not. If it is not &#34;TOOL,&#34; the processing branches to step 525. 
     Step 522: The machining program currently being executed or having been found by searching its beginning is searched from the beginning to the end for a tool change command. 
     Step 523: If a tool change command has not been found until the end, the processing branches to step 525 without any further execution to search the next machining program for the command. 
     Step 524: Since the tool change command has been found, the skip flag is switched off to complete the skip. Accordingly, the next machining program is run, beginning with the tool change command found. 
     Step 525: A check is made to see if the skip mode is &#34;WORK&#34; or not. If it is not &#34;WORK,&#34; the processing branches to step 529. 
     Step 526: The machining program currently being executed or having been found by searching its beginning is searched from the beginning to the end for a workpiece change command. 
     Step 527: If a workpiece change command has not been found until the end, the processing branches to step 529 without any further execution to search the next machining program for the command. 
     Step 528: Since the workpiece change command has been found, the skip flag is switched off to complete the skip. Accordingly, the next machining program is run, starting with the workpiece change command found. 
     Step 529: A check is made to see if the skip mode is &#34;PALLET&#34; or not. If it is not &#34;PALLET,&#34; the processing branches to step 533. 
     Step 530: The machining program currently being executed or having been found by searching its beginning is searched from the beginning to the end for a pallet change command. 
     Step 531: If a pallet change command has not been found until the end, the processing branches to step 533 without any further execution to search the next machining program for the command. 
     Step 532: Since the pallet change command has been found, the skip flag is switched off to complete the skip. Accordingly, the next machining program is run, beginning with the pallet change command found. 
     Step 533: The processing returns to the parent program. 
     FIG. 6(a) is a skip condition flag set processing flowchart, that begins with START step 600. 
     Step 601: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;NEXT,&#34; the processing branches to step 603. 
     Step 602: If the &#34;skip&#34; is &#34;NEXT,&#34; the skip flag is switched on to set &#34;NEXT&#34; to the skip mode. 
     Step 603: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;TOOL,&#34; the processing branches to step 605. 
     Step 604: If the &#34;skip&#34; is &#34;TOOL,&#34; the skip flag is switched on to set &#34;TOOL&#34; to the skip mode. 
     Step 605: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;WORK,&#34; the processing branches to step 607. 
     Step 606: If the &#34;skip&#34; is &#34;WORK,&#34; the skip flag is switched on to set &#34;WORK&#34; to the skip mode. 
     Step 607: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;PALLET,&#34; the processing branches to step 609. 
     Step 608: If the &#34;skip&#34; is &#34;PALLET,&#34; the skip flag is switched on to set &#34;PALLET&#34; to the skip mode. 
     Step 609: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;CLASS,&#34; the processing branches to step 611. 
     Step 610: If the &#34;skip&#34; is &#34;CLASS,&#34; the skip flag is switched on to set &#34;CLASS&#34; to the skip mode. The &#34;class&#34; of the schedule block is also read and set to &#34;classno.&#34; 
     Step 611: The &#34;skip&#34; of the schedule block is checked. If the &#34;skip&#34; is not &#34;CONDITION,&#34; the processing branches to step 620. If the &#34;skip&#34; is &#34;CONDITION,&#34; the processing branches to the step 612. 
     Step 612: The alarm is checked. If the alarm is not a &#34;program error,&#34; the processing branches to step 614. 
     Step 613: Since the alarm is a &#34;program error,&#34; the processing causes a skip to the next machining program. The skip flag is switched on and &#34;NEXT&#34; is set to the skip mode. 
     Step 614: The alarm is checked. If the alarm is not a &#34;no-tool error,&#34; the processing branches to step 616. 
     Step 615: Since the alarm is a &#34;no-tool error,&#34; it is desired to abandon the machining with this tool and resume the machining with a next tool. Hence, the processing causes a skip to the next tool change command. The skip flag is switched on and &#34;TOOL&#34; is set to the skip mode. 
     Step 616: The alarm is checked. If the alarm is not a &#34;tool breakage error,&#34; the processing branches to step 618. 
     Step 617: Since the alarm is a &#34;tool breakage error,&#34; this workpiece probably was damaged when the tool was broken. Therefore, it is desired to abandon the machining of this workpiece and resume the machining for a next workpiece. Hence, the processing causes a skip to the next workpiece change command. The skip flag is switched on and &#34;WORK&#34; is set to the skip mode. 
     Step 618: The alarm is checked. If the alarm is not a &#34;pallet loading error,&#34; the processing branches to step 620. 
     Step 619: Since the alarm is a &#34;pallet loading error,&#34; it seems that the pallet cannot be loaded to the machine properly or use of this pallet may be impossible. Therefore, it is desired to abandon the machining using this pallet and resume the machining employing a next pallet. Hence, the processing causes a skip to the next pallet change command. The skip flag is switched on and &#34;PALLET&#34; is set to the skip mode. 
     Step 620: The processing returns to the parent program. 
     FIG. 6(b) is a measurement block call processing flowchart which begins with START step 630. 
     Step 631: A check is made to see if a measurement block is present or absent. The measurement block exists if &#34;mes&#34; of the schedule block is not 0. If there is no measurement block, the processing branches to step 637 and returns to the parent program. 
     Step 632: Since there is a measurement block, the number of measurement block call times is counted up. &#34;cnumb&#34; of the measurement block indicates the number of call times. 
     Step 633: A check is made to see if measurement is made or not. A comparison is made between &#34;cnumb&#34; and &#34;numb&#34; of the measurement block. The measurement is made if &#34;cnumb&#34; is equal to or greater than &#34;numb.&#34; If the measurement is not performed, the processing branches to step 637 and returns to the parent program. 
     Step 634: Since the measurement is carried out, the number of measurement block call times &#34;cnumb&#34; is cleared to zero. 
     Step 635: To run the measurement program, the beginning of the measurement program is searched for by using the measurement program name (name) set to the measurement block as an argument. 
     Step 636: The measurement program is run. 
     Step 637: The processing returns to the parent program. 
     FIG. 7 shows a schedule run setting/display screen displayed on the CRT/MDI unit 7, wherein &#34;MACHINING NAME&#34; indicates a setting/display section of names on a schedule basis. In this example, two schedules of &#34;PART AB&#34; and &#34;PART C&#34; have been registered. &#34;QTY&#34; indicates the number of schedule repetitions, and &#34;NO. MACHINED&#34; the number of run repetitions from when the run of &#34;PART AB&#34; is started finally. &#34;START TIME&#34; indicates reserved run start time of day or run interval time. &#34;SKIP TYPE&#34; indicates a type of a schedule skip caused when alarm occurs. &#34;MEASUREMENT NAME&#34; indicates the name of a measurement schedule block called for in a schedule run. 
     Concerning &#34;PART AB&#34;, 2 in the &#34;QTY&#34; section indicates that machining was scheduled to be repeated twice and 2 in the &#34;NO. MACHINED&#34; means that the machining has been repeated twice. 18:00:00 in the &#34;START TIME&#34; section tells that the machining was specified to start at 18 o&#39;clock sharp. Since there is no setting in the &#34;SKIP TYPE&#34; section, a skip was not designated at the occurrence of alarm. Because nothing has been set in &#34;MEASUREMENT NAME,&#34; no measurement is made after the run of &#34;PART AB.&#34; 
     In regards to &#34;PART C,&#34; 100 in the &#34;QTY&#34; section indicates that 100 pieces have been set for machining and 58 in &#34;NO. MACHINED&#34; shows that 58 pieces have been machined. 
     00:00:40INC in the &#34;START TIME&#34; section means that the machining is done at intervals of 40 seconds. No setting in &#34;SKIP TYPE&#34; tells that an alarm-time skip is not specified. &#34;PART C MEASUREMENT&#34; in &#34;MEASUREMENT NAME&#34; denotes that the measurement schedule block &#34;PART C MEASUREMENT&#34; is called every time the machining of &#34;PART C&#34; is over. 
     The run status of each schedule block is displayed at the left end of the screen. In this example, the run of &#34;PART AB&#34; is complete and that of &#34;PART C&#34; is being made. 
     A horizontal line under &#34;PART AB&#34; is a cursor which is moved on the screen by pressing cursor keys (such as →, ←, ↑ and ↓) to select any of the display items. &#34;PART AB&#34; has been selected in the example. By pressing a key corresponding to &#34;OPEN&#34; in this state, the details of &#34;PART AB&#34; can be displayed. 
     FIG. 8 shows a display screen of the detailed schedule of &#34;PART AB.&#34; In the example, &#34;PART AB&#34; consists of two schedule blocks, &#34;PART A&#34; and &#34;PART B.&#34; 
     Pressing a key corresponding to &#34;CLOSE&#34; on this screen returns to a higher-level schedule screen shown in FIG. 7. 
     In the example in FIG. 8, the cursor is located under &#34;PART B,&#34; indicating that &#34;PART B&#34; is being selected. By pressing the key associated with &#34;OPEN&#34; in this state, the details of &#34;PART B&#34; can be displayed. 
     FIG. 9 provides the detailed schedule of &#34;PART B.&#34; Pressing the key associated with &#34;CLOSE&#34; on this screen returns to the screen in FIG. 8. 
     According to the example in FIG. 9, the schedule block &#34;PART B&#34; comprises six blocks; &#34;O100(MILLING),&#34; &#34;O101(ROUGHING),&#34; &#34;O102(STARTING HOLE),&#34; &#34;O103(DRILLING),&#34; &#34;O104(SPOT FACING)&#34; and &#34;O105(FINISHING).&#34; 
     The &#34;SKIP TYPE&#34; for &#34;O100(MILLING)&#34; is &#34;CLASS+2&#34; which causes a skip two classes up (&#34;PART AB&#34; or &#34;PART C&#34;) when an alarm occurs. 
     The &#34;SKIP TYPE&#34; for &#34;O100(MILLING)&#34; is &#34;TOOL&#34; which causes a skip to the next tool change command at the occurrence of an alarm. 
     The &#34;SKIP TYPE&#34; for &#34;O102(STARTING HOLE)&#34; and &#34;O103(DRILLING)&#34; is &#34;CONDITION&#34; which causes a skip according to the alarm type at the occurrence of an alarm. 
     The &#34;SKIP TYPE&#34; for &#34;O104(SPOT FACING)&#34; is &#34;NEXT&#34; which causes a skip to the next program (&#34;O105(FINISHING)&#34;) at the occurrence of an alarm. 
     The &#34;SKIP TYPE&#34; for &#34;O105(FINISHING)&#34; is &#34;WORK&#34; which causes a skip to the next workpiece change command at the occurrence of an alarm. 
     Like FIG. 8, FIG. 10 gives the details of the schedule block &#34;PART AB,&#34; wherein the cursor is located under &#34;PART B MEASUREMENT&#34; indicating that &#34;PART B MEASUREMENT&#34; has been selected. By pressing the key corresponding to &#34;OPEN&#34; in this state, the details of &#34;PART B MEASUREMENT&#34; can be displayed. 
     FIG. 11 displays the details of &#34;PART B MEASUREMENT&#34; along with those of the other measurement schedule blocks. In this example, four measurement blocks, &#34;PART A MEASUREMENT,&#34; &#34;PART B MEASUREMENT,&#34; &#34;PART C MEASUREMENT&#34; and &#34;HOLE DEPTH MEASUREMENT&#34; are being displayed. &#34;PROGRAM NO.&#34; denotes a measurement program number. In the example, the program number for &#34;PART B MEASUREMENT&#34; is &#34;o9001.&#34; 
     &#34;MEASUREMENT FREQUENCY(1/SETTING)&#34; indicates how many times the measurement block is called before the measurement program is executed once. In the example, &#34;PART B MEASUREMENT&#34; is made once every time the measurement block is called 100 times. 
     &#34;CALL COUNT&#34; indicates how many times the measurement block has been called after the previous measurement was made. In the example, the measurement block has been called 28 times after &#34;PART B MEASUREMENT&#34; was made. When the measurement block is called 72 more times, measurement is made and &#34;CALL COUNT&#34; is cleared to zero. 
     A run status is indicated on the left end. In the example, &#34;PART C MEASUREMENT&#34; is being made. 
     Pressing the key corresponding to &#34;CLOSE&#34; on this screen returns to the display of the schedule block from which the selected measurement block has been called. Since &#34;PART B MEASUREMENT&#34; is selected in the example, the display returns to the screen in FIG. 10. 
     In FIG. 9, the cursor is under &#34;O103(DRILLING).&#34; By pressing the key corresponding to &#34;OPEN&#34; in this state, the details of &#34;O103(DRILLING)&#34; are displayed. Since &#34;O103(DRILLING)&#34; is the lowest-level schedule block, a program as shown in FIG. 12 is displayed. 
     FIG. 12 illustrates the details of &#34;O0103(DRILLING).&#34; Pressing a key associated with &#34;CHECK&#34; on this screen allows the plotting of an &#34;O103(DRILLING)&#34; program to be checked. Pressing a key corresponding to &#34;READ&#34; allows the machining program to be entered from an external input device. Pressing a key corresponding to &#34;PRINT&#34; allows the &#34;O103(DRILLING)&#34; program to be printed out on an external printer. Pressing a key associated with &#34;EDIT&#34; allows the &#34;O103(DRILLING)&#34; program to be edited. Pressing the key corresponding to &#34;CLOSE&#34; returns to the screen in FIG. 9. 
     Processing will now be described. 
     FIG. 13 is a flowchart of &#34;specified block change&#34; processing called when an up cursor key (↑) or a down cursor key (↓) is pressed on the schedule block display screen, beginning with START step 1300. 
     Step 1301: A check is made to see if the key pressed is the up cursor key or not. If it is the up cursor key, the processing branches to step 1304 and moves the specified block one position backward. 
     Step 1302: A check is made to see if there is a next block or not. There is a next block if the &#34;next&#34; of this schedule block is not 0. When there is no next block, the processing branches to step 1307 since there is nothing to be done. 
     Step 1303: The address &#34;next&#34; of the next block is assigned to a pointer global variable &#34;xpoint&#34; indicating the address of the specified block, thereby using the next block as the specified block. The processing then returns to the parent program at step 1307. 
     Step 1304: Since the up cursor key has been pressed, it is desired to employ a block preceding the current specified block as the specified block. Hence, the preceding block is searched for. A block of which &#34;next&#34; matches the current &#34;xpoint&#34; is the preceding block. 
     Step 1305: If the preceding block does not exist, the processing branches to step 1307 because there is nothing to be done. 
     Step 1306: The address of the preceding block is assigned to &#34;xpoint&#34;, thereby employing the preceding block as the specified block. 
     Step 1307: The processing returns to the parent program. 
     FIG. 14 is a flowchart of &#34;open&#34; processing called when the key corresponding to &#34;OPEN&#34; is pressed on the schedule block display screen. 
     Step 1401: A check is made to see if there is a child block in the specified block. The child block exists if &#34;sub&#34; of the specified block is not 0. If there is no child block, the processing branches to step 1404 and transits to an edit screen. 
     Step 1402: Since there is a child block, &#34;sub&#34; is assigned to the pointer global variable &#34;xpoint&#34; indicating the address of the specified block, thereby using the child block as the specified block. 
     Step 1403: The schedule block is displayed. The process then returns to the parent block at step 1406. 
     Step 1404: Since there is no child block, the program having the program name (name) of the specified block is searched for to move to the edit screen. 
     Step 1405: The edit screen is displayed. 
     Step 1406: The processing returns to the parent program. 
     FIG. 15 is a flowchart of &#34;close&#34; processing called when the key corresponding to &#34;CLOSE&#34; is pressed on the edit screen or the schedule block display screen. 
     Step 1501: A check is made to see if the edit screen is being displayed or not. If the screen being displayed is not the edit screen (is the schedule block display screen), the processing branches to step 1504. 
     Step 1502: The schedule block wherein the program being displayed on the edit screen is registered is searched for. The block searched for is the one having the &#34;name&#34; matching the program name on the edit screen. 
     Step 1503: The address of the block found is assigned to the pointer global variable &#34;xpoint&#34; indicating the address of the specified block, thereby using it as the specified block. The processing then progresses to step 1507. 
     Step 1504: A parent data block is searched for since &#34;CLOSE&#34; has been selected on the schedule block display screen. Blocks before the specified block are searched for a block whose &#34;sub&#34; is the address of the first block. This is the parent block. 
     Step 1505: When there is no parent data block, the processing branches to step 1507 since there is nothing to be done. 
     Step 1506: The address of the parent data block is assigned to &#34;xpoint,&#34; thereby using the parent data block as the specified block. 
     Step 1507: A block preceding the specified block is searched for. The schedule block of which &#34;next&#34; matches &#34;xpoint&#34; is the preceding block. 
     Step 1508: If the preceding block is absent, it indicates that the specified block is the first block and therefore the processing branches to step 1510 and displays the schedule block. 
     Step 1509: The address of the preceding block is assigned to &#34;xpoint&#34; to employ the preceding block as the specified block. To search for the first block, the processing branches to the step 1507 and repeats the following steps. 
     Step 1510: Schedule blocks are displayed, beginning with the specified schedule block indicated by &#34;xpoint.&#34; 
     Step 1511: The processing returns to the parent program. 
     According to the present invention, as described above, the schedule skipping means for skipping a schedule at the occurrence of an alarm allows machining to be continued without stopping a schedule run if an alarm occurs during the run. 
     The memory for storing a measurement schedule corresponding to a machining schedule allows any measurement schedule to be made out, ensuring the implementation of the measurement schedule which will not impair productivity greatly. 
     The memory capable of registering two or more schedule elements as one group allows a complicated schedule, such as the repeated machining of multiple sets of workpiece machining, to be made out easily with a small-capacity memory. 
     The clock and the memory for storing run start time corresponding to a schedule allow run start time of day and run interval time to be set, ensuring ease of control such as an unattended warming-up run and an interval run including machine cooling time. 
     The machining schedule specifying means, the schedule display-to-edit transition means and the edit-to-schedule display transition means allow any of schedule data displayed on a schedule registration display screen to be specified and edited and an edit screen for a machining program to be directly transited to a corresponding schedule display screen to check the schedule status of that program, ensuring ease of operation as well as preventing incorrect program edition from being made by writing and/or entering a wrong program number.