Delta Electronics AH500 Manual page 160

Motion control module
Hide thumbs Also See for AH500:
Table of Contents

Advertisement

API
Instruction code
28
D
WXOR
Device
X
Y
M
S
1
S
2
D
E xp la nat io n
E xamp le 1
E xamp le 2
S
1
D 11 D 10
Before the instruction
is executed
S
2
D 21 D 20
After the instruction
D
is executed
D 41 D 40
5 - 4 5
Operand
P
S
, S
1
S
K
16#
F
Pulse instruction 16-bit instruction (7 steps) 32-bit instruction (9 steps)
S
: Source device 1; S
: Source device 2; D: Operation result
1
2
A logical XOR operator takes the binary representations in S
and performs the logical exclusive OR operation on each pair of
corresponding bits. The operation result is stored in D.
The result in each position is 1 if the two bits are different, and 0 if they
are the same.
When X0.0 is ON, a logical XOR operator takes the values in the 16-bit
device D0 and the 16-bit device D2, and performs the exclusive OR
operation on each pair of corresponding bits, and the operation result is
stored in D4.
X0.0
WXO R
S
1
Before the instruction
is executed
S
2
After the instruction
D
is executed
When X0.1 is ON, a logical XOR operator takes the values in the 32-bit
device (D11, D10) and the 32-bit device (D21, D20), and performs the
logical exclusive OR operation on each pair of corresponding bits, and
the operation result is stored in (D41, D40).
X0.1
D WXOR
b31
1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1
0 0 0
1
1
0
0
0
0 0
1 1 1
0
1 1
0
1
0 0
Ch ap te r 5 Ap plie d Instruc tions
Logical exclusive OR
, D
2
operation
KnM KnS
D
W
D 0
D 2
b15
D 0
0
1
0
1
0
1
0
1
0 1
WX OR
D 2
0 0 0 0
1 1
1
1
1
D 4
0
1
0
1
1
0
1
0
1 1 1
D 10
D20
b15
1
1
1
1
1
DWX OR
1 1
1 0 0
1
0
0 0 0
0 0
1
1
1
0
1
1
1 1 1
0
1 1
Function
T
C
V
Z
and S
,
1
2
D 4
b0
0
1
0
1
0
1
0
1
0
0
1
0
1
1
0
0
0
0
D 40
b0
1
1 1
0 0
0 0
1
1
1 1
1
1
1
1
0 0 0
0
0 0
0
1
0 0
1
1
1
0
1
1

Advertisement

Table of Contents
loading

Table of Contents