3 ) programming example – Yaskawa MP900 Series Ladder Programming Manual User Manual

Page 137

Advertising
background image

5.4 Logic Operations and Comparison Instructions

5.4.3 Exclusive OR (XOR)

5-68

( 3 ) Programming Example

In the following programming example, an exclusive logical OR is performed on 12,345 (3039 hex) in input data A in
MW00000 and 3,855 (0F0F hex) in input data B in MW00001, and the result is stored in the output data in DW00000.

0

Bit 0

Bit 7

Bit F

Bit 3

Bit B

Bit 4

Bit 8

Bit C

MW00000 :

12,345 (3039 hex)

0

1

1

0

0

0

0

0

0

1

1

1

0

0

1

0

0

0

0

1

1

1

1

0

0

0

0

1

1

1

1

0

0

1

1

1

1

1

1

0

0

1

1

0

1

1

0

MW00001 :

3,855 (0F0F hex)

DW00000 :

16,182 (3F36 hex)

MW00000 ^ MW00001 → DW00000

Advertising
This manual is related to the following products: