Home     Contact     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science     RSS     Terms of services     Privacy policy  
 Home      Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science   

11 August 2009
Author: Giorgos Lazaridis
Two Speed Temperature Fan PWM Controller

The circuit in operation. The black 'thing' on the left of the thermometer is the NTC

In many cases, we need a fan to cool a device or an area only when it is hot. In this case, a temperature controller is needed. There are some cheap temperature controllers in the market. But the circuit that i present here is more than this. It is also a PWM fan speed controller, suitable for almost any kind of DC fan. The fan is turned on at low speed when the temperature has reach the first level, and then it runs at full speed when it goes above the higher level. Both levels are controlled by independent potentiometer for easier adjustment. The low speed of the fan is also controlled by an independent potentiometer.

In Action!

The circuit

Following i present you the circuit.

Although i tried to keep it as simple as possible, the requirements i had on the first place increased the difficulty a little bit. I did not want just a simple temperature controller. The circuit has two temperature set-points. The first set-point will turn on the fan but not in full speed. The fan will be controlled through a PWM generator performed by the 555. This set point is chosen from the R2 potentiometer. The fan speed can be set by changing the duty cycle of the PWM generator using the R5 potentiometer. As the temperature rises, there is another set-point that will set the fan in full speed. This set point is selected using the potentiometer R6.

Circuit Operation:

From left to right, first we see the NTC. I chose a 4K NTC performing a voltage divider along with the R1. From their common point, two signals are leaving. The first one will drive the T2 through the R2 potentiometer. The transistor T2 will turn on or off the next transistor T1. When T1 is turned on, the 555 will get enough power to operate. The 555 is connected as a PWM generator. The frequency of the 555 is above acoustic frequencies to avoid any kicking sound from the fan. The output of 555 is driven to the T3-T4 pair that perform an OR logic gate. The PWM pulses are driven as-is directly to the gate of the mosfet.

On the other hand, there is another signal leaving from the R1-NTC pair. This signal is driven to the 741 inverting input. The 741 performs a comparator. The non-inverting input comes from the potentiometer R6, that gives a DC level for comparison. The output of the 741 is driven directly to the other port of the T3-T4 transistor pair. When the output of the 741 is driven high, then the gate of the mosfet is also driven high, and the PWM pulses have no effect on it. Therefore, the fan will run at full speed.

Adjusting the circuit

Before start adjusting the circuit, we need to make sure two things:

  • 1. The 'full speed' temperature set point is above the 'low speed' temperature set point
  • 2. The PWM pulses have a duty cycle able to rotate the fan

You can adjust the circuit under real conditions or using another heat source like a thermo-gun for heat shrinks.

I have the regulator of the thermo-gun set to 1, the lowest scale possible.

First, we need to make sure that the 'full speed' temperature set point is above the 'low speed' temperature set point. To do so, we will set the 'full speed' at a very high temperature, the highest possible. Put all potentiometers near the center. Then power on the circuit. Turn the R6 potentiometer completely to one side. If the fan start to rotate, then turn it on the other side. The side that the fan does not rotate is the one that we want.

Then, we need to make sure that the PWM duty cycle is able to rotate the fan. To do so, turn the R2 completely to one side. Then, start rotating the R5 from side to side until the fan start rotating. If the fan does not rotate in either sides, then go back to R2 and turn it completely to the other side. The R5 potentiometer can be used to set the low speed of the fan. Set the speed that you desire and proceed to next step.

Now you need to set the temperature level for the 'low speed' operation. I use my electronic-controlled thermo gun for my heat shrinks and a thermometer. I turn on the gun and i put the thermistor and the thermometer side to side across the gun. The gun is set to it's lowest temperature possible and i keep it about 20cm away from the thermometer. At this point, i get about 40 �C. When the temperature is steady for about one minute, start turning the R2 until the fan is turned off. Then turn it the other way. you must find the exact point where the fan is turned on. When you do so, you are done with the 'low speed' set-point.

The next and last step is to set the 'full speed' temperature. In continue to the above procedure, put the thermo-gun closer to the NTC-thermometer pair. The temperature will rise. Using my gub, at about 15 cm i get around 46 �C. When the temperature is stable for about a minute or so, start turning the R6 potentiometer. Do it slowly and find the exact point where you hear the fan rotating at full speed. If you have done this correctly, the circuit is ready to operate. The fan will turn on at about 40 �C and revolve at 'low speed'. If the temperature goes above 46 �C, the fan will revolve at full speed. That's it!

Selecting a different NTC

