PLC Simulator
fundamentals
beginner

What Is a PLC? Plain-English Guide for Beginners

By PLC Simulation Software7 min read

What Is a PLC? Plain-English Guide for Beginners

If you have ever wondered why a factory floor machine keeps running perfectly without a person watching every step, the answer is almost always a PLC.

A PLC (Programmable Logic Controller) is a ruggedised industrial computer that continuously reads sensor inputs, executes a control program, and switches outputs — motors, valves, lights — on or off according to the logic you wrote. It repeats this cycle thousands of times per second, reliably, in dusty or wet environments where a regular laptop would fail in minutes.

PLC system architecture showing field sensors feeding input modules, the CPU running the program, and output modules driving motors, valves and lights

The Three-Part Loop Every PLC Runs

Every PLC operates on the same fundamental loop, called the scan cycle:

  1. Read inputs — the processor samples every sensor, switch, and signal wired to its input terminals and stores the values in an input image table in memory.
  2. Execute the program — the CPU works through your ladder logic (or structured text) rung by rung, evaluating conditions and setting output bits in an output image table.
  3. Write outputs — the processor pushes the output image table to the physical output terminals, energising or de-energising every wired device.

Flowchart of the PLC scan cycle: read inputs, execute the control program, write outputs, then repeat

Then it starts again. On a typical mid-range PLC the whole cycle takes 1–20 ms — so the machine sees a "new reality" up to 1,000 times per second.

Timing diagram of PLC cyclic scanning showing inputs sampled at the start of each scan and outputs updated at the end

The inside of a PLC mirrors this loop: a CPU at the centre, flanked by the memory that holds your program, the I/O modules that wire to the field, communication ports for HMIs and networks, and a power supply feeding it all.

Anatomy of a PLC showing the CPU connected to memory, I/O modules, communications ports and the power supply

Where PLCs Are Used

PLCs were invented in the late 1960s to replace relay panels in automotive assembly plants. Today they control:

  • Conveyor and sorting systems — directing boxes or parts based on weight or barcode reads.
  • Water and wastewater treatment — opening valves, running pumps, dosing chemicals in sequence.
  • HVAC and building automation — sequencing chillers, modulating dampers, managing boiler startup.
  • Packaging machinery — carton erectors, case packers, labelers, palletisers.
  • Process control — maintaining temperature, pressure, and level with PID loops.

Checklist of industries and applications where PLCs are used, from conveyors and water treatment to packaging and process control

Anywhere a process must happen in a defined sequence, reliably, is a candidate for a PLC.

What Makes a PLC Different From a Regular Computer?

| Feature | PLC | Regular PC | |---|---|---| | Scan cycle timing | Deterministic (guaranteed ms) | Non-deterministic (OS scheduling) | | Environmental rating | IP65+ dust/moisture protection common | Requires clean, conditioned environment | | Input/output | Dedicated industrial I/O modules | USB peripherals | | Programming | Ladder logic, structured text, FBD, SFC, IL (IEC 61131-3) | Any general-purpose language | | Startup time | Milliseconds | Minutes | | Reliability | 10–20 year MTBF typical | Standard consumer MTBF |

Comparison table of a PLC versus a regular PC across scan timing, environment, I/O, startup time and reliability

A PLC sacrifices raw computing power for determinism and ruggedness — it guarantees it will respond to inputs within a fixed time window, every single time.

PLCs originally replaced banks of hardwired relays, and the advantages still hold today: logic lives in software you can change without rewiring, in a fraction of the panel space.

Comparison of a PLC versus a hardwired relay panel, listing the advantages of a programmable controller

The Five IEC 61131-3 Programming Languages

The IEC 61131-3 international standard defines five programming languages that most modern PLCs support:

  • Ladder Diagram (LD) — graphical relay-style rungs; still the most widely used language.
  • Structured Text (ST) — text-based, resembles Pascal; great for complex maths and loops.
  • Function Block Diagram (FBD) — graphical blocks wired together; popular for analogue and PID.
  • Instruction List (IL) — deprecated in IEC 61131-3:2013; low-level assembly-like.
  • Sequential Function Chart (SFC) — step-and-transition diagram for sequential processes.

