Start and stop a PLC sequence from an HMI button

7 min read · Published November 13, 2026

The Start button writes one C bit, not a mode bit. The ladder runs the valve sequence while that bit is on and resets it when the last valve turns off, so one press runs one cycle. Initial Value Off and Retentive No keep a power cut from restarting the cycle.

Your Start and Stop buttons should start and stop the valve cycle, not the PLC. The references _PLC_MODE at SC11 and _PLC_Mode_change_to_stop at SC50 move the controller between RUN and STOP, and a controller in STOP solves no ladder: no timer accumulates, no step advances, no rung turns a valve off on schedule. You would trade a running sequence for a frozen one.

The build that works is small. The Start button sets one C bit. The ladder runs the ten valves while that bit is on. The rung after valve 10's dwell resets the bit, and the sequence waits for the next press. One press, one cycle, and the button light shows the machine's state for exactly as long as the cycle runs.

Why the mode bits are the wrong lever

The names say what they do. _PLC_MODE at SC11 is the controller's mode; _PLC_Mode_change_to_stop at SC50 requests the change to STOP. Both act on the controller, one level below your machine.

The sequence you want to stop is ten states of ten outputs. While the controller is in RUN it solves the ladder every scan, and that solve is what reads the button, times each dwell and closes each valve on schedule. Move the controller to STOP from a touchscreen and the solve ends: the dwell timers stop accumulating, the step counter stops advancing, and the outputs land in whatever state that controller's stop behavior dictates, with no logic managing the transition. Run and stop control belongs with the person holding the programming software or the key, and the cycle button belongs on a C bit.

What the buttons should write

Pick one unused C bit as the cycle request. The Start button on the display is a Set On object pointed at that bit. Not an X, not a Y, not a system reference: X addresses mirror the wired inputs and Y addresses are the physical outputs, and a display writing either one couples the operator's finger straight to the I/O table with no sequence behind it.

The object type matters as much as the address. Set On latches the bit; the ladder owns the reset after valve 10. The button object also reads the bit back, so it stays lit for the whole cycle and clears the scan after the ladder resets it. A momentary press behaves differently, and how many PLC scans a momentary button bit stays on is worth understanding before you lock the object type in.

Control Type Address Who clears it
Start Set On the request C bit the ladder, after valve 10's dwell
Stop, if you build an abort clears the same bit the request C bit the abort rung, same scan
Button light reads the bit the request C bit follows the ladder's reset

This is the same command-bit pattern as turning a PLC output on from an HMI button: the display carries the request, the ladder makes every machine decision.

What you need before you start

  • The ladder program with the ten timed steps, working on its own.
  • One unused C bit address, written identically in the ladder and in the display project.
  • The dwell time for each valve, taken from the process.
  • The display project with one Set On button, plus a Stop button only after you choose its meaning below.

The build, step by step

  1. Pick one unused C bit as the cycle request and write its address in both projects. A mismatch here is the classic silent failure: the display changes a bit the ladder never reads.
  2. In the address picker, set that bit's Initial Value to Off and Retentive to No. Both fields are edited per address in the picker.
  3. Build the steps. One drum instruction sequences 1 to 16 steps and turns on up to 16 outputs in a pattern you define, so all ten valves fit in a single instruction. Ten step bits with one timer each give the same result with more rungs and more visibility while debugging.
  4. Gate step 1 on the request bit. In each step the valve output is on and the dwell timer runs; the timer's completion turns the valve off and advances to the next step.
  5. When valve 10's dwell completes, reset the request bit and return to idle. That one reset rung is the entire "wait for the next operator press" logic.
  6. Point the display's Start button at the request bit as a Set On object. Test the ladder with the bit forced from the programming software first, then connect the display.

If your process needs an operator to walk the steps by hand instead of on a timer, advancing one stage in a PLC sequence from a button is the related pattern.

What a Stop button has to mean

There are two honest meanings, and you pick one before you draw the button.

Complete cycle: there is no Stop button. The request bit resets itself after valve 10, and the operator simply does not press Start again.

Abort: a second button clears the same request bit, and the ladder must say what happens to the valve that is running. A step that holds itself on until its timer completes will finish that dwell with the request bit off, unless you add an abort rung that turns the active valve off, resets the step and clears the timer in the same scan. Write that rung, and the Stop button is real.

