![Mitsubishi Electric FX3G SERIES Programming Manual Download Page 579](http://html.mh-extra.com/html/mitsubishi-electric/fx3g-series/fx3g-series_programming-manual_238902579.webp)
577
FX
3G
/FX
3U
/FX
3UC
Series Programmable Controllers
Programming Manual - Basic & Applied Instruction Edition
21 Real Time Clock Control – FNC160 to FNC169
21.8 FNC167 – TWR / Set RTC data
21
FNC160
-F
NC1
69
R
eal
T
ime C
lock
C
ontrol
22
FNC17
0-F
NC
179
E
xternal D
evice
23
FNC
180
Alternate
Instructions
24
FN
C181-
FNC18
9
O
thers
25
FNC190
-F
NC1
99
Bl
oc
k D
ata
Op
er
atio
n
26
FNC20
0-F
NC209
C
har
ac
te
r S
trin
g
Con
tro
l
27
FNC2
10-
FNC21
9
Dat
a
Operati
on 3
28
FNC220
-F
NC2
49
Da
ta
C
omp
ari
son
29
FNC25
0-F
N
C
269
D
ata T
abl
e
Operation
30
FNC2
70-
FNC275
Ex
-Dev
ice
Inverter C
om
m
s
21.8
FNC167 – TWR / Set RTC data
Outline
This instruction writes the clock data to the built-in PLC real time clock.
1. Instruction format
2. Set data
3. Applicable devices
S
: This function is supported only in FX
3U
/FX
3UC
PLCs.
Explanation of function and operation
The clock data stored in
to
+6 is written to D8013 to D8019 for the built-in PLC real time clock.
- D8018 (year data) can be converted into the 4-digit mode. (Refer to the program example shown later.)
- When TWR (FNC167) instruction is executed, the clock data of the real time clock is immediately changed.
Accordingly, transfer the clock data several minutes ahead to
to
+6 in advance, and then execute
FNC167 instruction when the accurate time has come.
- When setting the clock data (time) using this instruction, it is not necessary to control the special auxiliary relay
M8015 (time stop and time setting).
- If a numeric value indicating impossible date/time is set, the clock data is not changed.
Set the correct clock data, and then write it.
Operand type
Description
Data type
Specifies the head device number to which the clock data is written.
(Seven devices are occupied.)
16-bit binary
Oper-
and
Type
Bit Devices
Word Devices
Others
System User
Digit Specification
System User
Special
Unit
Index
Con-
stant
Real
Number
Charac-
ter String
Pointer
X Y M T C S D
.b KnX KnY KnM KnS T C D R U
\G
V
Z Modify K H
E
"
"
P
3 3 3 3
S
3
Device
Item
Clock data
Device
Item
Time dat
a t
o
be s
et
D 10
Year
0 to 99
(lower two digits)
→
D8018
Year
S
p
ec
ia
l d
at
a
re
gi
st
er
D 11
Month
1 to 12
→
D8017
Month
D 12
Day
1 to 31
→
D8016
Day
D 13
Hour
0 to 23
→
D8015
Hour
D 14
Minute
0 to 59
→
D8014
Minute
D 15
Second
o to 59
→
D8013
Second
D 16
Day of week
0 (Sunday) to
6 (Saturday)
→
D8019
Day of week
P
FNC 167
TWR
−
Mnemonic
Operation Condition
16-bit Instruction
3 steps TWR
TWRP
Mnemonic
Operation Condition
Continuous
Operation
Pulse (Single)
Operation
32-bit Instruction
S
S
S
S
Command
input
FNC167
TWRP
S
S
S