<< Click to Display Table of Contents >> Navigation: »No topics above this level« Function blocks (IEC ST) |
mapp Services V5.16
The definition of a function block includes its implementation. A pure declaration without implementation is used to map external function blocks.
VAR_INPUT
SET : BOOL; // Sets output Q
RESET : BOOL; // Resets output Q (priority)
END_VAR
VAR_OUTPUT
Q : BOOL; // Output value
END_VAR
Q := NOT RESET AND (SET OR Q);
END_FUNCTION_BLOCK
The scope of declared function blocks is determined according to the file extension and the most recent #pragma SCOPE.
Topics in this section: