PWM to Analog converter circuit

That's not a bad idea mate.

I would also advise a slot above the heatsink too, especially if you have loads of fans attached, not so much that it's sticking out but a hole so it can expel the warmer air.

Anyway I've ordered more fan header strips so I can do more like this. Currently I only have dual row, which I might be able to modify into single row but it's a bit of a hack.

Will check what size would be required. It's bigger than the Phanteks solution of course as it has more going on, and is mounted on stripboard which isn't the best space saving circuit board out there.
 
Board size is 80mm x 15mm and 20mm high at its most.

A 25mm heatshrink will be fine to cover everything do I will grab some of that.

I had planned to have a single 3/4 pin connector coming off a flying lead and then the end user would add a splitter as required. Panyan asked for a board with fan headers like the one I had in the older vidoes and I thought it cool if it were integrated.
 
Couple of things arrived this morning.

ShrinkNIRL540.jpg


The heatshrink. The logic level Mosfet.
 
It is rather large but is apparently 25.4mm when round, it of course comes flat.

Not as orange as I'd hoped but it's ok.

I've finished Panyan's converter. I was just waiting on the shrink really.

panyan1.jpg


And I also put together the LED PWM dimmer. It has a PWM connector and Molex for power, along with a 3 pin fan header on the board for LED strip hookup. This is even better on the stripboard than it was on the breadboard. The Mosfet remains cool.


panyan2.jpg


 
Last edited:
Here's one I made for Resident. A few subtle differences. This one has a longer PWM/RPM lead to the connector. It's about 220mm long. The resistor bank is keyed to Resident's needs, needing to drive 2 x Corsair SP120 high performance which I put on the Medium setting, it also has 3 fan headers on board instead of 4.

P1050192.jpg



P1050194.jpg



P1050188.jpg


Obviously not all hot glued and heatshrunk up yet as I wanted some naked shots. I forgot to take some of Panyan's board.
 
Very nice! Are you going to cut heatshrink for slider switch first then put it inside the big heatshrink with cutout for it on board?

Thanks again.

I was planning on does a similar thing as with Panyan's one. Just have it sticking out the top and the end sealed with hot glue. The switch is a set once and forget until you change fans thing anyway so it's not something that'll be fiddled with. I will do a cut out for the fan hookups though. That worked out better than I expected as the shrink goes nice and thick when shrunk down.
 
Did anyone notice the silly error in this image?

panyan2.jpg



Yes it's the wrong gender connector.

This is what it's supposed to look like. Also bent the Mosfet over as Panyan's idea for mounting on a standoff.

ledpwmthingy.jpg


Spent a little while compiling a list of resistor to current values.

I wanted to remove the guesswork in calculating the amount of resistance needed for a given fan output. It's a non linear graph as expected. The figures give a 11.8-11.9v maxiumum speed that allows a drop down to 4.2-5.0v at low duty cycle so should be spot on for most uses.


ohmsvscurrent.jpg


I can throw a circuit together in next to no time now. It's just the wiring that takes the time. Now that I know which resistors to choose that'll help me a lot.

Leeroy asked me to build two circuits, one for his Gelid Icy Vision Rev 2 and one for his two Gentle Typhoon AP15s.
 
It doesn't do any conversion, it's just an amplifier of the PWM signal that allows one to drive up to 20 Amps of load off the signal. It's a bit off-topic and not really good for fans, although to be fair I haven't tried it with any.

The fan header on board is just there for convenience. Everyone has an old fan they can rip the connector off and hook up to an LED strip.
 
Ok.

I brought some fans, some PWM converters, a multimeter and an 0.8A LED strip into the the house for connecting up to my PC and running some final tests.

Seeing as I like graphs and data I thought I'd show how Panyan's reacted to PWM duty cycle through it's range with a load of 0.35A.

panyan-med-setting.jpg


A nice smooth transition down from slightly below top speed, down to slow speeds. Speed is consistent too. Only varies by an RPM or two once it's set.

On high setting it's quite different as high is engineered to cope with a fan or two extra.

panyan-high-setting.jpg


It runs at full whack and begins to slow down very slowly as duyty cycle drops away, then eventually it drops away. I guess this would be useful if you liked a bit of top end speed early on in the duty cycle range.

The converter has been running now for about an hour up and down and it's warm but not too bad. Ideally the heatsink would be exposed to air but it's using the heatshrink to dissipate it's heat instead. :)

