You are on page 1of 32

EXPERIMENT 1

AIM: To study the terminology and LADSIM software and develop simple basic circuits on
software using input and output and develop AND, OR, and Not circuits.
SOFTWARE REQUIREMENT: LADSIM software
THEORY: LADSIM stands for LADDER SIMULATOR, is a fully-functional Ladder Logic
Editor and PLC Simulator that incorporates all the basic functions used in PLC Programming.
With Inputs, Outputs, Timers, Counters, Flags and Shift Registers available, we can develop
ladder programs quickly and easily. Each function is simply 'dragged' onto the ladder rung with
name tags assigned via a pop-up window. Extra rungs can be added with the click of a button,
together with branches to form more complex programs.
LADSIM incorporates seven 'real' process simulations that will test our understanding of Ladder
Logic Programming. For each simulation we must develop the necessary ladder code to effect
safe control of the scenario. The simulations provided within LADSIM are a Traffic Light,
Annunciator, Car Park, Lift, Drinks Machine, Packing Line and Bottling Plant. While LADSIM
can be used as a stand-alone teaching aid with its library of internal simulations, it also has the
added benefit of being capable of controlling external applications via one of our PC Internal
Interface cards.

The LADSIM Editing Screen


The main screen of LADSIM is where the main ladder program is created.
1. The Ladder Logic Diagram Window: This is where the ladder code is displayed. Each
time you add or edit a rung, the result will be shown here.

Fig1. Ladder logic diagram

2. The Controls box: This contains the ladder symbols that are used to create the ladder
diagram. See below for further details.

Fig2. Control box


3. The toolbar: This includes the standard buttons of LADSIM and allows you to start a
new diagram, open an existing file, print, save and comment your ladder diagram.

Fig3. Tool bar


The LADSIM Controls
1. Ladder logic programs are made up of symbols that represent the various inputs and
outputs of the plant equipment we wish to control. LADSIM uses the same symbols to
produce the ladder code on screen and each one is defined below :
2. LADSIM features a total 12 inputs, 12 outputs, 8 timers, 16 counters, 16 flags, 4 shift
registers and 12 reset functions for the timers and counters.
Creating a Ladder Diagram

1. A ladder diagram can be quickly generated by 'dragging' the required controls from the
control panel and dropping them on the rung. In LADSIM, once we have dropped a
control onto a rung, a box appears where we can enter information about that control.

Fig4. Dragging a rung


Testing your Diagrams
Once you have created a piece of ladder code it is important to ensure its correct operation before
applying it to a real control problem. LADSIM has a unique testing facility built into the package
so you can test and debug the ladder programs created in LADSIM.
The Debugging Simulator is activated by clicking on the simulate button or the debugger from
the simulate menu. LADSIM's debugging simulator gives you access to the various inputs used
in your program. Here you are able to force the inputs simply by clicking on the button and
examining the result. All the information provided will help with the debugging and testing of
your ladder diagram within a safe environment.

Fig5. Debuggig simulator

PROCEDURE: Following are the steps to be followed to create AND, OR and NOT circuits in
LADSIM software:
AND Gate: The AND gate is a basic digital logic gate that implements logical conjunction - it
behaves according to the truth table given below.. A HIGH output (1) results only if both the
inputs to the AND gate are HIGH (1). If neither or only one input to the AND gate is HIGH, a
LOW output results. In an
another
other sense, the function of AND effectively finds
the minimum between two binary digits, just as the OR function finds the maximum.
maximum Therefore,
the output is always 0 except when all the input
inputs are 1s.
INPUT OUTPUT

The AND gate with inputs A and B and output C implements


the logical expression
.

A.B

1 1
1
STEPS:
a) Open the LADSIM software. Go to the toolbar, click file tab and
select new.
b) Now the ladder logic diagram window will be open. From control box select add
rung. A new rung is added to the ladder logic diagram space.
c) After adding rung go to the controls where we will see the symbols of inputs, outputs
etc. select input with symbo
symbol
as input and drag it to the rung named rung 0.
d) When we place the input in the space a new window will open showing the input
name. Select the new input as input0.