A request bit on a touchscreen is a production control, never a safety stop. If a person can be in the machine, the protective stop is a safety function built from rated components that drop the valve power, and no display bit takes part in it.

Restart behavior after a power cut

With Retentive set to No, the controller writes the Initial Value to the bit after power-up or after a change from STOP to RUN. Initial Value Off means the request comes back off: the machine waits at idle instead of resuming a half-finished cycle.

That setting governs the one bit. Give the step counter and the timers the same review, because a retained step number with a cleared request can surprise you on the next Start; initializing PLC bits to a safe state after a long power outage covers the wider startup pass.

Example: ten valves, eight seconds each

Say each valve runs an 8 s dwell. The full cycle is 10 x 8 s = 80 s. Press Start at t = 0 s: valve 1 is on from 0 s to 8 s, valve 2 from 8 s to 16 s, and valve k from (k - 1) x 8 s to k x 8 s, so valve 10 runs from 9 x 8 s = 72 s to 80 s. At t = 80 s the ladder resets the request bit, the sequence returns to idle and the button light clears.

Cut the power at t = 45 s. Valves 1 through 5 have consumed 5 x 8 s = 40 s, so 45 s is 45 - 40 = 5 s into valve 6's dwell, with 8 - 5 = 3 s left on it. On restoration the Initial Value writes Off to the request bit, the sequence sits at idle, and the next press starts at valve 1. Nothing resumes into valve 6 unless you build a resume path on purpose.

If instead the operator presses an abort button at t = 45 s, the abort rung turns valve 6 off in that scan, resets the step and the timer, and the machine idles with the request bit already clear.

How to check it worked

  • With the display disconnected, force the request bit from the programming software. Watch ten output transitions at 8 s spacing across 80 s, then idle.
  • Confirm the request bit resets in the same scan valve 10 turns off, and that one more force starts a fresh cycle.
  • Connect the display. One press of Start must produce the same ten transitions, with the button lit for the full 80 s.
  • Pull the controller power at t = 45 s of a test cycle and confirm the restored machine waits at idle for a press.
  • If the display changes a bit the ladder never reads, compare the address in the button object against the address in the ladder; they must match character for character.

Recommendation: use one C bit with Initial Value Off and Retentive No, a Set On Start button, one drum or ten step bits for the valves, and a reset rung after valve 10's dwell. Skip the Stop button unless you write the abort rung that drops the running valve and reinitializes the step in the same scan, and keep any protective stop on safety-rated hardware wired to the valve power. Leave _PLC_MODE at SC11 and _PLC_Mode_change_to_stop at SC50 alone: they change the controller's mode, and your cycle lives above that layer.

Questions

What actually happens to the valves if the PLC goes to STOP mid-cycle?

The controller stops solving the ladder, so no rung executes: dwell timers freeze, no step advances, and nothing resets the request bit. The outputs land in whatever state that controller's stop behavior is configured for, and no logic manages the transition. That is a mode question decided in the controller's configuration, and it is why run and stop belongs to the key or the programming port while the cycle button writes a C bit.

Why not point the Start button at an X or Y address?

An X address is the wired input image: the controller refreshes it from the terminal every scan, so a write from the display is overwritten on the next input update. A Y address is a physical output, so the button would energize a valve with no dwell timer, no step order and no interlocks. A C bit keeps the division of labor clean: the display requests, the ladder decides.

Can the sequence resume where it stopped after a power cut?

Not with the settings in this article, and that is the safe default: the request bit returns off and the machine waits. If the process truly must resume, set the step number's Retentive to Yes in the address picker, leave the request bit at Retentive No, and write a startup rung that re-enters the interrupted step only after the operator presses Start. Test that path from an interruption at every step, not just one.

How long should the Start button stay lit?

Exactly as long as the request bit is on. A Set On object reads back the bit it writes, so the light tracks the cycle, not the finger: 80 s in the ten-valve, 8 s example, clearing in the scan after the ladder's reset. A light that stays on after the cycle means the reset rung is missing or reads a different address than the button.

Planning information, not legal or engineering advice. Rules differ by place: check codes and permits with your local authority and your licensed trades.

Keep reading

Build your signAsk for a quote