As I remove the PWM connection the fans instantly speed up to maximum as designed.

I'm pretty happy with that.

Onto the LED strip dimmer. This works quite well but does go pretty dim at sub 30% duty cycle. It's hard to say how this will be with single colour LED strip though. It could do with a bit of a boost at the lower end. Not quite sure how to do that at the moment but will look into it. Maybe some sort of voltage divider coming in with the PWM signal to boost it from 1v average at 20% to 2v or something.

Next up Resident's.
 
Panyan said:
(why is that? )

I'm not wholly sure. It's fine down to 40% and then dims off pretty rapidly from there. I don't have a blue LED strip to test out on but the Blues are the fastest to tail off on my RGB strip. Strange as it works pretty well right down to 20% on my PWM circuit in the shed. I suppose these are the differences between my 25khz PWM and Intels PWM.

Anyway I'm going to fiddle with a few components to see if I can keep the signal up a little in the 0v times of the PWM signal.

Edit: So maybe this.

Test1.jpg


A capacitor will sit across the LED strip and hold a little bit of charge that sees it through the down period of the signal. The top oscope shows a more or less naked circuit as it is now and the bottom oscope shows it again with the addition of a 50uF capacitor.

Capacitors are a little like batteries but much more fun and fast. They like to keep charge in a circuit the same as are used all over circuits to maintain a steady voltage for all components.

For example if an integrated circuit that draws 5uA at idle and then all of a sudden draw 20mA it'll cause a voltage sag as the power supply tries to keep up. A capacitor across the power supply will enable that voltage to be supplied without a big ripple while the power supply catches up. Cool things are caps.

In other news I've hooked up to my CPU PWM socket now and will see how that influences stuff. The GPU and CPU PWM should be roughly the same so I'm not expecting any surprises.

It appears the rpm is lower at same voltage on medium setting graph vs high setting.

It's not a perfect world. Maybe I was going up in speed instead of down and didn't wait long enough for things to normalise. The graphs were actually an afterthough after I'd recorded a few values.
 
Last edited:
very interesting - thanks :)

Doh it's just the Red LEDs preventing the other LED colours from starting up. Normally a RGB would have a different PWM controller per colour to eliminate the issue.

So I wired up a few purple LEDs to the circuit at ultra low duty cycle and they light up.

So then wired up just the blue parts of my RGB strip to the circuit and it works right down to 20% where the LED basically switch off. Provided you don't go below 30% you'll get good range of light from them. At 30% they are quite dim but will give really subdued case lighting, meanwhile at 100% they are fully bright.

A capacitor might help a little at the bottom range so I will look at adding one just for the low duty cycles, even if it helps a little it'll be a help. Earlier when the red was hooked up it made a big difference low down. More info on that tomorrow. I've got martial arts training tonight so fiddle time is over for now, much to my wife's agreement, as having 6 fans littered around the living room with multimeters and LED strips strewn about isn't making me Mr Popular.

Anyway hooked Residents up and recorded the data from the medium setting.

Resident.jpg


I'm having a strange issue with the High setting is that despite it supposedly being good for 0.4-0.45A it's not making much difference than the Medium setting and certainly not going near 0.4A. Bit confused by that. Will investigate that but anyway the medium setting which was designed for the 2 SP-120s works a treat.
 
Another little update for you Resident.

Not quite sure why 400 ohms and 1.1k give a very similar output, when on other circuits using the same components they are markedly different. Maybe there is a gain difference between B772s. I hadn't really considered that there would be that much difference.

Anyway I redid the board (built another but used the same wiring) and put on some fresh resistors using 333 Ohms for High, 1.5k for Medium and 2.5k for Low. I made it 6 holes wide as it just looks better. Will update with pics later.:)

Again at 0.29A and running off Intel PWM controlled through Speedfan.

This time I've plotted both Medium and High.

Resident-final.jpg


So I'm happy with that.

And to Panyan.

I've added a 10uF cap to the LED dimmer and it helps a bit and lights up right down to 20% now , although it's pretty dim down there, but it's just fine at 30% and has good range through to about 90% where you'd be hard pressed to see the difference to 100%. You may need to increase the capacity of the cap depending on how many LEDs you'll be powering as it'll probably be a lot more than I have here, What I will do is throw in some 22uF, 33uf, 47uF caps in if I suitable ones and you can tailor it to your needs. Bigger caps take longer to fill so throwing a mega 3300uF cap on there wouldn't help at 25kHz.
 