e) Again repeat the step (C), and (d). Name the new input as input1. The new input
input1 is placed in series with the input0.
f) Now from the controls table select and drag the output symbol
to the rung0.
A new window will be open showing various outputs, select the output0.

g) Now go to the control table and press the button


to open the debugging
simulator window.
h) Close the input0 and input1 together to get an output. The high output is indicated by
the red signal.

OR Gate: The OR gate is a digital logic gate that implements logical disjunction - it behaves
according to the truth table given below. A HIGH
GH output (1) results if one or both the inputs to
the gate are HIGH (1). If neither input is high, a LOW output (0) results. In another sense, the
function of OR effectively finds the maximum between two binary digits, just as the
complementary AND function finds the minimum.

The OR gate with inputs A and B and


output Q implements the logical expression Q = A+B.

INPUT OUTPUT
A B
A+B
0

STEPS:
a) Open the LADSIM software. Go to the toolbar, click file tab and select new.
b) Now the ladder logic diagram window will be open. From control box select add
rung. A new rung is added to the ladder logic diagram space.
c) After adding rung go to the controls w
where
here we will see the symbols of inputs, outputs
etc. select input with symbol
as input and drag it to the rung named rung 0.
d) When we place the input in the space a new window will open showing the input
name. Select the new input as input0.

e) Again repeat the step (c), and (d). Name the new input as input1. The new input
input1 is placed in parallel with the input0.
f) To place new input parallel to the previous one, select
from the control
box, and specifies the location of the new branch as per the given fig below.

g) Now from the controls table select and drag the output symbol
to the rung0.
A new window will be open showing various outputs, select the output0.

h) Now go to the control table and press the button


to open the debugging
simulator window.
i) Close either the input0 or input1 to get an output. The high output is indicated by the
red signal.

NOT Gate: In digital logic, an inverter or NOT gate is a logic gate which implements logical
negation. The truth table is shown on the right.
INPUT OUTPUT
The NOT gate with inputs A and
output OUT implements the logical expression OUT = NOT A.

NOT A

STEPS:
a) Open the LADSIM software. Go to the toolbar, click file tab and select new.
b) Now the ladder logic diagram window will be open. From control box select add
rung. A new rung is added to the ladder logic diagram space.
c) After adding rung go to the controls where we will see the symbols of inputs, outputs
etc. select input with symbol
as input and drag it to the rung named rung 0.
d) When we place the input in the space a new window will open showing the input
name. Select the new input as input0.

e) Now from the controls table select and drag the output symbol
to the rung0.
A new window will be open showing various outputs, select the output0.

f) Now go to the control table and press the button


to open the debugging
simulator window.
g) Close the input0 and the output is always low. The low output is indicated by the
black signal. As soon as the input is open the output is high, and the high signal is
shown by the red signal.

RESULT: The terminology and LADSIM software is studied and simple basic circuits
AND, OR, NOT on software using input and output were developed.

EXPERIMENT-2
Aim-To study the use of latch, timers , counters ,BSR,BSL in LADSIM Software.
Equipment\Hardware Required-Networked Computer
Software Requirement-LADSIM Software
Theory-Latch is a retentive output instruction. Latch can only turn on a bit. This instruction is
usually used with Unlatch with both Latch and Unlatch addressing the same bit. Actuating the
latch input turns the function on or causes it to change state. The function then stays on even if
the latch input is turned off. To turn the function off, another input must unlatch which turns the
function off.
With timers, counters one can edit their ladder code easily and quickly. A counter might be used
to count up or count down and then activate a contact. When counting down, you must also enter
a number in the accumulator equal to or smaller than the count. The contacts close when the
accumulator is decremented to zero. When counting up, you should have zero in the accumulator
and the contacts close when the accumulator is incremented to the same value as the number of
preset counts. Each time a BSR( bit shift right) is done with bit 15 being replaced by a 0, the
binary number is divided by two.
If BSL is used (Bit Shift Left), all the bits are shifted left with the LSB being replaced by a zero,
the binary value is doubled.
Using LADSIM diagram, this is a sample program using branches . The screenshots of the ladder
program are shown below.