I have not try it but i suppose the circuit will work with another NTC as well. The R1 should have resistance near the resistance of the NTC. Be careful not to select a low resistance NTC because the current that will go through will be large enough to destroy the NTC and the resistor.

Relative pages
  • 555 timer basic circuits
  • 555 theory of operation
  • Dr.Calculus: 555 Astable multivibrator calculator
  • How to make a PWM fan controller / LED dimmer using a 555
  • How to make a light / dark activated switch - 3 different circuits under the microscope
  • Create PWM pulses with variable duty cycle controlled by a DC voltage input
  • PWM signal theory
  • Control a 3-wire Fan with PWM pulses and use the Pulse Stretching method to get clear rpf feedback
  • An intelligent self-tunned fan PWM controller
  • Learn about the most popular PC Cooling methods
  • PIC Thermometer and thermostat circuit, designed for etching baths
  • Re-use and/or extend your molex connectors

  • Comments


      Email (shall not be published)


    Notify me of new posts via email

    Write your comments below:
    BEFORE you post a comment:You are welcome to comment for corrections and suggestions on this page. But if you have questions please use the forum instead to post it. Thank you.


  • At 16 May 2014, 0:46:29 user hassan wrote:   [reply @ hassan]
    • I built the circuit in proteous...but fan is not rotating there :(

  • At 6 December 2013, 6:52:59 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Christopher Sauer Well, it should start rotating. Either you have a problem with the comparator, or the thermistor or the driving mosfet

  • At 6 December 2013, 6:49:14 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Christopher Sauer Usually people have trouble connecting the diodes correct on the PWM. OR it could be a problem with the thermistor input?

  • At 20 November 2013, 17:07:28 user Christopher Sauer wrote:   [reply @ Christopher Sauer]
    • I've built the circuit just as you draw it and I'm heating the thermistor with a heat-shrink gun, but the pot's are not having any influence. On the 1st part of the adjust procedure, the fan does NOT stop rotating when turning R6. Can tou give more details about the adjustment? Thanks.

  • At 11 November 2013, 16:50:28 user Christopher Sauer wrote:   [reply @ Christopher Sauer]
    • @Giorgos Lazaridis
      I've done everything you said and built the circuit just as it is on the schematics, bu when I power it on, the fan starts and keeps on the same speed, even if I try to set the pots as you explained above. It's like the pots are having no influence on the circuit at all. Can you help me?

  • At 10 November 2013, 14:57:57 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Christopher Sauer Yes. But maybe smaller R2, like 50K or 20K

  • At 10 November 2013, 13:39:51 user Christopher Sauer wrote:   [reply @ Christopher Sauer]
    • @Giorgos Lazaridis
      And what about the 50k thermistor? Use it with a 50k R1?

  • At 8 November 2013, 10:05:36 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Christopher Sauer I'm not sure, i have not checked the datasheet.

  • At 6 November 2013, 19:24:47 user Christopher Sauer wrote:   [reply @ Christopher Sauer]
    • Can I use the LM393N instead of the LM741P?
      And to use a 50k thermistor, I will need a 50k R1, right?

  • At 6 January 2013, 22:08:29 user Marty wrote:   [reply @ Marty]
    • @Giorgos not what I wanted to hear.

      Anyway, thank you for all your effort and monies you put into your site. I truly appreciate it. Has made my interest much more rewarding. Thanks again. -marty

  • At 6 January 2013, 12:55:54 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Marty no it is not easy

  • At 3 January 2013, 22:38:40 user Marty wrote:   [reply @ Marty]
    • Question, can the closed loop high frequency circuitry be integrated into this circuit? I like the advantages of the closed loop circuit however need the dual speed/temperature control for my application. Thank you for your time. -marty

  • At 19 July 2012, 9:20:18 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Sebastian yes it is, connect them in parallel.

  • At 19 July 2012, 8:40:13 user Sebastian wrote:   [reply @ Sebastian]
    • Hey

      Nice Solution. But is it Possible to Control three Fans at the same time with this Circuit?

  • At 16 March 2012, 20:43:50 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @shawn for what? for cooling the engine water? no it can't

  • At 16 March 2012, 3:10:11 user shawn wrote:   [reply @ shawn]
    • can this also be used in an automotive application or would i need to mod this design some?

  • At 19 November 2011, 3:06:04 user Neric wrote:   [reply @ Neric]
    • Never mind, I got it figured out the E,B,C on my tarnsistors was maped wrong. In any event if someone need the PCB transfer and BOM let me know this one is with the LEDs what can u say I am a sucker for these little busters

  • At 18 November 2011, 2:10:25 user Neric wrote:   [reply @ Neric]
    • Like Tim from At 19 January 2010 am too having a problem with the fan being on all the time with no effect from the trim pots.
      I have verify that all my connection are true and par the recommendations for an alternative value for NTC mine is 19K so I divided it with 20K and my transistors are 2N2222A and 2N4401 (all what was available)...so this kept me puzzled I have tried different value for R4,5,6 and 9 with no success so please help as I am stump

  • At 12 March 2011, 20:05:49 user Kammenos wrote:   [reply @ Kammenos]
    • as i explain, the LEDs are only for demo. they are not supposed to be connected to the breadboard, as they will not operate normally. If you want to add them no matter what, you can connect them one from pin 6 of the 741, and one from pin 8 or 4 of the 444, but you must add also a protective resistor, like 470 ohm or above. This is something that you have to test yourself

  • At 11 March 2011, 13:04:33 user ronnie wrote:   [reply @ ronnie]
    • ah okay..thanks for the help..

      but my last question is, where do you exactly connect the terminals of the two LED's? I can't see the breadboard connection clearly if I zoom it in because it's kinda pixelated..

      thank you very much again!!! :)

  • At 8 March 2011, 20:29:17 user Kammenos wrote:   [reply @ Kammenos]
    • Ronnie, read the article

  • At 8 March 2011, 19:10:52 user Ronnie wrote:   [reply @ Ronnie]
    • Hi again..:)

      I've just completed my circuit by following the schematic diagram, and it works. My only problem is, how can I increase the sensitivity of my thermistor? I used a different value of thermistor. The fan is not running for a typical heat coming from the CPU of a computer. But, the fan starts to run when I put a very hot soldering iron near it.. how can I make the fan runs even for a lower temperature??

      thanks again for the help..! :)

  • At 7 March 2011, 13:42:03 user Kammenos wrote:   [reply @ Kammenos]
    • Ronnie if you want to make this circuit, you must follow the schematic of course. But no matter what, the circuit on the breadboard is the same always with the schematic. The only thing that i have add in some cases is a smoothing capacitor across the power supply.

  • At 7 March 2011, 13:14:07 user Ronnie wrote:   [reply @ Ronnie]
    • hi

      Should I follow only the schematic diagram and not the one connected in the breadboard? because in some of your videos like the PIC closed loop fan controller, there are no any trimmer in the schematic diagram, but in the breadboard, I saw a trimmer... which one would I follow? the one in the breadboard or the one in the schematic diagram?

      I hope you could help me, because I'm doing this one for my project in school...thanks..

  • At 27 February 2011, 9:38:10 user Kammenos wrote:   [reply @ Kammenos]
    • It does not really increase the speed, it has 2 set points with 2 different speeds, low and full speed. read the circuit description.

  • At 27 February 2011, 4:07:49 user King wrote:   [reply @ King]
    • Hi!

      I want to ask the circuit for a PWM control. It increase the speed of a motor with temperature rising. How can it work?

  • At 18 November 2010, 5:52:55 user Kammenos wrote:   [reply @ Kammenos]
    • Keeping the temperature steady is not always possible. I tried it myself and failed. There are cases that this can be achieved, but it has to do mainly with the ambient temperature.
      In any case, this very circuit will not change linear your fan speed. Also, i have never use such a sensor so i do not know if it will work.

  • At 17 November 2010, 22:33:46 user Hagop wrote:   [reply @ Hagop]
    • Hi

      I need to build a circut that can controll fan speed by using temperature feedback circuit, and i should be able to set the temperature as example to 30 degree, then the fan should increase or decrease linearly with the temperature to hold the room temperature stable on my setting. I am using two wire fan and temp sensor pt1000 from ELFA as shown in the link below:


      What kind of change i need if i want to use your circuit?


  • At 19 October 2010, 13:53:19 user Kammenos wrote:   [reply @ Kammenos]
    • I know what you mean. The fan starts when the temp is high, and when it starts the temp cools down fast, and then it stops etc etc etc. Although i have not test it, in a glance, i would advice you put an RC between T2 and T1. So, here how it should go. Reduce R4 to 1K. Then, remove the connection between T2 and T1. Instead, put a rheostat there. Then, between the T2 and the rheostat, put an electrolytic capacitor to the ground. I would try first with 47uF capacitor and 50K rheostat. Here is how to connect:


      In theory, this would work. Try different capacitors and maybe rheostat values. Please share with us the results.

  • At 19 October 2010, 2:32:41 user sakbar wrote:   [reply @ sakbar]
    • Hello,

      I have built on of this. But got a slight problem. the system turn itself on and off every few seconds, how to have the circuit turn on at threshold point and run atleast for a pre-determind time, say a minute.

      Also for the circuit I'hv used 50k NTC with 100k pot for r1(set at 50k). Also using irf540 i/o 520.

      really appreciate the good design

  • At 19 October 2010, 2:26:53 user sakbar wrote:   [reply @ sakbar]
    • Very good project, build one already running ok. But the problem is it turns on and off every few seconds, Can you advice how to have the circuit start and run for atleast a minute so that it does not turn itself on and off every few seconds.

      for building I could not find 4k NTC, instead using 50k NTC with a 100k pot set at 50k for r1. Also using IRF540 instead of 520 and running very smoothly.


  • At 31 August 2010, 2:36:49 user Michael Conner wrote:   [reply @ Michael Conner]
    • I need to reverse the operation of this circuit ie I need to have the fan on high speed at the lower temperature and cycle down when the temp gets warmer and shut down at a predetermined high temp.

  • At 20 April 2010, 19:00:22 user Kammenos wrote:   [reply @ Kammenos]
    • The circuit can handle up to 9 Amps, so yes, it would! (24V 50Watt = 2.08 Amps)

  • At 31 March 2010, 2:52:37 user Michael wrote:   [reply @ Michael]
    • would this circuit work on a 24V,50watts Fan,thanks

  • At 19 January 2010, 0:01:57 user Tim wrote:   [reply @ Tim]
    • If you are still interested in this circuit I'd like to email personally about it rather than post the entire exchange online. I'm having difficulty with T3 allowing current to flow all the time. Does npn allow current. and stop the flow with a positive bias maybe? My fan operates all the time, regardless of pot settings. A volt meter indicates a voltage reduction at the output of about 2 volts when adjusting the duty cycle. I couldn't find BC337 so I have tried 2N2222 and 2N4401 for T3 with the same results.
      I have completed an nice little single sided pcb layout I can contribute if we can solve this issue.

  • At 14 January 2010, 21:52:30 user Kammenos wrote:   [reply @ Kammenos]
    • Well, Tim, if you want my advice, forget about the autoroute. I tried to get some elegant PCBs using autoroute, but the result is really poor. Take my advice and draw manually the lines one by one. I know this is rather frustrating, but it really works. And after 3-4 tries, you will get the 'eye' and the 'hand' and you will draw the lines really fast. Use the airwires (the yellow straight lines) as guides, but draw the wires yourself. You will see that the airwires are very helpful. try it.
      As for the reverse, you can directly print the circuit reversed from eagle.

  • At 14 January 2010, 21:41:21 user Tim wrote:   [reply @ Tim]
    • If you have a few more moments, I could use a bit more advice. I downloaded/installed Eagle, and figured out how to input the circuit as shown above. I am struggling with component layout on the PCB. I successfully figured out how to set the autoroute to single layer but end up wit lots of airwires. I can't figure out how to optimize the component layout to acheive a successful trace route. Any advice for this newbie? I will also go try to locate a forum for the eagle software.

  • At 14 January 2010, 4:27:32 user Tim wrote:   [reply @ Tim]
    • Sorry I don't know the correct terminology. By reverse layout, I mean when you print pcb pattern, that it does it upside down for transfer to the bottom of the pcb board for etching with that ferro whatever chemcal from Radio Shack. I'll go look for the eagle lite software and see if I can figure it out.


  • At 13 January 2010, 19:37:12 user Kammenos wrote:   [reply @ Kammenos]
    • Hi Tim,

      What do you mean 'reverse layout'? For negative photo resistive PCBs? I'm sorry i really do not know. I use the eagle PCB lite version and do photoresistive method with positive photo transfer. btw, check this out:


  • At 13 January 2010, 19:30:37 user Tim wrote:   [reply @ Tim]
    • Nice project. I think it will work fine as the basis for an application to cool my beehives in mid August. I am using a solar cell as power supply. I used to do wire wrapping techniques but would rather do pcb\'s for this project. I think I will build 4-5 of these. I have no experience creating a pcb, but have read how to do so with a laser printer/photopaper technique. Did you ever create a reverse pcb layout for this project? If not, might you point me to some software to create the reverse layout?


    reddit this Reddit this

     HOT in heaven!

    NEW in heaven!

    New Theory: AC electric motor working principle

     Contact     Forum     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science     RSS   

    Site design: Giorgos Lazaridis
    © Copyright 2008
    Please read the Terms of services and the Privacy policy