SQO instruction

BDKuhns

Member
Join Date
Sep 2003
Location
KC, MO
Posts
78
My last project in this PLC-I class is to utilize the
SQO instruction for a car wash sequence.
I finally got the job done, but I had a problem with
the RSLogic-500 (SQO) instruction set up.
Below is the B3:0 file I used for the stepper file.

15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 Start
0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 Step-1
0 0 0 0 0 0 0 0 1 1 1 1 0 0 0 0 Step-2
0 0 0 0 1 1 1 1 0 0 0 0 0 0 0 0 Step-3
1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 Step-4


The problem I had is this;
On start up of the program, the sequencer would
start at the “Start” word (B3:0). After it stepped through
step-4, it would not return to the start word but jump right
to the step-1 word. I finally got it to run by adding another
start word before step-1.
Is this just a glitch in the program or did I do something
wrong?
 
Your sequencer DOES return to START... How else can it get to Step-1?

I suspect that you are causing the reset properly, but at the same time, I think you are "Stepping" the sequencer. This would cause a "Reset-to-Start" and a "Step".

Take a closer look at the control code you are using for Step-Control.

Make sure that the step-control-code is inactive until you want to step.
 
Terry, I don’t fully understand what you are referring to.
Here is how I set up the SQO.



----------------------
| SQO |
--------||---------------------| |
| File #B3:0 |
| Mask FFFFh |
| Destination O:2 |
| Control R6:0 |
| Length 5 |
| Position < |
|---------------------|

 
Are you saying that Outputs 12,13,14, and 15 Do not flash off?

Do Outputs 0,1,2,& 3 go on once and then never go on again?


I think that maybe you just don't see it.
Do you have a timer running concurrent?
 
BDKuhns said:

The problem I had is this;
On start up of the program, the sequencer would
start at the “Start” word (B3:0). After it stepped through
step-4, it would not return to the start word but jump right
to the step-1 word. I finally got it to run by adding another
start word before step-1.
Is this just a glitch in the program or did I do something
wrong?

It is not a glitch and you did nothing wrong, it's just the nature of the beast. From the SLC500 SQO instruction help:

Length is the number of steps of the sequencer file starting at position 1. Maximum = 255 words (104 words when using the MicroLogix controller). Position 0 is the startup position. The instruction resets (wraps) to position 1 at each cycle completion. For example, placing a 6 in this parameter means 6 elements beyond the starting address (total of 7 elements). A length value that points past the end of the programmed file causes a runtime major error to occur.
 
Gbradley,
No GB, I’m not. What was happening, was when I
loaded the program and set it to run, no lights were
on at the start. (The outputs are lights) When I pushed
the input button once, it step to step-1 and turned on
lights 1,2,3 and 4. Pushing the input again turned off
the first set of light and turned on 5,6,7, and 8.
This correctly goes on until I push the input one final
time which is supposed to turn off 12,13,14, and 15, so
that all lights are off indicating a stopped condition.
This final step reverts to turning the first set of light
back on and running through the sequence from there.

:confused:

Doug_P,
I went back and re-read the chapter in the text book to
see if I missed something. After looking at your msg, I
see that the first word (B3:0) in the bit file is always
going to be a start position, and the looping sequence will
restart a current run at the second word (B3:1). I do not
have the RSLogic prgm here at home, so I couldn’t look in
the help file. Thanks for sharing.

:rolleyes:

I know this seem like a stupit-simple project, the author of
this text does'nt seem to know how to communicate his thoughts.

By the way, Are the instruction set for the PLC-5 and SLC-500 pretty
much the same? I can get a set of the PLC-5's books, but we are
using the SLC-500 at school.
 
Terry Woods said:

Take a closer look at the control code you are using for Step-Control.

Terry, The text that I am using states;

"A sequencer does not have a designated data file like a timer or counter. Since there is no designated data file to store information and status bits associated with the sequencer instruction, the control data file (file 6) will be used. Data file R6 was created for instructions that do not have specific data files assigned."

I understand that the sequencer needs a bit file to operate from, but from this info above, I have no idea how it works or how to correct a control code error.
barry
 
Last edited:
BDKuhns said:

I understand that the sequencer needs a bit file to operate from, but from this info above, I have no idea how it works or how to correct a control code error.
barry

I'm speculating here but I think you're confusing the control 'code' and the control 'register'.

The control code is the ladder logic which triggers the sequencer to advance to the next step. The control data (register) is the PLC structure which manages the internal operation of the sequencer - stuff like incrementing the position word, setting the done bit, etc.

You can get a pretty fair idea of what the sequencer is doing by building one from scratch. You don't need much, a counter, a file of words to hold the step output states, a word set aside to receive the sequencer output, and a MOV instruction to transfer the state words to the output word. Setting up something like this may give you the AHA! experience, since you're controlling the details of the thing.
 
I see now. I remember having to move all of my bits down in the past.
Sometimes I would have a timed sequence, and the timer value was all screwed up, because I thought it was returning to the starting point. It just seems that if you start at B3:0, it should wrap back to b3:0, not b3:1. Go figure!
There is probably a method to the madness?
:rolleyes:
 
The "benefit" to ignoring the initial step during operation is that you can maintain a "startup / alarm" state that is different from all "operational" states.

The simplest ways around your problem are either:

Adding a separate step as you already have done (though I would put it as "Step 5" rather than a "new start step" so that your first transition works properly).

Or moving a -1 into the .POS of your control when you reach the last step and are ready to transition to the "start".

Good luck,

Marc
 
msinclair

I see the light :nodi: and understand. Thanks for the input
I'll go back and flip-flop the added word to the end of the
step list before I present it. :p
 
Off Topic

Barry-
I like your Avatar

I originally thought that the Jet was hiting the sound barrier. In fact the guy who took this
f18nm.jpg

picture swears that he heard the sonic boom when he snapped the photo.
The effect can happen at subsonic speeds.
THe B2 we know cannot break the sound barrier in level flight, but here
b2_ocean_small.jpg


is a picture of a B2 with the same vapor cloud.
Heres a good link on the subject.
 
gbradley,

Thanks for the links! I found this one while studying Physics. The topic was sound and wave forms. The question I presented (which we were not able to answer) was; What is the shape of the cloud on the back side? This particular conndensation cloud looked as if it were the nose end of a conic shape shock wave. This is why I thought it was produced by "High Pressure Shock Wave" that is present when objects pass through and beond Mock-1. During the calc phase of the
exercises, we were able to prove that this effect could happen at lower velocities due to increased humidity and lower saturation temperatures.
 

Similar Topics

I am working on a machine that is using the SQO instruction to step through a cycle, but I am getting lost following it. I have not worked with...
Replies
18
Views
3,459
how does an sqo instruction work with no bit to trigger the next step
Replies
7
Views
1,836
Can someone help converting an SQO in a SLC150 to RSLogix500? See attached JPG also attached the program. Thanks
Replies
4
Views
1,999
I am converting Old SLC 150 Program in an RSLogix 500 I am finding a problem in the understanding of the following instruction can some body help...
Replies
2
Views
1,668
Hi again, im not sure if this sqo will work and cant test it yet. cip1_seq_ctrl4 is a 2 dim array [542,150] N37_14 is a dint that goes from 525...
Replies
1
Views
1,413
Back
Top Bottom