The output of the above program is shown below

TIMERS
Timer are used in Ladder programming in Rungs and a preset value is fed into it. These are used
to delay the proogress from the current rung to the next rung by the preset seconds.
A sample program in which timer was used is shown in the figure below.

The output of the above program is shown below.

COUNTERS
As tha name suggests, counters are used to count. They are mainly employed in industries in
which we have to perform counting function.eg. in conveyor belts where the number of goods
passing through that conveyor belt are counted.
In LADSIM a preset value is fed into the counter after which it is reset. A sample program with
output using counter is set and reset position is shown below.

SHIFT REGISTERS
Another facility available in LADSIM package is the Shift Register, this function uses a 16 bit
word in its operation. There are two type of shift registers in ladsim (BSR) and (BSL). Each time
a BSR( bit shift right) is done with bit 15 being replaced by a 0, the binary number is divided
by two.
If BSL is used (Bit Shift Left), all the bits are shifted left with the LSB being replaced by a zero,
the binary value is doubled. The program and its output is shown in the figure below.

Viva Voice Questions


Q1) What does resetting a Timer mean?
Ans- An ON condition to this function clears all mailbox inputs, outputs, resets all timers to
inactive state, and clears all latched relay bits. All integer variables will be cleared to zeros and
all string variables will be assigned to empty string.
Q2) What advantage does shift register have?
Ans- A shift register may be multidimensional, such that its"data in" and stage outputs are
themselves bit arrays , this is implemented simply by running several shift registers of the same
bit-length in parallel. Shift registers can have both parallel and serial inputs and output.
Q3)How can we use shift registers?
Ans- In digital circuits, a shift register is a cascade of flip flops, sharing the same clock, in which
the output of each flip-flop is connected to the "data" input of the next flip-flop in the chain,
resulting in a circuit that shifts by one position the "bit array" stored in it, shifting in the data .

EXPERIMENT NO. 3
Aim: To study the various pneumatic- and actuation and control valves available in the
laboratory & develop basic circuits A+A-with start-stop buttons& A+B+A-B-with and without
start-stop buttons.
Equipment: Pneumatic compressor, direction control valves, PU4 tubes, limiting switch
actuators.
Theory: Pneumatic and hydraulic systems use directional control valves to direct the flow of
fluid through a system. They either completely open or completely closes the devices. Such
on/off deices are widely used to develop sequenced control systems.
Common type of directional control valve is the spool valves. Another common form of D.C.
valve is the poppet valve. This valve is normally in the closed condition, there being no
connection between the parts to supply pressure to the system. When the push button is pressed,
the ball is pulled out of the seat and flow across the ports. When the button is released, the spring
forces the ball back up against its seat and so closes off the flow.
There are various ways by which the valves can be actuated, such as: Push button
By pedal
By plunges
By levers
By roller
By pneumatic pressure
By spring
By solenoid
Solenoid operated valve is actuated by passing a current through a solenoid. Thus is can be used
for electro pneumatic purposes.

Circuit Diagrams/Connections:

Figure 1:: Circuit for sequence A+


A+A- with Start/Stop switch

Figure 2:: Circuit for sequence A+B+A


A+B+A-B- with Start/Stop switch

Figure 3:: Circuit for sequence A+B+A-B- without Start/Stop switch


Procedure:
Sequence A+A- With Start/Stop Switch.
1. The pneumatic circuit is connected as shown in the circuit diagram 1.
2. The compressor is turned on so that air supply is turned on to the pneumatic system.
3. Push the button of the push button valve.
4. The air supply is switched off to cylinder A which starts extending.
5. The air is supplied to cylinder A which starts extending.
6. At the end of extension, cylinders piston handle strikes the limiting switch a+.
7. Limiting switch a+ turns on the right side of the valve.
8. Air is then supplied to the other end of cylinder A & it starts compressing.
9. To restart the sequence A+A
A+A-, step 3) to 8) are followed again.

Sequence A+B+A-B- With Start/Stop Switch.


