# PID Temperature Controller

Discussion in 'The Projects Forum' started by kyleS4562, Apr 10, 2011.

1. ### kyleS4562 Thread Starter New Member

Mar 23, 2011
4
0
Hi everyone,

I am designing a PI temperature controller for a school project. The goal is to design the electronics necessary to control the temperature of a small piece of copper tubing by sending pulses of current through a small heater. In response to a four bit digital word, the temperature will be settable in a range from 24 to 40 degrees Celsius with a resolution and accuracy of better than 1.0 degrees. It must not drift over time by more than 1.0 degrees. The system must heat the tubing to full scale in less than 50 seconds. The copper tubbing also has a thermistor on it, which is what is used to measure the current temperature.

With these specs we were able to develop a block diagram(See Temp_Control_BD attachment). We have figure out the design for everything except the Measurement Electronics. I do have an overall design (See Measurement_Electronics attachment). I have currently have up to the P Part working in lab. I used a bridge and a difference amp to give me the current temperature, in proportion to the DACs output. So 24 degrees is about 36mV for both the Set Ponit (SP) given by the dac and the Processed Variable (PV) given by the first difference amp, and 40 degrees is about 1.22 V for the SP and the PV. Then the PV and SP are passed to another Difference amp, which gives the error. I also applied the proportional gain with this amp, so currently the output is P*e. My problem is I am not sure of a few concepts I guess. First of all, I am not sure how big the gain of P and I should be, especially I. I know I am going to need to adjust it, but I am not sure of even a ballpark idea.

My other wonder is, currently I find the error and apply the proportional gain in the same step. Should I instead, find the error, and change the unity gain amplifier to an amp the will apply the appropriate P. This would also allow me to adjust P using one potentiometer in the place of R1. I also plan on adjusting the integral term using a potentiometer in the place of R2 but I am not sure what to choose for C1 and if that idea will even work.

Some other related information I guess is about the PWM. We currently are passing the output of the measuring electronics to a triangle wave to get our current pulse. Right now the triangle wave ranges from 0-5v with a frequency of 1.1 kHZ. Let me know if you need any other info that could help you help me.

I have read through a few similar threads, and I know a lot of you would solve my problem using a PD controller instead of a PI. I have discussed this point with my professor and he does not agree. So I am going to do what makes him happy, so I would appreciate any help I can get with my PI design.

Kyle

File size:
19.7 KB
Views:
49
File size:
25.8 KB
Views:
58
2. ### hgmjr Moderator

Jan 28, 2005
9,030
215
One important piece of data that you will need to measure early on is the natural thermal response time of your system made up of the copper tube and the heater.

Such a measurement would involve starting with your copper tube at room temperature apply the maximum drive to your heat source. Then take data over one second intervals and plot temperature versus time. The information gained from this measurement will be an important parameter in setting up your PI values.

hgmjr

3. ### kyleS4562 Thread Starter New Member

Mar 23, 2011
4
0
Would you recommend making this measurement with the thermistor attached to the copper tubbing or a an external thermometer?

4. ### hgmjr Moderator

Jan 28, 2005
9,030
215
I was thinking in terms of making the measurement using a standard thermometer. The idea is to establish how quickly the tube can be heated. Obviously the target is to be sure that the system can achieve the required rise in temperature well within the time requirement of 50 seconds in the open loop mode. The faster the rate of rise in temperature the better will be the likelihood of achieving the target response with the system in closed loop mode.

I assume that there is an expression for converting between the actual temperature and the output of the thermistor.

hgmjr

5. ### kyleS4562 Thread Starter New Member

Mar 23, 2011
4
0
Not so much an expression but we have mapped the characteristics of the thermistor across the temperature range. Thank you and I will sure to check that soon. I'm guessing after doing so, I should be able to develop an idea of what the time constant for the integrator should be?