an OT workspace — P&ID plant & controllers · IEC 61131-3 logic, Structured Text ⇄ Ladder · live scan simulation · by Joshua Ott
editing
Structured text
examples
Inputs
Outputs this scan
Diagram
bittimers & counterscomparemath
[ ] normally open — passes power when TRUE · [/] normally closed — passes power when FALSE
series contacts are AND · parallel branches are OR · +∥ adds a branch ·
wires light where power actually flows green = energized this scan · arithmetic uses function blocks, not operators
an IF/ELSE in text becomes two rungs gated by the same variable and its complement
the diagram is editable: click a tag, pin, or coil to rename it · click a contact symbol
to flip [ ]/[/] · drag ⋮⋮ to reorder rungs · drag contacts to reorder them ·
× deletes · type any expression into a pin
diagram edits regenerate the text in flat rung form — complementary rungs collapse back to
IF/ELSE, comments are dropped
this is a real scan: state persists between scans, so seal-in rungs latch and
TON/TOF/TP timers, CTU/CTD counters and R_TRIG/F_TRIG edges work —
declare instances in VAR … END_VAR, call them like tmr(IN := b, PT := T#5s),
read tmr.Q · reset is a cold restart · step single-scans while stopped
viewlayersexamplesdrag a device to move it · drag the background to pan · ctrl + wheel to zoom ·
double-click a controller to open its logic
every device from the P&ID appears in its level · drag a card between lanes ·
link two devices to draw a conduit · click a conduit to set its traffic ·
double-click a controller to open its logic