K1: Mode group, channel, program operation, reset response
9.8 Block search Type 5 SERUPRO
Basic Functions
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
543
Nesting rules
The following features regulate the interaction between NC commands IPTRLOCK and IPTRUNLOCK with
nesting and end of subroutine:
1. IPTRLOCK is activated implicitly at the end of the subroutine in which IPTRUNLOCK is called.
2. IPTRLOCK in an untraceable section has no effect.
3. If subprogram1 calls subprogram2 in a search-suppressed area, subprogram2 remains search-suppressed.
IPTRUNLOCK in particular has no effect in subroutine 2.
Examples of nesting with two program levels
Nesting of search-suppressed program sections in 2 program levels.
An interruption in a search-suppressed program section of the above program always returns N10030 G4 F1
block.
With implicit IPTRUNLOCK
Nesting of search-suppressed program sections in two program levels with implicit IPTRUNLOCK. The implicit
IPTRUNLOCK in subprogram 1 ends the search-suppressed area.
Table 9-1
; Interpretation of the blocks in an illustrative
sequence.
; Subprogram1 is prepared for the block search:
N10010 IPTRLOCK() ; Program level 1
N10020 R1 = R1 + 1 ;
N10030 G4 F1 ; hold block
of the search-suppressed program section starts
... ;
N10040 Subprogram2 ; Interpretation of subprogram2
... ; Program level 2
N20010 IPTRLOCK () ; is ineffective
... ;
N20020 IPTRUNLOCK () ; is ineffective
... ;
N20030 RET ;
... ;
N10050 IPTRLOCK() ;
N10060 R2 = R2 + 2 ;
N10070 G4 F1 ; End of search-suppressed program section