Programming a custom POU
- Prerequisite
- You must create a custom Program Organisation Unit before you can program it.
- Start editing the real-time application.
- In the menu bar, click Program.
- Select the custom POU from the POU tree.
- Create local variables in the context of the custom POU.
- Change the data type and initial value as required.
- Change the section of all variables that serve as inputs to VAR_INPUT.
- Change the section of all variables that serve as outputs to VAR_OUTPUT.
- Add the local variables to the custom POU.
- Add POUs from the catalogue to the custom POU.
- Connect the elements in the worksheet as required.
Creating a local variable
Adding a variable to a program
Adding a POU to a program
Data types
Functions and function blocks of the standard library