beautypg.com

Examples of use by data type – Yaskawa MP940 User Manual

Page 83

background image

Basic System Operation

3.6.2 Data Types

3-36

Examples of Use by Data Type

Bits

Bits are used for relay circuit ON/OFF or for logic operations.

• Motion Program Example

MB000101=IB000100;
IF IB000001==1;
DB000001=DB000001 | 1

Words

Words are used for numeric operations and logic operations.

• Motion Program Example

MW00101=MW00100 | 00FFH;
MW00103=MW00102+12345;
MW00105=MW00104;



[ MB001003 ]

[ MF00100 ]

[ ML00100 ]

[ MW00101 ]

[ MW00103 ]

[ MW00102 ]

[ MW00100 ]

[ MA00100 ]

nn

Pointer Designations

Register area

Memory

address

MB000101

IB000100

IB000001

IFON

OB000001

1

OB000001

MW00100

H00FF

MW00101

MW00102

12345

MW00103

MW00104 INV

MW00105