FE MONITOUCH V8 SERIES Reference: Additional Functions page 382

Table of Contents

Advertisement

Conversion
CLND_TO_GRE F0 F1 F2
Function: Conversion from calendar data to GMT-based UNIX time
This macro is used to convert the calendar data [F1] in format [F2] to the UNIX time based on GMT,
and to store the converted result in [F0].
Calendar data
F1
Available memory
Internal Memory
F0
F1
F2
Range
F0
Time data 0
Time data 1
F0 + 1
F1
4 or 2 digits: Year
F1 + 1
1 to 12: Month
F1 + 2
1 to 31: Day
F1 + 3
0 to 23: Hour
F1 + 4
0 to 59: Minutes
F1 + 5
0 to 59: Seconds
0: DEC
F2
1: BCD
Example
The calendar data in $u200 - $u205 in DEC format, 17 (hour):25 (minutes):10 (seconds) on June 10 in
2010, is converted to the GMT-based UNIX time, and the converted result is stored in $u100 and
$u101.
$u200 = 2010 (W)
$u201 = 6 (W)
$u202 = 10 (W)
$u203 = 17 (W)
$u204 = 25 (W)
$u205 = 10 (W)
$u300 = 0 (W)
CLND_TO_GRE $u100 $u200 $u300
The GMT-based UNIX time "1276190710 seconds" is obtained.
Time data 0 → $u100 = 8182 DEC
Time data 1 → $u101 = 19473 DEC
GMT-based UNIX time
F0
CLND_TO_GRE
PLC1 - PLC8
Memory
: Setting enabled (indirect designation disabled)
: Setting enabled (indirect designation enabled)
Value
Time data 1
UNIX time since January 1, 1970 GMT
Memory Card
Constant
DEC only
Time data 0
Data format
for [F1]
: ← V series (Return data)
23
Macro
23
Remarks
23-13

Advertisement

Table of Contents
loading

Table of Contents