Holiday
Holiday (FB)
Holiday (FB)FUNCTION_BLOCK Holiday
Short description
Definition of 10 holiday periods (= channels) with switch-on and switch-off dates. Typical application: clock system
Representation

Interfaces
Inputs
xEN
BOOL
Enable / disable the holiday periods (FALSE = disabled, TRUE = enabled)
Outputs
xActive
BOOL
State of the holiday periods (FALSE = not active, TRUE = active)
datActiveFrom
DATE
Switch-on date of the last active holiday period (channel 10 = highest priority)
datActiveTo
DATE
Switch-off date of the last active holiday period (channel 10 = highest priority)
Setpoints / parameters
xCh10_Mode
BOOL
TRUE
Enable / disable channel 10 (FALSE = disabled, TRUE = enabled)
datCH10_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 10
datCH10_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 10
sCH10_Notice
STRING
‘Notice’
Label for channel 10
xCh9_Mode
BOOL
TRUE
Enable / disable channel 9 (FALSE = disabled, TRUE = enabled)
datCH9_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 9
datCH9_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 9
sCH9_Notice
STRING
‘Notice’
Label for channel 9
xCh8_Mode
BOOL
TRUE
Enable / disable channel 8 (FALSE = disabled, TRUE = enabled)
datCH8_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 8
datCH8_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 8
sCH8_Notice
STRING
‘Notice’
Label for channel 8
xCh7_Mode
BOOL
TRUE
Enable / disable channel 7 (FALSE = disabled, TRUE = enabled)
datCH7_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 7
datCH7_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 7
sCH7_Notice
STRING
‘Notice’
Label for channel 7
xCh6_Mode
BOOL
TRUE
Enable / disable channel 6 (FALSE = disabled, TRUE = enabled)
datCH6_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 6
datCH6_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 6
sCH6_Notice
STRING
‘Notice’
Label for channel 6
xCh5_Mode
BOOL
TRUE
Enable / disable channel 5 (FALSE = disabled, TRUE = enabled)
datCH5_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 5
datCH5_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 5
sCH5_Notice
STRING
‘Notice’
Label for channel 5
xCh4_Mode
BOOL
TRUE
Enable / disable channel 4 (FALSE = disabled, TRUE = enabled)
datCH4_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 4
datCH4_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 4
sCH4_Notice
STRING
‘Notice’
Label for channel 4
xCh3_Mode
BOOL
TRUE
Enable / disable channel 3 (FALSE = disabled, TRUE = enabled)
datCH3_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 3
datCH3_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 3
sCH3_Notice
STRING
‘Notice’
Label for channel 3
xCh2_Mode
BOOL
TRUE
Enable / disable channel 2 (FALSE = disabled, TRUE = enabled)
datCH2_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 2
datCH2_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 2
sCH2_Notice
STRING
‘Notice’
Label for channel 2
xCh1_Mode
BOOL
TRUE
Enable / disable channel 1 (FALSE = disabled, TRUE = enabled)
datCH1_DateFrom
DATE
DATE#2019-1-1
Switch-on date channel 1
datCH1_DateTo
DATE
DATE#2019-1-1
Switch-off date channel 1
sCH1_Notice
STRING
‘Notice’
Label for channel 1
Function description
General
This function block evaluates up to 10 freely definable holiday periods (= channels). If evaluation is generally enabled (xEN = TRUE), then for all activated holiday periods (xChX_Mode = TRUE, 0 < X < 11) it is checked whether the current date lies within the holiday period. If this is the case for at least one activated holiday period, the output xActive is activated (= TRUE). In all other cases the output xActive is deactivated (= FALSE). If the switch-off date is earlier than the switch-on date (channels 1 - 10), the switch-off date is internally set equal to the switch-on date. If the switch-on and switch-off date of a channel (channels 1 - 10) are identical, that day is considered a holiday. datActiveFrom or datActiveTo At the outputs xEN are available (requirement:
Prerequisite for using the function block Holiday
The use of the TimeRead2 function block is required for correct operation.
Visualization
Matching visualization element from the HVACV Visu Library: Holidays
Representation
Interfaces Visu-Element
FB_Holiday
Holiday
VAR_IN_OUT
Enter FB Holiday here e.g. PRG.Holiday
BMS_Active
BOOL
VAR_INPUT
BMS (Building Management System) GLT (building management). If BMS_Active = TRUE the input/editing of the clocks is disabled because they can then only be set via the BMS. Times can then only be viewed.
DisableInput
BOOL
VAR_INPUT
DisableInput = TRUE times of the weekly clocks can only be viewed and not edited./// - BMS (Building Management System) GLT (building management). If BMS_Active = TRUE the input/editing of the clocks is disabled because they can then only be set via the BMS. Times can then only be viewed.
Note: VAR_IN_OUT interfaces must be assigned, VAR_INPUT are optional.
CODESYS
InOut:
Input
xEn
BOOL
Input Const
sCH1_Notice
STRING
‘Notice’
Input Const
datCH1_DateTo
DATE
DATE#2022-1-1
Input Const
datCH1_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH1_Mode
BOOL
TRUE
Input Const
sCH2_Notice
STRING
‘Notice’
Input Const
datCH2_DateTo
DATE
DATE#2022-1-1
Input Const
datCH2_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH2_Mode
BOOL
TRUE
Input Const
sCH3_Notice
STRING
‘Notice’
Input Const
datCH3_DateTo
DATE
DATE#2022-1-1
Input Const
datCH3_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH3_Mode
BOOL
TRUE
Input Const
sCH4_Notice
STRING
‘Notice’
Input Const
datCH4_DateTo
DATE
DATE#2022-1-1
Input Const
datCH4_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH4_Mode
BOOL
TRUE
Input Const
sCH5_Notice
STRING
‘Notice’
Input Const
datCH5_DateTo
DATE
DATE#2022-1-1
Input Const
datCH5_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH5_Mode
BOOL
TRUE
Input Const
sCH6_Notice
STRING
‘Notice’
Input Const
datCH6_DateTo
DATE
DATE#2022-1-1
Input Const
datCH6_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH6_Mode
BOOL
TRUE
Input Const
sCH7_Notice
STRING
‘Notice’
Input Const
datCH7_DateTo
DATE
DATE#2022-1-1
Input Const
datCH7_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH7_Mode
BOOL
TRUE
Input Const
sCH8_Notice
STRING
‘Notice’
Input Const
datCH8_DateTo
DATE
DATE#2022-1-1
Input Const
datCH8_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH8_Mode
BOOL
TRUE
Input Const
sCH9_Notice
STRING
‘Notice’
Input Const
datCH9_DateTo
DATE
DATE#2022-1-1
Input Const
datCH9_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH9_Mode
BOOL
TRUE
Input Const
sCH10_Notice
STRING
‘Notice’
Input Const
datCH10_DateTo
DATE
DATE#2022-1-1
Input Const
datCH10_DateFrom
DATE
DATE#2022-1-1
Input Const
xCH10_Mode
BOOL
TRUE
Output
xActive
BOOL
Output
datActiveFrom
DATE
Output
datActiveTo
DATE
Last updated

