Control Exp 7 Student Manual
Control Exp 7 Student Manual
Abstract:
PLC: A Programmable Logic Controller (PLC) is an industrial computer control system that
continuously monitors the state of input devices and makes decisions based upon a custom
program to control the state of output devices. In this experiment, a complete program will be
designed using relay, timer and counters.
Introduction:
In this experiment, students will learn how to program using switch, timer, and counters
using PC45/ML.
The PLC must be able to perform counting and timing operations. Most PLCs have timers
and counters that can be programmed into a ladder diagram. The timer is essentially an
internal clock that can be set to count in set intervals of seconds or parts of seconds. The
number of intervals counted is called the accumulated value (AC). For example, if each
interval is 0.1 seconds and the AC value is 10, then the time elapsed is 1 second.
Timers are used to insert a delay. Timers are enabled so that an output can be activated after a
certain time. During the time the timer is enabled, it continuously increments its accumulator
value by the timing step, until it reaches the preset value. Counters count events. Every time
it is activated, it increments or decrements the accumulator value by one, unless it reaches the
preset value. When a timer or a counter reaches the preset value a DONE (denoted as DN in
the ladder logic diagrams) signal becomes active. To restart timing or counting, the reset
signals have to be active (denoted as RES in the ladder logic diagrams).
A timer is activated by a latched input. That is why it cannot be simply activated by a switch
or an active sensor. However, a counter is generally activated by a switch or an active sensor.
The following figure illustrates this. Note that the input and output addresses are not the real
addresses of the PLC-they are just used to illustrate the above point.
I8
I8 O12 CU/CD
L
O12
RTO END
END
I9
CU/CD
END
Pre-Lab Homework:
You must solve the following questions and make a short report on that before the start of the
lab-
1. Get all the theoretical basics on timers and counters that will be helpful to
implement the experiment.
Apparatus:
Precautions:
Students should take the following precautions while conducting the experiment –
1. Check the computer if it is working; otherwise inform lab instructor,
2. Be careful while handling the power supply buttons of computers and to keep them
off when they are not needed,
3. Check if PLC is working correctly and beware of typing mistakes.
Experimental Procedure:
Be familiar with the RSLogix software. All programming will be done using RSLogix
programming software.
StartProgramsRockwell Software RSLogix 500 Starter.
In following exercise, you will use the Timer ON instruction in order to see how each of its
instruction bits operate in a real-life system.
The following programming exercises primarily require that either a tall or short object is
detected and then thrown off the conveyor. You should note that Sensor 1 can detect only tall
object, while Sensor 2 can detect both short and tall object. Therefore, detecting tall objects
are straightforward; however, detecting short objects are not. If the total number of objects is
known, then it is easier to detect short objects.
Also require timers and counters. Note that the timers should be named as T4:0, T4:1 etc. and
counters should be named as C5:0, C5:1 etc. The timers that should be used here is the Timer
ON (TON) or Retentive Timer ON (RTO). The counters that should be used are Up Counter
(CU) and Down Counter (CD).
Programming Exercise 2:
Design a ladder logic program where pressing of green push button will start the conveyor in
forward direction and after 45 second conveyor will stop automatically.
Programming Exercise 3:
Some objects including both tall and short objects-are passing through the conveyor. Develop
a program that starts the conveyor when green switch is turned on and stops the conveyor
after detecting 5 tall objects.
Programming Exercise 4:
Two objects-one tall and one short-are passing through the conveyor. It is not known which
object comes first. Develop a program to detect the tall object and throw it off the conveyor
through cylinder 1. Use timers.
Programming Exercise 5:
Two objects-one tall and one short-are passing through the conveyor. The tall object should
follow the short object. Develop a program to detect the short object and throw it off the
conveyor through cylinder 2. Use timers.
Programming Exercise 6:
Two objects-one tall and one short-are passing through the conveyor. The short object should
follow the tall object. Develop a program to detect the short object and throw it off the
conveyor through cylinder 2. Use 2 timers or 1 timer and 1 counter.
Programming Exercise 7:
You have to develop a program to perform the following:
(i) Use Sensor 1 on the conveyor to determine if a component is tall or short (Should
be set to detect a tall component only)
(ii) Sensor 2 on the conveyor is used to start timing for either a tall or short
component. (Should be set to detect all components)
(iii) Cylinder 1 (cylinder furthest from the sensors) is operated when a tall component
reaches it.
(iv) Cylinder 2 (middle cylinder) is operated when a short component reaches it.
(v) If the red push button is pressed, the conveyor stops, any timing taking place
should be stopped and the content of Accum held at its last value.
(vi) Pressing the green push button should re-start the conveyor and timing if
previously stopped.
Programming Exercise 8:
1. A press of green push button starts the conveyor in forward direction (using a self-
latch operation) and a press of red push button stops the conveyor. Green lamp comes
on when conveyor starts and red lamp comes on when conveyor stops.
2. If MCR zone is activated, taller objects (detected by both sensor 1 and sensor 2) will
be detected and cylinder 1 is activated to hit the object. For short object (detected by
both sensor 2) cylinder 3 is activated to hit the object.
3. Use two counters. First counter counts no. of short objects and second counters counts
no. of tall objects. Conveyor belt stops when total 5 tall objects and 5 shorts object is
detected.
Interpret the data/findings and determine the extent to which the experiment was successful
in complying with the goal that was initially set. Discuss any mistake you might have made
while conducting the investigation and describe ways the study could have been improved.
Reference(s):
[1] Norman S. Nise, “Control Systems Engineering”, available Edition, John Wiley & Sons
Inc.
[2] An Introduction to Industrial Programmable Controllers, PC45/ML Curriculum Manual,
LJ Technical Systems
[3] Control System Laboratory Manual, American International University-Bangladesh
(AIUB), 2013
Appendix
http://jjackson.eng.ua.edu/courses/ece485/lectures/
Your driver should now be running and look like the picture below.
Close the Configure Drivers dialog box and close RSLinx. Actually RSLinx is now running in the background and you'll probably see its little icon in
the system tray.
Save the project as something like Test.RSS in an easy place to find like My Documents.
RSEmulator 500
The emulator lets us test our work by running a virtual PLC. We'll be able to download our program to it and run it in a very similar fashion to a
real PLC. Start the emulator with the START > All Programs > Rockwell Software > RSLogix Emulate 500 > RSLogix Emulate 500 shortcut. The
emulator is pictured below. I know. It doesn't look like much but it gets the job done.
Believe it or not but the emulator is now ready. Leave it running and go back to your project in RSLogix Micro.
In RSLogix Micro Starter select the Comms > System Comms menu item. The following dialog box will pop up.
In the left hand pane, drill down and select the 01, MicroLogix 1000, TEST processor. Yours might look a little different if you selected different
If successful you'll see the ladder picture spinning round on the online toolbar. To scan the ladder logic put the processor into Run mode by
clicking on the arrow to the right of mode status (REMOTE PROGRAM).
To test the ladder logic, change the input state by right clicking on the address and selecting toggle bit.
You will see the instruction go green indicating it is true and it will make the output instruction turn green also indicating the output is turned on.
That's it! You get all that for the cost of a download. Now break out the manuals and start learning about all the different instructions.