EET3370 – Programmable Logic Controller Basics

 

Lab 7 – SLC500 Sequencers

 

Initial lab written by Rob Gonyer Class of 95

rev. 10/24/00 rff
rev.
2/19/04 mnp

 

PURPOSE

 

The purpose of this exercise is to introduce you to the sequencer instruction.  The sequencer instruction is one of the most powerful functions on the PLC.  In this lab, you will program the SQO sequencer output instruction, and will demonstrate it with the SLC-500.

 

APPLICABILITY CRITERIA

 

The functions in this lab allow you to program sequencing functions used predominantly for machine and machine line control operations.  The sequencer function is designed to replace, in particular, drum switches, and therefore can be used in a wide variety of applications.

 

 

 

 

1.         [___]   Program the ladder below.  The steps to implement the sequencer follow the diagram.

 

 

|     I:1     T4:1                _TON___________________      |

|-----| |----|/|-----------------|Timer on delay         |     |

|       0       DN               |Timer            T4:1  |--EN-|

|                                |Time Base        0.01  |--DN |

|                                |Preset           300   |     |

|                                |Accum              0   |     |

|                                |_______________________|     |

|                                                              |

|                                                              |

|      T4:1                       _SQO___________________      |

|-------|/|----------------------|File           #B12:0  |     |

|          DN                    |Mask           FFFFh   |--EN-|

|                                |Destination     O:2.0  |--DN |

|                                |Control         R6:1   |     |

|                                |Length             4   |     |

|                                |Position           0   |     |

|                                |_______________________|     |

 

Please see next page…
SQO Instruction Summary:

           

            File Address:  #B12:0

§         This is where the sequencer reads its data.  We will enter the data later.

            File Mask:  FFFFh

§         This information determines which bits will pass through to the output.  1’s or F’s allow data to pass, 0’s do not.  You can use any combo, but for purposes we will use FFFFh (the lower case h stands for Hexadecimal).

            Destination:  O:2.0

§         This tells it where to output the data to.  In our case, we will use the first data word of output slot #2.

            Control:  R6:1 

§         Control file number.  This is the logical address of the sequencer instruction.

            Length:  4

§         You will be writing 4 words of data, plus there is an initialize word which makes 5 actual words used.                    

            Position:  0

§         Specifies which word to start with.

 

 

2.         [___]   Now you will enter the data into the file B12:0.

 

Open file B12 using project tree on left side of your screen.

 

You will then see 5 rows of binary numbers.  You can point and click around and edit them as you wish.  Each bit corresponds to an output.  A 1 is on, and a 0 is off.  The first line will be your first sequence, the second your second, and so on.  Make the bits look like this:

 

B12:0              0000   0000   0000   0000

B12:1              0000   0000   1111   1111

B12:2             1111 1111     0000   0000

B12:3             1111   1111   1111   1111

B12:4              0000   0000   0000   0000

 

 

3.         [___]   When finished entering the bits, download and run your program.  Watch your outputs after you turn Input 1 on.  After you have seen that it cycles through this pattern:

 

a)     All lights off

b)     8 lights on

c)      Other 8 lights on

d)     All lights on

e)     Repeat

 

Demonstrate your program’s operation to your instructor.  Initial ______


4.         [___]   Now modify your SQO instruction to alternate between even numbered outputs and odd numbered outputs.  You will need to change your length to 2, and modify your file content again.

 

Demonstrate to your instructor.  Initial _________

 

 

5.         [___]   Start a new program.  Build a program that will emulate a traffic light when input 1 is turned on.  To help you along, here are the states and the time each state is on:

 

State1 - NS green on, EW red on, 3 sec.

State2 - NS yellow on, EW red on, 1 sec.

State3 - NS red on, EW green on, 4 sec.

State4 - NS red on, EW yellow on, 2 sec.

Repeat back to state 1.

 

Use the following addressing for the lights:

 

O:2/8               NS Red                                  O:2/12            EW Red

O:2/9               NS Yellow                               O:2/13            EW Yellow

O:2/10            NS Green                               O:2/14            EW Green

 

Demonstrate to your instructor.  Initial _______

 

Print a copy of your traffic light program and staple it to your lab submission.

 

DELETE ALL THE FILES YOU CREATED WHEN YOU ARE FINISHED WITH THIS LAB.