Mitsubishi Electronics FXCPU Video Game Controller User Manual


 
21 Applied Instructions (Real Time Clock Control)
21.6 STOH / Second to Hour Conversion
555
FXCPU Structured Programming Manual
[Basic & Applied Instruction]
21
Applied Instructions
(Real Time
Clock Control)
22
Applied Instructions
(External Device)
23
Applied Instructions
(Extension
Function)
24
Applied Instructions
(Others)
25
Applied Instructions
(Block Data
Operation)
26
Applied Instructions
(Character
String Control)
27
Applied Instructions
(Data Operation 3)
28
Applied Instructions
(Data Comparison)
29
Applied Instructions
(Data Table
Operation)
30
Applied Instructions
(External Device
Communication)
Function and operation explanation
1. 16-bit operation
The second unit data of the device specified by is converted into "hour, minute, second" unit, and the
result is stored in the device specified by .
For example, when 29011 seconds is specified, the operation is as follows.
2. 32-bit operation
The second unit data of the device specified by is converted into "hour, minute, second" unit, and the
result is stored in the device specified by .
For example, when 45325 seconds is specified, the operation is as follows.
Error
In the following case, it is an operation error, and the error flag (M8067) is turned ON, and the error code is
stored in D8067.
1) When the data of the device specified by is out of the range. (Error code: K6706)
STOH
EN
s
ENO
d
Command
input
Device for storing the time data in
second unit before conversion
Device for storing the time data in "hour, minute, second"
unit after conversion
hour
minute
second
+1
+2
(0 to 9)
(0 to 59)
(0 to 59)
second (0 to 32767)
s
d
d
d
d
8
3
31
+1
+2
29011
s
d
d
DSTOH
EN
s
ENO
d
Device for storing the time data in
second unit before conversion
Command
input
Device for storing the time data in "hour, minute, second"
unit after conversion
hour
minute
second
+1
+2
(0 to 32767)
(0 to 59)
(0 to 59)
second (0 to 117964799)
+1
s
d
d
d
s
12
35
25
+1
+2
45325
+1
d
d
d
ss