Skip to content
Samet Karayoluk
Genel

SCL or LAD in TIA Portal? Which One Should You Use and When?

TIA Portal SCL ve LAD karşılaştırması

TIA Portal users eventually face the same question:

Should I use LAD or SCL?

I don’t think asking “which one is better?” is really the right question, because each language has its own strengths.

If I want to quickly understand in the field why a motor is not running, LAD is extremely useful. But if I need to process 20 values stored in an array, perform calculations, or apply the same logic repeatedly, using SCL instead of extending the same logic in LAD usually makes much more sense.

Siemens follows a similar approach in its programming recommendations for S7-1200 and S7-1500 systems: the programming language should be selected according to the task. LAD/FBD are particularly suitable for binary logic, while SCL becomes a strong option for data processing and algorithm-oriented structures.

So the real question is not LAD vs. SCL.

It is about using the right tool for the right task.

Why is LAD still so useful?

LAD, or Ladder Diagram, is very close to traditional electrical control logic.

In TIA Portal, we frequently work with basic elements such as contacts and coils.

Let’s use a classic example.

Suppose we have a motor:

  • It should run when the Start button is pressed.
  • It should stop when the Stop button is pressed.
  • It should not run if there is a thermal overload fault.
  • It should not run if the system is not ready.

In LAD, we can represent this logic very clearly.

The main advantage is troubleshooting.

If the machine is not running, I can go online and follow the network directly. Is Ready missing? Is Thermal_Fault active? Is the Start command missing?

I can visually follow the logic.

LAD is especially practical for:

  • motors,
  • valves,
  • sensors,
  • interlocks,
  • permissive conditions,
  • simple machine control logic.

There is also a small but important detail here:

The [ ] and [/] instructions in TIA Portal evaluate a BOOL value. They should not automatically be treated as the equivalent of a physically wired NO or NC contact.

How the physical input is wired and what the PLC tag represents are two separate matters.

Where does SCL come into play?

On the Siemens side, SCL stands for Structured Control Language and is based on the Structured Text programming approach.

Instead of contacts and coils, we write code.

The motor logic above could, for example, be written in SCL like this:

IF #Stop OR #Thermal_Fault OR NOT #Ready THEN
    #Motor := FALSE;

ELSIF #Start THEN
    #Motor := TRUE;
END_IF;

Clean and straightforward.

However, if I only need to write simple motor control logic like this, I personally find LAD more practical because the operating conditions are easier to diagnose in the field.

The real advantage of SCL appears when the problem becomes more data-oriented or repetitive.

Imagine 100 similar asynchronous motors

Suppose a facility contains 100 similar asynchronous motors.

For each motor, we may have signals such as:

  • start command,
  • run permissive,
  • thermal or drive fault,
  • running feedback,
  • output command.

Of course, this can be programmed in LAD.

However, if we start repeating essentially the same logic in separate networks for 100 motors, the project quickly becomes much larger.

We may end up recreating the same structure for Motor 1, Motor 2, Motor 3 and so on until Motor 100.

With SCL, we can instead store the motor data in an ARRAY and apply the same logic using a loop.

In simplified form:

FOR #i := 1 TO 100 DO

    IF #Motor[#i].Start
       AND #Motor[#i].Ready
       AND NOT #Motor[#i].Fault THEN

        #Motor[#i].Output := TRUE;

    ELSE
        #Motor[#i].Output := FALSE;

    END_IF;

END_FOR;

Instead of writing the same code separately for 100 motors, we apply the same logic to every motor in the array.

The real advantage is not simply that there are many motors.

The advantage comes from having the same structure repeated across many pieces of equipment.

For example, if we later want to add a new operating condition to every motor, we can update the relevant algorithm in one place instead of modifying 100 separate networks.

Therefore, LAD is highly practical when following the field logic of an individual motor, while SCL can offer a major advantage when managing data and repetitive operations for many similar devices.

Is SCL or LAD better in TIA Portal?

There is no programming language that is universally better.

LAD is highly useful for binary control logic and field diagnostics, while SCL is generally more suitable for calculations, loops, arrays and data processing.

Can SCL be used with S7-1200 and S7-1500?

Yes.

SCL can be used with both S7-1200 and S7-1500 PLCs in Siemens TIA Portal, and LAD and SCL can also be used together within the same project.


© Samet Karayoluk. This content was prepared by Samet Karayoluk. It may not be copied or republished without permission. Short excerpts may be used with proper attribution.

Type at least 2 characters.

↑↓ · Enter · Esc

Share with