Download XC Series Programmable ProgrammableController Controller

Transcript
特殊功能
[SUB]
16 bits instruction:SUB
K/H
Bit
Device
X
DX
DY
D M
S2·
DS
TD
CD
D
FD
D·
Y
X0
M
S
SUB
T
C
Flag
Suitable Device
S1·
Word
Device
Function
32 bits instruction:DSUB
Suitable Models
Models::
XC1、XC3、XC5
Zero
Borrow
Carry
D n .m
S1·
S2·
D·
D1 0
D1 2
D1 4
(D10)—(D12)→(D14)
�
appoint the soft unit’s content, subtract the soft unit’s content appointed by S2· in the
format of algebra. The result will be stored in the soft unit appointed by D· . (5-(-8)=13)
� The action of each flag, the appointment method of 32 bits operation’s soft units are both
the same with the preceding ADD instruction.
� The importance is: in the preceding program, if X0 is ON, SUB operation will be
executed every scan cycle
S1·
The relationship of the flag’s action and vale’s positive/negative is shown below:
168
M8020
M8021
M8022