You are on page 1of 44

Lab 8 Part A: PLC Fundamentals with

MicroLogix 1100/1400
Presenter: Peter Bell
MicroLogix and PanelView Component Regional Product Manager
Please DO NOT take this manual!

PLC Fundamentals with MicroLogix 1100/1400

Contents
Before you begin......................................................................................................................................... 5
About this lab ................................................................................................................................................ 5
Tools & prerequisites .................................................................................................................................... 5
Lab A1 Creating a New Project............................................................................................................... 7
Launching RSLogix Micro Programming Software ....................................................................................... 7
Creating a New Controller Project ................................................................................................................ 7
Examining Your New RSLogix Micro Project................................................................................................ 9
Creating the First Rung of Ladder Logic ..................................................................................................... 10
Creating the second ladder logic rung ........................................................................................................ 16
Creating the third ladder logic rung............................................................................................................. 22
Verifying your ladder logic program ............................................................................................................ 22
Saving your work......................................................................................................................................... 24
Lab A2 Testing Your Ladder Logic ...................................................................................................... 25
Power cycle your MicroLogix 1100/1400 demonstration box ..................................................................... 25
Downloading your ladder logic to the PLC.................................................................................................. 25
Changing the PLC from Program to Run mode .......................................................................................... 29
Monitoring and testing your PLC ladder program ....................................................................................... 30
Lab A3 Using Basic Instructions in Ladder Logic.............................................................................. 32
Changing the PLC from Run to Program mode .......................................................................................... 32
Copy and Rename your previous ladder logic program ............................................................................. 32
Modifying your existing ladder logic program.............................................................................................. 33
Adding a timer to your ladder logic program ............................................................................................... 35

3 of 44

Adding a counter to your ladder logic program ........................................................................................... 36


Adding a Limit instruction to your ladder logic program.............................................................................. 38
Adding rung comments to your ladder logic program ................................................................................. 39
Saving your work......................................................................................................................................... 40
Changing the PLC from Program to Run mode .......................................................................................... 41
Testing and monitoring your completed PLC ladder logic program............................................................ 41
Demonstration Box Button Description for this Lab............................................................................. 44

4 of 44

Before you begin


Before you begin this Hands-On Lab, please be sure to close any applications that are currently running.
For this lab you will need to complete all sections in order, because each section builds upon the previous
section.

About this lab


This session provides you with an opportunity to explore the basics of programmable logic control using a
MicroLogix 1100 or MicroLogix 1400 PLC. The following sections explain what youll be doing in this lab
session, and what you will need to do to complete the hands-on exercises.

Tools & prerequisites


You have the following materials that will allow you to complete the labs in this workbook.
(1) 1763-L16BWA

MicroLogix 1100 (10 DC Inputs / 06 relay outputs, 120 VAC power)


OR

(1) 1766-L32BWA

MicroLogix 1400 (20 DC Inputs / 12 relay outputs, 120 VAC power)

(1) Ethernet Switch


(10) Pushbuttons

Labeled DI0 through DI9

(6) Lights

Labeled DO0 through D05

5 of 44

RSLogix Micro programming software v8.10 (CPR9)


RSLinx Classic v2.54 (CPR9)

6 of 44

Lab A1 Creating a New Project


In this lab, we will introduce you to the basics of programming a PLC using the MicroLogix 1100 or
MicroLogix 1400 controller and RSLogix Micro programming software. You will:
Create a new project
Write 3 rungs of ladder logic to start and stop a simulated motor
Save your project to the hard drive of the PC
Download this project to the MicroLogix controller at your lab station
Monitor and Test your program on-line with the MicroLogix controller

Launching RSLogix Micro Programming Software


In this section of the lab, you will launch the RSLogix Micro software, which will allow you to program your
MicroLogix controller.
1. From the Windows start menu, select Start > Programs > Rockwell Software > RSLogix Micro
English > RSLogix Micro English as shown below:

Creating a New Controller Project


In this portion of the lab, you will create an offline project for your MicroLogix 1100/1400 controller.
1. Maximize RSLogix Micro by clicking the maximize Icon
the RSLogix Micro window.

