PID, SMC, Roll my own?

glaverty

Member
Join Date
Apr 2002
Location
Parts Unknown
Posts
509
I have an application where I need to control the temperature of a product in a vessel. The basic setup of the system is a container for the product a blower to move air through the product and a heater. There are two RTD's in the system, one placed to measure the temperature of the air leaving the heater and another to measure the temperature of the product. The heater output is controlled using a 4-20mA signal. The blower remains at a constant speed.

Different products will be run in this machine that need different temperatures and times so profiles will need to be developed based on the product.

There are multiple heating steps in the process going from one temperature to the next and remaining at a set temperature for a set time during certain steps until a final temperature is reached. Each successive temperature is greater than the previous.

The customer wants to be able to go from Temp A to temp B and tell the controller to do it in certain amount of time. This is the part I am having trouble with. Your basic PID loop is just going to try and get to the Setpoint as fast as it can and then remain at that temp.

The program is going to have to calculate the rate that the temperature needs to change based on the difference between the starting temp and ending temp and the time it should take to make the change. Then adjust the heater output accordingly to get that rate of change. Once it reaches the temperature setpoint it will then need to remain there for some amount of time.

Can this be done using a built in PID Loop? I’ve read through the posts on SMC and looked at the code Peter Nachtwey wrote but that seems more built for ON/OFF heater control and doesn’t really take into account trying to maintain a certain slope in the temperature.

The PLC being used is a GE Versamax.


Any suggestions or insights are appreciated.
 
glaverty said:
The customer wants to be able to go from Temp A to temp B and tell the controller to do it in certain amount of time. This is the part I am having trouble with. Your basic PID loop is just going to try and get to the Setpoint as fast as it can and then remain at that temp.

It will jump from A to B as fast as possilbe only if you make a step change in the setpoint. Ramp the setpoint using the equation

Setpoint = BeginSetpoint + ((EndSetpoint - BeginSetpoint) * ElapsedTime/DesiredRampTime)

If the PID is tuned properly it will follow the setpoint as the ramp equation changes it

What you are describing is a classic ramp/soak setpoint profile with multiple segments. This can take several forms.


All segments are ramps (a soak is a no slope ramp)
SETPT TIME
100 10 Ramp to 100 in 10 minutes
100 30 ramp from 100 to 100 (soak) for 30 minutes
200 20 Ramp from 100 to 200 for 20 minutes
200 30 ramp from 200 to 200 (soak) for 30 mintues


All segments are ramp + soak
(precludes two adjacent ramps of differing slopes)
SETPT RAMPRATE SOAKTIME
100 10 30 Ramp to 100 and 10/min and soak for 30 min.
200 5 30 Ramp to 100 at 5/min and soak for 30 min

 
glaverty said:
Different products will be run in this machine that need different temperatures and times so profiles will need to be developed based on the product.
This means you will need different gains too

There are multiple heating steps in the process going from one temperature to the next and remaining at a set temperature for a set time during certain steps until a final temperature is reached. Each successive temperature is greater than the previous. The customer wants to be able to go from Temp A to temp B and tell the controller to do it in certain amount of time. This is the part I am having trouble with.
Seems very similar to a motion profile too me. You should be able to do this easily if linear ramps are OK. I would have able of times and temperatures. I would use the SCP function to linearly interpolate between the time entries to get the current temperature SP.

Your basic PID loop is just going to try and get to the Setpoint as fast as it can and then remain at that temp.
NOT SO!!!! The PID will follow the current SP which will change as a function of time. There will be a lag because feed forwards are not being used.

Also, if you have been following the more advanced threads you know that you can change the closed loop time constant so the PID will tend to close faster or slower depending on your choice of closed loop time constant.

The program is going to have to calculate the rate that the temperature needs to change based on the difference between the starting temp and ending temp and the time it should take to make the change.
It depends on how closely you need to follow the ramp. In the sample case, all you need is the interpolated setpoint as a function of time SP(t). If you need to follow even more closely then feed forwards or bias may be required. In this case you will need to calculate the set point rate or SP'(t) which is the derivative of the temperature. If you need to follow the temperature profile even closer then you will need a SP''(t) or the second derivative of the temperature set point.



Can this be done using a built in PID Loop? I’ve read through the posts on SMC and looked at the code Peter Nachtwey wrote but that seems more built for ON/OFF heater control and doesn’t really take into account trying to maintain a certain slope in the temperature.
Either the SMC or PID can follow ramps, but you rightly pointed out that normal SMC use ON/OFF control and you are using analog. SMC can be used with analog outputs but it requies a non-linear function to the error to output. The advantage the SMC would have is that it is more robust and wouldn't require different gains for different thermal masses.

The PLC being used is a GE Versamax.
I have no idea what a Veramaxes PID is like.
Does GE have a scale function?

Hurdles
1 How do you index through the table of times and temperatures?
2 Does the tuning need to change with each product?
3 Are feed forwards required.

Need to know more about the secifications.
I will try to find the function SMC need to convert errors and error rates to control output.
 
Thanks for the replies guys.

Peter Nachtwey said:
This means you will need different gains too

Possibly, it's going to depend on how the different products react to the heat. There will be different amounts of product though 2, 5 or 10 pounds, those will probably need different gains. We won't know until we try it though, right now I just want to get it working with the ramps.

Peter Nachtwey said:
Seems very similar to a motion profile too me. You should be able to do this easily if linear ramps are OK. I would have able of times and temperatures. I would use the SCP function to linearly interpolate between the time entries to get the current temperature SP.

Linear ramps should be fine.

Peter Nachtwey said:
NOT SO!!!! The PID will follow the current SP which will change as a function of time. There will be a lag because feed forwards are not being used.

Also, if you have been following the more advanced threads you know that you can change the closed loop time constant so the PID will tend to close faster or slower depending on your choice of closed loop time constant.

I think what I was trying to say was that if you set the SP to the final temp you want to reach its not that easy to control how long it takes to get there.

Peter Nachtwey said:
I have no idea what a Veramaxes PID is like.
Does GE have a scale function?

The newer GE processors do, so yes this one does support a scale function. I've attached a screen capture of the GE PID function along with tuning dialog, GE doesn't offer an autotune function or a PID Trend.

PID_34.jpg
 

Similar Topics

I’m not a regular user of soft starts but the SMC Flex list the aux contacts can be set to “Normal”, what does normal mean? The manual doesn't say...
Replies
8
Views
5,044
Hi all, I read an old thread on here about sliding mode control (SMC) and how it should be considered more in temperature applications as apposed...
Replies
6
Views
2,608
Hi, I would like to assemble a simulator/practice booster pump system that uses PID to maintain steady water pressure under various outlet demands...
Replies
0
Views
82
Hello, I have a motor that we are sending a RPM Speed Output from 0-100% to the VFD. However, the Motor HP needs to be limited to 6000 HP and the...
Replies
3
Views
91
I have S7 1512C controler for controlling 48 PID temperature loop, the output is PWM. Please I need the best, most efficient way to write the...
Replies
13
Views
611
Back
Top Bottom