Last edited:
Thanks guys. I'm happy you find this so interesting.

I had a partial board built so threw some resistors on in preparation for the control of Leeroy123's Gelid Icy Vision Rev2 .

A little different this one as the fans are stated as 0.5A for the two but I don't believe it will be so high so I created 3 graphs with different loads so one of these should work well for his chosen cooling curve. They were recorded using 0.48A, 0.33A and 0.18A loads on Hi, Med, Lo settings. Resistances were 500 Ohms, 1k Ohms and 2.2k Ohms for the settings. I did originally guess 333 Ohms but it worked out as just a bit top heavy, so a snip later and it was good.

leeroyGPU.jpg


I seem to be starting things but never getting things finished. Sorry about that guys. Saying that though they are all very close to complete, just needing a few blobs of hot glue and some heatshrink and these things can go in the post.

I'm also happy to say that despite messing around with these things and pulling them on an off my PWM header it's still happily working. :) The 1k resistor on PWM input is a safety thing as it prevents too much current being drawn.

All board have now been tested for a good time on my PC, on both Intel and AMD PWM outputs.

And some photos...

First Resident new board
P1050213.jpg


P1050215.jpg


P1050216.jpg


and Leeroy123's
P1050219.jpg


P1050220.jpg


And oops. Hard things and fans don't always mix.

P1050212.jpg
 
Last edited:
I dropped another fan onto it while I was taking another one off the circuit. It's a little unbalanced now ;)

Shame as I rather fancied using it on my Shaman.
 
Another update.

Decided to shrink up Resident's circuit today.

P1050222.jpg


P1050224.jpg


It takes a fair amount of heat to get the thing to go down and the hairdryer I'm using, even though it's 200 watts doesn't do a wonderful job. Anyway it went down eventually.

So that's all ready. :)

So I started another one for Leeroy123, this one will control 2 or 3 Gentle Typhoon AP-15 and thanks to Panyan I know exactly how much they draw.

leeroy2.jpg


As you can see it's not quite finished yet as I've only just started adding the power delivery resistors.

Interestingly I made an error with the Orange wire and wired it up to the gate of the Mosfet rather than the drain and the circuit started working backwards. Increasing duty cycle caused the fans to slow down, reducing duty cycle caused the fans to speed up. I couldn't figure it out for a few minutes but twigged in the end. ;)

In other news I came across this today..

rivalpwmtodc.jpg


...A similar concept to mine but uses 4 transistors and from the pdf they market it through the potentiometer is used to trim the low end, just like the potentiomter did in my earlier design, before I changed it to the switch to make it simpler for you guys.

I might see if I can't reverse engineer it from that image and see what they've done that needs 4 transistors, although just by looking at it I would guess that the top right 2 are in a darlington configuration to boost current, while the other two might be a NPN and PNP to invert the PWM signal.
 
As for the rival board. I think your simpler design is better, much less to go wrong. Plus yours draws power from and 'external' source which in my mind is better as it protects the header, stopping the fan drawing too much current. Also the rival board only has only one output.
If what you say is true regarding the extra transistors being using to boost current then wouldn't that indicate that it couldn't power more than one fan ?

Also the rival board is a lot more square so heatshrink isnt as neat and harder to tuck away in the case :)

These are both true but nevertheless I'm intrigued enough to wonder if this gets around some of the shortcomings I have with getting the power to load ratio more or less right, and if they've got around the issue of overloading the potentiometer. I've considered putting an additional transistor in the circuit to allow high current without burning stuff up but haven't done so as of yet. An additional transistor would add a penny to the cost, the potentiometer would add a few too, but would remove the need for a switch.

EDIT: Had a quick look at it and it looks like the designer has used a very similar PWM inverter and then, as I said used a couple of transistors on the output to handle the load. Rather than going for a more expensive power transistor he's just used a couple of the cheaper ones instead. Seeing as I got the B772 cheap from Hong Kong I'm not too concerned.

Ideally the circuit would measure current draw, compare with voltage output and PWM signal duty cycle and decide whether or not to increase the power to the circuit.

As I've said before I'm more than happy with the performance of my circuit and think it's fine as a self build but it's not really that marketable for the general user, at least not yet anyway.

