High level language
153
$SWITCH
$CASE
$ENDSWITCH
$BREAK
$DEFAULT
Conditional execution SWITCH.
$SWITCH <expression1>
$SWITCH <expression2>
$ENDSWITCH
$BREAK
$DEFAULT
Note: this instruction calculates the result
of <expression1> and executes the blocks
contained between the $CASE instruction,
whose <expression2> has the same value
a s t h e c a l c u l a t e d r e s u l t a n d t h e
corresponding $BREAK instruction.
The $SWITCH instruction always ends with
a $ENDSWITCH.
The $CASE instruction always ends with a
$BREAK. As many $CASE instructions as
necessary may be programmed.
As an option, a $DEFAULT instruction may
be inserted in such a way that if the result
of <expression1> does not coincide with
the value of any <expression2>, it executes
the blocks contained between $DEFAULT
and $ENDSWITCH.
E.g.:
$SWITCH [P1=P2/P3]
$CASE 10
… (executes this section if P1=10)
$BREAK
$CASE 20
… (executes this section if P1=20)
$BREAK
$CASE 40
… (executes this section if P1=40)
$BREAK
$DEFAULT
… (executes this section for other P1 values)
$ENDSWITCH
Instruction
Meaning
Содержание CNC 8060
Страница 1: ...CNC 8060 65 User quick reference Ref 1906...
Страница 44: ...Work modes 44...
Страница 64: ...ISO language 64...
Страница 102: ...ISO canned cycles T 102...
Страница 128: ...Conversational cycles M 128...
Страница 136: ...Conversational cycles T 136...
Страница 150: ...Measuring and calibration cycles T 150...
Страница 169: ......