in the upper right hand corner of

2. From the toolbar menu, select File > New, or click on the New File icon, to create a new controller
file.

7 of 44

3. Enter the Processor Name as M-LAB1 as shown below.


4. Using the down arrow or mouse click, select the MicroLogix 1100 Series B or MicroLogix 1400
Series A controller.

At this time you do not need to make any changes to the communications
settings
5. Once you have selected your controller all that is left is to click OK.
6. From the toolbar menu, select File > Save As and then click Save as shown below.

8 of 44

7. If the following prompt appears, click Yes to replace the file.

Examining Your New RSLogix Micro Project


In this section of the lab, you will use the following display to review the RSLogix Micro programming
environment.

A: Project Viewer
Controller information/setup = Series Revision, Configuration Information
Program Files - Where ladder logic is entered
Data Files - Where data values are stored
Force Files - Where you can override the state of the I/O with a forced value, so an input that is
turned on by an external sensor may be forced off even when the sensor is turned on. Or a relay
output may be forced on, even when the program running in the controller did not turn it on.
Custom Data Monitors = User Configurable Data monitor registers, which allows a user to manipulate
user program information (beyond the scope of this course)

9 of 44

B: Program Viewer
Where Programs reside
Where ladder logic is entered
C: Program TABS
When a program file is open a TAB is created
Allows easy/quick access to program file content
D: Instruction Buttons
Drag & Drop, or Double Click
Must have Program Viewer Active
E: Tabbed Toolbar
Instructions grouped by function.
Floating Toolbar Support

Creating the First Rung of Ladder Logic


1. Verify that the ladder editor in RSLogix Micro is active by clicking in the white space below:

2. Click on the User tab.

10 of 44

3. Locate the New Rung button.

4. Click and hold the New Rung with the left mouse button and drag the icon to rung zero (0000).
5. When you see the green X on rung zero release the left mouse button.

Rungs can be thought of as the means to get current from the left rail to the
right rail. In simple relay ladder diagrams, wires did exactly that.
6. Verify that your RSLogix Micro program window appears as shown below.

The lower case e to the left of the ladder logic indicates the rung is in edit
mode.
Our empty rung represents a dead short, so we need to add the conditions that define
when we want current to flow, or actions to take place. We will start by adding an input
instruction to our blank ladder rung. An input instruction gives the controller information that
it interprets as the cause component of cause and effect. Given the proper inputs
(causes) the controller will generate specific outputs (effects).

11 of 44

7. Click on the Bit tab to show the bit level instructions.

8. Click on the Examine if Closed ( XIC ) instruction and drag the instruction to your new rung.

9. When you see the green X, release the mouse button.

The XIC instruction eXamines if an Input is Closed (a.k.a. normally open


contact).

We now need to provide an address for our new XIC input. The address tells the ladder
logic where to look for the input. PLCs use addressing where Relay Logic (or hard-wired
logic) used the physical connection of wires to make a circuit.
If at anytime you wish to delete a rung or instruction from your program simply
select the rung or instruction (Highlight it red) and press the delete key on your
keyboard or right mouse click and select delete.

12 of 44

10. Make sure your XIC instruction is highlighted, type I:0/0 and press Enter.

11. When the description window appears, enter the description as shown below and click on OK.

Adding a description is not required; however, it is good practice for program


documentation and for future troubleshooting. This will allow you to later read
your program, and understand it much more easily.
12. Verify that your ladder rung appears as follows:

Now let us add an output instruction to this rung. This represents the effect, as discussed earlier.

13 of 44

13. From the Bit tab, click and drag an OutpuT Energize OTE instruction
below. As before, when you see the green X release the mouse button.

to the rung as shown

Again we need to provide an address for our new OTE output.


14. Make sure the OTE instruction is highlighted, type O:0/0 and press Enter.

There is a difference between the letter O (which stands for Output), and the
number 0.

14 of 44

15. Enter a description as shown below and then click on OK.

16. Verify that your ladder rung appears as follows:

If your addresses do not look the same, make sure that you are properly using
the letter O and the number 0.

