Delta AS Series Programming Manual page 868

Hide thumbs Also See for AS Series:
Table of Contents

Advertisement

API
Instruction code
1603
T-
Device
X
Y
M
S
1
S
2
D
Data
type
S
1
S
2
D
Symbol
Explanation
1.
This instruction subtracts the value of the hour, the minute, and the second in the real-time clock specified by S
from the value of the hour, the minute, and the second in the real-time clock specified by S
difference in the register specified by D.
2.
The operands S
, S
, and D all occupy three consecutive devices.
1
2
3.
If the difference is a negative, SM601 is ON, and the instruction adds 24 hours to the difference and then stores
the result in D.
4.
If the difference is zero (zero hour zero minute zero second), SM600 is ON.
Example
1.
When M0 is ON, the instruction subtracts the value of the hour, the minute, and the second in D10–D12 from the
value of the hour, the minute, and the second in D0–D2, and stores the difference in D20–D22.
D0
D1
D2
20 hour 20 minute 50 second
Operand
P
S
, S
, D
1
2
S
T
C
HC
Pulse instruction
AS
: Source device 1
S
1
: Source device 2
S
2
D : Device where the result is stored
20 ( Hour )
D10
14 (
20 ( Minute)
30 (
-
D11
5 ( Second)
D12
8 (
14 hour 30 minute 8 second
Ch ap te r 6 Ap pl ie d Instruc ti ons
D
FR
SM
SR
16-bit instruction
AS
Hour
Hour
)
D20
5 (
Minute
Minute
)
D21
49 (
Second
Second
)
D22
57 (
5 hour 49 minute 57 second
Function
Subtracting the time
E
K
16#
"$"
F
32-bit instruction
-
2
, and stores the
1
)
)
)
6 - 5 8 9
6_

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents