Mitsubishi MELSEC-Q/L Programming Manual page 581

Table of Contents

Advertisement

7.15.5
SECOND, SECONDP
Time data conversion (from Hour/Minute/Second to
Second)
7.15.5
SECOND, SECONDP
SECOND
SECONDP
: Head number of the devices where the clock data before conversion is stored (BIN 16 bits)
S
: Head number of the devices where the clock data after conversion will be stored (BIN 32 bits)
D
Internal Devices
Setting
Data
Bit
Word
––
S
D
Function
(1) Converts the time data stored in the area starting from the device designated by
result into the device designated by
For example, if the value were 4 hours, 29 minutes, and 31 seconds, the conversion would be made as follows:
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into
SD0.
Error
code
4100
The value set for
is not within the setting range.
S
The range of the device specified by
4101
corresponding device.
Program Example
(1) The following program converts the clock time data read from the clock element into second when X20 is turned ON, and
stores the result at D100 and D101.
[Ladder Mode]
Command
Command
J
\
R, ZR
Bit
Word
.
D
Data range
S
Hour
(0 to 23)
S
+1
Minute
(0 to 59)
S
Second
(0 to 59)
+2
S
4
+1
S
29
S
31
+2
Error details
exceeds the range of the
S
[List Mode]
Step
SECOND, SECONDP
High
Basic
Process
performance
S
SECOND
SECONDP
S
Zn
U
\G
––
to seconds and stores the conversion
S
D
+1
D
Second
D
1
D
16171
Q00J/
Q00/
QnH
QnPH QnPRH
Q01
––
––
––
––
––
––
Instruction
Device
Redundant Universal
LCPU
D
D
Constants
Other
––
––
QnU
LCPU
––
––
579
1
2
3
4
4
6
7
8

Advertisement

Table of Contents
loading

Table of Contents