EasyManua.ls Logo

HEIDENHAIN CNC PILOT 640 - Program Branch SWITCH..CASE

HEIDENHAIN CNC PILOT 640
697 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
DIN/ISO programming | Conditional block run
4
482
HEIDENHAIN | User's Manual smart.Turn and DIN Programming | 12/2017
Program branch SWITCH..CASE
The program branch consists of the elements:
SWITCH, followed by a variable. The content of the variable is
interrogated in the following CASE statement
CASE x: The CASE branch is run with the variable value x. CASE
can be programmed repeated times
DEFAULT: This branch is executed if no CASE statement
matched the variable value. DEFAULT can be omitted
BREAK: Concludes the CASE branch or DEFAULT branch
Programming:
Select Extras > DINplus word…. The control opens the Insert
DIN PLUS word selection list.
Select SWITCH
Enter the switch variable
For each CASE branch:
Select CASE (in Extras > DINplus word…)
Enter the SWITCH condition (value of the variable) and insert
the NC blocks to be executed
For the DEFAULT branch: Insert the NC blocks to be executed
Example: SWITCH..CASE
. . .
N.. SWITCH #g201
N.. CASE 1
Executed if #g201=1
N.. G0 Xi10
. . .
N.. BREAK
N.. CASE 2
Executed if #g201=2
N.. G0 Xi20
. . .
N.. BREAK
N.. DEFAULT
No CASE statement matched the variable value
N.. G0 Xi30
. . .
N.. BREAK
N.. ENDSWITCH
. . .

Table of Contents

Related product manuals