PLC-API Requirements 5.2.3 FB_CTRL_LOOP_SCHEDULER This function block allows the system loading to be distributed over a number of control loops that are a) parameterised using the same tCtrlCycleTime and b) for which the condition tCtrlCycleTime > tTaskCycleTime is true. The output vector calculated by this block is used to start the individual control loops at different times, so that the system loading is distributed. Behavior of the output vector: 6 control loops are managed in this diagram. In this case, tCtrlCycleTime = 7 · tTaskCycleTime. The programmer must create the following array in the PLC if this function block is to be used: arrOutputVector :
ARRAY[1..nNumberOfControlLoops] OF BOOL; The function block sets the bits in this vector to TRUE or FALSE. The control loops that are managed with the loop scheduler are to be switched into the eCTRL_MODE_ACTIVE state when the corresponding bit in the output vector is TRUE. See sample code below. TS4100 22 Version: 1.1 Development environment Target system type PLC libraries to be linked TwinCAT v2.8 PC (i386) TcControllerToolbox.lib