Editors Example: Insert "struvar." -> the components of structure struct1 will be offered 5.1 Declaration Editor The declaration editor is used to declare variables of POUs and global variables, for data type declarations, and in the Watch and Recipe Manager. It gives access to the usual Windows functions, and even those of the IntelliMouse can be used if the corresponding driver is installed. In Overwrite mode, 'OV' is shown in black on the status bar; switching between Overwrite and Insert modes can be accomplished with the key. The declaration of variables is supported by syntax coloring. The most important commands are found in the context menu (right mouse button).
Declaration Part All variables to be used only in this POU are declared in the declaration part of the POU. These can include: input variables, output variables , in-put/output variables, local variables, retain variables, and constants. The declaration syntax is based on the IEC1131-3 standard. An example of a correct declaration of variables in TwinCAT PLC Control-Editor: Declarationeditor Input Variable Between the key words VAR_INPUT and END_VAR, all variables are declared that serve as input variables for a POU. That means that at the call position, the value of the variables can be given along with a call. Example: VAR_INPUT in1:INT; (* 1.
Inputvariable*) END_VAR Output Variable TX1200 116 Version: 1.3