Congratulations you have just created your first rung of ladder logic!
When the conditions on the input (left) side of a rung are met, the instruction on the output (right) side of
the rung will be executed. In this case, the OTE instruction will be executed whenever the XIC instruction
is evaluated as true. In other words, when the input (InputButton0) is closed or turned on at address
I:0/0 the result will be the output (Light0 on the controller) will be turned on at address O:0/0.
The inputs and outputs in your ladder logic can be physical, real outputs like the relay output shown
above, or can be virtual or a bit stored in the data table. You use physical outputs for controlling external
devices but you may want to create virtual outputs to identify when something turns on or off other parts
of your ladder logic program.

15 of 44

Creating the second ladder logic rung


We need to start a new rung. So lets insert a new rung into our program. You can do this either by the
method we used in the previous section (Click/Drag) or you can try another method:
1. Select rung 1 (0001) and simply press the Insert key on your keyboard.
You will now see a new empty rung in your ladder logic program as shown below.

Lets add the first input instruction to this new rung just as you did in the previous section.
2. Click and Drag an XIO instruction
button.

to rung 1 until you see the green X, then release your mouse

The XIO instruction eXamines if an Input is Open (a.k.a. a normally closed


contact).

16 of 44

3. With the newly added XIO highlighted, enter the address I:0/1 and then press Enter.

4. Add a description as shown below and click OK.

When finished, your rung should appear as follows:

Lets add a second input instruction on rung 1.

17 of 44

5. Click and drag an XIC instruction


(eXamine If Closed) down to rung 1, to the right of our XIO
instruction, until you see the green X, then release your mouse button.

6. Using what you learned in the previous steps, address this new instruction as I:0/2 and add a
description of StartButton. When finished your rung should now look like this.

Putting serial conditions on the rung allows us to look for AND conditions. In
this case we are asking if the Stop Button is not pressed AND the Start Button is
pressed. Both conditions have to be true for the rung to be true.

7. Add an OTE instruction


(OutpuT Energize) to rung 1 and address it as O:0/1. Add a description
of Motor1 so that your rung appears as follows:

18 of 44

Now lets add a Branch to rung 1.

Branches allow for either / or programming. For example, we would use


branched rungs if we wanted to indicate that either Pushbutton 1 or Pushbutton 2
could be used to turn on an output.

8. Click on the User tab and then click and hold the left mouse button to drag the Rung Branch
button in between the XIO (StopButton) and the XIC (StartButton) instructions on rung 1.
9. When you see the green X as shown below, release the mouse button.

10. Verify that your rung appears as follows:

19 of 44

We must now identify what the either / or decision will be. To do this, we need to move the branch
around our Start Button.
11. Click and hold on the right side of the branch leg (the part highlighted red). Drag the branch leg to the
right side of the Start Button. When you see the green X, release the mouse button.

Your rung should now appear as follows:

We now need to add an input instruction on our branch.

20 of 44

12. Using what you learned in the previous steps, click and drag an XIC onto the new branch you just
created and address the new XIC as O:0/1.

Your completed rung should appear as follows:

You will notice you are entering the same address for this XIC instruction as the
output address of your OTE instruction. This is the power of the PLC. What you
have just accomplished is the PLC equivalent to auxiliary contacts on a motor
starter that allow you to create a Seal In circuit. By adding this branch with the
OTE address the motor will now stay on when the start button is released, until
the stop button is pressed.

21 of 44

Creating the third ladder logic rung


1. Using what youve learned so far, add another rung as shown below.

Verifying your ladder logic program


Program validation or a verification, checks the program you have written for errors. After verification is
completed the Results window will open and gives you information about mistakes or omissions that may
have been found as your program logic was inspected by the software.
There are two types of program verification. The first one verifies the file you are currently working in and
only this file. The second verifies all files (Main and Subroutines) for the project you created. Because our
program only resides in File #2 we will use the first program verification method.
1. Click on the Verify File button as shown below:

When the verify has completed and no errors are found all program edit markers (the e to the left of
the ladder rungs) will disappear and no errors found will be displayed at the bottom of the RSLogix
Micro software screen.
2. If no errors are identified in your logic program proceed to the next section Saving Your Work.

