EasyManua.ls Logo

Siemens S7-1200 - SET_TIMEZONE (Set Timezone) Instruction

Siemens S7-1200
1028 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Extended instructions
8.1 Date, time-of-day, and clock functions
S7-1200 Programmable controller
290 System Manual, 03/2014, A5E02486680-AG
8.1.4
SET_TIMEZONE (Set timezone) instruction
Table 8- 11 SET_TIMEZONE instruction
LAD / FBD
SCL
Description
"SET_TIMEZONE_DB"(
REQ:=_bool_in,
Timezone:=_struct_in,
DONE=>_bool_out_,
BUSY=>_bool_out_,
ERROR=>_bool_out_,
STATUS=>_word_out_);
Sets the local time zone and daylight
saving parameters that are used to
transform the CPU system time to local
time.
1
In the SCL example, "SET_TIMEZONE_DB" is the name of the instance DB.
Table 8- 12 Data types for the parameters
Parameter and type
Data type
Description
REQ
IN
Bool
REQ=1: execute function
Timezone IN TimeTransformationRule Rules for the transformation from system time to
local time
DONE
OUT
Bool
Function complete
BUSY
OUT
Bool
Function busy
ERROR OUT Bool Error detected
STATUS
OUT
Word
Function result / error message
To manually configure the time zone parameters for the CPU, use the "Time of day"
properties of the "General" tab of the device configuration.
Use the SET_TIMEZONE instruction to set the local time configuration programmatically.
The parameters of the "TimeTransformationRule (Page 289)" structure assign the local time
zone and timing for automatic switching between standard time and daylight saving time.
Condition codes:
ENO = 1 means no error occurred. ENO = 0 means an execution error
occurred, and a condition code is provided at the STATUS output.
STATUS
(W#16#....)
Description
0 No error
7000
No job processing active
7001
Start of job processing. Parameter BUSY = 1, DONE = 0
7002
Intermediate call (REQ irrelevant): Instruction already active; BUSY has the value "1".
808x
Error at x-th component: For example 8084 indicates that DaylightStartWeekif is not a value from 1to 5.

Table of Contents

Other manuals for Siemens S7-1200

Related product manuals