PLC handling and recovery after an emergency stop — The safety circuit stops; the PLC cleans up and recovers (sample)

Last updated: 2026-09-23 / Category: Samples, flowcharts

What stops the machine on an emergency stop is the safety circuit; a standard PLC handles the clean-up and the recovery procedure. For anyone unsure what the PLC should do after an emergency stop, this flowchart shows the PLC side only.

Open this sample in the editor Download the JSON

The free browser editor opens in a new tab with this flowchart loaded. No installation, no sign-up, and nothing you enter is sent anywhere. Editing it does not change the sample on this page. The JSON is the source data for reopening it in the editor or handing it to an AI (format: JSON data format).

Flowchart of PLC handling and recovery after an emergency stop. When the safety relay monitor turns OFF, turn the motion outputs OFF, clear the latches and positioning commands, show which button was pressed and record the step it stopped in. Wait for all emergency stop buttons to be released, then for the reset to be pressed and released. Wait up to 3 s for power to return; if it does not, show "Power not restored" and return to waiting for the reset. If the positions of every axis and cylinder are known and the interrupted step may be resumed, go to waiting for the start button. Otherwise wait for the homing button, home, and if homing does not complete, show "Homing fault" and return to waiting for the homing button. Finally, when the start button is pressed, go to automatic operation.
A decision whose NO loops back to itself means "wait until it holds". Waits for a human operation have no time limit. Not drawn: from any stage, if the safety relay monitor turns OFF, return to the beginning.

1. The safety circuit stops; this chart is the PLC side only

A standard PLC is not built for safety functions. With an output transistor failed ON, or in the middle of a program download, it cannot be relied on to stop. The safety circuit is designed after a risk assessment, to ISO 13849-1 and IEC 60204-1. This chart is no substitute for it.

2. Why this order: give people time to check, and never let the machine start on its own

  1. Releasing the button, reset and start are three separate operations If releasing the button alone started the machine, it would catch someone else inside it. Reset restores the power and start begins the motion; kept apart, there is time to check the surroundings before anything moves. On the PLC side too, the emergency stop input returning is not a resume condition; it waits for the start button.
  2. Keep the motion outputs OFF until start or homing The moment the reset restores power, the machine moves according to whatever outputs are left. Clear the remaining outputs and latches, and also the positioning start commands and any remaining travel. Outputs that cause no motion, such as lamps and buzzers, need not be turned OFF.
  3. What happens when power is cut is decided by the choice of equipment When power or air is cut, clamps and vacuum may release the part. A single-solenoid valve returns to the spring side and vacuum loses its grip, so choose equipment that keeps holding. For a 2-position double solenoid, check which way it moves when the air returns (Air cylinder timing chart (sample)).
  4. Knowing the positions is not the same as knowing it is safe to continue The state of the part matters as well as the step number. To resume, you also need to know how far the part was processed and whether it is gripped. Decide per step, and write in the specification, that if anything is unknown the machine homes and starts over.
  5. Homing is started by the operator Started automatically after the reset, the axes would move before the operator is ready. Give homing a time limit too; if it stops partway, show a fault and return to waiting for the homing button. An incremental servo loses its position if even the amplifier's control power is cut, so check how far the emergency stop cuts.

3. The specification states what is cut, how to resume, what is shown, and the time limits

The stop and recovery for an opened guard door is drawn almost the same way: the door switch is in the safety circuit, and the order is close the door, reset, start. On a machine a person can enter, whoever goes in takes the door switch key (or their own padlock) with them. If the door must stay shut until the machine has stopped, use an interlocked door and add a stage that unlocks it after confirming the stop.

Once open in the editor, double-click a symbol to change its text.

The tools this sample was made with

  • Flowchart Editor — The figure above and the sample JSON were made and exported with this editor.
  • Timing Chart Editor — The normal cycle after recovery can be drawn as a timing chart of the signal order.

Related articles

yk.builds