22 of 44

3. If you have errors in your logic program, those rungs containing the errors will still show the edit
markers (the small e beside the rung number) as shown below:

4. If the Verify Results window doesnt open automatically, select View > Results from the toolbar menu
or simply press ALT+1.
5. Click on the error message in the Verify Results window and you will notice RSLogix Micro highlights
the ladder rung and instruction that contains the error.
6. Go back through the previous lab and correct your error(s).

Common errors are using letters instead of numbers such as ( O instead of 0 )

7. After correcting your error(s) verify your file again.


8. Once all errors are fixed proceed to the next section Saving Your Work.

23 of 44

Saving your work


Your project is still not stored on your computers hard drive. Save your program to prevent your work
from being lost.
1. Click on the Save button

or from the toolbar menu select File > Save.

2. If the Revision Note box appears, click OK.

The revision note box will appear. RSLogix 500 software is automatically
configured to allow you to enter notes on version changes of your program and
back-up older versions of your program as you make changes. This allows you to
quickly go back to an older version if you make a mistake. The number of
revision copies is configurable and can be turned off if you do not desire to have
this feature active.

24 of 44

Lab A2 Testing Your Ladder Logic

Power cycle your MicroLogix 1100/1400 demonstration box


1. Switch the demo box power switch off (O) for several seconds and then back on again (1). This
will reload a default ladder program from the memory module into the MicroLogix 1100/1400.

Downloading your ladder logic to the PLC


1. From the RSLogix Micro toolbar menu, select. Comms > System Comms.

2. Expand the AB_ETHIP-1 driver by clicking on the + sign in front of the driver.
3. Highlight the MicroLogix 1100 or 1400 at 192.168.1.2 as shown below:

25 of 44

4. Click Download. If the revision note window appears simply click OK.

5. You will be asked to confirm the download click YES

26 of 44

6. You may then be prompted to replace the controllers communications settings with your new project
settings. Simply click YES.

7. If the controller is currently in remote RUN mode and executing a program the following screen will
appear asking to switch the controller to the remote PROGram mode to begin the download. Simply
click YES.

The MicroLogix 1100/1400 controller has a mode switch that is accessible using
the LCD display and buttons located on the controller. The software is able to
change the controllers mode only when the controller is in the remote RUN or
PROGram mode. If the Mode Switch on a MicroLogix 1100/1400 controller is in
the Run position or the Program position, the software program will not be able to
change the operating mode.
You will see the download progress window appear as the download occurs.

27 of 44

****************************************IMPORTANT******************************************************
8. You may be prompted to apply communications channel changes if your program settings are
different then what is configured in the Micrologix. Since we made no changes to how the MicroLogix
1100/1400 communicates, if this screen appears, simply click Dont Apply.

****************************************IMPORTANT******************************************************
9. Just click OK if you get the following message:

10. If your controller was in the RUN mode prior to the download RSLogix 500 will ask if you wish to
switch the controller back into the RUN mode. Click NO. We will manually switch into the RUN mode
in a later step.

28 of 44

11. You will then be asked if you wish to Go Online with your controller. Click YES.

Changing the PLC from Program to Run mode


1. Click on the down arrow next to REMOTE PROG as shown below:

Notice there are three (3) Run selections for the PLC:

Run scans the program and outputs are enabled

Test Continuous scans the program and the outputs are disabled

Test Single Scan performs one scan cycle with outputs disabled

2. Click Run.
3. When asked Are you sure you want to change processor mode to RUN? click Yes.

29 of 44

Monitoring and testing your PLC ladder program


With the PLC now in Remote Run, you can monitor or edit data within the controller. This allows you to
make program debugging changes and change data variables while in the run mode.
You can also use the LCD display of the MicroLogix 1100/1400 to see I/O status as well as other
attributes of the controller. See example below.

COMM1
Ethernet Status

Controller
Mode
(it may also
say
REMOTE
meaning
Remote
RUN)

Input Status

Output Status

