Need some adice on this Sequencer program with dwell time.

Join Date
Mar 2015
Location
KY
Posts
16
I have most of this program finished but wasn't sure on how to do the switches for this program. I worked around it and finished most of it. I will paste the parts for the program and an attachment of what I have.

*Program a sequencer to provide the following sequence if INPUT O (STOP) is CLOSED, and INPUT 1 (START/RESUME) is MOMENTARILY CLOSED.

*Output 1 will be first with .4s dwell time
Output 3 next with .7s dwell time
Output 5 next with .5s dwell time
Output 7 next with .8s dwell time
Output 9 next with .6s dwell time
Output 11 next with .9s dwell time

I have this part done besides the dwell time. Wasn't sure on how to approach this.

*While running, if INPUT 0 is opened, stop the process and turn off all of the outputs. When INPUT 0 is closed, return the outputs in the current state on, but do not resume the pattern until INPUT 1 is momentarily closed. When pattern is resumed, the time in the accumalted value time in the current position should be rest. (use a TON).

This is the one part I did not do because I the switches were giving me hard time.

*After the cycle runs 5 times, stop the process and call a subroutine to alternately flash outputs 1, 5, and 9 and 3, 7, 11 every 1 second. (Considered O/0 an even number). If INPUT 0 is opened, turn off the outputs while it is off, but resume flashing when INPUT 0 is closed.

I have most of this part finished but again the switches I did not know how to approach. So I worked around it.

*Use a second subroutine to reset the cycle counter if Input 0 is opened and INPUT 1 is closed 4 time.

I have this part mostly finished but again the switches part I was not sure about.

Some help would be greatly appreciated!
 
If I could just an idea of how to do the dwell time and some advice on the switches INPUT 0 and 1, I will be okay.

Would a MOV command work for the light operation to flash for their desired time period? I tried putting one in but no luck.
 
Okay, here are some ideas to improve your program:

1. Stop screwing around with Latch and Unlatch. You don't need to use those in this program EVER. Use the Sequencer for the Main routine, and use OTE Outputs for Subroutine 3. Why latch a bunch of stuff ON, that may get left ON accidently just as your instructor starts checking your program? If you don't latch them, but use OTEs, they will go off automatically when the OTEs are deenergized. Make your life easier, use OTEs where possible and feasible.

2. Your Rung 0 has a fatal flaw. The momentary Start/Resume pushbutton will not keep Timer T4:0 running. Didn't you see that big "MOMENTARILY CLOSED" in your instructions? That means that INPUT 1 has a momentary-contact pushbutton connected to it, so it will not stay ON when you release it. That means you need to use a seal-in contact (as about 90% of industrial control circuits use, so you might as well learn how to do this).
INPUT 1 (START/RESUME) is MOMENTARILY CLOSED.
Use a RUN relay bit. I used B3:0/0 as RUN Mode, and made it self-sealing (a XIC B3:0/0 in parallel with the I:1/1 Start/Resume MOMENTARY-CONTACT pushbutton.

3. When you have a sequencer in a program, it is smart to try to use it to turn Outputs ON or OFF, not some external Latch or Unlatch bits as you tried on your Rung 003. Two sets of controls for the same Outputs causes all kinds of trouble. Keep that situation to a minimum. You have to use "double" controls for Sub 3 (repeats some of Outputs in Sequencer), but for limited cases it can be made to work.

4. As for the dwell times, you do need a new idea. Try this: Use the sequencer R6:0.POS value to control the time that is set in T4:0.PRE. For example, the attached picture shows the first 4 rungs. When R6:0.POS = 1, then Rung 2 sets the dwell timer T4:0.PRE to "4" for the first Output 1. When R6:0.POS = 2, Rung 3 sets timer T4:0.PRE to "7" for Output 2. Place these before the Sequencer instruction, so the time is set before the sequencer is triggered to turn on the new Output.

5. Another tip to keep your thinking straight and logical: When you start a new rung, the second thing to do after inserting the blank rung is to add a comment that tells what the rung is supposed to DO. If you can't do that, think about it until you can. If you can't describe the action, most likely you can't write the logic correctly either. For your student problems, you got it easy. All you have to do is regurgitate your given instructions in comment lines, rung by rung until you have all of them covered. In other words, read the directions, then follow the directions for each rung of logic.

Practice Program- Sequencers- Main Rungs 0 - 3.jpg
 
Last edited:
You may struggle with how to trigger the sequencer for hours and hours. Here is how to do that to handle the temporary stop and restart on rungs 8 to 10.

Before you call Sub 3, in the Main Lad 2, when C5:0/Dn goes ON, first use a one-shot to CLR O:2 to turn off all Sequencer Outputs. (You don't want left-over sequencer outputs to interfere with your Sub 3 Outputs.) Then on another rung, when XIC C5:0/DN is ON, JSR Sub 3.

In your Subroutine 3, use one rung with 2 parallel branches. Use a XIC S:4/9 to flash On/Off parallel OTE Outputs 1, 5 and 9. On the second parallel branch, use XIO S:4/9 to flash On/OFF Outputs 3, 7 and 11 at alternate 1-second times. Place a XIC I:1/0 to the left of the parallel branches, to turn off all Outputs when the Stop Switch is OFF.

Practice Program- Sequencers- Main Rungs 8 - 11.jpg
 
Last edited:

Similar Topics

Good evening. I display the step number of a SFC on a display. Sometimes, on a trip, it goes quickly through many steps and I need to prove to...
Replies
1
Views
100
Good morning all. I'm working on a rehab where they had a standalone InTouch 2014 HMI that they called a SCADA, but it's really basic stuff. The...
Replies
4
Views
167
We are trying to poll data coming from a PLC for remote monitoring we have the IP address of the PLC and the default port number and the path is...
Replies
25
Views
543
The idea here is to provide for a brief rapid influx of message codes while preventing sequentially repeating the same message. i.e. if two...
Replies
23
Views
661
Hi all Trying to remotely connect to a TIA Portal PLC. I can ping it without a problem but can't get my software to connect. I've opened port...
Replies
8
Views
310
Back
Top Bottom