1. The pneumatic circuit is connected as shown in the circuit diagram 2.
2. Push button is pressed after turning on the compressor.
3. The cylinder A starts extending and actuates limiting switch a+.
4. This switch activates the left position the valve 3 and cylinder B also starts
sta
+ +
extending. In this way A B sequence is obtained.
5. Full extension of cylinder B activates limiting switch b+. This switch activates right
position of valves 1 and cylinder A starts compressing.

6. On full compression, limiting switch a- is activated which activates the right portion
of valve 3 and cylinder B starts compressing.
7. In this way the sequence A+B+A-B- is completed using push button.
8. To repeat the sequence, push button is pressed again.

Sequence A+B+A-B- Without Start/Stop Switch.


1. The pneumatic circuit is connected as shown in the circuit diagram 3.
2. Compressor is turned on.
3. The left position of valve 1 is activated and cylinder A starts extending.
4. Limiting switch a+ is activated which activates the left position of valve 2.
5. The cylinder B starts extending and on full extension, switch b+ is activated.
6. The right position of the valve 1 activates & cylinder A starts compressing.
7. Switch a- is activated and this activates right position of valve 2. Cylinder B starts
compressing and the switch b- is activated, this actuates the left position of the valve 1
again.
8. Thus the sequence A+B+A-B- is continuously repeated.
9. To stop the sequence, compressor is turned off.

Result: The sequence A+A- with start-stop buttons & A+B+A-B-with and without start-stop
buttons is obtained using pneumatic kit and direction control valves.
Precautions:
1. The connecting pipes should not be bent and their length should be minimum.
2. Compressor should have a safety valve and a pressure gauge.
3. PU4 tubes should not be pulled without unlocking the connectors.

Experiment no.- 4

AIM
To develop an electro pneumatic circuit of the given sequence A+ A- on the electro pneumatic
using solenoid operated valves and relay switches.

EQUIPMENTS
Pneumatic compressors, direction control valves, relay switches, connecting wires, PU4 tubes.

THEORY
Relays are electrically operated switches in which changing a current in one electric circuit
switches a current ON/OFF in another circuit. Relays are often used in control systems because
relays are inductances, they can generate a back voltage when the energising current is switched
OFF or when their input switches from a high to low signal. To overcome this problem, a diode
is connected across the relay. When the back emf occurs, the diode conducts and shorts it out.
Such a diode is termed as free-wheeling or flyback diode.
Time-delay relays are control relays that have a delayed switching action. The time delay is
usually adjustable and can be initiated when a current flows through the relay coil or when it
ceases to flow through the coil.
PROCEDURE:
1.
2.
3.
4.
5.
6.
7.
8.

Connect the pneumatic circuit as shown.


Connect the electrical circuit as shown.
The pneumatic compressor and electrical circuit swtich is turned ON.
The left side solenoid is activated initially and cylinder starts extending.
Limiting switch A+ is activated which changes the current in the relay coil.
The relay coil then activates the right side solenoid and cylinder starts compressing.
The limiting switch A- is activated and the current in relay coil is changed again.
Relay coil switch the current to the left side solenoid and the sequence A+A- is repeated
again.
9. To turn OFF the system, electrical switch and the pneumatic compressor is turned OFF.

24/11/2014
R2-DC-2
R2-DC-3
R2-DC-4
R2-DC-5
R2-DC-6
R2-DC-7
R2-DC-8
F
R1-DC-1
R1-DC-2
R1-DC-3
R1-DC-4
R1-DC-5
R1-DC-6
R1-DC-7
R1-DC-8
R1-AC-1
R1-AC-2
R1-AC-3
R1-AC-4
R1-AC-5
R1-AC-6
R1-AC-7
R1-AC-8
R2-AC-1
R2-AC-2

R1

R2-AC-3
R2-AC-4

ON

R2-AC-5

OFF

R2-AC-6
R2-AC-7
R2-AC-8

R2

L1

L1

L1

L2

L2

COM

ND

NC

COM ND

L2

L4

L4

NC

COM ND

L4

L3

L3

NC

COM ND

L3

S1

S1

S2

S2

NC

