FB_BA_SunblindZone
In a blind zone, one or more blinds are combined for simultaneous control. The template FB_BA_SunblindZone bundles the predefined data of the facades and decides on the basis of a zone presence detection and local selection and deselection which functionality is active.
Together with the resulting telegram of high-priority functions from the facade, these functionalities are placed on a telegram selector at the end of the template. This then uses the priority to decide which telegram in the higher-level room template is passed on to the blinds.
Functions
- Manual function
The zone template contains a manual function that enables manual control of the blind via the key functions bSwiUp/bSwiDwn. The switchover time to latching, nSwiOverTi [ms], is pre-parameterized to 250 ms. The manual function is deleted via input bRstManFnct. - Thermal automatic
Thermal automatic is considered active if it is selected locally (parameter bThAutoSlcn), if no presence is detected (input bPrcDetc) and the facade template FB_BA_Facade has determined the enable for this building side. If it is active, the positioning is decided on the basis of the room temperature (input fRoomTempSen) and the building setpoints for heating and cooling: If the room temperature is above the building value for comfort cooling, the blinds move to a predefinable position. If, on the other hand, the temperature drops below the value for comfort heating, the blinds will open completely. - Automatic sun protection
In contrast to the thermal automatic, the automatic sun protection is only active when presence is detected (input bPrcDetc). It must also be selected locally (parameter bSunPrtcSlcn) and be enabled by the facade template, among other things by the direction-dependent brightness. The blind position and angle are also determined in the facade. - Twilight automatic
The twilight automatic is enabled in the facade on the basis of the brightness values. If the automatic for the zone is selected (input bTwiLgtAutoSlcn) the blind moves to a predefined position in case of twilight (parameter fTwiLgtAutoPos/fTwiLgtAutoAngl).
Input stReferenceFeedback
Information about the controlled blind actuator or the reference actuator of a group is fed back into the blind control function via this input.
These are the position details and status of the reference actuator.
Data exchange HMI
The data exchange with the HMI is realized here in the base class FB_BA_Ext_SunblindAngle (internal function block). The use of the following variables is visible in this template:
- bResetManual_In: Command from the HMI to delete the manual function.
- fSunblindPosition_Out: Output information position to the HMI.
- fSunblindAngle_Degree: Output information angle in degrees to the HMI.
- bOpened_Out: Output information "Blind completely open" to the HMI.
- bClosed_Out: Output information "Blind completely closed" to the HMI.
- bErr_Out: Output information "Reference actuator faulty" to the HMI.
- eActualPrio_Out: Currently controlling telegram priority to the HMI.
The initialization of the template takes place within the method FB_Init. |
Block diagram
Syntax
FUNCTION_BLOCK FB_BA_SunblindZone EXTENDS FB_BA_Ext_SunblindAngle
VAR_INPUT
fRoomTempSen : REAL;
bPrcDetc : BOOL;
bSwiUp : BOOL;
bSwiDwn : BOOL;
bRstManFnct : BOOL;
stBuildingSpRmT : ST_BA_SpRmT;
stFacade : ST_BA_Facade;
stScene : ST_BA_Sunbld;
stReferenceFeedback : ST_BA_SunblindActuatorFeedback;
END_VAR
VAR_OUTPUT
stSunBldOut : ST_BA_SunBld;
END_VAR
VAR_INPUT CONSTANT PERSISTENT
bThAutoSlcn : BOOL;
fThAutoColPos : REAL;
fThAutoColAngl : REAL;
bSunPrtcSlcn : BOOL;
bTwiLgtAutoSlcn : BOOL;
fTwiLgtAutoPos : REAL;
fTwiLgtAutoAngl : REAL;
nSwiOverTi : UDINT;
END_VAR
VAR_INPUT CONSTANT
ManSwi : FB_BA_SunBldSwi := (ePrio:= E_BA_SunBldPrio.eManualGroup);
ThAuto : FB_BA_SunBldEvt := (ePrio:= E_BA_SunBldPrio.eGroupThermoAuto);
SunPrtc : FB_BA_SunBldEvt := (ePrio:= E_BA_SunBldPrio.eSunProtection);
TwiLgtAuto : FB_BA_SunBldEvt := (ePrio:= E_BA_SunBldPrio.eGroupTwiLightAuto);
END_VAR
VAR
ThAutoSwi : FB_BA_Swi2P;
PrioSwi : FB_BA_SunBldTgmSel8;
EnSunBldSwi : SR;
END_VAR
Inputs
Name | Type | Description |
---|---|---|
fRoomtempSen | REAL | Room temperature sensor [°C]. |
bPrcDetc | BOOL | Presence detection. |
bSwiUp | BOOL | Local push button "up". |
bSwiDwn | BOOL | Local push button "down". |
bRstManFnct | BOOL | Input for resetting all internal manual functions, both those via the inputs bSwiUp/bSwiDwn, and external control (e.g. HMI). |
stBuildingSpRmT | Structure of room setpoints (Protection Cooling..Comfort Cooling and Protection Heating ... Comfort Heating). | |
stFacade | Facade-specific blind data and telegrams. | |
stScene | Reserved telegram input for scene control. | |
stReferenceFeedback | Feedback input of the controlled blind actuator or the reference actuator of the controlled group. |
Inputs CONSTANT PERSISTENT
Name | Type | Description |
---|---|---|
bThAutoSlcn | BOOL | Thermal automatic enable. |
fThAutoColPos | REAL | Thermal automatic cooling position [%]. |
fThAutoColAngl | REAL | Thermal automatic cooling angle [°]. |
bSunPrtcSlcn | BOOL | Shading automatic enable. |
bTwiLgtAutoSlcn | BOOL | Twilight automatic enable. |
fTwiLgtAutoPos | REAL | Twilight automatic position [%]. |
fTwiLgtAutoAngl | REAL | Twilight automatic position [°]. |
nSwiOverTi | UDINT | Changeover time [ms] of the manual switch SunBldSwi for latching. |
Inputs CONSTANT
Name | Type | Description |
---|---|---|
ManSwi | Group (zone) push button block. | |
ThAuto | Telegram block for group (zone) thermal automatic. | |
SunPrtc | Telegram block for group (zone) shading automatic. | |
TwiLgtAuto | Telegram block for group (zone) twilight automatic. |
VAR
Name | Type | Description |
---|---|---|
ThAutoSwi | Hysteresis block for heating/cooling changeover for group (zone) thermal automatic. | |
PrioSwi | Selection of the resulting telegram. | |
EnSunBldSwi | SR | Activation memory of the above mentioned function block. |
Requirements
Development environment | Necessary function |
---|---|
TwinCAT from v3.1.4024.35 | TF8040 | TwinCAT Building Automation from V5.0.0.0 |