Chapter 6 Instruction Details
XBC E-Type Main Unit
6-181
Ver. 1
6.30 Logic Operation Instruction
6.30.1 WAND, WANDP, DWAND, DWANDP
Instruction
Area Available
Step
Flag
P M K F L T C S Z D.x R.x
Co
nst.
U N D R
Error
(F110)
Zero
(F111)
Carry
(F112)
WAND(P)
DWAND(P)
S1 O O O O O O O - O -
- O O O O O
4~6
-
O
-
S2 O O O O O O O - O -
-
- O O O O
D O O O - O O O - O -
-
- O
O O
[Flag Set]
1) WAND (Word AND)
(1) Saves the result of word data (16-bit) S1 and S2 operated in Logic AND for each bit in D.
2) DWAND (Double Word AND)
(1) Saves the result of double word data (32-bit) (S1+1,S1) and (S2+1,S2) operated in Logic AND for each bit
in (D+1, D).
WAND
D
b15
b8
b0
b7
1 0 0 1 1 1 1 0 0 1 0 1 0 1 1 1
S2
b8
b0
b7
S1
b15
b8
b0
b7
b15
1 0 1 0 0 1 1 0 1 1 1 1 0 1 1 1
1 0 0 0 0 1 1 0 0 1 0 1 0 1 1 1
Operand
Description
Data Type
S1
Data to execute WAND operation with S2
BIN 16/32
S2
Data to execute WAND operation with S1
BIN 16/32
D
Address to save WAND operation result in
BIN 32
Flag
Description
Device
Number
Zero
To be set if operation result is Zero.
F111
(D)WAND
means
WAND/DWAND
P S1 S2
(D)WANDP
S1 S2 D
D
Summary of Contents for XBC-DN10E
Page 1: ......
Page 10: ...Table of Contents Table of Contents 6 10 10 CLEAR ALL PLC 29...