Command: Interface Editor
Symbol: , Shortcut: Alt+F6
Function: The command opens and closes the Interface Editor tab above the visualization editor.
Call: menu Also by clicking on the small down arrow at the top of the visualization editor
Tab: Interface Editor
Symbol:
The tab provides an editor for the declaration of interface variables. The editor behaves in a similar way to the declaration editor of a function block, however interface variables do not have an initialization.
Syntax
<scope> {attribute ' <attribute name> ' := ' <expression> '} <variable name> : <data type>; END_VAR
Syntax | Description |
---|---|
| Scope: |
| Optional Attribute pragma |
| Optional Attribute value (parameter) |
| Declaration of the interface variables NoteInterface variables do not have an initialization. |
Declaration in the interface editor
VAR_INPUT {attribute 'parameterstringof'} sIdentifier : STRING; // String for instance name iCounter : INT; END_VAR VAR_IN_OUT {attribute 'VAR_IN_OUT_AS_POINTER'} fbController: FB_Controller; END_VAR
Scopes
Possible scopes for interfaces of visualizations or dialogs
|
NoteIn the case of dialogs, the data is written back only when the dialog is closed. TipHint: We strongly recommend that you use this scope so that the return of values is possible. Moreover, no data needs to be copied. |
Pragma | When transferring a pointer to a data object In contrast to the NoteHint: We strongly recommend that you use this scope so that the return of values is possible. Moreover, no data needs to be copied. |
| When transferring data that will only be read Note
|
Pragma | When transferring a variable (data type |