June 21, 2020

Count boxes on the conveyor

Application:-There is one conveyor in the factory and boxes are moving on the conveyor. Write PLC program to count boxes moving on the table.

 Components:-Programmable logic controller, electric DC motor, sensor, wires.



Explanation:-

There is one system in the factory. In this system there is one conveyor and some boxes are moving on the conveyor. Now our requirement is to count boxes moving on the conveyor. So for that we have done mechanical arrangement near to conveyor belt. In this mechanical arrangement one sensor is mounted so when box will pass through this sensor, it will cut the beam and

 

PLC program:-

Write the ladder program for above application using ladder diagram language. Here for ladder logic we can use any supported PLC system like S7-1200, S7-300, S7-1500 or any other PLC which can support this instruction. For PLC logic we need digital inputs and outputs.

For programming define the digital inputs and outputs and also prepare list of memory coils.

 

Digital inputs:-

ON/OFF Switch=I0.0

Box Detector=I0.1

Digital Output:-

Conveyor=Q0.0

M memory:-

M0.0=Reset















PLC program Explanation:-

In network 1, we have taken NO contact of ON/OFF switch to operate conveyor so when ON/OFF switch (I0.0) is pressed, conveyor (Q0.0) will be ON.

In network 2, we have taken counter logic. When conveyor is running the box will start to move so box detector (I0.1) will count parts and 200 parts completed then production completed (M0.1) command will on.

We have used NC contact of production completed (M0.1) memory bit so when part completed it will stop the conveyor.

 













UP and Down counter using example

Application:-Understand the concept of CTUD (count up and down) counter instruction in the PLC. Explain CTUD counter concept using PLC program.

Components:-Programmable logic controller, two lamps (24 VDC).




Explanation:-

CTUD counter is the combination of UP counter and down counter. This counter will work on both the function count UP and count down. Take two lamps to understand the concept of CTUD counter. In this UP function will operate L1 and down counter will operate L2.

PLC program:-

Write the ladder program for above application using ladder diagram language. Here for ladder logic we can use any supported PLC system like S7-1200, S7-300, S7-1500 or any other PLC which can support this instruction. For PLC logic we need digital inputs and outputs.

Digital inputs:-

UP button=I0.0

Down button=I0.1

Reset Button=I0.2

Load Button=I0.3

Digital Output:-

L1=Q0.0

L2=Q0.1


















PLC program Explanation:-

In network 1, we have used CTUD counter to understand the concept,

Here CU is for counter UP, CD is for counter down, R is reset input and load is for load input. QU is the output of UP counter and QD is the output of down counter.

So if UP button is pressed, counter will start to count up and CD is pressed counter will count down.

If R is pressed then UP counter value reset and if LD is pressed then PV will be load.

If CV value is equal to PV value or greater than PV value, L1 (Q0.0) will be ON.

If CV value is less the or equal to zero, then L2 (Q0.1) will be ON.















Down counter instruction using example.

Application:-Understand the concept of down counter instruction in the PLC. Explain down counter concept using PLC program.

Components:-Programmable logic controller.



















Explanation:-

Generally counter is used to count events in the application. Generally down counter is used to count down sequence (for example it will count from 5 to 1 like 5 4 3 2 1).Down counter will generate output when current count value is equal to 0 or less than 0. And if load input is changed from 0 to 1, it will load PV value.

 

PLC program:-

Write the ladder program for above application using ladder diagram language. Here for ladder logic we can use any supported PLC system like S7-1200, S7-300, S7-1500 or any other PLC which can support this instruction. For PLC logic we need digital inputs and outputs.

For our application on/off button is digital input and lamp is the digital output. So define digital input address and output address as per below explanation,

Digital inputs:-

ON/OFF button=I0.0

Load=I0.1

Digital Output:-

Lamp=Q0.0



PLC program Explanation:-

In above network 1, we have used down counter (CTD). So lamp will be on immediately when 5 in PV. When ON/OFF button is pressed 5 times then counter will become zero.

Press load button to load value into PV.







Up counter instruction using example.

Application:-Understand the concept of UP counter instruction in the PLC. Explain UP counter concept using PLC program.

Components:-Programmable logic controller.





 

Explanation:-

Generally counter is used to count events in the application. Counter is used in so many application like object count, students counts, cars count etc. Counter instruction used in programmable logic controller for deferent types of logic. Here our aim is to understand UP counter, UP counter counts the objects. 

 

PLC program:-

Write the ladder program for above application using ladder diagram language. Here for ladder logic we can use any supported PLC system like S7-1200, S7-300, S7-1500 or any other PLC which can support this instruction. For PLC logic we need digital inputs and outputs.

For our application ON/OFF button is digital input and lamp is the digital output. So define digital input address and output address as per below explanation,

Digital inputs:-

ON/OFF button=I0.0

Counter Reset=I0.1

Digital Output:-

Lamp=Q0.0


 












PLC program Explanation:-

In above network 1, we have used UP counter (CTU). We can use INT data type for the counter. When ON/FF button (I0.0) is pressed five times, valve (Q0.0) should be ON.

Here UP counter will continue to count till reset button pressed. If we will not press reset button, counter will continue to count after five. UP counter should be reset after its PV value over.

In in PV, we can set preset count value and actual count value can be monitored in CV (current count value).