EXPERIMENT NO. 5:
AIM: To automate a traffic control unit using LADSIM software
software.
Equipment/Hardware Required:
Software Required:
Circuits:

Networked Computer.
LADSIM Software.
Make the circuit as shown in the procedure.

Procedure:
STEP 1
Open ladsim and make the input and output latch as shown in fig.1.

Fig.1
STEP 2
Then go to add rung and add 1 rung and then add inputs and timer ( set time 5sec) as shown in
fig 2.

Fig. 2
STEP 3
Then go to add rung again and add input (T1/DN) and a reset (T1) and add branch and then add
latch (OP1) as shown in fig. 3

Fig. 3
STEP 4
Again go to add rung and add the input
input(OP1) and timer (T2 -5sec) ass done in fig. 4

Fig.4
STEP 5
Then again add rung and add input (T2/DN) and then add unlatch output at the end of rung and
then go to add branch and click in between the rung and at the end then go to controls and drag
unlatch and put
ut it in the box as shown in th
the fig and do it for all the things you want to add in the
rung. And finally the fig will be like the one as shown in the figure 5

Fig.5
STEP 6
Then again addd rung and go to controls and add input (OP2) and put it in start and then timer
(T3) at the end and put time-55 sec
sec.

Fig. 6

STEP 7
Then again add rung and add input (T3/DN) and the unlatch (OP2) and then add branch in
parallel to the unlatch one and put a reset tool for T3 as shown in fig. 7

Fig. 7
STEP 8
Go to simulation on top left of the window and click on eith
either
er debugger or traffic light. and u
will get the window like this

Fig. 8
VIVA VOCE
1) How many timers are available in LADSIM?
Ans: There are eight timers available in LADSIM.
2) How many counters are available in LADSIM?
Ans: There are eight counters available in LADSIM.
3) How many flags are there in a LADSIM?
Ans: There are sixteen flags in a LADSIM.
4) How many inputs and outputs are in LADSIM
LADSIM?
Ans: There are twelve inputs and outputs in LADSIM.

EXPERIMENT NO.-6
AIM- To program a vinytics make PLC through keypad and develop basic programs to
demonstrate use of inputs , outputs , AND & OR.
EQUIPMENT/HARDWARE REQUIRED- Vinytics make modular PLC , keypad and UPS.
THEORY- A programmable logic controller, PLC or programmable controller is a digital
computer used for automation of typically industrial electromechanical processes, such as control
of machinery on factory assembly lines, amusement rides, or light fixtures. PLCs are used in
many industries and machines. PLCs are designed for multiple analogue and digital inputs and
output arrangements, extended temperature ranges, immunity to electrical noise, and resistance
to vibration and impact. Programs to control machine operation are typically stored in batterybacked-up or non-volatile memory. A PLC is an example of a "hard" real-time system since
output results must be produced in response to input conditions within a limited time, otherwise
unintended operation will result.

COMMAND DESCRIPTION
The VMC-PLCT has 28 keys and six seven segment displays to communicate with the outside
world. As VMC-PLCT is switched ON , a message PLC 51 is displayed on the display and all
the keys are in command mode. The keyboard is shown below.

Keyboard description
RESET- resets the system
SHIFT- provides a second level command to all keys
CHK (check)- checks the status of output of only higher stage and if it is lower stage it goes to
next line.
GOTO- unconditional jump to levels
CNT- counter
ANI- AND inverse
RST- reset the input.
LD- inputs
SER(serial command)- for RS232C communication with PC
END- end the program
TIM- timer
EXEC- for execution
COUNT- to set the delays or number of counts in timer and counter
SET- to set the input/output. Once the output is set, it remains high until it is reset
LDI- load inverse
OUT- output
ORI- OR inverse
PRE(previous)- previous is used as a immediate terminator in case of exam memory

NEXT- increments the program counter


ORB- OR block
EXAM(examine memory)- allows user to examine instructions
SEC- second
IL(interlock)- to interlock the execution after any particular command
ILC(interlock clear)- to clear interlock for further execution
EN(enable counter)- to enable the counter
BLANK- this key is used for execution of a command
BM(block move)- allows user to move a block form monitor to RAM area
OR- logical OR
AND- logical AND
0 to 9- numeric keys
If instead of a valid command the user gives a data, then system will display -err.

