SIMATIC AX Main Program: Call Functions and Function Blocks

Published: 21 July 2026
on channel: Otomakeit
23
0

In this short SIMATIC AX tutorial, I create and organize the project’s MainProgram.
Because MainProgram is assigned to the cyclic Main task, its role is similar to OB1 in TIA Portal.
First, I reference the global tank interface through VAR_EXTERNAL. Then I declare the function-block instances inside VAR. Each function-block type creates an instance with its own retained data.
Finally, I organize the execution order into three sections:
Read and scale physical inputs.
Run the control logic.
Scale and write physical outputs.
The mapping functions are called directly, while the declared function-block instances are called in the control section.
GitHub project:
https://github.com/yuriyOtomakeit/ax-...
Previous tutorials:
Create Structured Text Files in SIMATIC AX:
[PASTE VIDEO URL]
Create a Function in SIMATIC AX:
[PASTE VIDEO URL]
Create a Function Block in SIMATIC AX:
[PASTE VIDEO URL]
Create a UDT in SIMATIC AX:
[PASTE VIDEO URL]
Create a Global Variable in SIMATIC AX:
[PASTE VIDEO URL]
Earlier tank-demo videos:
Tank Control Requirements Before Code:
   • SIMATIC AX Tank Demo: Requirements Before ...  
GitHub, TIA Selection Tool, and AX Hardware Compile:
   • SIMATIC AX Tank Demo #20: GitHub, TIA Sele...  
More SIMATIC AX articles:
https://otomakeit.com/tags/simatic-ax/
#SIMATICAX #MainProgram #FunctionBlock #StructuredText #PLCProgramming #IndustrialAutomation #Otomakeit


On this page of the site you can watch the video online SIMATIC AX Main Program: Call Functions and Function Blocks with a duration of hours minute second in good quality, which was uploaded by the user Otomakeit 21 July 2026, share the link with friends and acquaintances, this video has already been watched 23 times on youtube and it was liked by 0 viewers. Enjoy your viewing!