Program example FB_BARSunblindSwitch
This example is intended to show how a possible activation (input bEnable) of the manual blind controller might look. The input and output variables (bordered) have the following meaning:
tAutoResetTime : time after which the activation is to be automatically reset.
bSwitchUp : blind up button.
bSwitchDown : blind down button.
bPauseClock : pause signal of the property, e.g. lunch break: 12:00-13:00. bPauseClock = TRUE: pause.
bPresenceDetection : occupied message of the room in which the blinds are controlled. bPresenceDetection= TRUE: room is occupied.
uiSwitchOverTime : time in milliseconds until the corresponding manual command latches in the case of a continuous active command input.
stSunblind: positioning telegram, see ST_BARSunblind. For further linking to a priority selection, see FB_BARSunblindPrioritySwitch.
Functioning
If one of the blind buttons bSwitchUp or bSwitchDown is actuated, the output of the flip-flop will initially be set to TRUE, but only if there is currently no pause signal applied (bPauseClock) or if the room is currently occupied (bPresenceDetection). The bEnable input of the function block fbBARSunblindSwitch is thus TRUE, which activates it. The respective push button signal which has led to the activation can be passed on by the function block directly in the command telegram stSunblind.
At the same time, a TRUE signal is present at the input of the switch-off delay tofAutoResetTimer and its output Q is immediately set to TRUE. On releasing the blind button the switch-off delay is started, and after the expiry of tAutoResetTime the output Q is reset to FALSE. This falling edge is in turn recognized by ftAutoResetTimer and a trigger pulse is sent that resets the flip-flop. The activation input bEnable is thus FALSE once again and the function block fbBARSunblindSwitch is passive.
If this function block is linked via the command telegram to a priority selection FB_BARSunblindPrioritySwitch, then the telegram will be passed through there to the next priority: