3

The requirements

I want to control PWM fans to maintain some HDDs in a server at about 35°C, the absolute value isn't critical, however I want the temperature to be stable regardless of the ambiant temperature (within reasonable limits of course, if the ambiant temperature is 40 °C then obviously it can't work).

I already designed a controller based on a LM35 (which will be attached to the case of one of the drives) but it was proportional only. Then I modified it to add an integral term to avoid any steady-state error (mainly due to the ambiant temperature changes).

The circuit

You can find the circuit diagram here.

U1:A is the error amplifier
U1:B is the triangle wave generator (I know it'll not generate a perfect triangle signal, it's ok for me)
U1:C is the final comparator who generate the PWM signal (not connected because it doesn't matter for now)
U1:D is the PI filter

The problems

1) I don't know how to chose the values for R9, R10 and C3 (they're just placeholder for now) because all I can find on PI(D) controllers is for software controllers (and, no, I don't want to use an arduino or any other MCU).

2) I don't know how I can control the Kp and Ki parameters independently and what their values should be for this application.

3) I'm not sure of the components arrangement around U1:D.

NB: The drives have a huge thermal inertia so I guess the loop will probably be very stable without too much tuning, but if someone can confirm it would be great. Minimizing system settling time isn't a concern at all here.

Thanks to anyone who can help :)

Biduleohm
  • 359
  • 1
  • 3
  • 14
  • Tuning a regulator loop is not a simple task whether analog or digital. For typical independent PID controllers, you have separate generators for each term, in your diagram, that would be a separate op-amp for each term, summed together finally. Then you use pots to tune it. There isn't any realistic way of calculating the requirements for each term ahead of time. – R Drast Oct 30 '15 at 11:02
  • I know it's possible to aggregate all the terms on one op-amp. I did found a very good web page or video (can't remember) a while ago (didn't bookmarked it because I didn't needed it at the time...) but I can't find it anymore. Each term was very well explained and in the end the guy explained how you can use only one op-amp to do the same job. I know I'll need to use pots for Kp and Ki but I don't know where to put them exactly. Thanks ;) – Biduleohm Oct 30 '15 at 15:55
  • You put the pots where they adjust something. The time constant of the integrator, the gain of the proportional error, and the rate of the derivative term. – R Drast Oct 30 '15 at 17:02
  • So I need to replace R9 and R10 with pots if I understand correctly. – Biduleohm Oct 30 '15 at 18:01
  • C3 is an electro .Double check the volts across it .It could get reverse polarity the way I see it .If in doubt use two electros back to back with reverse diodes across them . – Autistic Nov 04 '15 at 10:41
  • @Autistic Yep, I already planned to take care of this problem if it happens. Thanks ;) – Biduleohm Nov 04 '15 at 16:22
  • The drives already know how hot they are inside (this can be queried using SMART) I would be looking for a way for the CPU to command the fans – Jasen Слава Україні Jan 09 '16 at 05:32
  • I know but I don't want any software to run this controller (actually I could have used an simple arduino and have done the PI(D) in software) for reliability and simplicity reasons. After some reading I think I now understand; I'll post an answer as soon as I finished the controller and checked that everything works. – Biduleohm Jan 12 '16 at 19:36
  • I'm interested in the answer to this question. I usually do this sort of thing on a microcontroller. Author mentioned an impending post a couple of months ago... – slightlynybbled Mar 11 '16 at 05:11
  • I didn't forgot, I'm just currently very very busy, sorry. – Biduleohm Mar 12 '16 at 14:20

1 Answers1

1

In your case I would just play with the settings until I got a decent control response.

In general, the proportional term allows for an instantaneous response to any disturbance in the controlled variable. The integral term, slower, takes care of zeroing steady-state error.

If settling time isn't a concern (and I would also believe that your system's dynamics are relatively simple), you could start by using only the integral term, starting from a low setting for Ki. This would be sufficient for eventually controlling the temperature.

Then you could start experimentally raising the Ki and adding some Kp to quicken the response.

Regarding the component values, I don't recall it for the moment but I would suggest checking analog implementations of PI controllers using opamps. It's a very common application.

SuperGeo
  • 556
  • 2
  • 13