PID and control output

Cajunman0821

Member
Join Date
May 2004
Posts
3
I am new to PID and have a question about the control output.

First of all, I am using a DirectLogic205 PLC with a 250-1 CPU. I have a 4 channel analog input and an 8 point output module.

After setting up the PID the control output goes up if my set point is higher than my process variable and goes down if the SP is lower. This part makes sense to me, sort of.

The problem is that I would expect the CO to be a certain value when SP=PV and always be that same value when SP=PV. But, the CO does not change to the same value, it just stops changing when SP=PV. So I could have a value of 1000, 0, or anything in between for the CO when SP=PV.

How do I know when to turn my outputs ON or OFF?
 
It looks like the PID is functioning correctly.

You must be using the integrator and it is correcting for changes in the load. If the load changes then the CO may need to be higher or lower to keep PV = SP.

The PID will control the output correctly if the PID is tuned correctly. It appears like you have tuned the system reasonably well.

I will write more later when not at work.
 
well, you said you're new ... here's a "basic idea" shot at your problem ...

Greetings, Cajunman0821,

you said:
I would expect the CO to be a certain value when SP=PV and always be that same value when SP=PV. But, the CO does not change to the same value, it just stops changing when SP=PV. So I could have a value of 1000, 0, or anything in between for the CO when SP=PV.

here’s an analogy using a cruise control for a car ...

I would expect the GAS PEDAL to be a certain value when DESIRED SPEED = ACTUAL SPEED and always be that same value when DESIRED SPEED = ACTUAL SPEED. But, the GAS PEDAL does not change to the same value, it just stops changing when DESIRED SPEED = ACTUAL SPEED.

stop for a second and read that again carefully ... this is EXACTLY the way a cruise control operates ... specifically, you tell it how fast you want to go ... it moves the gas pedal up or down until the correct speed is obtained ...

now here is what (I think) is confusing you ...

apparently you’ve failed to consider the LOAD on the system ... if you’re going UP a hill, you’ll need MORE GAS to maintain the desired speed ... if you’re going DOWN a hill, you’ll need LESS GAS to maintain the desired speed ... so the cruise control (or your PID) automatically COMPENSATES for the changes in load by changing the gas pedal setting ...

specific point: the cruise control (or your PID) should look at the incoming signal ... compare it to the desired signal ... and then do ONE of three things:

1. increase the output
2. decrease the output
3. leave the output the same

consider this from the controller’s point of view ... the little man inside the box doesn’t know what the load on the system happens to be ... all he knows is “I’m going too slow” or “I’m going too fast” or “I’m going just right” ... and that’s why you won’t always see the same amount of output for the same amount of speed ... any change in the load on the system will affect the amount of output required ....

hope this helps ...

PS edit: if I understand correctly, your system doesn't have an analog output module ... just discrete (on or off) outputs ... if that's the case, you'll probably need to use something along the lines of a "time proportional signal" ... you should be able to find quite a bit about that subject by searching this forum ...
 
Last edited:
Thanks

Ron,

Thanks. That helped a lot.

I have another question...I have one output (discrete) that starts a cooling unit and another that starts a heating unit. I can handle the situation if the temperature is too low, but if the temperature is too high, then the CO will start going down, so I need to turn on the cooling unit.

I am using a "time proprotional signal" that looks like the following:

| T0
|--|/|------------|TMRF T0 K1000|
|
| T0
|--| |------------|LD V2005| This is the Current output value
| |BTOR|
| |DIVR R4.095|
| |RTOB|
| |BCD|
| |OUT V1400|
|
| T0
|--|/|------------|TMRF T1 V1400|
|
| T1 TA1 K0
|--|/|--| != |----(OUT Y0)
|
|


I got this from an example in the user manual. But I need to do the opposite if the temperature too high.

Any suggestions?
 
Last edited:
Greetings, Cajunman0821,

Sorry that I don't have much time available ... but here is a quick suggestion ...

based on what you've posted so far, I'd say that there is the possibility (probability?) that PID might not really be the best answer to your problem ...

if all you need to do is "turn on a heater" or "turn on a cooler" then a couple of simple comparison rungs might be all that you need ...

basic idea: when we use time proportional signals, we're pulsing the output off and on - off and on - off and on ... does that sound like the type of thing that you want to do to the system you're working on? ...

here's a suggestion: tell us some more about the system ... describe its operation in as much detail as you can ... the chances are that someone on this forum has already done something very similar to what you're trying to get done ...

but ... to answer your specific question ... it's been years since I've worked with PID in a DirectLogic PLC so this might be totally out in left field ... but with an Allen-Bradley processor, we would probably set up two separate PID rungs ... one for the heater ... another for the cooler ...

the PID for the heating section would be configured for E=SP-PV ... so that when the PV goes DOWN (the temperature is dropping) then the CO would go UP (feed more fuel to the fire) ...

the PID for the cooling section would be configured in the reverse or E=PV-SP ... so that when the PV goes UP (the temperature is rising) then the CO would also go UP (more cooling water through the coils) ... I'm not sure how DirectLogic handles that particular setting but with AB it's just a matter of going to the PID setup screen and turning one bit off or on ... maybe someone with more DL experience can offer some more advice on this particular subject ...

finally ... unless this is just a lab-type experiment that you're working with, I'd STRONGLY suggest that you tell us some more about your system before you try any of this out ... the more details you give us, the better the answers will be ...
 

Similar Topics

i have a control valve that is used to heat a tank of water. the steam valve only has digital signal to control it and no position feed back. when...
Replies
4
Views
2,710
I am practicing temp controller setup with E5CN R2MTD 500. My parameter values are; Control type=PID, Control period=10 seconds, Proportional...
Replies
7
Views
2,823
Hello All! I have a PLC5 which is controlling a cocurrent drying process through a rotary kiln. I believe the control stategy of using an outlet...
Replies
11
Views
12,155
I am working with a FB 58 TCONT_CP with sample time set to 1 second P GAIN set to 10, I to .13, D to .79. I am controlling a process...
Replies
2
Views
2,055
I am Using SLC505 Processor To Control Flow and Pressure. I am using Flow and Pressure Transmitter. I would like to use dual PID to contol one...
Replies
3
Views
1,822
Back
Top Bottom