
B–61863E/15
2. SEQUENCE PROGRAMPMC SEQUENCE PROGRAM
45
A sequence program consists of three parts: 1st level sequence, 2nd level
sequence and 3rd level sequence. The 3rd level sequence part is added
to the models usable the 3rd level sequence. (see Fig. 2.3 (a)).
Sequence program
1st level sequence part
2nd level sequence part
3rd level sequence part
Specifies the end of the
1st level sequence part.
SUB 1
SUB 2
SUB 48
Division 1
Division 2
Division n
Specifies the end of the
2nd level sequence part.
(Only the models usable the 3rd level sequence)
Specifies the end of the 3rd level sequence part.
Fig. 2.3 (a) Construction of sequence program
The 1st level sequence part operates every 8 ms (high–speed sequential
operation).
If the 1st level sequence part is long, the total operating time, including
the 2nd level sequence part, is extended. Therefore the 1st level sequence
part must be programmed to be processed in as short time as possible.
The 2nd level sequence part operates every 8×n ms. Here n is a dividing
number for the 2nd level sequence part. The 2nd level sequence part is
divided automatically when the sequence program is transferred to the
RAM for debugging in the CNC unit or it is written on ROM after the
program is created. The time for one cycle of the sequence program is
then displayed on the offline programmer screen.
The 3rd level sequence part operates during idle time of PMC.
(1) Division of the 2nd level sequence part
The 2nd level sequence part must be divided in order to execute the
1st level sequence part. For example a sequence program is executed
in the following sequence when the dividing number is n. (See Fig.
2.3 (b), 2.3 (c) )
After the last 2nd level sequence part (division n) is executed, the
sequence program is executed again from the beginning. Thus, when
the dividing number is n, the cycle of execution is 8mms (8ms×n).
The 1st level sequence operates every 8 msec, and the 2nd level
sequence every 8×n msec. If the steps of the 1st level sequence is
increased, the steps of the 2nd level sequence operating within 8 msec
becomes less, thereby increasing the dividing number and making
the processing time longer. Therefore, it is desirable to program so
as to reduce the 1st level sequence to a minimum.
In the, PMC–SA1, –SA2, –SB and –SB2, 1.25 ms of 8 ms is assigned
to execution of the 1st and 2nd level sequences. The remaining time
is assigned to NC processing.
In the PMC–SC, 5 ms of 8 ms is assigned to execution of the 1st and
2nd level sequences. The standard setting value is 5 ms when system
parameter LADDER EXEC = 100%. The remaining time is assigned
to execution of the 3rd level sequence and the program.
2.3
PRIORITY OF
EXECUTION
(1ST LEVEL, 2ND
LEVEL AND 3RD
LEVEL)