Parameterizable Subprogram Return Jump (Ret - Siemens SINUMERIK 840D sl Programming Manual

Nc programming
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

Work preparation
3.2 Subprogram technique
Subprogram:
Program code
PROC SUB_PROG
...
N100 RET
3.2.2.10

Parameterizable subprogram return jump (RET ...)

Generally, a return jump is made from a subprogram into the calling program using the RET
command. Processing is then continued with the program line following the subprogram call.
The following options are available if program processing is to be continued at another location:
● Resume program execution after calling the stock removal cycles in the ISO dialect mode
(after describing the contour).
● Return to main program from any subprogram level (even after ASUB) for error handling.
● Return jump across several program levels for special applications in compile cycles and in
the ISO dialect mode.
To achieve this, the RET command should be programmed with additional parameters.
Search direction
When specifying parameter <target block>, a return jump is first made to the block after the
calling block. A search is then made for the target in the direction of the end of the program into
which a return jump was made. A search is made toward the start of the program if the search
was not successful.
Syntax
RET("<target block>")
RET("<target block>",<block after target block>)
RET("<target block>",<block after target block> <number of return
jump levels>)
RET("<target block>", ,<number of return jump levels>)
RET("<target block>",<block after target block>,<number of return
jump levels>,
<return jump to the beginning of the program>)
RET( , ,<number of return jump levels>,<return jump to the beginning
of the program>)
512
Comment
; Return jump to block N60 in the main program.
Programming Manual, 12/2019, 6FC5398-2EP40-0BA0
NC programming

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 840de sl

Table of Contents