Need constructive criticism on this small program

g.robert

Lifetime Supporting Member
Join Date
Aug 2003
Location
texas
Posts
320
I set this up on prologix. I plan to use same on a micrologix 1200.It consist of "hand on control" for both pumps and a system auto. When auto is selected "A" will run for set time then "B" for set time and repeat. If auto is turned off timer values are retained and resumed when auto is reselected.
This is tested and works. My question is could it be done better? Should it be done better? PS. there is a "end" line at bottom rung allthough I believe it will not show up.

[attachment]

timer test.jpg
 
Is it OK if someone runs both motors manually at the same time? Is it OK if someone runs one of the motors manually while the other is running in auto?
If not, condition against these two cases.
As far as the logical idea I think what you have is good.

Keith
 
Might work!

This may work in the Lp simulator, but A-B RSLogix will never let you get away with series coils in the output. And even if it would why would you want to? B3:1/0 and B3:1/1 in series with the timer enable outputs should be in parallel with the timers if you plan to use them. But, why not just use the timer enable bits in place of them and clean up your program some more?
 
Robert

I agree with Alan's comments about DOCUMENTING, but also suggest:

get rid of the "auto run a" outputs (B3:1/0) - also "b", and simply use the Timer Timing bit, eg on the first rung replace B3:1/0 and T4:0/DN with just T4:0/TT. Ditto with the second pump.

M
 
I used the "B" bit as an internal marker which is the way I do it on programable relays. I was unsure of Randy's comment, but Moebius's advice seems to say the same and I understood it. I did not use timing bit because I did not know it was there to use. I will revise and resubmit.

Thanks for the advice and feel free to add more as needed.

Randy are you sure that in an AB PLC this would not work? I now understand that the "B" is redundant and not needed but why would it not work?

FYI my background is 20+ years in motor controls but just now coming to the other side (PLC).
 
In some PLCs, this would work. In AB, it won't work. AB rules state that any output function (of which RTO and OTE (-()-) both are) must be connected directly to the right "power rail".

OTOH, the 'TT' bit in the timer is almost unique to AB. Since the wqy you intend it, B3:1/0 == T4:0/EN, and since, in AB rules, /TT == /EN and NOT(/DN), then your branch of B3:1/0 & NOT (T4:0/DN) == T4:0/EN and NOT (T4:0/DN) == T4:0/TT.

Simple algebra, really.

A quibble of my own: Your annotation of B3:1/0, "AUTO RUN A" is not correct. If it were, then that would be the only bit needed to drive A in the auto mode. But it's not - you need the NOT(T4/DN) bit as well.

But don't let all this criticism get you down - your first program works. And it isn't bad at all. You just asked for improvements, and we're giving you "little known tricks", like the TT bit. I've seen some programmers take YEARS before they find out about that one.
 
I felt compelled to follow through with some of the suggestions. Thanks to all that replied. Some post came after I did this and as such were not addressed. I'm not so sure about the rung info. It seems like allot of extra work. What would you do on the rung comments? If you had 500 rungs, would you add comments on all?
[attachment]

test page1.jpg
 
g.robert,

"pump a hand" sounds like a politician rubbing skin with the public. How about, "Pump-A is Running in Manual" or "Pump-A is in Manual Mode".

The terminology you use is all-important to anyone else that might look at the code... much like we are doing now.

So... what I see is...

  • If A is in Manual but B is NOT in Manual,...
    OR...
    If system is in Auto, while Timer-A is running and Timer-A is NOT Timed Out... then Run Pump-A.

    If the system is in Auto, and neither pump is in Manual, and Timer B is NOT Done, then Run the Timer-A.

    If the system is in Auto, and neither pump is in Manual, and Timer-A is Done, then Run Timer-B.

    If A is NOT in Manual but B is in Manual,...
    OR...
    If system is in Auto, while Timer-B is running and Timer-B is NOT Timed Out... then Run Pump-B.

    When Timer-B times out, Reset both Timers.

It appears to me that you want to be able to run one, and only one, pump manually when you want to. But, if you choose to run the system in Auto, and if neither pump is in manual, you want each pump to run for 20 seconds, alternatingly... maybe.

Now, in terms of actual actions, what I see is...

Any time that Pump-A is in Manual but Pump-B is NOT in Manual, Pump-A will ALWAYS run... even if the System is in Auto! Is that what you want?

Any time that Pump-A is NOT in Manual but Pump-B is in Manual, Pump-B will ALWAYS run... even if the System is in Auto! Is that what you want?

If both Manual controls are OFF and the system is in Auto, you want the Automatic Timer sequence to run.
Pump-A runs while timer-A is running and NOT Done, then when Timer-A is Done, Pump-B runs while Timer-B is running and NOT Done.

I'm not sure, but it appears that Pump-A might be running while Pump-B is running.

If folks are gonna use acronyms, PLEASE, give the Full Name on the first instance! For those of us that refuse to be assimilated... What the Fork is "TT"?

Anyway, Kieffer, the more I look at this code the more I cannot figure out whay your real intention is. Please describe your intent.
 
Terry thanks for the input.
"It appears to me that you want to be able to run one, and only one, pump manually when you want to. But, if you choose to run the system in Auto, and if neither pump is in manual, you want each pump to run for 20 seconds, alternatingly... maybe."

not maybe, but exactly.

"Any time that Pump-A is in Manual but Pump-B is NOT in Manual, Pump-A will ALWAYS run... even if the System is in Auto! Is that what you want?"

you can't select auto if a pump is left in manual.

"I'm not sure, but it appears that Pump-A might be running while Pump-B is running."

They can never run at the same time. They are electrically enterlocked within the logic.

Lastly, the TT (which I only found out about through this post) was pointed out by Randy.

Thanks for everyone's input. I believe I can make most any app work ,but I wanted ideas for things I might be missing that a seasoned PLC pro would not. I think I picked up a few pointers, thanks again.
 
Last edited:
Are these switches..is Auto a maintained switch and manual A or B a momentary pushbutton or switch? Interlocked so if its in Auto then A or B cannot be manually engaged and a 3 position switch or momentaries for manual so neither can be run at same time?

I will try something tommorrow
 
Last edited:
Re: AB speak

randylud said:
TT is A-B speak for the bit on a timer that is true when a Timer is Timing. TT, Timer Timing, catchy huh?

TT can also stand for Torture Terry... :p

beerchug

-Eric
 
rsdoran, all switches (manual A, Manual B and system auto) are 2 position maintained selector switches.
 

Similar Topics

I'm fairly new to Rockwell software, I've had some basic training in the past but nothing too advanced. My company and I use Reliable products for...
Replies
11
Views
303
Hi all, I am having issues accessing my Cimplicity software - the site code changed after re-install and I am no longer able to attain a new key...
Replies
10
Views
158
Good day all! Can someone help me with the procedure to update Beijers E700 firmware? The Panel I am working on is firmware 2.04v and I would...
Replies
1
Views
64
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
126
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
180
Back
Top Bottom