Section 3 Parameter Interface Parameter for Control Modules and Diagrams
3BSE042835-600 29
The differences between the four types include the different access rules from the
code inside the control module and the limitations for connecting the parameters:
• In parameters can only be read, where as Out, In_Out and Unspecified
parameters can be both read and written.
•The In parameter of
a sub control module can be connected to either the
In parameter or the Ou
t parameter in the surrounding control module.
Between control modules on t
he same level, it is only allowed to connect In to
Out. Several In parameters can be connected to one Out (if it is not a structured
type containing a reverse attribute). In_Out must be connected to a variable (on
any level).
These rules also apply to connecting parameters to
communication variables.
The in communication variable should be connected to In parameters and the
out communication variable should be connected to Out parameters only.
• U
nspecified parameters can be used without limitations when connected to
other parameters with unspecified direction for compatibility reasons. However
unspecified parameters cannot be connected to parameters with direction and
vice versa. The unspecified parameters are not applicable for diagram type
instances.
The direction Unspecified must not be used for parameters in a new control
module type in library or a sub level control module.
The direction should be noted as a keyword in the description for each parameter.
See also Type Description Keyword on page 32.