downtime timers

geekwannabe

Member
Join Date
Sep 2021
Location
Michigan
Posts
5
i have a few machines here at my shop that we want to keep track of the machines downtime due to maintenance, i have a 5/03 processor using RS500 platform. i could easily do this with a selector switch to trigger a timer in PLC when operator calls for maintenance but id like to take the idiot factor out of the equation, and have a timer visible from the panel without going online with it. i have no HMI .i could really use some input on this with help as to the writing of the logic. my programming goes as far as modifying and troubleshooting with a laptop, creating logic for this is rarely done on my part.
 
I have done this a few times... I doubt I could find the program but I will look

Just use a input that you know is on when the machine is running, are all the machines connected on a single PLC? give us some more info about the machines and the network (if any)

I remember I had one run timer and one down timer and use simple logic like IF this input and this input and not this one means the machine is running, then move the value to a register this would be my min/hour register and then it was displayed on a local display so everyone could see "todays uptime"

The good thing is I got a raise when the project was done, it really helped with productivity just by making it visible.

Bernie helped me with the AD stuff as the whole project morphed into a really big project, ended up with about 15 PLC's networked and connect just about everything in the plant to it, then did a SCADA project with.
 
@geekwannabe:

I did it with a ML1400 several years ago, so it is easy to convert it to SLC5/03.
It also an OEE calculator included.
Please send me a pm with your email.
It´s free and yours as soon as you send me your message and email .
 
the 3 machines are totally separate and not connected in anyway. they do have 2 separate plc for each machine that work together but each machine is its own entity.
 
@geekwannabe:

I did it with a ML1400 several years ago, so it is easy to convert it to SLC5/03.
It also an OEE calculator included.
Please send me a pm with your email.
It´s free and yours as soon as you send me your message and email .
i sent you my email widelto. i'm new here and really appreciate all your guys input.
 
i have a few machines here at my shop that we want to keep track of the machines downtime due to maintenance ...

May we assume there is some combination of inputs or other bits that defines the current state as either "in maintenance" or "not in maintenance?"


Does this cover only one maintenance event at a time e.g. someone wants to know how long since the current maintenance started, or do you want to track uptime vs. downtime over a months- or years-long period of multiple maintenance events?

What sort of time resolution is desired? Is a single instantaneous sample every 10s "close enough" to represent the entire 10s?
 
time is for a 10 hr shift twice a day. they want to be able to track daily if the machine is down for maintenance or because the operator left machine. and to see if machine is down due to repairs as much as they claim on paperwork. they want it to start keeping track only when machine has stopped and than to start again if machine stops again. giving them a total amount of time it was down. 10s increments are fine. they dont need an exact time down to the second.yes drbitboy i do have inputs showing which motors are running, including the main motor.i considered using the Auto/Manual SS as one signal ina line of several considering when it goes down we usually always put it in manual to narrow down the problem and isolate that region.
 
Last edited:
SLC has an instruction, I think it's RHC for Read High-speed Clock. It will put the current value of a 20-bit 100kHz clock counter into a REAL, so that will repeat every 10.48576s = 1,048,576 (= 2**20) ticks of the clock. So if you use RHC to put the current value into a REAL on each scan, and save the REAL value from the previous scan, the current value will be less than the previous value for one scan every 10s+, so the sequence is

...
RHC current_rhc
LES current_rhc previous_rhc OTE trigger
MOV current_rhc previous_rhc
...


and you can use that trigger as a one shot to decide when to increment one the INT counters MACHINE_IS_RUNNING or MACHINE_IS_IN_MAINTENANCE, and at any time multiplying either of those counters by 10.48576s or (10.48678/60) (10.48678/3600) will give the seconds or minutes or hours the machine has been in each state.

Or the counters could be REALs and you add 10.48576 or (10.48576/60) or (10.48576/3600) to have the desired units directly available.

Or you could use an STI task that runs every 1000ms, or a repeating timer, whatever works to get that regular one-shot.


Or you could skip any attempt at triggering a timed event, and simply count the number of scans the machine is in each state, and assume the average scan is of a constant length; converting to an absolute time would be problematic, but the relative fraction of time the machine is in each state is trivial.


That is probably straightforward; the messy part will probably be the logic that resets the counters at the start of each shift, as well as any logic to save previous shifts' data.
 
Last edited:
I did the same thing for our shop, but it was done using Beckhoff PLCs and written in Structed Text. If you're savvy enough in your skills, most of it could easily be converted to Ladder and written for SLC500. For instance, the code runs locally on the machine and it tracks downtime, even when the machine/PLC is powered off. At 12:00 midnite of the first day of every month, it writes the downtime/uptime results entry to an ongoing text file. Something like ,

"Machine Utilization for the month of AUG-2021 was 89.45%".

I can share for anyone interested in the code. Just PM me. It does use at least one FB from the OSCAT library. So you'll need that too.
 

Similar Topics

I am trying to build a Machine Downtime within the PLC. I was thinking to capture system time but I got tripped on how to store downtime start and...
Replies
17
Views
5,159
Hello, I've been browsing the forum and doing internet searches but i haven't been able to make anything work. What i am trying to do is log how...
Replies
5
Views
2,151
Can someone help me? i want to know what is the exact time of the machine downtime. Which when i go the machine i can just take note of the time...
Replies
9
Views
2,270
Is there are any PLC or HMI programming methods available to reduce downtime by rapid troubleshooting of any alarm in a minute or so? Any...
Replies
18
Views
4,623
Good Morning , Yesterday we had some downtime due to some communication problems with remote Ethernet I/O. I am still a fan of hardwiring...
Replies
9
Views
3,387
Back
Top Bottom