So now lets examine your ladder logic in operation. (If needed, you may refer to the button location at the
end of this lab document)
When green bars are shown on either side of ladder logic elements this indicates Logical Continuity,
which helps determine how the application is operating and is designed to help you in debugging your
application ladder logic. In a relay logic model, this is the same as current flowing.
1. To test rung 0, enable (Press and hold) InputButton0 (DI0) on the demonstration box, examine the
display of your MicroLogix controller and rung 0 in your RSLogix 500 project.
2. Light0 (DO0) will turn ON and in your ladder program you see InputButton0 and Light0 highlight
indicating that the input switch and output have been turned on. Also notice on the LCD display that
Output 0 is also turned on.

3. To test rung 1, press and release (ON then OFF) StartButton (DI2). Motor1 (DO1) will illuminate on
the demonstration box. Notice StartButton and Motor1 in your MicroLogix 1100/1400 program is
also highlighted indicating an energized or on condition.

Inputs and Outputs are numbered 0,1,2, etc. This means that address I:0/2 is
actually the third button on the demonstration box.

30 of 44

Notice that even after you release StartButton, Motor1 continues to stay on. The logic decision
between StartButton and Motor1 in our input circuit is an OR. If either StartButton is pressed, or
Motor1 is energized, Motor1 will stay running. This is a perfect example of a latching circuit also
called a 3-wire control circuit. If you toggle StopButton (DI1) on the demonstration box, you will see
that Motor1 will de-energize or turn off.

The two inputs on rung 2 are the outputs of rungs 0 and 1. RunningLight will energize (Turn On)
when the two inputs are true. So in other words, the outputs from rung 0 and rung 1 must be ON or
TRUE to turn on our RunningLight. This is an example of AND ladder logic.
Go ahead, give it a try - turn on your RunningLight.

31 of 44

Lab A3 Using Basic Instructions in Ladder Logic


We are now going to take your program from Lab #2, modify two rungs, and create some new program
logic. We are also going to program a timer and counter in our program to see how they can be used to
provide unique control capabilities. The last thing we will do is program a Limit command. The limit
command is one of several powerful comparison instructions available in a PLC controller.
One capability that the MicroLogix 1100/1400 shares with larger Allen-Bradley programmable controllers
is online editing capability. This is the ability to make changes to the ladder logic while online with the
controller, even while the controller is in RUN mode!

Changing the PLC from Run to Program mode


1. Click on the down arrow next to REMOTE RUN and select Program.
2. Click Yes when asked if you want to change the processor mode to PROGRAM.

Copy and Rename your previous ladder logic program


1. From the toolbar menu, select File > Save As to create a copy of your program.
2. Type the File name M-LAB3 as shown below and then click Save. Select Yes to Replace existing
File? if the file already exists.

32 of 44

3. Click Yes when prompted with the following:

Modifying your existing ladder logic program


First, let us add an XIO Instruction to rung 1.
1. Since we are still online, you must double click on rung number, 0001, in order to put it into edit
mode. The es by the rung indicates that it is now in edit mode. Notice that a duplicate of the rung
appears just below it with rs by it (for replace):

2. Click on the User tab.


3. Click, hold and drag the XIO
to the location between the branch and the OTE (remember when
you see a green box, release the mouse button).

33 of 44

4. With the XIO instruction highlighted type C5:0/DN and then press Enter.
5. When asked to enter a description, type CounterDoneBit and press OK.
6. Click on the rung number, 0001, and then click on the Accept Current Rung Edits checkmark:

7. The es will disappear and your modified ladder logic should appear as shown below:

34 of 44

Now, lets Modify the first XIC instruction on rung 2.


8. Double click on the rung number, 0002, to put it into edit mode and then double click the first XIC
instruction in rung 2.
This will open the text edit box for the instruction.

9. Type T4:0/DN and press Enter.


This will overwrite the existing address.

This is one of the most powerful features of a micro controller, the ability to
change the operation of a program through software. To do the same thing in
relay logic, an electrician would have to disconnect the wire from a normally open
contact (our InputButton0 in rung 0) and wire it to the done or output of a timer.
Besides avoiding the obvious potential for miss-wiring and the time it would take
to do the wiring, the micro controller has the benefit that the timer is already built
in.

