beautypg.com

Instructions fun 050 or or – Toshiba 6F3B0253 User Manual

Page 159

background image

6F3B0253

Basic Hardware and Function

157

7. Instructions

FUN 050

OR

OR

Expression

Input

[ A OR B

C ]

Output

Function

When the input is ON, this instruction finds logical OR of A and B, and stores the result in C.

Execution condition

Input

Operation

Output

OFF

No execution

OFF

ON

Execution

ON

Operand

Name

Device

Register

Constant Index

X

Y

R

S

T.

C. XW YW RW SW T

C

D

I

J

K

A Source

B source

C OR

Example

When R012 is ON, logical OR operation is executed for the data of RW13 and RW20, and the
result is stored in D0031.

If the data of RW13 is H5678 and RW20 is H4321, the result H5779 is stored in D0031.

F

E

D

C

B

A

9

8

7

6

5

4

3

2

1

0

RW13

0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0

5

6

7

8

OR

RW20

0 1 0 0 0 0 1 1 0 0 1 0 0 0 0 1

4

3

2

1

D0031

0 1 0 1 0 1 1 1 0 1 1 1 1 0 0 1

5

7

7

9