FB_BAFSunblindSuntracking

FB_BAFSunblindSuntracking 1:

Function-block for controlling a Shading as a function of the position of the sun directly out of the PLC-program.

VAR_INPUT

uiId                     : UINT;
bStartExecution          : BOOL;
bStopExecution           : BOOL;
bSafetyPositionSet       : BOOL;
bSafetyPositionReset     : BOOL;
bUp                      : BOOL;
bDown                    : BOOL;
bStop                    : BOOL;
bStepUp                  : BOOL;
bStepDown                : BOOL;
bSetPositionAngleDirect  : BOOL;
lrSetPositionDirect      : LREAL;
lrSetAngleDirect         : LREAL;
bSetControlMode          : BOOL;
iSetControlMode          : INT;
bDriveToFavoritePosition : BOOL;

uiId: Object id of the instance (see object id).

bStartExecution: Starts the instance of the sunblind.

bStopExecution: Stops the instance of the sunblind.

bSafetyPositionSet: All blind drives in the assigned blind drive group (see parameter uiBlindDriveGroupId) will move to their safety-positions.

bSafetyPositionReset: All blind drives in the assigned blind drive group are released do move from their safety-positions.

bUp: All blind drives in the assigned blind drive group will move up.

bDown: All blind drives in the assigned blind drive group will move down.

bStop: All blind drives in the assigned blind drive group will stop moving.

bStepUp: The bStepUp-command for the assigned blind drive group will be sent.

bStepDown: The bStepDown-command for the assigned blind drive group will be sent.

bSetPositionAngleDirect: The sunblind will be moved to the angle entered under lrSetAngleDirect. As the BA-Framework-element Standard Blind Drive does not support angle-driving functionality - unlike Blind Drive connected with KL2532 - this command will only influence the position.

lrSetPositionDirect: See bSetPositionAngleDirect. 0% means fully opened, 100% means completely closed.

lrSetAngleDirect: See bSetPositionAngleDirect.

bSetControlMode: Sets the sunblind into the control mode given under iSetControlMode.

iSetControlMode: See bSetControlMode.

bDriveToFavoritePosition: Drives the sunblind to the favourite position.

VAR_OUTPUT

uiErrorId                : UINT;
iErrorParameter          : INT;
eExecutionState          : E_BAF_ExecutionState;
lrAveragePosition        : LREAL;
iTypeOfSeason            : INT;
bMotionDetection         : BOOL;
lrOutdoorBrightness      : LREAL;
lrRoomTemperature        : LREAL;

uiErrorId: Contains the error code of the last executed command (see Error codes).

iErrorParameter: Contains the specific parameter of the error code (see Error codes).

eExecutionState: Contains the actual execution state of the instance of the lighting.

lrAveragePosition: The average position (0% - 100%) of the assigned blind drive group.

iTypeOfSeason: Shows the actual operating-mode: (0: undefined ; 1: winter-mode ; 2: summer-mode).

bMotionDetection: Indicates if motion was detected.

lrOutdoorBrightness: Represents the outdoor brightness.

lrRoomTemperature: Shows the room temperature.