A.2.4 substitution operator, A.2.5 function, A.2.6 others – Yaskawa MP900 Series Machine Controller New Ladder Editor User Manual

Page 245

Advertising
background image

A.2 Recognizable Expression

A-7

A

A.2.4 Substitution Operator

If it is a difference of the real type or the integer type even if a right, left type is different,
substitution is possible. However, the rounding error is caused when substituting from the
real type to the integer type.
Substitution for the bit type register can do only a logical value (bit type register or true/
false). In the case to substitute the values other than a logical value for the bit type register,
the values are compared with 0 (Or, 0.0), and the truth is converted into the substituted code.
The substitution of the bit type excluding the bit type register is assumed to be impossible.

MW00001

= MW00002

OK

ML00003

= MW00002

OK

MF00006

= MW00002 ∗ 343

OK

MB000010

= MB000011

OK

MW00001

= MF00012

OK

MB000102

= MW00010

OK

MB000102

= true

OK

MW00010

= MB000101

NG

MW00010

= true

NG

A.2.5 Function

The argument and the return value to the function depend on the specification of controller’s
function. That is, the output value is returned by the integer when the register of the integer
and the integer type is input to sin (), cos (), and atan (), and when the register of the real
number and the real type is input, the output value is returned by the real number. When the
register of the integer type is input because the argument of tan () is a real number, is treated
as a real type.

MW00001

= sin (MW00002)

OK

MF00001

= cos (MF00002 ∗ 3.14)

OK

MW00001

= − atan(MF00002)

OK

A.2.6 Others

„

Parentheses

Two or more expressions can be united by using “(” and “)”.

MW00001

= − ((MW00002 − MW00003) / (MW00004 + MW00005))

OK

EXAMPLE

EXAMPLE

EXAMPLE

Advertising
This manual is related to the following products: