5
Categories and Use of Basic Application Instructions
DVP-PM Application Manual
5-127
API Mnemonic
Operands
Function
218~
220
D AND#
Contact Logical Operation AND#
Controllers
20PM
10PM
Bit Devices
Word Devices
Program Steps
Type
OP
X Y M S K H
KnX KnY KnM KnS T
C
D
V
Z
S
1
*
*
*
*
*
*
*
*
*
*
*
S
2
*
*
*
*
*
*
*
*
*
*
*
AND#: 5 steps
DAND#: 7 steps
Operands:
S
1
: Data source device 1
S
2
: Data source device 2
Explanations:
1. See the specifications of DVP-PM for its range of use.
2. #: &, |, ^
3. AND# instruction compares the content in
S
1
and
S
2
. If the result is not “0”, the instruction will be ON. If the result
is “0”, instruction will be OFF.
4. AND# is series connected to contacts:
API No.
16-bit
instruction
32-bit
instruction
“ON" condition
“OFF” condition
218 AND&
D
AND&
S
1
&
S
2
≠
0
S
1
&
S
2
=
0
219 AND|
D
AND|
S
1
|
S
2
≠
0
S
1
|
S
2
=
0
220 AND^
D
AND^
S
1
^
S
2
≠
0
S
1
^
S
2
=
0
5. &: Logical ‘AND’ operation
6. |: Logical ‘OR’ operatioin
7. ^: Logical ‘XOR’ operation
8. When 32-bit counters (C200 ~ C255) are used in this instruction for operation, please adopt 32-bit instruction
(DAND#). If 16-bit instruction (AND#) is adopted, “program error” will occur, and the ERROR LED indicator on
the panel of DVP-PM will flash.
Program Example:
1. When the result of logical AND operation of C0 and C10
≠
0, Y10 will be ON.
2. When the result of logical OR operation of D10 and D0
≠
0 and X1 = OFF, Y11 will be ON and held.
3. When X2 = ON and the result of logical XOR operation of 32-bit register D200 (D201) and 32-bit register D100
(D101)
≠
0 or M3 = ON, M50 will be ON.
M3
DAND
D200
D100
M50
AND
C0
C10
AND
D10
D0
SET
&
^
I
Y11
Y10
X0
X1
X2
Содержание DVP-10PM
Страница 1: ......
Страница 45: ...2 Hardware Specifications and Wiring DVP PM Application Manual 2 30 MEMO...
Страница 125: ...3 Functions of Devices in DVP PM DVP PM Application Manual 3 80 MEMO...
Страница 341: ...8 Application Examples DVP PM Application Manual 8 2 Trajectory 3 Trajectory 4...
Страница 427: ...9 Electrical CAM DVP PM Application Manual 9 74...
Страница 437: ...10 Encrypting User Program DVP PM Application Manual 10 10 MEMO...
Страница 458: ...11 G code Application DVP PM Application Manual 11 21 B O100 main program...
Страница 561: ...14 Appendix DVP PM Application Manual 14 4 MEMO...