129
CHAPTER 3 FUNCTIONS
3
3.5 Clock Function
(b) Reading clock data
To read clock data to the data register, use either of the following instructions in the program.
• DATERD (instruction for reading clock data)
• S(P).DATERD (instruction for reading extended clock data)
The following figure shows a program for storing clock data that are read using the DATERD instruction to D10
to D16.
*1 The following figure shows the clock data stored in D10 to D16.
For details of the DATERD and S(P).DATERD instructions, refer to the following.
MELSEC-Q/L Programming Manual (Common Instruction)
Clock data can also be written or read by the special relay (SM210 to SM213) and special register (SD210 to SD213). For
details of the special relay and special register, refer to the following.
QCPU User's Manual (Hardware Design, Maintenance and Inspection).
Read request
X1
DATERD
D10
Stores clock data to D10
to D16.
*1
D10
D11
D12
D13
D14
D15
D16
2004
4
1
11
35
24
2
Year (four digits)
Month
Date
Hour
Minute
Second
Day of the week
( Page 127, Section 3.5 (2))