SLC 500 - RS Logix 500 - Sequencing & Timing Query

EKLIH2017

Member
Join Date
Feb 2017
Location
Port Moresby
Posts
10
Hi All,

Am new here. Would appreciate any ideas to help me do some sequence/timing programming am wanting to do.

Am wanting to keep track of how long some devices are in a certain stage for, then based on this, which ever device has been in that stage for the longer time is allowed to proceed onto the next stage(while the others wait).

Basically, want to know how one can compare, say, run times for equipment, in RS Logix 500, to see which has the longer run time.
From what I see, TON and TOF timers, work based on a pre-defined time. I need something that just monitors how long something has been running for and then compares that with other running times to see which is longer.
 
use something like this:
Device On Bit
-||-----------------------------TON 1 sec
TON 1 sec done,
-||-----------------------------second counter +1 (60 sec preset)
second counter done,
-||-----------------------------minute counter +1 (60 min preset) & reset second counter

minute counter done,
-||-----------------------------hour counter +1 (24 hour preset) & reset minute counter
hour counter done,
-||----------------------------day counter + 1 (365 days preset) & reset hour counter

and so on for years..
 
Thanks for the replies guys.
I replied clarifying in detail what am trying to achieve but I don't see that reply in this thread. Must have done something wrong
 
Am probably being a bit too vague here. Will clarify what am trying to achieve here. We have four water treatment plants that are controlled by four slc 500 plcs. Each plant works as a standalone unit, meaning it goes through its stages without regard for what the other plants are doing. One of the stages the plants have to go through is the “regen stage”. This stage is triggered if high conductivity is detected (High Conductivity bit set in PLC) in the plant’s water vessel.
Issue now is, we want only one of the water plants to go in “regen mode” any one time, which means the separate plants will have to start talking to each other. This I will achieve by adding a 5th PLC which will act as a common plc gathering regen and high conductivity status from the plant plcs (they are all currently connected on Ethernet).
The common plc has to determine which of the plants has a high conductivity, and if they do, which one had high conductivity first or has had it for the longest time. It then allows this plant to go into regen mode while the others wait for it to finish it’s regen cycle, before the next one with the longest “wait time” (or the one that had the high conductivity triggered first) can go into regen mode.
Thus, the question about logging time below. Was wanting to track how long each plant had been in high conductivity for, based on the high conductivity bit
 
You could use a TON in each PLC; just set the preset to a high value like 9999 so that it keeps timing for long enough to serve your purposes.

Another way is to use a one-second pulse, or a one-minute pulse, and just a simple ADD instruction.

So, let's say you have a bit that turns on for one scan every minute. If PLC1 needs a regen, then each time that "one minute pulse" bit comes on, you perform ADD N7:0 1 N7:0. This will take the value that is in N7:0, add one to it, and store it back in N7:0. N7:0 now represents the number of minutes that PLC1 has been requiring a regen. Once a regen is no longer required (because it completes), MOV 0 N7:0 or simply CLR N7:0 will reset it back to zero.

Does that help?
 
Have the master collect the conductivity times from each PLC and insert these into a file. The file is searched and the PLC with highest time has its value cleared and is allowed to regen while the others are prohibited from doing so. When finished, the next highest time is searched and so on.
 
Note:
- The counters are ADD instruction.
- Make sure you use L type so it can hold alot of seconds.

- Edit: oh I forgot, after each regen start, clear the counter so you start fresh! :)

This should be your starting point.

Good Luck.jpg
 
Last edited:
Thanks guys. Much appreciated. Will try out the suggestions and advise. I just started another thread on the comms part of this task, to do with Ethernet msgs between the different plcs. Hope you guys can advise as well on that. Am more familiar with Concept and Modicon PLC's, not so much the AB PLCs.
 
I think everyone is over complicating this. You don't need timers at all. All the 5th plc cares is who went into high conductivity last. You need a 4 position queue and that's it. Machine goes high load it's number in position 0. Next machine goes high load it into position 1 of table. Next machine position 2. Each time a machine starts regen shift the table down.

Pos 0 = machine 4
Pos 1 = machine 2
Pos 2 = machine 1
Pos 3 = 0 ( machine 3 not needing regen)

When machine 4 starts regen then table is shifted

Pos 0 = machine 2
Pos 1 = machine 1
Pos 2 = 0
Pos 3 = 0

Now machine 3 needs regen

Pos 0 = machine 2
Pos 1 = machine 1
Pos 2 = machine 3
Pod 3 = 0

No timers involved and you can display thus queue on an HMI...you can even get fancy and delete a machine in the middle if you need to.
 
I think everyone is over complicating this. You don't need timers at all. All the 5th plc cares is who went into high conductivity last. You need a 4 position queue and that's it. .............

It's a good job I scrolled down to see all the replies before submitting an almost identical suggestion to this....;)
 
Hi All,

From what I see, TON and TOF timers, work based on a pre-defined time.

Since you clarified what you needed solved, you might not be as concerned with the timers now. But anyway, you can use the TON to time for an arbitrary time as long as the timer does not meet or exceed the .pre time. Set the pre to 2147483647. This would let the timer run for about 596 hours before it times out (setting the .DN bit and quits timing). If you need more time that that then you need to start using counter or the clock time from the PLC.
 
Since you clarified what you needed solved, you might not be as concerned with the timers now. But anyway, you can use the TON to time for an arbitrary time as long as the timer does not meet or exceed the .pre time. Set the pre to 2147483647. This would let the timer run for about 596 hours before it times out (setting the .DN bit and quits timing). If you need more time that that then you need to start using counter or the clock time from the PLC.

On a RSLogix 500-based system, the highest .PRE value for a timer is 32767. If you set the timebase to 1.0 (seconds) then that gives you a little over 9 hours, which should be fine for this application - but moot point as the OP seems to be sorted for a solution now anyway :)
 

Similar Topics

Hello. I am trying to change the indexes when I Paste from SLC Library and I must be doing something wrong. I tried it with a very simple rung to...
Replies
5
Views
1,448
I have the pleasure of converting a very large SLC program to Studio 5000 for an L81E processor. To cut to the chase, I've come across many COP...
Replies
3
Views
1,919
Good Afternoon , I'm going to be replacing a few SLC 500 PLC's with CompactLogix this year. I would like to keep the PowerFlex 70 Drives in...
Replies
6
Views
2,128
Good Evening , I'm sorry. so many PLC concepts I still struggle with. I need to move some 8 digit numbers from a SLC 500 5/05 processor to a...
Replies
12
Views
3,757
Good Evening , I should know this . How do you force inputs and outputs in a SLC 500 ? On Top right it says Forces Disabled . The drop...
Replies
4
Views
4,009
Back
Top Bottom