June 28, 2020

Clock memory function in the S7-1200 PLC.

Clock memory function in the S7-1200 PLC.

Application:-Understand the concept of clock memory and system memory function in the S7-1200 PLC using example



Explanation:-

To understand the system and clock memory we can use S7-1200 PLC. Clock memory configure byte and that cycle of individual bit on and off at fixed interval. These bits can be used in the program for controlling or for some time based logic. We can use these bits for triggering function.

 

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.

Select clock memory and define address in the hardware confugration.For example take byte 0 for clock memory so form M0.0 to M0.7 can be used for clock pulse.















Digital Output:-

OP 1=Q0.0

OP 2=Q0.1

OP 3=Q0.2

OP 4=Q0.3

OP 5=Q0.4

OP 6=Q0.5

OP 7=Q0.6

OP 7=Q0.7

M memory:-

M0.0=10 Hz pulse

M0.1 =5 Hz pulse

M0.2=2.5 Hz pulse

M0.3=2 Hz Pulse

M0.4=1.25 Hz Pulse

M0.5=1 Hz pulse

M0.6=0.625 Hz Pulse

M0.7=0.5 Hz Pulse
















PLC program Explanation:-

In network 1, OP 0 is blinking at 10 Hz frequency

In network 2, OP 1 is blinking at 5 Hz frequency

In network 3, OP 2 is blinking at 2.5 Hz frequency

In network 4, OP 3 is blinking at 2 Hz frequency

In network 5, OP 4 is blinking at 1.25 Hz frequency

In network 6, OP 5 is blinking at 1 Hz frequency

In network 7, OP 6 is blinking at 0.625 Hz frequency

In network 8, OP 7 is blinking at 0.5 Hz frequency



Make test mode and manual mode in the system.

Application:-There are two valves in the system and two valve should be operated in test mode and manual mode also. Write the PLC program for this application using ladder diagram language.





Explanation:-

As per above application, there are two valves in the system and we want to ON/OFF valves as per selected mode. We have taken one selector switch for test and manual mode selection. Test mode will work only for testing function like mechanical block or function of valve. Manual mode work with all interlocks which are required for manual function like both valve should not on together.

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 start switch is digital input and valves are the digital output. So define digital input address and output address as per below explanation,

Digital inputs:-

Test/Manual Mode=I0.0

Valve 1 ON/OFF=I0.1

Valve 2 ON/OFF=I0.2

 

Digital Output:-

Valve 1=Q0.0

Valve 2=Q0.1




















PLC program Explanation:-

In network 1, we have used the test and manual mode logic. If manual mode (I0.0) is on and valve ON/Off (I0.0) switch is on and valve 2 is off then valve 1 (Q0.0) will be ON.

If test mode is selected and valve 1 switch is on then valve 1 will be ON.

In network 2, we have used the test mode and manual mode logic same as network 1

If manual mode is selected and valve 2 switch is on and valve 1 is off then valve 2 will be ON. And if test mode is selected and valve 2 switch is on then valve 2 will be on directly.

Hence in manual mode interlock is required between two valves but in test mode we can test valve easily without interlock.

Automatic overhead tank system.

Automatic overhead tank system.

Application:-Make automatic system for overhead tank in the house. Provide PLC based automatic system so it can control motor as per water requirement. 




Explanation:-

Generally in home we are using overhead tank for water supply in the house. But mostly we are using manual system to fill the tank, in this system we need to check tank level physically and start/stop the motor. So by this application we will make automatic system so it can fill tank as per the level of the tank.

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 start/stop switch and buttons are digital inputs and pump is the digital output. So define digital input address and output address as per below explanation,

 

Digital inputs:-

Start=I0.0

Stop=I0.1

Trip=I0.2

High Level=I0.3

Low level=I0.4

Digital Output:-

Pump=Q0.0




PLC program Explanation:-

In network 1, we have written start/stop logic in this network. When start button is pressed, memory coil will be latched. We have used latching circuit for this so circuit will be latched automatically.

In network 2, in this network we have used pump operation so when low level is detected then pump will be on and if high level detected then pump will be off automatically.

If cycle stop button is pressed during operation, cycle will be off.

If motor trip during the operation, cycle will be off.



Level indications in the HMI for the water tank.

Level indications in the HMI for the water tank.

Application: - There is one level tank in the system and we need to show levels of tanks in the display. Write the PLC program using ladder diagram language. 



Explanation:-

In above application we will not consider all system. We need to add additional feature in the existing system. System already running but we want to add level sensor indication in the display so operator can see level of the tank easily. And he can manage system by observing level in the display.

 

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 high level and low level are digital inputs.

Digital inputs:-

Low level=I0.0

High level=I0.1

 

M memory:-

Low level indication=M0.0

High level indication=M0.1




PLC program Explanation:-

In network 1, we have taken NO contact of low level sensor (I0.0) and operate M coil (M0.0) for low level indication in the display.

In network 2, we have taken NO contact of high level sensor and operate M coil (M0.1) for high level indication in the display

NO contact and NC contact is depended on the sensor type. If you have NPN type sensor then we can use NC contact also.


















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.