Checklist of the five IEC 61131-3 PLC programming languages: ladder diagram, structured text, function block diagram, instruction list and sequential function chart

Most real-world programs mix at least two: ladder for interlocks and sequencing, structured text for calculations.

A Simple Ladder Logic Example

Here is the canonical "motor start/stop" rung in IEC 61131-3 structured text:

(* Motor start/stop with seal-in *)
IF StartButton AND NOT StopButton AND NOT Overload THEN
    MotorRun := TRUE;
END_IF;

IF StopButton OR Overload THEN
    MotorRun := FALSE;
END_IF;

And the equivalent logic expressed as ladder pseudocode:

|--[StartButton]--+--[MotorRun]--+--[/StopButton]--[/Overload]--( MotorRun )--|
                  |              |
                  +-[MotorRun]---+

PLC ladder logic example of a motor start/stop seal-in rung with a Start contact, normally-closed Stop contact and a MotorRun coil

The second branch — MotorRun in parallel with StartButton — is a seal-in rung. Once the motor starts, its own output coil keeps itself energised even after the start button is released. Read more about seal-in rungs in Seal-In Rungs in Ladder Logic: The Complete Guide.

Key PLC Vocabulary

| Term | Meaning | |---|---| | Coil | An output that is turned on or off | | Contact | An input condition checked in a rung | | Rung | One horizontal row in a ladder diagram | | Tag / variable | A named memory location (e.g., MotorRun) | | I/O module | The hardware card that interfaces with field devices | | Function block | A reusable sub-routine (timer, counter, PID) | | Scan time | The duration of one complete read-execute-write cycle |

Vendor Dialects vs the IEC Standard

While IEC 61131-3 is the standard, each major vendor extends and customises it:

  • Allen-Bradley (Rockwell Automation) uses Ladder Diagram with its own tag-based addressing and proprietary function blocks in RSLogix 5000 / Studio 5000.
  • Siemens uses its own naming conventions in TIA Portal (S7-1200, S7-1500), though Structured Text is compliant with IEC semantics.
  • Codesys and OpenPLC offer the most faithful IEC 61131-3 implementations and are popular in education.

If you are learning from scratch, start with generic IEC 61131-3 concepts — the fundamentals transfer to every vendor. Then read PLC Dialects Compared: IEC 61131-3 vs Allen-Bradley vs Siemens to understand the differences before specialising.

How to Learn PLC Programming Without Hardware

Physical PLCs cost hundreds to thousands of dollars and require wiring, panel space, and software licences. Browser-based simulators remove every one of those barriers. You write real ladder logic, run it against a simulated machine model, and get instant pass/fail feedback — exactly the feedback loop you need to build fluency fast.

The Traffic Light scenario is the traditional first project for beginners: three outputs (red, amber, green), timed transitions, and no sensors to confuse the picture. From there you can progress through motor control lessons and work up to PID loops.


Practice this yourself in the simulator — 3 scenarios free. No install. No credit card. Write real ladder logic against a live machine model in your browser.

Try the simulator free →

Share:X / TwitterLinkedIn

Practice this yourself in the simulator

3 scenarios free — no install, no credit card. Write real ladder logic against a live machine model.

Try the simulator free →

Related articles

ladder logic
function block

Ladder Logic vs Function Block Diagram: When to Use Each

Ladder logic suits discrete interlocks and relay replacement; function block diagram suits analog, PID, and reusable logic. Compare LD vs FBD and pick the right one.

June 7, 2026 · 8 min read
ladder logic
examples

PLC Programming Examples and Solutions (with Ladder Logic)

Eight classic PLC programming examples with full ladder logic solutions and explanations — motor seal-in, timers, counters, traffic lights, tank control and star-delta.

June 7, 2026 · 10 min read
fundamentals
career

PLC Programming vs Traditional Programming: Python, Arduino & C

How PLC programming differs from Python, C and Arduino: the scan cycle, ladder vs relay logic, determinism, and whether a software dev can make the switch.

June 7, 2026 · 9 min read