SAMPLE PROGRAMS
UNDERSTANDING PROCEDURE OF WRITING PROGRAM LOGICS
Input (either high or low) are given at the input ports (X00-X07 and X10-X17) and the output is
obtained at the ports (Y20-Y27 and Y30-Y37).
Here X00 controls the output port Y20.
Example 1
Implement the following ladder network using PLC.
X00
Y20

PROGRAM
LD 00 NEXT
OUT 20 NEXT

END
NEXT BLANK BLANK NEXT EXECUTE
Now, when PLC is connected to the power supply and a +5V is given to the 00 port the
corresponding output port 20 also goes high and the LED glows
LOGIC
X00
Y20
H
H
L
L

Example 2
Implement the following ladder network using PLC
X00
Y20
X01

Y21

Program
LD 00 NEXT
OUT 20 NEXT
LDI 01 NEXT
OUT 21 NEXT
END
NEXT BLANK BLANK NEXT EXECUTE
LOGIC
X00

Y20

X01

Y21

ON
OFF

ON
OFF

ON
OFF

OFF
ON

Example 3
Implement the following ladder network using PLC
X00
X01
Y20

X00

Program
LD OO NEXT
AND 01 NEXT
OUT 20 NEXT

X02

Y21

LD
00 NEXT
ANI 02 NEXT
OUT 21 NEXT
END
NEXT BLANK BLANK NEXT EXECUTE
LOGIC
X00
X01
X02
Y20
ON
ON
ON
ON
OFF
ON
ON
OFF
ON
OFF
ON
OFF
OFF
OFF
OFF
OFF
ON
OFF
OFF
OFF

Y21
OFF
OFF
OFF
OFF
ON

Example 4
Implement the following network
X00

Y20

X01
X01
Y21
X02
Program
LD 00
OR 01
OUT 20
LD 01
ORI 02
OUT 21
END

NEXT
NEXT
NEXT
NEXT
NEXT
NEXT
NEXT BLANK BLANK NEXT EXECUTE
LOGIC
X00
X01
Y20
X01
X02
0
0
0
0
0
0
1
1
1
0
1
0
1
0
1
1
1
1
1
1

Example 5

Y21
1
1
0
1

Implement the following network


X00
Program
LD 00 NEXT
X01
OR 01 NEXT
LD 02 NEXT
OR 03 NEXT
ANB NEXT
OUT 20 NEXT
END
NEXT BLANK BLANK NEXT EXECUTE

X02

Y20

X03

LOGIC

Example 6
Implement the
network using PLC

X00
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1

X01
0
0
0
0
1
1
1
1
0
0
0
0
1
1
1
1
X00

X02
0
0
1
1
0
0
1
1
0
0
1
1
0
0
1
1

X03
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1 ORB

X02

Program
X01
X03
LD 00 NEXT
AND 02 NEXT
LD 01 NEXT
AND 03 NEXT
ORB NEXT
OUT 20 NEXT
END
NEXT BLANK BLANK NEXT EXECUTE

Y20
0
0
0
0
0
1
1
1
0
1
1
1
0
following ladder
1
1
1 Y20

X00
ON
OFF
ON
ON

X01
OFF
ON
OFF
OFF

LOGIC
X02
ON
OFF
OFF
ON

Program 7
LD 00
NEXT
SET 20
NEXT
LD 01
NEXT
RST 20
NEXT
END
NEXT BLANK BLANK NEXT EXECUTE
LOGIC
X00
X01
ON
OFF
OFF
ON

X03
OFF
ON
OFF
OFF

Y20
ON
ON
OFF
OFF

Y20
ON
OFF

Program 8

LD 00
TIM 60
# 50
LD 60
OUT 20
END

NEXT
NEXT
NEXT
NEXT
NEXT
NEXT BLANK BLANK NEXT EXECUTE

X00
ON

LOGIC
TIM60
ON (after 5 sec)

Y20
ON