Posted by: Harold Ennulat | January 14, 2010

PLC Tip: Taming the Gremlin in PID Control Update Timing

This is actually another PLC Scan time gotcha: Running PID controllers in a PLC’s continuous task. 

The continuous task (or scan) is typical the default PLC scan mode.  The continuous scan mode scans at a rate that is not deterministic.  It just scans as fast as it can.  This causes problems with PID controls which require a fixed time base to operate properly.  With temperature loops and other slow loops which have time bases at least 10 times the maximum expected scan rate it is possible to get away with running this in a continuous task without ever running into a problem.  My experience has been that if an engineer puts the PID control in the continuous task it has always been out of ignorance rather then from an engineering judgement.  In such a case the PID controls can behave in an unpredictable manner when additional programming is added or additional communications loading is placeed on the PLC processor. 

In any case, placing the PID controllers in the continuous task is not the preferred practice.  Even the older PLC’s have the ability to place the PID controllers in one (1) or more “periodic tasks” which is where they belong.  The “periodic task” time is matched with the “PID update time” and the PID software controllers will perform as designed. 

For fast loops a timed interrupt can be used when the PID controls may need to update more then once per scan.

This is another gremlin that never needs to show its ugly head.

Advertisements

Responses

  1. Great practical app advice. Thanks


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Categories

%d bloggers like this: