15 v a riable pr ogr amming – HEIDENHAIN CNC Pilot 4290 User Manual

Page 193

Advertising
background image

HEIDENHAIN CNC PILOT 4290

181

4.15

V

a

riable Pr

ogr

amming

Skip level/..

An NC block with preceding skip level is not run with an active skip
level (see “

4.3.3 Machining Menu“).

Skip levels are activated/deactivated in Automatic mode (machine
mode of operation).

In addition, you can use the skip cycle (setup parameter 11
“deletion level/cycle”). “Skip cycle x” activates the skip level every
xth time.

Example:

/1 N 100 G...

“N100” is not executed if skip level 1 is active.

For lathes equipped with one slide or
program heads containing only one slide,
a slide code is not necessary.

SWITCH..CASE—Program branch

The “switch statement“ consists of the elements:

SWITCH—Followed by a variable. The content of the variable is

interrogated in the following CASE statement.

CASE x—This CASE branch is run with the variable value x.

CASE can be programmed more than once.

DEFAULT—This branch is run if no CASE statement matched

the variable. DEFAULT can be omitted.

BREAK—Closes the CASE or DEFAULT branches.

Programming notes

Select SWITCH (Machining menu: Instructions—DIN PLUS words)

Enter the variable (without parentheses)

For each CASE branch:

Select CASE (Machining menu: Instructions—DIN PLUS words)

Enter the “SWITCH condition” (value of the variable).

Insert the NC blocks to be executed.

For the DEFAULT branch:

Insert the NC blocks to be executed.

Example:

N.. SWITCH {V1}

N.. CASE 1

[executed if V1=1]

N..

G0 Xi10

. . .

N.. BREAK

N.. CASE 2

[executed if V1=2]

N..

G0 Xi10

. . .

N.. BREAK

N.. DEFAULT

[executed if no]

N..

G0 Xi10

CASE instruction

. . .

matched the variable value]

N.. BREAK

N.. ENDSWITCH

. . .

If the branch is triggered by V variables

or events, the contour follow-up is
switched off with the SWITCH statement
and back on with the ENDSWITCH
statement. With G703 you can switch on
the contour follow-up function.

The variable value should be a whole

number—it is not rounded.

Slide code $..

An NC block preceded by a slide code is executed only for the
indicated slide (see “

4.3.3 Machining Menu“). NC blocks that are

not preceded by slide codes are executed on all slides.

Advertising