Help with Micro 1000 program

GMc:

Since we now have a better idea of what your trying to do, take a look at the attached program.

Again it was something I threw together quick, and has NOT been debugged. But, it might give you some ideas.

Basically, I left the timer and sequencer in the main program and then, I run a different subroutine based on the number of pumps required.
In the first routine, I used you sequencing logic and got rid of the other stuff.
In the 2nd routine, I just changed the sequence output form XIC to XIO, should result in sequencing one pump off.

3rd routine, all pumps run if not disabled.
 
Great program from Ken, use the last version.

Remove the orgn_prg subroutine though.

...What would you say is the problem with my program??

Those three bits in the sequencer togle from 0 to 1 in order, only one of them is 1 at any given time so the addittion that you made rung 6,7,8 might bring two pumps on in one time but never three, also you may want to review the use of the "pump off" bits in those rungs.
 
Eugen

Please forgive me but I just can't see what you meant by..

Those three bits in the sequencer togle from 0 to 1 in order, only one of them is 1 at any given time so the addittion that you made rung 6,7,8 might bring two pumps on in one time but never three

The addition I made to rungs 6, 7 & 8 is for in the event I shut down a pump for service another pump will be available to turn on. 2 pumps is all that could run if I have one off.

If no pumps are turned off and all 3 VC switches are true, all pumps will run..

review the use of the "pump off" bits in those rungs

Whats wrong with these bits??

Thanks,
Gary

P.S. Ken, do you see the same problems?? I have to run.. I'll get back with you.. Thanks
 
Last edited:
grs

The attachment you posted looks identicle to mine.. Did you post the right file??

Ken

Looks great. Could you please explain though the reason it's better than mine. I really appreciate the help but if I don't ask I will never know what mistakes I made or how to write code efficiently myself. I really want to learn the best way to design code myself.. Who knows, maybe I will be able to help someone on this forum someday.

Thanks,
Gary
 
GMc,
I don't know that my program is any better or any worse than yours. Often there are hidden "gotchas" that do not show up until you test your logic. There are always many ways to do the same thing. Different programmers use different techniques, some better, some worse, a lot of times, it's re-using what you know worked before. Although it may not be the best solution.
I drive to work using my left hand, and have a cup of coffee in my right, you may drive with both hands on the wheel. We both get to work, but your method is safer, mine does two things at once hehe. Which is best?

As for my program vs yours, assuming they both work correctly, I believe mine would be easier for someone else, (not you or I), to understand and follow in the future.


Just my .02

Ken
 
Last edited:
Ken,

Ok, thanks for all your input and time doing so.

I am currently building a test box with a extra Micro Logic 1000 we have so I can test the code before putting it into place.. Being a hospital I can't just shut the machine off and play with it all day..

Plus good ole Dell has not shipped my laptop yet..

Thank you again and everyone else for helping me try and make things more efficient for our Vetrans.

One other thing Ken, do you know what Eugen was saying in his last post.. He's got my brain working in overtime..

Those three bits in the sequencer togle from 0 to 1 in order, only one of them is 1 at any given time so the addittion that you made rung 6,7,8 might bring two pumps on in one time but never three, also you may want to review the use of the "pump off" bits in those rungs.

Gary
 
I posted the right file. My logic is in ladder file 10 - I just didn't document is as such.

Ken's most recent program is best and takes into account all three pumps running - which mine doesn't. The only thing I'd really question is the use of a sequencer for this application as you said you wanted a simple approach.

I think Eugene may have been talking about your original program, as Ken's doesn't have a rung 7 and 8 in any of the subroutines.
 
grs,

Ok, I will look again for yours.. (just currious)

No, Eugen was talking about my lattest code, rungs 6, 7, & 8 and I can't figure out what he's saying.. I don't see the problem he see's

Gary
 
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 ...
 
OK, I added a bit more to my attempt. It's in ladder file 10 (which I documented this time).

Maybe I'm missing something here or not completely understanding how this is supposed to work but it seems to me that using sequencers and jumping to several different subroutines is a bit of overkill for this (not trying to sound ****y or condescending). I'm not able to test my program but to me it looks like it should work the way I understand your system to cycle without using a sequencer, in one ladder file, and only 8 rungs of logic.

Let me know if I'm out to lunch or if this is what you're looking for.
 
Ok first I am confused is grs and GMs the same person or not??


And then I am a little more clear about the programs :D I dont know what you are trying to do but I can see what the program you wrote is doing.

I will try to say this without a ladder logic first.

1 One program writen from grs (the last one) is trying to achive the original request from GMs every time a vacum is requested turn on a pump and cycle between them every given amount of time and it works ok but that is it, we need more after latest GMs revelation:

2 there are three levels of vacums detectet and when more vacumm is required (all dentists are back from vacation and all of them are working?? strange) turn on two pupms at the SAME time and cycle the off period (so every motor can rest) When even more vaccum is required (one dentist is working and there is a cut hose) turn on all three motors at the Same time. This is what Ken's program is doing and is very easy to read great to troubleshoot for a wireman :) Thanks Ken

Naturally both programs include the service request switch. The only minor ( which can be fixed very easy) problem is that the sequencer is working even when the motors are off and after the OFF cycle the same motor might start again, but after this the cycle continues.

As for your program GMs it does not apply to any of the above scenarios and the service request feature does not work.
 
Last edited:
Eugen,

First of all grs and GMc are 2 different users. (not even spelled the same)

The only minor ( which can be fixed very easy) problem is that the sequencer is working even when the motors are off and after the OFF cycle the same motor might start again, but after this the cycle continues.

This has never been a problem because of the ammount of vacuum used by doctors and probably even leaks that are present at the instrument connections. The sequencer that cycles a new motor every 15 minutes isn't that critical. The main idea is to NOT have a motor sit for a LONG period of time without running. In a 8 hour time period I can guarantee you that each of the 3 pumps will run quite a few times which is fine.

As for your program GMs it does not apply to any of the above scenarios and the service request feature does not work

Well Eugen, the original program that I posted at the beginning has been working for about 6 years without a hitch. It does EVERYTHING your saying it won't do except the motor bypass that I added. The additions that I made surely won't keep it from working the way it did before. I don't know what your missing.

Thanks
Gary
 
The previous post was from me..

I don't know why it's knocking me out before I get the message posted..

Sorry

Gary
 
Ron Beaufort,

the step-by-step format is pretty important

Sure makes a difference. Looking at the examples you all have posted here one can really understand whats going on.

Thanks, it looks great. I got in late tonight but I will look at it better over the weekend.

Thanks again,
Gary
 

Similar Topics

Hi all So I made this PLC learner box with 6 toggle switches and some push buttons I have it all wired up and all set. However I am having a...
Replies
2
Views
1,431
iam new at this, so be nice,,,lol can anyone tell me if the 300 micro can control a timer, and can it change the a fifu outpout bit and if so how...
Replies
13
Views
3,864
I recently had an employee quit but before doing so he put a password on the processor does anybody know how to get around this??? The PLC is a...
Replies
3
Views
5,604
Hi! I need help converting an old MicroLogix 1100 project to Micro 820. Project Details I have an old MicroLogix 1100 program that has been in...
Replies
0
Views
464
Hello, first assignment with A-B stuff. The CPU is a MicroLogix 1000. Have a serial interface, so RS Linx Classic to edit the driver (AB-DF1) with...
Replies
7
Views
1,676
Back
Top Bottom