2 combinations of math operations, 3 combinations of logic operations – Yaskawa MP900 Series Motion Programming Manual User Manual
Page 137

Sequence Commands
4.1.3 Combinations of Logic Operations
4 -4
Classification
Programming Format
Name
Command
Basic Functions
SIN
SINE
SIN(MW− );
COS
COSINE
COS(MW− );
TAN
TANGENT
TAN(MW− );
ASN
ARC SINE
ASN(MW− );
ACS
ARC COSINE
ACS(MW− );
ATN
ARC TANGENT
ATN(MW− );
SQRT
SQUARE ROOT
SQRT(MW− );
BIN
BCD-TO-BINARY
BIN(MW− );
BCD
BINARY-TO-BCD
BCD(MW− );
S{}
SET BIT
S{MB−} = MB− &MB− ;
R{}
RESET BIT
R{MB−} = MB− &MB− ;
4.1.2 Combinations of Math Operations
Operations can be performed by combining math commands and functions. The order of prior-
ity of operations does not have to be considered. Perform the operations from left to right.
To change the order, use parentheses.
The following example shows a math expression.
Example: MW00100=MW00102
+
MW00104 * SIN(MW00106);
1
2
The operation is performed in the order shown by the numbers.
The following examples show the changes in the operation order when parentheses ( ) are used.
S
MF00100=100.+200.* 0.5 * SIN(30.);
(75.)
1
2
3
S
MF00100=100.+ (200.* 0.5 * SIN(30.));
(150.)
3
1
2
S
MF00100=100.+ (200* 0.5) * SIN(30.);
(100.)
2
1
3
4.1.3 Combinations of Logic Operations
Logic operations can be performed by combining logic operation commands and functions.
There is no order of priority for operations. Although operations that use a combination of math
operations and mixed expressions are also possible, real number operations cannot be per-
formed.
4
INFO