Documentation

GETDSTOFFSET

Time shift summer/winter time

Function name

GETDSTOFFSET

ST call

PROGRAM GETDSTOFFSET_DEMO
VAR
TIME_OUT: TIME;
END_VAR
TIME_OUT:=GETDSTOFFSET(T:=GETLOCALTIME());
END_PROGRAM

Description

The block returns the time difference between standard zone time and zone daylight saving time. The output is 0 h at winter time, and 1 h at summer time for central Europe. The change takes place at midnight.

Inputs

Input Type Description
T DT Input date and time

Outputs

Output Type Description
=> TIME Output value

Application example