Mitsubishi Electric FX3G SERIES Programming Manual page 577

Programmable controllers
Hide thumbs Also See for FX3G SERIES:
Table of Contents

Advertisement

FX
/FX
/FX
Series Programmable Controllers
3G
3U
3UC
Programming Manual - Basic & Applied Instruction Edition
2. 32-bit operation (DSTOH and DSTOHP)
The time data in units of "second" stored in
second", and stored to three devices
Command
input
FNC165
DSTOH
S
+1
S
Second
For example, when "45,325 seconds" is specified, the operation is as follows:
S
+1
S
45325
Error
An operation error is caused in the following case; The error flag M8067 turns ON, and the error code is store in
D8067.
• When the data of
Program example
In the program shown below, the time data in units of "second" stored in D0 and D1 is converted into data in units of
"hour, minute, and second", and stored to D100, D101, and D102 when X020 turns ON.
X020
Operation
• Converting the data in second into the data in hour, minute and second using STOHP instruction
(when "40,000 seconds" is specified by D1 and D0)
D1,D0
S
D
,
S
D
(0 to 117964799)
D
D
+1
D
+2
is outside the allowable range (error code: K6706)
S
FNC165
D0
DSTOH
D100
40000
D101
D102
21 Real Time Clock Control – FNC160 to FNC169
21.6 FNC165 – STOH / Second to Hour Conversion
+1 and
S
is converted into data in units of "hour, minute, and
D
+1, and
D
+2 (hour, minute, and second).
D
Hour
D
+1
Minute
D
+2
Second
12
35
25
D100
END
11
6
40
(0 to 32767)
(0 to 59)
(0 to 59)
21
22
23
24
25
26
27
28
29
30
575

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fx3u seriesFx3uc series

Table of Contents