Pages: [1] 2   Go Down
Author Topic: Mosfet body diode as flyback?  (Read 2446 times)
0 Members and 1 Guest are viewing this topic.
Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

After discovering that they're a lot cheaper than a voltage regulator with an enable pin that can handle high current, and deciding I might want to drive motors that need a little more than 3V, I'm thinking about using this logic level n-channel mosfet on one of my boards:

http://www.onsemi.com/pub_link/Collateral/NTD5867NL-D.PDF

And the diode in the schematic got me wondering... do I even need an external flyback diode when using this with a small DC motor I'll be controlling with PWM and which will draw less than 2A @ 5V?  (I only need to drive it in one directon, which is why I'm not making an H bridge.)

The data sheet lists the diode's max rating at 20A, well above what I need.  An external diode might spread the heat out some more, but a post I saw somewhere indicated the internal diode might conduct first and the external one will conduct less of the current.  So I'm not sure if there would be any benefit there.

Any thoughts?


Btw, this would be the external diode if I use one:
http://www.onsemi.com/pub_link/Collateral/MBR140SFT1-D.PDF


[edit]

I'm not really sure how to compare the two diodes.  There doesn't seem to be a lot of data to compare between them.  But it does look like the diode in the MOSFET has a forward voltage of around .76V at 3A, while the external one is around .85V at 3A.  If I'm not mistaken that means the internal one is more efficient, which is odd.  The external one I chose because it was designed to handle high currents. 
« Last Edit: July 23, 2012, 12:20:54 am by scswift » Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 437
Posts: 23718
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm guessing you wouldn't need external as the 20A internal does appear to be designed in for just that.
At the most, you blow 53 cents if wrong.
http://www.digikey.com/product-detail/en/NTD5867NL-1G/NTD5867NL-1GOS-ND/2401422
http://www.digikey.com/product-detail/en/NTD5867NLT4G/NTD5867NLT4GOSCT-ND/2409631

and the diodes are the same price.
http://www.digikey.com/product-detail/en/MBR140SFT1G/MBR140SFT1GOSCT-ND/917969
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Since I plan to have around 250 of these made, I'll blow quite a bit more than 53 cents if wrong, but I also don't want to waste $75+ on 250 diodes and their placement if I don't need to.  (Plus all the money I'd be wasting in future designs sticking diodes on there I don't need.)

Hm.  I'd like to get some more opinions.  I've read a lot of posts on other forums saying you absolutely do need the diode, but I can't see why, and it's possible a lot of people are stuck in old habits and things have changed.

On another note, I've been trying to do some power calculations for this mosfet.  I used some formulas I'd been using for my voltage regulators, and a thermal simulator for PCBs/heat sinks, and it looks like the tiny PCB I'm going to mount this on will only be able to dissipate around 1.25W, while the mosfet itself can dissipate around 2.77W to the ambient air.  I'm not sure how to calculate how much power the mosfet will dissipate, but assuming a worst case scenario where all the power is converted to heat, it looks like I would be safe putting 800mA through it.  And I have to assume that only a fraction of the power will be converted to heat so it should be quite a bit higher than that. 

I think Rds(on) is the resistance when it's full on, which is 39mOhms max for this mosfet, and 5V and 39mOhms gives me... 641 watts dissipated?  Yeah, that ain't right.  I mean if it was connected directly to a battery with no load.  But not with a motor in there.  Hm....
 
« Last Edit: July 23, 2012, 02:44:26 am by scswift » Logged

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ugh, even after all this study power calculations still confuse the hell out of me.  You'd think something with a lower resistance would generate less heat, but I don't know how to calcualte that.  Or do I?  I seem to remember something about voltage drop being what's converted to heat.  Can I calculate the voltage drop from the input voltage and that resistor?  I guess I'll have to look up how to do that.  Maybe there's something in the datasheet too.

[edit]

