557
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
FN
C
160-FN
C
169
R
eal
Ti
m
e
C
loc
k
C
ont
ro
l
22
FN
C
170
-F
N
C
17
9
E
xt
e
rnal
D
evi
ce
23
FN
C
180
Su
b
st.
I
n
str
. I
n
fo
24
FN
C
181-FN
C
189
O
ther
s
25
FN
C
190-FN
C
19
9
B
loc
k D
a
ta
O
per
at
io
n
26
FN
C
200-FN
C
209
C
har
act
e
r St
ring
C
ont
ro
l
27
F
N
C2
10
-F
NC
21
9
Da
ta
O
per
at
ion 3
28
FN
C
220-FN
C
24
9
Da
ta
Co
m
p
a
ris
o
n
29
FN
C
250-FN
C
269
Da
ta
T
a
b
le
O
per
at
io
n
30
FN
C
27
0-F
N
C
274
Ex
-D
ev
ic
e
In
ve
rte
r C
o
mm
s
Program example
1. Example of setting the clock data (time)
In the program example shown below, the real time clock is set (to 15:20:30 on Tuesday, April 25, 2001).
• The shaded area indicates the set value of each item.
• When setting the time, it is recommended to set the time to several minutes ahead in advance, and then
set X000 to ON when the accurate time is reached. The set time is then immediately written to the real
time clock, and the clock data is updated.
• Every time X001 is set to ON, the current time can be corrected by ±30 seconds.
• When handling the year in the 4-digit mode, add the following program.
D8018 will specify the 4-digit year mode in the second scan and later after the PLC mode is changed to
RUN.
- A PLC is normally operating in the 2-digit year mode. When the above instruction is executed and
"K2000 (fixed value)" is transferred to D8018 (year) in only one operation cycle after the PLC mode was
changed to RUN, the year mode is switched to the 4-digit mode.
- Execute this program every time the PLC mode is changed to RUN. Even if "K2000" is transferred, only
the display format is changed to the 4-digit year mode. The current date and time are not affected.
- In the 4-digit year mode, the set values "80 to 99" correspond to "1980 to 1999", and "00 to 79"
correspond to "2000 to 2079".
Examples:
"80" indicates 1980. "99" indicates 1999. "00" indicates 2000. "79" indicates 2079.
• When the data access unit FX-10DU-E is connected, select the 2-digit year mode. If the 4-digit year mode
is selected, the year is not correctly displayed in the current version of the FX-10DU-E.
X000
K1
D0
FNC 12
MOV
D1
K4
FNC 12
MOV
D2
K25
FNC 12
MOV
D3
K15
FNC 12
MOV
D4
K20
FNC 12
MOV
D5
K30
FNC 12
MOV
D6
K2
FNC 12
MOV
FNC167
TWR
D0
Year (lower two digits)
Month
Day
Hour
Minute
Second
Day of week
The current value of the built-in
real time clock is updated.
M8017
X001
The current value is
corrected by ±30 seconds.
M8002
FNC 12
MOV
K2000
D8018
Initial pulse
Содержание FX3U Series
Страница 1: ...PROGRAMMING MANUAL Basic Applied Instructions Edition FX3U FX3UC SERIES PROGRAMMABLE CONTROLLERS ...
Страница 2: ......
Страница 889: ......