beautypg.com

Program as subprogram -8, 3 program as subprogram – HEIDENHAIN TNC 407 (280 580) ISO Programming User Manual

Page 186

background image

TNC 426/TNC 425/TNC 415 B/TNC 407

6-8

6

Subprograms and Program Section Repeats

6.3 Program as Subprogram

Operating sequence

A program is executed (

1

) up to the block in which

another program is called (block with %).

Then the other program is run from beginning to
end (

2

).

The first program is then resumed beginning with
the block behind the program call (

3

).

Operating limitations

• Programs called from an external data medium

(e.g., floppy disk) must not contain any subpro-
grams or program section repeats.

• No labels are needed to call main programs as

subprograms.

• The called program must not contain the miscel-

laneous functions M02 or M30.

• The called program must not contain a jump into

the calling program.

Calling a program as a subprogram

PROGRAM NAME ?

Enter the name of the program that you wish to call from this block.

Function

Soft key

Call a plain-language program

Call an ISO program

Call an externally stored program

Resulting NC block: % NAME

You can also call a program with cycle G39 (see page 8-53).
• When calling an ISO program, the program name must not contain G50, G70 or G71.

The following additional notes apply to the TNC 426:
• If the program you want to call is located in the same directory as the program you are calling it from, you only

have to enter the program name.

• If the program you want to call is not located in the same directory as the program you are calling it from, then

you must enter the full path (e.g., \VZW35\ROUGH\PGM1.I).

• If you want to call a plain-language program, enter the file type .H behind the program name.

R

S

% A ... *

% B *

N99999

% A ... *

1

3

% B ... *

N99999

% B … *

2

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

0

/

0

Fig. 6.3:

Flow diagram of a program as subprogram.

S

= jump,

R

= return jump

426