Motion Detection based Street Light: PLC Logic Solution

In this article. you will learn the motion detection-based street light control using a sensor with PLC logic solution.

Note: This PLC logic is prepared for learning purposes. It can be used to learn ladder logic programming.

Motion Detection based Street Light

Problem Statement:

Design a PLC ladder logic for the following application.

We are using one motion detection sensor to control Street Light.

The Street Light gets ON for 20 seconds when there is any movement detected and then blinks with an interval of 2 seconds, and gets turned OFF after 30 seconds.

Note: In this example, the timings are reduced for easy learning purposes. In real-time, the timings are in hours.

PLC Logic Solution

Instrumentation Tools provides PLC logic solutions for simple and advanced programming examples.

This PLC video explains the street lights programming from scratch.

Inputs/Outputs

Digital Inputs:

Sensor: I0.0

Digital Outputs:

Street Light: Q0.0

Ladder Diagram

Motion Detection based Street Light PLC Logic Solution

Programming Explanation

We have used Normally Open Contacts for Sensor (I0.0), Memory Bit 1 (M0), Memory Bit 2 (M1), and Memory Bit 4 (M3).

In Rung 0:

  1. Normally Open Contacts are used for Sensor (I0.0) to Turn ON  Memory Bit 1 (M0) and Memory Bit 2 (M1).
  2. Timer Function Block type TP is used to Turn ON Memory Bit 1 (M0) for a limited time.
  3. Timer Function Block type TON is used to delay the turning ON time of Memory Bit 2 (M1) for some time.
  4. Timer Function Block type TP is used to Turn ON Memory Bit 2 (M1) for a limited time.

In Rung 1:

  1. Normally Open Contacts are used for Memory Bit 2 (M1) to Turn ON  Memory Bit 4 (M3) and  Memory Bit 3 (M2).
  2. Normally Closed Contact is used for Memory Bit 3 (M2) to turn OFF Memory Bit 4 (M3).
  3. Timer Function Block type TP is used to Turn ON Memory Bit 4 (M3) for a limited time.
  4. Normally Closed Contact is used for Street Light (Q0.0) to turn ON Memory Bit 3 (M2).
  5. Timer Function Block type TON is used to delay the turning ON time of Memory Bit 3 (M2) for some time.

In Rung 2:

  1. Normally Open Contacts are used for Memory Bit 1 (M0) and Memory Bit 4 (M3) to turn ON the output Street Light (Q0.0).

Simulation Result: When the Sensor detects movement

Now we simulate the PLC program and discuss the results. We show the partial logic with different simulation steps. We recommend you to watch the above video for detailed explanation.

When Sensor (I0.0) gets activated (Sensor detects movement), Memory Bit 1 (M0) turns ON as Normally Open Contact used for Sensor (I0.0) allows the signal to through it.

Motion Sensor based Street Lights Automation

When Memory Bit 1 (M0) turns ON in Rung0, Normally Open Contact used for Memory Bit 1 (M0) will be in True state and pass the signal to turn ON the output Street Light (Q0.0) or Street Light turns ON.

PLC motion detection street light

In Rung0, Memory Bit 1 (M0) will turn OFF after 20 seconds as Timer Function Block type TP is used to turn ON Memory Bit 1 (M0) for a limited time. The time is set to 20 seconds.

After 20 seconds, Memory Bit 1 (M0) turns OFF.

Automated street light control system

When Sensor (I0.0) gets activated (Sensor detects movement), Memory Bit 2 (M1) turns ON but after 20 seconds (i.e immediately after Memory Bit 1 (M0) turns OFF) as Timer Function Block type TON is used to delay the turning ON time of Memory Bit 2 (M1).

Sensor-controlled street lighting solution

The time is set to 20 seconds. After 20 seconds, Memory Bit 2 (M1) will turn ON but only for a limited time as Timer Function Block Type TP is used to turn ON Memory Bit 2 (M1) for a limited time.

Motion-sensing street light automation

When Memory Bit 2 (M1) turns ON in Rung0, Normally Open Contact used for Memory Bit 2 (M1) will be in True state and pass the signal through it.

In a false state, Memory Bit 3 (M2)  also passes the signal to turn ON Memory Bit 4 (M3).

Street light program with PLC

When Memory Bit 4 (M3) turns ON in Rung1, Normally Open Contact used for Memory Bit 4 (M3) will be in True state and the output Street Light (Q0.0) still remains ON.

Memory Bit 4 (M3) in Rung1 turns OFF after some time as Timer Function Block type TP is used to turn ON Memory Bit 4 (M3) for a limited time.

PLC logic for street light control

The time is set to 2 seconds. After 2 seconds, Memory Bit 4 (M3) turns OFF.

When Memory Bit 4 (M3) turns OFF in Rung1, Normally Open Contact used for Memory Bit 4 (M3) in Rung2 will be in a False state and the output street Light (Q0.0) turns OFF.

PLC programming for street light automation

When the output Street Light (Q0.0) turns OFF in Rung2, Normally Closed Contact used for Street Light in Rung0 will be in a False state and passes the signal to turn ON Memory Bit 3 (M2) and Memory Bit 3 (M2) turns ON but it will turn OFF within no time because in Rung1, Normally Closed Contact is used for Memory Bit 3 (M2).

Smart street light control with PLC

In Rung1, Normally Closed Contact used for Memory Bit 3 (M2) will also turn ON and OFF within no time and the whole process in Rung1 and Rung2 will restart and will run in a loop till the Timer Function Block type TP used for Memory Bit 2 (M1) in Rung0 will reach its time limit.

Street light control using motion sensor

The time is set to 30 seconds. After 30 seconds, Memory Bit 2 (M1) will turn OFF. When Memory Bit 2 (M1) turns OFF in Rung0, Normally Open Contact used for Memory Bit 2 (M1) will be in a False state and does not allow the signal to pass through it and the whole process stops.

Motion-triggered street light on and off

Advanced Street Lights PLC Program

This video explains the advanced Street Lights PLC programming concept. The video explains the project objective, PLC wiring, logic brief, and PLC programming with HMI design and simulation.

If you liked this article, please subscribe to our YouTube Channel for PLC and SCADA video tutorials.

You can also follow us on Facebook and Twitter to receive daily updates.

Don't Miss Our Updates
Be the first to get exclusive content straight to your email.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address

Leave a Comment