Scan time...?

shoelesscraig

Member
Join Date
Apr 2009
Location
LA
Posts
382
I've got a program in a SLC 5/03 processor (16k). I am experiencing scan times (according to the processor status menu) of about 15-19ms on average. And if I look at the max scan time, it will be WWAAYY up there, like 1500ms or something, if I reset it and come back later, it will be high again. Is this about normal?? I'm not having any problems or anything, I'm just wondering. I have seen other programs that are much faster, of course I know every one will be different depending on a variety of things. Thanks guys.
 
No 1500ms is not normal. 15-19 ms is not so bad for an SLC5/03.
Did the CPU not fault ? If the scantime hits the set watchdog (S:3 ; high byte), it will generate a major fault.
If it did not fault, then maybe some buggy code writes to the S:22. edit: Or a buggy HMI program.

Another idea:
Monitor the last scantime S:35, and generate an alarm if it exceeds any unrealistic value (>50ms). Maybe that can link to some condition that causes the error.
 
Well, now that I think about it, the 1500 only pops up after I've been doing a lot of editing and changing things. When I reset the max time and then just let it run, it really only goes up to 20ms or so. Maybe the editing (online) has something to do with it?
 
Not sure if the CPU suspends the monitoring of the scantime when it is "accepting edits" or "assembling edits". That could well be. When assembling edits, it must shovel some memory around because rungs are deleted. And that can well be very scantime intensive.

Apart from that,
What is S:3 high byte set to ?
Is the PLC memory maybe almost exhausted ?
 
Online editing will definitely spike the scan time. It should only be a millisecond or two above normal, unless your CPU memory is almost filled. If you're nearly out of memory, your scan time can take a giant hit like you're seeing, especially if your online edits are many and scattered.

There are other things that might cause this, like intermittently accessing lots of M0/M1 files, looping and some other things.

I have two different systems, one is a 5/04 and one is a 5/05 that see about 850ms on 1st scan and then settle down to about 20ms. These two machines have a lot of drives on devicenet and I think that is related, and it only happens on first scan, so not much worry about it interfering with normal operation.

Your case is different, and I would suspect that you are running short of memory, since you say it never happens unless you're editing. If that's not the case, then it could be excessive communications slowing things down. If neither of those are the problem, then you should post your code and we can help you look for other causes.

Paul
 
After playing with it today, I realized that the scan time is only very long after I burn to the EEPROM and then go back into run. So I suspect that the first scan is causing the problem. After that, I reset the max and it only went back up to 21ms. If I look at the memory used, it shows that I have used about 2/3 of the available instructions, so I'm thinking that maybe the memory has nothing to do with it...?? Like I said, I'm not having any problems, I was just wondering what "normal" is.
 

Similar Topics

Hi everyone, I'm trying to simulate any program in control expert and see a register in Modscan32 or any software to do that (Like ModbusPoll). I...
Replies
0
Views
93
I am not sure if this is possible but if there is a way, you guys would be the ones to know. I am currently working on a project where we are...
Replies
7
Views
216
I have a Type C to RS485 adapter connect to my Siemens RWF55. I use modscan to scan it to get a value from the Siemens controller. In the...
Replies
4
Views
100
Hi, I'm new to PLCs and learning about PLC Scan times for Schneider PLCs I've derived the PLC scan time using the free running blocks. The PLC...
Replies
7
Views
665
Hello. Does anyone know the equivalent of the first scan bit in a L32ER compactlogix? Do o need to obtain it via GSV? I’m looking to regain...
Replies
3
Views
448
Back
Top Bottom