Making a fan controller to use in my PC’s ductwork

When I’m running computer intensive tasks, I want the fans to cool my processor. When I’m not, I want the fans to be quiet. While I could use a manual rheostat to control the fans, I want to learn more about HVAC and control systems. So, I want to make a fan controller that senses the temperature and adjusts the fan speeds accordingly. I would like to get your input for my plan.

I’m starting from a project I did a while ago where I used ductwork to route air through my PC. 5” diameter dryer duct hose connects the front and back fans (Silverstone FM121 - http://www.silverstonetek.com/product.php?pid=118&area=usa) to the heat-sink (CoolerMaster Hyper 212+ http://www.coolermaster.com/product.php?product_id=3096) that is mounted on the processor.

What I’m planning to do is to install a temperature transducer to measure the temperature of the processor. A PLC (I was going to use an Arduino Uno http://arduino.cc/en/Main/ArduinoBoardUno, because it is cheap and easy to program) would read the transduced temperature. Based on a set-point that I enter and the temperature it reads, the PLC would vary the fan speed.

Below are some puzzles that arise with this approach that I haven’t figured out how to solve. I would appreciate your input on any or all of them.

Which temperature transducer should I use? I’ve seen a variety of temperature sensors out there:

There are various sensing technologies (http://www.maxim-ic.com/app-notes/index.mvp/id/3229) • RTD (e.g., http://www.mamacsys.com/TE-701-702ordering_information.htm) • Thermistors (e.g., http://www.mamacsys.com/TE-701-702ordering_information.htm) • Thermocouple + transducer e.g., (http://www.pc-s.com/multi/MultitekTRtherm.htm) • Integrated circuit (e.g., LM35 http://www.ladyada.net/learn/sensors/tmp36.html). I can’t think of a good way to mount an IC.

There are various mounting styles (http://www.mamacsys.com/TE-701-702ordering_information.htm) • Flange • Bulkhead

There are various resistances (http://www.mamacsys.com/TE-701-702ordering_information.htm) from 100 ohm to 100 kohm. The PLC I’m planning to use takes 0-5V on its analog inputs.

Which of these varieties do you recommend for my project and why?

Where should I put the temperature probe? At the end of the day, the temperature I care about is the temperature on the surface of the processor.

The most accurate way to measure this I’ve seen is to mill a channel in the processor and put a thermocouple in it (for example, http://www.hardocp.com/image.html?image=MTMxMDczNDE4NkdFU2tUckRQRzlfMV8zX2wuanBn). However, I milling the surface of a $225 processor a bigger risk than I’m willing to take.

So, my best idea right now is to measure the exhaust heat by putting the probe right after the heat-sink.

One of my concerns with this is that it will inhibit the airflow too much. Another concern is that I don’t want air to be escaping from the hole the probe pokes through. Do you have ideas for solving these issues?

What algorithm will take in the set-point and current temperature and calculate the fan power? Another puzzle that I need to figure out is which control algorithm I want to use in the PLC. I’ve heard about the following (http://en.wikipedia.org/wiki/Control_systems):

• Binary control: if the temperature is above the set-point, turn the fans on. One problem with this is the fans need to be running at a low level all of the time to prevent the processor from overheating. One way around this would be to run the fans at a low level (e.g., 50%) as a default state; when the temperature pierces a certain threshold, I would run them at 100%. I could see the fans cycling on and off at a high frequency with this approach and wasting a lot of electricity. • Proportional control: the PLC would vary the fan speed in proportion to the difference between the current temperature and the set-point. So, for example, if it is way hotter than it should be, the fans will run at 100%, while if it is barely hotter, they will run at 40% (their minimum speed). Wikipedia talks about downsides to this, but I don’t understand them. • PID control. The PLC would also consider the rate the temperature is changing and historical temperatures when deciding how much power to apply to the fan. One challenge with this is how to implement the algorithm. I would have to spend some time programming the thing. The lazy (and expensive) solution would be for me to pick up a PLC with the algorithm already built in (e.g., http://www.mcmaster.com/#38615k73/).

Which algorithm do you advise I use?

What is a good online HVAC controls distributor? I’ve seen a variety of sites that have just a listing of the manufacturers they carry and then a link to CGNA (http://www.cgnacontrols.com/search/), which seems to have a limited selection. One easier to use site I found was controlstop.com. What do you usually use?

I'm surprised that a computer setup worth spending this much effort on cooling doesn't already have fan speed control. It's quite common to have fan speed controlled based on onboard temperature sensors.

PeterH: I'm surprised that a computer setup worth spending this much effort on cooling doesn't already have fan speed control. It's quite common to have fan speed controlled based on onboard temperature sensors.

This. The CMOS should vary the fans. 3 pin fans are varied by analog voltage, 4 pin are managed by PWM. Your BIOS will have selections as to when to engage each respective fan. I have my CPU fan set to 20% up to 65C, them ramp from 20% to 70% from 65C to 85C, and 100% after that. I idle at 55C. No case fans, with an open side.

Thanks. That's a good solution. Were price, performance, and reliability my top considerations, that's exactly what I would do. However, an additional value I'm trying to get out of this project is experience with hvac control systems. For that reason, I'm more inclined to build a system more from scratch. SeEing if I can build a better system than the one built into the motherboard will be a good challenge.

I ended picking up 1k rtd probes, both in bulkhead and flange varieties.

I also picked up a stroboscopic tachometer to bench test the plc's ability to vary fan speed with pwm.

I still haven't decided where I want to put the probe or what control algorithm to use.

JamesWatt: Thanks. That's a good solution. Were price, performance, and reliability my top considerations, that's exactly what I would do. However, an additional value I'm trying to get out of this project is experience with hvac control systems. For that reason, I'm more inclined to build a system more from scratch. SeEing if I can build a better system than the one built into the motherboard will be a good challenge.

I ended picking up 1k rtd probes, both in bulkhead and flange varieties.

I also picked up a stroboscopic tachometer to bench test the plc's ability to vary fan speed with pwm.

I still haven't decided where I want to put the probe or what control algorithm to use.

You don't need the strobe, if you're working with 3 wire fans. the yellow wire is a tach wire. Just like an engine tach, it will go high every time the fan makes 1 rotation. So theoretically you can do what the motherboard does, and see how many times it goes high in a set time period (like 1 second) and convert that to an RPM.

The 'IT clever' way to do this would be to find how to access the CPU's existing temp sender from software running on your PC, and how to control the speeds of the existing fans in software. I assume it's possible on your system.

If you specifically want to make an embedded controller to do the job, you might still think about having a small agent on the PC telling it what the CPU temperature is, because I expect that would be dramatically more accurate and more responsive than any external temperature sensor you add.