Planning standard interfaces
An interface to a function block or function is the first point at which a programmer can start to control how an object is interacted with. The interface serves as a ruleset of what is allowed to be passed in and out of this object.
You can see an example of an interface in the following screenshot:
By offering an interface, programmers (and other people who may have to maintain or modify the project) have a better chance at reducing mistakes when using the object.
Defining variables in an interface
An interface is made up of three different key areas, as outlined here:
- Inputs
- Outputs
- InOut variables
Each behaves differently and performs different functions.
Inputs
Inputs are variables that are read-only. Once an input interface variable is passed into an object, it is not recommended to modify it. TIA Portal does allow input variables to be written...