I think that this is what you're looking for ...
Greetings Gary,
try the attached program and see if it does what you need ... you’ll probably have to cut-and-paste the rungs into your existing file ... sorry but I didn’t have a MicroLogix handy to try it out on so I used an SLC system instead ... naturally the input and output addresses will be different but you should be able to follow through by paying careful attention to the documentation ... especially the symbols ... post again and ask questions if you need help with anything along those lines ... I’ve debugged about as much as I can using simulator switches, etc. ... naturally I can’t guarantee that I haven’t dropped a stitch here or there ... so pay careful attention to how it works if and when you decide to try it out ...
basically the program is broken down into the following steps (as indicated by the green title bars at the top of each individual section) ...
1. set up a sequencer to cycle through the vacuum pumps
2. decide which pump to use as the first (primary) pump
3. decide which pump to use as the second pump
4. decide which pump to use as the third pump
5. decide how many pumps we need to run (1, 2 or 3)
6. decide which pumps we need to run (A, B or C)
7. decide whether we need to use the sequencer
this is my personal favorite programming approach for a system with requirements like this ... see what you think of it ... one major feature is that it uses individual binary bits to mark the various operating conditions involved in the logic ... some people think that the extra rungs are a waste of time and resources ... personally I think that they help break the program down into individual logical steps and keep each of the rungs as simple as possible ... sure, there may be MORE rungs, but at least each rung is pretty manageable ...
What follows next is my “best guess” as to your system requirements ... PLEASE correct any faulty assumptions ... I’ll be glad to accommodate any programming changes required ... but this is the best I can do based on what you’ve already posted ... if any changes are required, I’d STRONGLY suggest that you cut and paste my description below into a new file and then make whatever changes are necessary ... the step-by-step format is pretty important ... you need to polish up your approach to this part of the programming project if you’re going to stay in this line of work ...
anyway ...
Three vacuum pumps are sequenced to operate one at a time in a simple “relay” fashion. The main purpose of this sequencing is to equalize the amount of operating time among the individual pumps. In normal operation, each pump will be operated for a maximum total elapsed time of 15 minutes before the next pump in the sequence is selected.
The amount of vacuum in the system is sensed by three independent vacuum switches. Switch #1 is set to turn on whenever the vacuum decreases to 18” Hg and turns off whenever the vacuum has reached 23” Hg. Switch #2 is set to turn on whenever the vacuum decreases to 17” Hg and turns off whenever the vacuum has reached 22” Hg. Switch #3 is set to turn on whenever the vacuum decreases to 16” Hg and turns off whenever the vacuum has reached 21” Hg. In addition to controlling the pumps, Switch #3 also turns on various alarms whenever it senses a critically low vacuum.
In normal operation with typical loading, only one pump at a time is required to maintain an adequate vacuum. Under more extreme loading, if the vacuum cannot be maintained by only one pump, then one or both of the other two pumps will be brought online as necessary. The staggered settings of the three vacuum switches are used to determine how many (one, two or three) pumps are required to maintain the required vacuum.
Each pump is provided with a bypass key switch which can be manually turned on whenever a pump is disabled for maintenance or for any other reason. Whenever one of the pumps is bypassed in this manner, the remaining pumps will automatically compensate for the bypassed pump by simply skipping over its position in the sequence without pausing.
In an extreme condition where only one pump is available, the off and on status of that single pump will still be controlled by the three vacuum switches. If the load on the system prevents the single pump from maintaining an adequate vacuum, then the pump will simply run continuously if necessary since no other pumps would be available to be sequenced online.
and a note to everyone else who’s been contributing to this exercise: I’ve only had time to glance at the programs you’ve been posting ... I’m sorry if (maybe) my program rehashes some of the ideas you’ve been cooking up ... I hope to have time early next week to go over what you’ve come up with ... I always learn something new and useful that way ...
I hope this helps ...