The program editor is used to create and link function blocks.
The editor is divided into pages, each page can be considered as a
separate program. To add a new page, switch to Navigation in the right
view, click on the "+" symbol and select Program from the menu.
To add a function block, select the block in the left-hand window
"Function blocks" and drag it to the new page. Above there is also a
search function to find modules more easily. Tip: The view can be
enlarged with the zoom function in the toolbar or with Ctrl + mouse
wheel.
The function blocks can only be processed if the processing mode is switched off:
If the operating mode is activated, the changes are transferred to
the controller and activated. In this mode only the parameters of the
function blocks can be changed, but no new ones can be added or deleted.
Color of the title:
The title of the function blocks indicates the current state by its color:
White: Neutral, the block
is not disabled and there is no connection to the controller.
Green: The block is
running in the controller and the first debug data has been received
(operating mode active and connected to the controller).
Red: The block or the
page is disabled, or there is a license error.
Click on the function block to change the view:
The properties are displayed on the left and the variables and
inputs/outputs of the block on the right. By clicking on the page
background, the view changes back to the selection of function blocks.
The properties window is divided into two areas:
The upper area displays the properties of the page, the lower area displays the properties of the function block. See general parameters.
There are two ways to link a variable at the input of a function block:
Drag the variable from the variable window to the input or output of the function block.
Drag the variable from the Variable window into the Connections window.
Inputs and outputs of the function blocks can also be connected
internally without variables. To do this, click on the output of the
first block (a cross is displayed as the mouse cursor) and then on the
input of the next block. This is also possible across pages. To do
this, click on the output again, then switch to the target page and
click on the input.
An output can also be linked to several inputs. Conversely, it is
not possible to link several outputs to one input. If another output is
linked to the same input, the previous link is deleted. To delete a
connection, click with the right mouse button on a corresponding
input-output of the function block.
Alternatively, you can right-click the icon in the
Connections window:
Tip: It is also possible to link several inputs and outputs at the
same time via the Connections window. To do this, select several
variables in the variable window and drag them into the window with the
links, the variables will then be linked in sequence.