Help with driving a fan with pwm - Page 1
Forum section: electronics / projects

author: MrIndeciso
author_rank: Newbie
timestamp: March 22, 2017, 06:42:31 pm
content: Hi,I don't know if this is the right section or if I should write on Beginners, but I'm trying to make a circuit which should convert a 4 pin fan connector, with PWM, to a 3 pin fan connector that requires voltage regulation.I searched for something similar on the forum but I didn't find anything useful.I thought at these two (not so) different ways to do it:(I've never used CircuitMaker before so sorry for my wiring)Everything seems fine with one fan, and gets even better with a capacitor after the Mosfet, the voltage drop is about 0.3V (I think). The Mosfet gets just warm with a Duty Cycle of 60%.However when I try with two fans (every fan uses about 0.3A) the voltage drops of even 2 or 3V and the Mosfet starts heating up.What should I do?This is the datasheet of the mosfet:https://cdn.sparkfun.com/datasheets/Components/General/FQP30N06L.pdfThanks to everyone

author: mrkev
author_rank: Regular Contributor
timestamp: March 22, 2017, 07:24:21 pm
content: Hi.It is heating up, because you have it backwards. It acts as emitor follower and even worse, the body diode keeps it open the whole time. (just try to draw a line where the current flow. From +12V, to +12V pin on the fan, to pin 3 of the transistor and you get that the diode is in the forward direction to pin 2).Swap pins 2 and 3, and while keeping the resistor between pin 1 and 3 (you probably don't need the bipolar transistor) make the value lower (I would say even 4k7). When the transistor is switched off, its input capacitance (which is high: 1nF) is discharged through this resistor. From 680k and 1nF you get 680us time constant, which is too high.

author: MrIndeciso
author_rank: Newbie
timestamp: March 22, 2017, 07:35:07 pm
content: I checked and I just made it wrong in the schematic, on my breadbord it is right.I'll check later for the lower value resistor

author: artag
author_rank: Super Contributor
timestamp: March 23, 2017, 12:35:30 am
content: If you chop the ground connection, the tacho signal will get corrupted. It may rise to 12V which could upset the motherboard. Best to chop the 12V (which is what actual 4-wire fans do)

author: K5HJ
author_rank: Regular Contributor
timestamp: March 23, 2017, 02:47:58 am
content: Brushless fans do not work well with PWM'd DC input. Use one with a proper speed control input.

author: MrIndeciso
author_rank: Newbie
timestamp: March 23, 2017, 01:10:36 pm
content: Quote from: K5HJ on March 23, 2017, 02:47:58 amIf I have to build a circuit to convert it I think it's obvious that I can't use a fan with a proper speed control.The fan I'm using seems happy with a PWM 12V, and better with a capacitor.Quote from: artag on March 23, 2017, 12:35:30 amUnfortunately I can only use this Mosfet because it is the only one that I have at the moment, so I must switch groundDoes someone know why it is overheating?

author: bktemp
author_rank: Super Contributor
timestamp: March 23, 2017, 01:35:29 pm
content: Quote from: MrIndeciso on March 23, 2017, 01:10:36 pmThe mosfet gets hot, because a huge current flows when the mosfet turns on in every PWM cycle to recharge the capacitor. Then the mosfets acts as a resistor limiting the charge current and dissipating a lot of power.Using PWM on a fan not designed for beeing driven by PWM is a bad design. Adding a capacitor makes it even worse.I know it is not the answer you are looking for, but that's why there are fans with a dedicated PWM input.

author: MrIndeciso
author_rank: Newbie
timestamp: March 23, 2017, 01:45:51 pm
content: Quote from: bktemp on March 23, 2017, 01:35:29 pmBut why does this thing happen even if the Duty Cycle is 100% (so the Mosfet is always on)?The Mosfet is a logic level one and driven by 12V so it shouldn't have a so high resistance to cause the voltage to drop to 9V (this happens only with two fans, with one it is perfect)?

author: bktemp
author_rank: Super Contributor
timestamp: March 23, 2017, 02:02:15 pm
content: This mosfet shouldn't get warm when driving a fan unless the fan has >50W.Try measuring the voltage across drain-source. The voltage should be near 0V when driven at 100% duty cycle.

author: MrIndeciso
author_rank: Newbie
timestamp: March 23, 2017, 02:38:23 pm
content: Quote from: bktemp on March 23, 2017, 02:02:15 pmI changed the breadboard and now Drain-Source is about 20mV, which is correct since Mosfet RDS is 0.035?Should I try building this circuit on a stripboard?Is there another way to do this circuit?

author: bktemp
author_rank: Super Contributor
timestamp: March 23, 2017, 02:52:41 pm
content: 20mV sounds right. Does the mosfet still heat up?

author: MrIndeciso
author_rank: Newbie
timestamp: March 23, 2017, 02:56:54 pm
content: Quote from: bktemp on March 23, 2017, 02:52:41 pmWith this new breadboard it doesn't, at least when it is 100% Duty Cycle.I'll try on the stripboard later

author: mrflibble
author_rank: Super Contributor
timestamp: March 23, 2017, 03:31:05 pm
content: You may want to add a freewheeling diode to prevent components from dying horribly during the switch-off phase.As for breadboarding, in my experience mosfet pins tend to be a bit bigger that what comfortable fits. And in general, breadboard connections are not super reliable. For low current paths usually not a big problem. But for motor control you may want to make some connections with ye olde soldering iron. Especially when you get unexpected results that are about to become your nexttime sinklearning experience.That said, I also use mosfets in breadboard. But to be nice to my future self I put them in a specific row of the breadboard and then I mark that row with permanent marker. So, when I use that breadboard later for something completely different, I only use that row for big pins. You can of course still use small pins in there if you like intermittent contact induced surprises.And another solution is to solder the mosfet on a standard pin header. Then you can plug the pin header in the breadboard.