Time switch based on the S7-300/400 CPUs with simple HMI system
including radio-controlled clock connection
Rev. B - final 19.07.2002 29/84
Copyright © Siemens AG 2005 All rights reserved
BID21669756_Zeitschaltuhr_einfach_DOKU_v20_e.doc
4.3 STEP7 application level
Fig. 4-2 “STEP7 program overview“ gives you all the various elements of
the STEP7 program. The individual blocks are described in more detail in
the following sub-chapters.
Note
If certain blocks are not required, these can be removed from the displayed
program structure. This does not affect other blocks (“modular principle of
individual functions”).
Note
The function blocks have an exemplary, given numbering which can be changed.
OB1
call summer
winter FB103 FB103
prüfe, ob Sommer-/Winterzeit-
umschaltungstattgefunden hat
DB103
InstanzDBzu FB103
call day FB120
FB120
prüfe, ob aktuelle Zeit impara-
metriertenZeitraum liegt
DB120
InstanzDBzu FB120
call weekFB121
FB121
prüfe, ob aktuelle Zeit impara-
metriertenZeitraum liegt
DB121
InstanzDBzu FB121
call monthFB122
FB122
prüfe, ob aktuelle Zeit impara-
metriertenZeitraum liegt
DB122
InstanzDBzu FB122
call yearFB123
FB123
prüfe, ob aktuelle Zeit impara-
metriertenZeitraum liegt
DB123
InstanzDBzu FB123
call relativ FB124
FB124
prüfe, ob aktuelle Zeit impara-
metriertenZeitraum liegt
DB124
InstanzDBzu FB124
call check_holidaysFC100
FC100
prüfe, ob aktuelles Datum ein
Feiertag oder Sondertag ist
DB100
DB mit Feier- und Sondertagen
Additional functions
Absolute
ime switching functions
Relative
ime switching function
(Kapitel 4.3.3.1)
(Kapitel 4.3.3.2)
(Kapitel 4.3.1.1)
(Kapitel 4.3.1.2)
(Kapitel 4.3.1.3)
(Kapitel 4.3.1.4)
(Kapitel 4.3.2)
OB1
call summer
winter FB103 FB103
check whether summer/winter
time changeover occurred
DB103
InstancDBto FB103
call day FB120
FB120
check whether current time is
within parameterized range
DB120
Instance DBto FB120
call weekFB121
FB121
check whether current time is
within parameterized range
DB121
InstancDBto FB121
call monthFB122
FB122
check whether current time is
within parameterized range
DB122
InstancDBto FB122
call yearFB123
FB123
check whether current time is
within parameterized range
DB123
InstancDBto FB123
call relativ FB124
FB124
check whether current time is
within parameterized range
DB124
InstancDBto FB124
call check_holidaysFC100
FC100
check whether current date is
holiday or special day
DB100
DB with holiday/special days
(Chapter 4.3.3.1)
(Chapter 4.3.3.2)
(Chapter 4.3.1.1)
(Chapter 4.3.1.2)
(Chapter 4.3.1.3)
(Chapter 4.3.1.4)
(Chapter 4.3.2)
Fig. 4-2 STEP7 program overview