10. When asked to enter a description, type Timer done bit and click OK.
11. Verify that your rung now appears as follows:

12. To accept the changes, click on the rung number, 0002, and then click on the Accept Current Rung
Edits checkmark, as before. The es by rung 0002 should disappear.

Adding a timer to your ladder logic program


1. Click, hold and drag the New Rung button over 0003. Remember, with rung 0003 selected, you can
also simply press the Insert key to add a new rung as rung 0003.
2. Click, hold and Drag the XIC button onto the left side of the rung you just created.
3. With the instruction highlighted, type O:0/1 and Enter.

35 of 44

Notice as soon as you entered the address O:0/1 the description Motor1 was
automatically shown. Once an address has a description associated with it, that
description is carried throughout your ladder logic program.
Your rung should now look like this

Now lets add the Timer Instruction.


4. Click on the Timer/Counter tab near the top of the RSLogix 500 software.
5. Click, hold and drag the TON (Timer ON delay) onto the right side of the rung you just created.
Remember when you see the green x this indicates a valid location for you to place the instruction.
6. Enter the following parameters for the timer. Double-click on the Timer parameter in the TON
instruction.

Timer: T4:0 This is the address of the timer. Press Enter

Description: Motor On/Off Timer. Click OK

Time Base: 1.0 This is the increment that the timer counts, 1 second per count. Press Enter

Preset: 10 This is the value the timer must reach to be done. Press Enter

Accum: 0 This is the elapsed time of the timer while counting. Press Enter

Your rung should now look like this:

7. To accept the changes, click on the rung number, 0003, and then click on the Accept Current Rung
Edits checkmark, as before. The es by rung 0003 should disappear.

Adding a counter to your ladder logic program


Using what you have learned so far, add a new rung 0004.
1. Add a XIC onto the left side of the rung you just created.

36 of 44

2. Address the instruction as O:0/1 and then press Enter.


Your rung should now look like this:

3. Click on the Timer/Counter tab.


4. Click, hold and drag the CTU (CounT Up) onto the right side of the rung you just created.
5. Enter the following parameters for the counter. Double click on the Counter parameter in the Counter
instruction:

Counter: C5:0 This is the address of the counter. Press Enter

Description: Motor On/Off Cycle Counter. Click OK

Preset: 10 This is the value the counter must reach to be done. Press Enter

Accum: 0 This is the number of counts that the counter has recorded so far. Press Enter

Your rung should now look like this:

6. To accept the changes, click on the rung number, 0004, and then click on the Accept Current Rung
Edits checkmark, as before. The es by rung 0004 should disappear.
Now we need to add an instruction so we can reset our counter.
7. Add a new rung (rung 0005).
8. Add a XIC button onto the left side of the rung you just created.
9. Address the instruction as I:0/3 and then press Enter.
10. Enter the description Motor On/Off Counter Reset Button and click OK.
11. Click on the Timer/Counter tab and drag the RES button onto the right side of the rung you just
created (this instruction will allow us to reset our counter).

37 of 44

12. The address we will use for our RES instruction is C5:0.
Your rung should now appear as follows:

The function of the RES or reset instruction in our program is to zero out the
accumulator of our C5:0 counter whenever I:0/3 is energized.

13. To accept the changes, click on the rung number, 0005, and then click on the Accept Current Rung
Edits checkmark, as before. The es by rung 0005 should disappear.

Adding a Limit instruction to your ladder logic program


1. Add a new rung (rung 0006).
2. Click on the Compare tab and drag the LIM (Limit instruction) onto the left side of the rung you just
created.

The LIM instruction will allow us to compare the value of our timer against
predetermined limits.

3. Enter the following parameters for the LIM by double-clicking on each parameter in the Limit
instruction:

Low Limit: 1 This is the low limit we will use for our comparison. Press Enter
Test: T4:0.ACC This is the value we will be evaluating; If asked to enter a description simply
leave it blank and click OK
High Limit: 7 This is the high limit we will use for our comparison. Press Enter