I did some simulations on my simulator circuit which is the same, just using similar components with varying PWM frequency from 22kHz to 28kHz and PWM from 3.3v to 5v, which is basically what Intel says they must conform to. The bottom line is that even using the lowest PWM voltage and the lowest frequency the difference in output is just 0.05v or thereabouts, which is much better than I could ever achieve with a Low pass PWM input design, like the one I put up previously with the triangles and squares. ;) So this design is really quite strong.
 
Last edited:
Me again.

So I've completed the wiring and stuff on Leeory123's board.

This one is for two low power Gentle Typhoons so I've designed it such that he can choose a suitable fan curve based on how quiet he'd like them to be, and also give the option of a third GT AP-15 to go on there, at the loss of some speed on the High setting.

Leeroy123-018A-Load-3graphs.png


Three RPM and Voltage plots on two graphs this time as High and Medium are both topping out and I feel it needed that Low setting for a good curve, at the expense of some low end speed. I'd go with Low of course but I know that everyone is not like me :)

I'm going to look to getting something in the post today to Mr Panyan. Just need to do some hot glue on the LED dimmer.
 
A few pictures of more updates.

Shrunk a few up today and started another.

Leeroy's Gentle Typhoon controller all complete and ready for sending.
P1050233.jpg


P1050237.jpg


This one is a little different. It's to control the graphics card fans and therefore has those strange GPU fan connectors. I've used up everything I had so if any more were ever needed I'd have to buy more stuff in. The black connector plugs into the graphics card, the controller gets tucked behind the motherboard, gets Molexed up nicely, and then the other lead runs back to the graphics card's fans. The connector will only go one way around so this should be simple for Leeroy to fit.

P1050239.jpg


P1050241.jpg


The black bit is from a GPU to standard fan converter I bought 2 years ago and then never used.

P1050243.jpg


This end is actually a 5 pin with one of the pins removed and a little bit of hot glue stuffed down the empty cavity. The connector fits in lovely, just like a glove.

P1050244.jpg



So I thought I was done. Everyone who has asked for a circuit to be built has had them built and fully tested. Then it occured to me, there is one person who wanted one of these, ME! :p

The whole point in this was to develop something to control my DC fans with my PWM pulse.

So I busied about making my own.

As before the components fly onto the board but it's the connectors and wiring that takes a long time, especially when you sleeve the wires with Orange braid.

Yes I went for a potentiometer protected from melting by a 1k resistor. I'm only looking to control 1x Noctua 86mA fan for the moment so don't need anything beefy. If I want to control another one I will just make another.

mine3.jpg


mine2.jpg


mine1.jpg


I was thinking about having a flying lead off the end but the orange connector looks quite nice on the board and I will need to make a hole for the potentiometer anyway.

Not quite finished as I haven't actually powered this one up yet, but I'm confident.

Blew another B772 today. Good thing a new batch of 10 arrived this morning. ;)
 
Mine is complete, altough I haven't heatshrunk it yet.

P1050259.jpg


P1050264.jpg


No need for a heatsink on a 86mA fan so I won't bother with it.

My fan curve. I didn't bother with voltage as the multimeter was down the shed and I'm lazy today.

Tealcs-fan-curve.png


Got it all set up in Gigabyte's ET6 using PWM and it revs up nice and smooth responding to the PWM curve I set. 30% at 40 degrees, rising to 100% at 80 degrees.

Sweet. :)

I think I will make a PWM splitter now as I may want another one to control my rear fan, or I might use the graphics PWM as it's that that gets hot and needs the faster exhaust.

Oh and Panyan I did get to the post office yesterday but the dozy woman put a 2nd class stamp on the jiffy bag and the wife had paid before I realised so it might take a couple of days mate.
 
Oh dear I don't remember you saying anything about two cards mate. Now that I check your sig I can see that you have two.

Hmm.

It would probably power them both but connectivity is going to be tricky seeing as I used the only GPU fan connector I have is used on the single controller. Without the GPU to normal fan converter cables that came with the Gelid it's going to be tricky.

If I'd realised I would have made a dual board.

Can you please check if you have a adaptor cable with the small GPU fan connector on one end and a Molex or standard fan connector on the other end. You should have two of them.

You can see them in this image of the accessory pack that comes with the Gelid. The little black connector on the right can be then used to plug into my converter, with a slight modification or two.

1842-SAM_1630%20(Copy).jpg
 
Last edited:
Back
Top Bottom