beautypg.com

HEIDENHAIN TNC 407 (280 580) ISO Programming User Manual

Page 201

background image

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

7 - 1 2

7

Programming with Q Parameters

7.4

If-Then Decisions with Q Parameters

Jump example

You want to jump to program 100.H as soon as Q5 becomes negative.

N5

D00 Q5 P01 +10 * ............................................ Assign a value, such as +10, to parameter Q5

N9

D02 Q5 P01 +Q5 P02 +12 * ............................. Reduce the value of Q5

N10

D12 P01 +Q5 P02 +0 P03 5 * .......................... If +Q5 < 0, jump to label 5

N15

G98 L5 * ........................................................... Label 5

N16

% 100.H * ......................................................... Jump to program 100.H

.
.
.

.
.
.

.
.
.

.
.
.