Stepwise processing of the program (stepping)

You can execute a PLC project step by step, navigating through the code. This is useful for determining the status of your code at runtime. You can examine the call sequence, track variable values or determine errors. For this purpose, step commands are available in the menu Debug. The commands become available when the program is at a defined program step (debug mode). During debug mode, the current stop position is highlighted in yellow and marked in the text editors with the symbol Stepwise processing of the program (stepping) 1:.

Switch to debug mode

The PLC project is in online mode.
1. Set breakpoints in the POUs at the locations in the code you want to examine.
2. Start the program.
The program starts, the code is processed to the first breakpoint. The project is now in debug mode.
The editor with the current stop position is opened. The line of code with an active breakpoint, where the program execution was stopped, is highlighted in yellow and marked with the symbol Stepwise processing of the program (stepping) 2: (stop at breakpoint). The instruction has not been executed yet.
You can select the different step commands or display the call stack.

Behavior of the step commands

Select the command PLC > Window > Call Stack to display the previous call tree completely for the stop position currently reached in the program execution.

Stepwise processing of the program (stepping) 9:

The Call Tree view therefore shows where the function blocks are located in the call structure of the program at all times, even before compilation of the PLC project.