0
0
FreertosProgramBeginner · 2 min read

Ladder Logic Program for Conveyor Belt Control in PLC

A simple ladder logic program for conveyor belt control uses Start and Stop push buttons to control a Motor output coil with a seal-in (holding) contact; for example, Start --| |----+----( Motor ) and Stop --|/|----| with a holding contact from Motor coil in parallel to Start button.
📋

Examples

InputPress Start button
OutputMotor coil energizes, conveyor belt starts running
InputPress Stop button after Start
OutputMotor coil de-energizes, conveyor belt stops
InputNo button pressed
OutputMotor coil remains off, conveyor belt stopped
🧠

How to Think About It

To control a conveyor belt with ladder logic, use a Start button to energize the motor coil and a Stop button to de-energize it. Add a holding contact from the motor coil in parallel with the Start button to keep the motor running after releasing Start. The Stop button breaks the circuit to stop the motor.
📐

Algorithm

1
Check if Stop button is pressed; if yes, de-energize motor coil.
2
If Stop is not pressed, check if Start button is pressed or motor coil is already energized.
3
If Start is pressed or motor coil is energized, energize motor coil to run conveyor.
4
Repeat continuously to maintain motor state based on inputs.
💻

Code

plc_programming
(* Ladder Logic for Conveyor Belt Control *)
(* Inputs: Start PB = I0.0, Stop PB = I0.1 *)
(* Output: Motor = Q0.0 *)

(* Network 1: Motor control with seal-in *)
(* |---[Stop]---+---[Start]---+---(Motor)---| *)
(* |           |             |             | *)
(* |           +---[Motor]---+             | *)

(* Ladder logic *)
(* Stop button is normally closed contact *)
(* Start button is normally open contact *)
(* Motor coil contact is normally open contact *)

(* Rung *)
(* Motor := NOT Stop AND (Start OR Motor) *)

(* In structured text for clarity: *)
(* Motor := NOT I0.1 AND (I0.0 OR Motor); *)

(* In ladder logic symbols: *)
(* --|/|--| |--+--| |--( ) *)
(* Stop Start Motor Motor *)

(* This logic energizes Motor when Start is pressed and keeps it on until Stop is pressed. *)
Output
Motor coil energizes when Start is pressed and remains energized until Stop is pressed, controlling the conveyor belt motor.
🔍

Dry Run

Let's trace pressing Start then Stop through the ladder logic.

1

Initial state

Stop = not pressed (true), Start = not pressed (false), Motor = off (false)

2

Press Start button

Start = pressed (true), Stop = true, Motor = false

3

Evaluate Motor coil

Motor = NOT Stop AND (Start OR Motor) = true AND (true OR false) = true, Motor energizes

4

Release Start button

Start = false, Stop = true, Motor = true (holding contact keeps Motor energized)

5

Press Stop button

Stop = pressed (false), Motor = true

6

Evaluate Motor coil

Motor = NOT Stop AND (Start OR Motor) = false AND (false OR true) = false, Motor de-energizes

StepStopStartMotor
1truefalsefalse
2truetruefalse
3truetruetrue
4truefalsetrue
5falsefalsetrue
6falsefalsefalse
💡

Why This Works

Step 1: Stop button normally closed

The Stop button is a normally closed contact, so when not pressed it allows current to flow.

Step 2: Start button energizes motor

Pressing the Start button closes its contact, energizing the motor coil.

Step 3: Holding contact keeps motor running

A contact from the motor coil in parallel with the Start button keeps the motor energized after releasing Start.

Step 4: Stop button breaks circuit

Pressing the Stop button opens its contact, breaking the circuit and de-energizing the motor coil.

🔄

Alternative Approaches

Using a timer to delay motor stop
plc_programming
(* Add TON timer to delay motor stop after Stop pressed *)
(* Motor runs while timer not done *)
(* Start and Stop logic same, but motor output controlled by timer done bit *)
Adds smooth stop delay but increases complexity and requires timer hardware.
Using a latch coil instruction
plc_programming
(* Use latch (SET) and unlatch (RESET) instructions for motor control *)
(* SET motor on Start press, RESET motor on Stop press *)
Simplifies logic but depends on PLC supporting latch instructions.

Complexity: O(1) time, O(1) space

Time Complexity

The ladder logic runs in constant time each scan cycle, checking inputs and updating outputs without loops.

Space Complexity

Uses fixed memory for inputs, outputs, and internal coil states; no dynamic memory allocation.

Which Approach is Fastest?

All approaches run in constant time; using latch instructions may simplify logic but does not affect speed significantly.

ApproachTimeSpaceBest For
Basic Start/Stop with holding contactO(1)O(1)Simple, reliable conveyor control
Timer delay on stopO(1)O(1)Smooth motor stop with delay
Latch coil instructionsO(1)O(1)Simplified logic if PLC supports latches
💡
Always use a holding contact from the motor coil in parallel with the Start button to maintain motor running after releasing Start.
⚠️
Forgetting to use the holding contact causes the motor to stop immediately when the Start button is released.