Hm... I found a tutorial on transistors which says they dissipate relatively little heat when fully on.  This makes sense, but not when the equations for a resistor's power dissipation say it goes up as the resistance goes down.  Oh well, it looks like my transistor should run relatively cool then since I will only be turning it full on and full off with PWM.  Except for the heating from that diode in it...  Hm.. 1.2V forward drop worst case... That's 0.06W @ 50mA (which is what the motor I want to drive will use but I'd like to be able to drive up to a 1A load with this board), 1.2W @ 1A, 2.4W @ 2A (which is the limit of what the header pins and wires can carry).

I guess it should be okay.  I don't plan to put near 2A through it but it looks like it may survive that.  And in case anyone is confused, and to remind myself later, the 2A here would be the power flowing through the mosfet in reverse when the magnetic field of the motor that is being presumed to be driven collapses.  I presume the mosfet won't heat nearly as much with a normal load.  So it should be able to handle 2A without heating up much at all if driving something else.
« Last Edit: July 23, 2012, 03:07:17 am by scswift » Logged

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hm, on the subject of power dissipation again, I was just looking at this:
http://www.allaboutcircuits.com/vol_3/chpt_3/3.html

And saw this:
"Thermal resistance = R(Θ), the temperature difference between junction and outside air (R(Θ)JA) or between junction and leads (R(Θ)JL) for a given power dissipation. Expressed in units of degrees Celsius per watt (oC/W). Ideally, this figure would be zero, meaning that the diode package was a perfect thermal conductor and radiator, able to transfer all heat energy from the junction to the outside air (or to the leads) with no difference in temperature across the thickness of the diode package. A high thermal resistance means that the diode will build up excessive temperature at the junction (where its critical) despite best efforts at cooling the outside of the diode, and thus will limit its maximum power dissipation. "

So then the datasheet listing of R0ja = 45 C/W means for each watt of power dissipated the temperature will rise 45 degrees above ambient?  I assume something needs to be subtracted for the junction to case dissipation.  Not sure how to calculate that.  Also not sure how to calculate the power dissipated for the mosfet.  2A @ 5V = 10W, but would that be the power dissipation or something much less than that?  Based on what's I saw saying transistors dissipate little heat when fully on, I have to assume Pd is much less than 10W but again not sure how to calculate what it is.  I guess I don't need to obsess over it since it doesn't seem like it will be a concern at all, but it would still be nice to know.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 437
Posts: 23718
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Datasheet says Rds on = .05 Ohm @ Vgs = 4.5V & Ids = 10A.
I think you mentioned 800mA somewhere.
P = IxIxR = .8*.8*.05 = 32mW dissipated when turned on.
So I think you'll be okay.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If you are using a single mosfet to control a motor, then the body diode of the mosfet is in the wrong position in the circuit to act as a flyback diode, and you definitely need an external one. However, in a mosfet H-bridge configuration, the body diode of each mosfet acts a a flyback diode when the other mosfet in the same half of the H turns off, so you don't normally need separate flyback diodes.

If you are using PWM and there is a lot of flyback energy coming out of the motor, then a Schottky flyback diode is best, because it will run cooler. Otherwise, use a silicon fast recovery diode. If you are not using PWM, and ordinary silicon rectifier diode is OK.
« Last Edit: July 23, 2012, 09:49:29 am by dc42 » Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, both of you.

CrossRoads:
Okay, I guess that makes sense.  But I never know which equations to use when calculating power dissipation.  I was trying to use voltage and resistance which gave a much different result than using amperage and resistance.  I only "know" the amperage because I'm just picking a number out of thin air to see the result of that.  Perhaps that is what I just need to do though and trying to calculate it from the voltage was the wrong approach since what I really care about is how much power will be dissipated based on a particular amount of amperage.  I'm not really sure what I was trying to calculate using the resistance and voltage.  Watts obviously, but I mean I don't know what the wattage result I got would be interpreted as.  I guess maybe the wattage when there was no other resistance in the circuit?

On another note, based on your calculations, I get 1A as causing 0.5W power dissipation and 2A as causing 2W of power dissipation.  Obviously that's makes sense looking at the equation, but it was an unexpected result nonetheless.  Anyway it looks like 1A would be fine and brief surges of up to 2A would also be okay.  I don't know what I might need that much power for, but it's good to know it can handle it. 

Dc42:
I guess I'll use the external diode then.  I've already reduced the cost of this board dramatically by getting rid of the 3V regulator I was originally going to use. 

Btw, this board is for driving lasers and vibration motors, most laser diodes are 3V and most vibration motors are 3V because they are for cellphones or designed to run off 2 AA batteries, but I didn't want a high frequency vibration like a cellphone, I want something more like a game controller, and the larger ones require 5V-24V, which this new version of the board will be able to supply and there are still plenty of 5V laser modules out there.  That the mosfet was a fraction of the cost of the regulator was a bonus.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 437
Posts: 23718
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

P = (V*V)/R and I*I*R
Gotta go with what you know.
In this case, you know the planned current and the Rds of the MOSFET.
You can calculate the Voltage across the MOSFET given the current flow and Rds: V=IR, 0.8A * 0.05ohm = 0.04V
So, P = I^2*R = .8*.8*.05 = V^2/R = .04*.05/.05 = .032W
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Edison Member
*
Karma: 56
Posts: 2184
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I had always used external diodes.
The one time that I didn't, I paid for it. 
My test at 12V was OK, but when I ran the motor at 24V (it was low duty, too, "25%") - Kapow!
For me, the argument is settled: diodes (pref. Schottky), always.

Logged

"Hello, I must be going..."
"You gotta fight -- for your right -- to party!"
Don't react - Read.
"Who is like unto the beast? who is able to make war with him?"

Offline Offline
Full Member
***
Karma: 5
Posts: 199
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Same goes for me. I once blew up a nice SCR because I had forgotten to to use a diode across the motor. It ran few seconds but the next time I switched it on, nothing happened.
Logged

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Note to self:

I miscalculated the power dissipation for 1A and 2A @ 5V through the MOSFET.  I entered .50 for ohms, but the MOSFETs RDSon is 50 milliohms which is .050

So at:
1A, the power dissipation would be .05W, and at 2A, Pd = 0.2W, both way below what I calculated it will be able to dissipate.

But one thing still confuses me.  Surely the power dissipation cannot be the same with a 12V input as it is at 5V?  Yet if I just go by the above, that is the conclusion I have to come to, since voltage doesn't enter into the equation.  Can that be true?

I guess it kind of makes sense.  The voltage across the MOSFET was calculated to be .04V.  I presume that is the voltage drop.  That means a lot more voltage would be left after 12V passes through than 5V.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 437
Posts: 23718
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If you used a 12V source, presumably a lot of that 12V would dissipated by a larger load, such as a motor.
The current might also  by higher, leading to a higher voltage across the transistor.

If you had 12V across the initial 5V  motor,  presumably it would only need the same 800mA, so you would put a current limit resistor in series, as 12V across a 5V motor's coil would have more current flow as the motor's impedance (similar to a resistor's resistance value) does not change.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Surely the power dissipation cannot be the same with a 12V input as it is at 5V?  Yet if I just go by the above, that is the conclusion I have to come to, since voltage doesn't enter into the equation.  Can that be true?

The steady-state power dissipation when the mosfet is on depends on the current through the mosfet (which for most loads will increase with the supply voltage) and its Rds(on). There are also losses while the mosfet is switching on and off, due to the finite time this takes. These switching losses are proportional to the supply voltage, the switched current, and switching frequency. The standard Arduino PWM frequencies are quite low, so if you are controlling a 12V load with a logic-level mosfet fed from an Arduino pin through a 100 ohm resistor, you can normally ignore the switching losses. OTOH if you increased the gate series resistor to 10K, then the switching time would increase and the switching losses would be more significant.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Manchester, New Hampshire
Offline Offline
Edison Member
*
Karma: 1
Posts: 1283
Propmaker
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

dc42:
Thanks for mentioning the resistor.  The examples I'd looked at didn't have one, and I didn't know I might need one.  I've added one to be safe.  I chose 180 ohms because I had other resistors on the board with that value, but could have gone with 1K as well.  I've tried to calculate the switching speed of the MOSFET to see if 1K would be okay to use, but I'm not sure of my results.  I got something like a 3.6ghz switching speed.  I was looking at this page to see how to calculate it:

http://electronics.stackexchange.com/questions/20510/determine-mosfet-switching-speed

My MOSFET appears to be 10nC, or maybe as low as 1nC.  I'm not sure if I should use the total or threshold gate charge.  But I assume less means faster charge and discharge times.  The example on that page appears to indicate a switching speed of around 400khz.  But the example uses a smaller 100 ohm resistor, and the nC of around 70 in that example is only 7x as large as my MOSFET.  That leads me to believe my answer should be closer to 28mhz for switching speed.  I forget what the built in PWM of the Arduino is... I think it's like /8?  That's 200khz.   I don't think I will be switching that fast but I'd like to know what values of resistor are safe to use and what switching speeds I'll get.
Logged

Pages: [1] 2   Go Up
Jump to: