3) programming examples – Yaskawa MP2000 Series: User's Manual for Motion Programming User Manual
Page 221
8 Command Reference
8.4.12 I/O Variable Wait (IOW)
8-114
(b) Integer/Double Integer/Real Number Data Comparison
(3) Programming Examples
An IOW command programming example is shown below.
Fig. 8.65 I/O Variable Wait Command (IOW) Programming Example
Format
• All data comparison commands (==, <>, >, <, >=, <=) can be used.
• Specify a register either on the left or right.
IOW MW00000 == 3; "MW00000 = 3
IOW ML00000 <> ML00002; "ML00000
≠ ML00002
IOW 1.23456 >= MF00000; "1.23456
≥ MF00000
Operations in
Conditional
Expression
• Arithmetic operations and logic operations can be used.
IOW MW00000 == (MW00001/3); "MW00000 = (MW00001
÷ 3)
IOW (ML00000 & F0000000H) <> ML00002; "(ML00000
∧ F0000000H) ≠ ML00002
IOW 1.23456 >= (MF00000 * MF00002); "1.23456
≥ (MF00000 × MF00002)
Syntax Error
Examples
• When a constant is specified both on the left and right:
IOW 0 == 3; => Syntax error
IOW (3.14*2*1000) > 9000.0;
=> Syntax error
• No data comparison command:
IOW MW000000; => Syntax error
IOW (-1); => Syntax error
• When more than one data comparison command is used:
IOW (MW00000 < 0) & (MW000001 > 0); => Syntax error
IOW (MB001001&MB001002)== 1;
MOV [A1]1000;
EXAMPLE
Speed
Time
Positioning for the axis A1
MB001001
MB001002