The LIM instruction is true when the timer is between 1 and 7 seconds. The
question marks will disappear when you accept the rung edits.
Lets now add an output instruction to our LIM rung.
4. Click on the Bit tab and drag the OTE button over to the right side of the LIM rung you just created.
5. Address the instruction as O:0/4 and press Enter.

38 of 44

6. Following our good programming practices, label your new output address Motor Starting Light.
Your rung should now look like this:

7. To accept the changes, click on the rung number, 0006, and then click on the Accept Current Rung
Edits checkmark, as before. The es by rung 0006 should disappear.

Adding rung comments to your ladder logic program


1. Right click on rung 0006 and select Edit Comment.

39 of 44

2. Select File/Rung and type the description While the timer accumulator is between 1 and 7 seconds,
the LIMit instruction will turn output #4, the 'Motor Starting Pilot Light' ON.

3. Click OK to accept your changes.

Rung Comments can be used to describe in detail the function of a rung of ladder
logic. This is a good programming practice, and a great feature of RSLogix 500
programming software.
Your rung should now look like this:

Saving your work


1. Click on the Save button.

40 of 44

2. Click OK for Revision Note box.


3. Click Yes to the Warning! About Data Table changes.

Changing the PLC from Program to Run mode


1. Click on the down arrow next to REMOTE PROG.

2. Select Run and then click Yes when the following window appears.

Testing and monitoring your completed PLC ladder logic program


Using the buttons and watching the lights does your program work the way you expect? (If needed, you
may refer to the button location at the end of this lab document)
Lets examine your ladder logic in operation.
1. RUNG 0 - Enable DI0 on the demonstration box and DO0 will illuminate. Examine the LCD of your
MicroLogix controller and you will see Input 0 turn on. In your ladder program you will see
InputButton0 and Light0 highlight indicating that the input button and output have been turned on. If
you turn off InputButton0 then Light0 will turn off.

2. RUNG 1 - Watching your ladder logic carefully, Press and release (ON then OFF) StartButton or DI2
on the demonstration box. Notice Motor1 turns on. Also notice that on rung 3 the timer begins to time
because its input condition Motor1 has been turned on and the counter has incremented by one
count.

41 of 44

Even after you release DI2 StartButton the motor continues to stay on and the timer continues to
time. This is a perfect example of a latching circuit also called a 3-wire control circuit. Toggle
StopButton DI1 on the demonstration box. You now see that Motor1 turns off and the timer stops
timing.

3. RUNG 2 The two inputs on rung 2 are the T4:0 done bit and Motor1. The output RunningLight is a
condition of these two inputs. In order for our RunningLight to turn on the timer needs to time for 10
seconds and be done and Motor1 must be on. Only then will RunningLight or DO3 on the
demonstration box turn ON. So once the motor has been running for at least 10 seconds the
Running Pilot Light will come on.

4. RUNG 3- In order for our Motor On/Off Timer the TON to start timing Motor1 must be on. The
Timer starts timing once the motor begins running up to speed.

5. RUNG 4- Each time Motor1 is toggled from Off to On our Motor On/Off Cycle Counter the CTU will
count up by one. This will allow us to keep track of how many times our motor has been turned on
and off. This will help us to schedule maintenance appropriately.

42 of 44

6. RUNG 5- When Motor On/Off Counter Reset Button our counter reset switch is energized this will
reset counter C5:0 back to 0 . When we perform maintenance on the motor, we can reset the counter
to keep track of the next maintenance cycle.

7. RUNG 6- While our Motor On/Off timer accumulator is between 1 and 7 seconds, the LIMit
instruction will energize our Motor Starting Light and illuminate DO4 on our demonstration box. This
gives us the indication that the motor is spinning up to speed. DO4 then turns off after 7 seconds to
conserve the use of our pilot light.

8. Close RSLogix Micro.

CONGRATULATIONS!!
YOU HAVE JUST COMPLETED
THE BASICS OF PLCs
HANDS ON LAB

43 of 44

Demonstration Box Button Description for this Lab

StopButton
StartButton

Motor On/Off Counter


Reset Button
InputButton0

Motor Starting Light

Light0
Motor1

Running Light

44 of 44

You might also like