Delta AH500 Programming Manual page 536

Hide thumbs Also See for AH500:
Table of Contents

Advertisement

AH 5 00 Pr ogr am m ing Ma n ua l
API
Instruction code
1603
T-
Device X
Y
M
S
1
S
2
D
Symbol:
Explanation:
1.
The value of the hour, the value of the minute, and the value of the second in the real-time
clock specified by S
value of the second in the real-time clock specified by S
register specified by D.
2.
The operands S
, S
1
3.
If the difference is a negative, SM601 is ON, and the result gotten from the addition of 24 hours
to the difference is stored in D.
4.
If the difference is 0 (0 hour 0 minute 0 second), SM600 is ON.
Example:
1.
When M0 is ON, the instruction T- is executed. The value of the hour, the value of the minute,
and the value of the second in D10~D12 are subtracted from the value of the hour, the value of
the minute, and the value of the second in D0~D2, and the difference is stored in D20~D22.
D0
20 ( Minute)
D1
5 ( Second)
D2
20 hour 20 minute 50 second
2.
If the difference is a negative, SM601 is ON.
5 ( Hour )
20 ( Minute)
30 ( Second)
5 hour 20 minute 30 second
Additional remark:
1.
If the value in S
or S
1
6 - 3 6 8
Operand
P
S1, S2, D
S
T
C
HC
D
Pulse instruction 16-bit instruction (7 steps) 32-bit instruction
: Source device
S
1
: Source device
S
2
D : Device in which the result is stored
are subtracted from the value of the hour, the value of the minute, and the
2
, and D all occupy three consecutive devices.
2
20 ( Hour )
D10
14 (
30 (
-
D11
D12
8 (
14 hour 30 minute 8 second
Hour
19 (
Minute
11 (
-
Second
15 (
19 hour 11 mi nute 15 second 10 hour 9 minute 15 second
exceeds the range, the operation error occurs, the instruction is not
2
Subtracting the time
L
SM SR
E
AH500
AH500
, and the difference is stored in the
1
Hour
Hour
)
D20
5 (
Minute
Minute
)
D21
49 (
Second
Second
)
D22
57 (
5 hour 49 minute 57 second
)
)
)
Function
PR
K
16# "$"
DF
-
Word
Word
Word
)
)
)
Hour
)
10 (
Minute
)
9 (
Second
)
15 (

Advertisement

Table of Contents
loading

Table of Contents