What is a PLC simulator?

A PLC simulator runs a PLC program on an ordinary computer. It reads simulated inputs, solves your logic one scan at a time and writes simulated outputs, so you can write and test a program with no controller and no machine. FORGE is a free PLC simulator that runs in your browser.

What a PLC is

A PLC, or programmable logic controller, is the computer that runs a machine. It reads inputs such as buttons and sensors, runs a program, and turns outputs such as motors, valves and lamps on and off. It repeats this every few milliseconds. One round is one scan.

One scan: read all inputs, run the rungs from top to bottom, write all outputs, then start again.1Read inputsAll inputs,all at once2Run rungsTop to bottom,left to right3Write outputsAll outputs,all at onceThen again. The Scan setting (20 ms) sets how often.

What the simulator does

The simulator does the same three steps in software. You set the inputs yourself, or a simulated machine sets them, and you watch the outputs change. This is the same seal-in rung run one scan at a time in FORGE:

1. Press Start. The StartPB branch passes power and StopPB is off, so Motor turns on at the end of the scan.

StepStartPBStopPBMotor
1. Press Start101
2. Release Start001
3. Press Stop010
4. Release Stop000

FORGE, the free PLC simulator in your browser

In FORGEWhere to read more
Four languages: Ladder, Function Block Diagram, Sequential Function Chart and Structured TextFBD, SFC, Structured Text
90 instructions: contacts, coils, timers, counters, compare, math, text, arrays and moreInstructions
Run, Stop and Single Scan, with live tag values and forcesTest one scan at a time
Eight machine scenes to practise onSimulators and scenes
Operator screens in HMI StudioHMI Studio
Seven Link types to real devices and servicesLinks
FRC robot logic in ArenaArena

A simulator and a real PLC

PLC simulatorReal PLC
InputsSet by you, a forced value or a machine sceneWired buttons, switches and sensors
TimeSimulated: each scan moves the clock by exactly the scan timeReal time
MistakesFree: press Reset and try againCan damage a machine or hurt someone
UseLearning, practice and testing logicRunning a machine

FORGE is for learning and practice. It is not a safety system and must not run a real machine. A MicroController or network device you connect through a Link is for training setups.

Try it

  1. Open the free sandbox. No account is needed.
  2. It opens with Motor Starter Practice, a seal-in like the one above.
  3. Click Click to toggle bits, turn StartPB on, then click Single Scan.
  4. Read The scan cycle next, then open a scene from Simulators.

Related