Yaskawa YASNAC PC NC Programming Manual User Manual

Page 291

Advertising
background image

4 - 154

YASNAC PCNC Programming Manual

Chapter 4: Enhanced Level Commands

(6) Undefined Variables

Variables which have not been defined yet are called undefined variables, and their val-
ues are <empty>. The following variables are treated as undefined variables.

Local variables and common variables (#100 to #299) when the power is turned ON or
the NC is reset.

Local variables for which arguments are not specified where a microprogram is called
up.

Local variables which belong to the level of the microprogram from which the execu-
tion of program returns by the execution of M99.

Local variables and common variables where no values have been set in a micropro-
gram.

Common variables where no values have been set at the NC operation panel.

Variable “#0”. (This is always treated as <empty> and must not be entered in the left
side of an operation expression.)

(a) Meaning of <empty>

If an undefined variable is assigned, the address itself for which it is assigned is disre-
garded.

If an undefined variable is used in an operation expression, it is treated to have the
variable value of “0” with the exception that it is replaced with <empty>.

#2 = <empty>

G00X#2; is equivalent to G00;.

#2 = 0

G00X#2; is equivalent to G00X0;

#2 = <empty>

#3 = #2; indicates #3 = <empty>.

#2 = <empty>

#3 = # [#2+#2]; indicates #3 = #0 = <empty>.

#2 = <empty>

#3 = #1*#2; indicates #3 = <empty>.

#2 = <empty>

#3 = #2+#2; indicates #3 = <empty>.

#2 = <empty>

#3 = #2/#2; indicates #3 = <empty:>

#2 = <empty>

#3 = 5*#2; indicates #3 = <empty>.

#2 = <empty>

#3 = 2-#2; indicates #3 = 2.

#2 = <empty>

#3 = 5/#2 causes division error.

Advertising