 # Help me find the ultimate formula for choosing MOSFETs

So basically I want to be able to determine if a MOSFET is suitable for a certain circuit or not.
I will be driving the MOSFET like this: The gate signal will be a PWM signal from an MCU.
MOSFET driver is not an option because they cost 4 times the cost of a MOSFET in here and I don't think I'll ever use one in my hobby projects.

My question is, how do I determine if a MOSFET can handle a certain current at a certain frequency?
Lets say we're using the IRF530

As far as I know what I need to calculate is the switching speed and power dissipation. If those are within the MOSFETs specifications then I'm good to go.
Qeustion #1: Is there anything else other than switching speed and power dissipation I need to consider in order to choose a MOSFET? (Other than the obvious voltage and current capability)

For calculating switching speed my research tells me the best way is to use the gate charge from the datasheet as opposed to rise/fall/on/off times. Those timings seem to be only specific to the datasheet test circuit and don't seem to be meaningful for an arbitary circuit.
My sources:
https://e2e.ti.com/blogs_/b/powerhouse/archive/2015/07/16/understanding-mosfet-data-sheets-part-5-switching-parameters (last paragraph)
https://www.infineon.com/dgdl/mosfet.pdf?fileId=5546d462533600a4015357444e913f4f (gate charge section)

So I'm using the equation Q(total) = I(gate)t to calculate the time it takes to turn on the MOSFET. As opposed to using the turn-on or rising times from datasheet, or using the gate capacitance and RC time constant.
So with the equation Q(total) = I(gate)t we can determine how long it takes to turn on the MOSFET.
Question #2: How do I calculate gate current? Is it enough to imagine the gate as ground and solve for the value of I based on +12v and 10k (in above circuit)?
Qeustion #3: When I calculated t, should my PWM wave period be t
2 (on+off time). Or should it be (t
2*100)? Because the fastest the MOSFET will have to switch on and off will be at 1% duty cycle, so my period should be 100 times that.

In the above circuit assuming gate acts like ground our gate current will be ~1mA, then the time needed to turn on the MOSFET would be ~50us, so my PWM would need to be 100us which is a maximum of 10kHz. Or 10000us which will be 100Hz.

So we now know the maximum frequency that the MOSFET can switch with this setup.
Next we should calculate power dissipation. Assuming a 12v gate voltage the resistive power dissipation is easy to calculate
using Rds(on)*Id^2.

Now comes the tricky part that I find difficult to find a formula for. Power dissipated due to switching.
One source claims you can use the following formula to calculate switching power dissipation:

Now all these are available except for I(gate) which needs to be calculated. I haven't seen this formula elsewhere and it doesn't seem right to me because it doesn't use neither on/off times nor gate charge.
A more promising formula is this:

PD(sw) = 1/2 * VIN * I(load) * [t(rise) + t(fall)] * f(sw)

Now this formula is using rise and fall times. Which as far as my research and my common sense tell me are useless values. (discussed above).

I was wondering if I could use the on/off time I calculated using the total gate charge instead of rise and fall time and put it in this formula and use it as my guide to determine how much power will be dissipated by a MOSFET at a certain frequency and a certain load.

That will be On all the time until the Arduino output goes high to turn it off. Is that what you want?
You might consider a pullup to 5V on the NPN to keep it on (and the MOSFET off) until the Arduino wakes up to start controlling it.

As for power dissipation you went into it pretty deep.
I would find N-channel MOSFET with Very Low Rds and use that to start.
https://www.digikey.com/product-detail/en/alpha-omega-semiconductor-inc/AOD4132/785-1217-1-ND/2353935
<0.006 ohm Rds with Vgs = 4.5V, Id = 20A.
You’ll probably want to do some testing with a gate driver to make sure the input can be switched at the desired frequency. I don’t think a 10K pullup resistor is the best choice there. I’d go with something that can pull active High and Low. Maybe a 74ACT125 with 24mA high and low capability.

Maybe a 74ACT125 with 24mA high and low capability.

But that can't drive 12 V. If you use a logic-level FET, the Arduino will drive it directly. If you insist on using a non-logic-level FET for PWM, you need a gate driver. Doesn't need to. The AOD4132 will switch 12V just fine with 4.5V on the gate. That's why I suggested it.

That will be On all the time until the Arduino output goes high to turn it off. Is that what you want?
You might consider a pullup to 5V on the NPN to keep it on (and the MOSFET off) until the Arduino wakes up to start controlling it.

Yes that would be better.

I would find N-channel MOSFET with Very Low Rds and use that to start.

The ones with low Rds(on) tend to have higher input charge/capacitance. So for switching I still feel the need to calculate switching power dissipation.
Also, this is partially theoretical. I want to be able to calculate this if I ever needed to.
Also I would like to know the limits of the parts I have at hand, namely the IRF530 rather than buying new ones.
Also MOSFETs do not have much variety where I live and the good ones like the one you linked are usually unavailable or quite expensive.

I don't think a 10K pullup resistor is the best choice there. I'd go with something that can pull active High and Low. Maybe a 74ACT125 with 24mA high and low capability.

Can you explain why? And I'm not sure what that IC does.
Also that circuit is what I found in a tutorial and I'm using it as an example. I intend to use the smallest possible resistor value, 560 Ohms perhaps, which will give me ~20ma. Will that also not be good enough?

Paul__B:
If you use a logic-level FET, the Arduino will drive it directly. If you insist on using a non-logic-level FET for PWM, you need a gate driver. Why?
How is Arduino different from Arduino+BJT? If anything the BJT can supply much more current than an Arduino pin, given a low value for R1. And as far as I know they can switch at many hundred kilohertz.

10K will limit how much current to flow to charge the gate capacitance.
12V/10K = 1.2mA.
74ACT125 (pretty much any part from the 74ACT family) will sink & source 24mA, charge & discharge that capacitance right up.

BJT only pulls low to turn off. Need something to drive high too.

BJT only pulls low to turn off. Need something to drive high too.

The resistor drives high when BJT is off. And as I mentioned using a 560 ohm resistor will give me ~20mA. Anything wrong with that?

That should work. NPN has to sink around 20mA to turn off the FET, 560 provides a little more to charge up.

Cool.

So if anyone could answer question #3 now. And more importantly the last question about the formula.

And just to be clear, I know I can buy a MOSFET with specs so good that I would not have to worry about anything with a few amps and a few hundred kilohertz. I know I can use a driver IC. But I want to know what I can do with a BJT driver and the MOSFETs I currently have.
Other than that I am just deadly curious to find out how to get at least a good (not perfect) estimation of whether a MOSFET is suitable for a particular switching circuit or not. Because I have searched a lot and there is so much information and they seem to be either contradictory or too technical.

Period = high time + low time.
Frequency = 1/period.

Not sure what you are getting at with t2 (on+off time) and (t2*100).
If you want to measure rise time + high time + fall time + low time and call that the period, that would be correct.

Going to have to measure those with an oscilloscope tho.

That should work. NPN has to sink around 20mA to turn off the FET, 560 provides a little more to charge up.

Well, the NPN has to sink the 20mA coming from the 560R, and up to another 20mA to bring the gate low.

pourduino, would something like the CMOS version of the 555 timer be something you have easy access to - if it could be used as a mosfet driver?

Period = high time + low time.
Frequency = 1/period.

Not sure what you are getting at with t2 (on+off time) and (t2*100).

t is turn on time that I calculate using total gate charge and base current.
I’m assuming on+off time to be t*2 is because I’m just assuming the turn off time will be the same. Even tho in this circuit turn off time will actually be less.

And this is how I came up with t2100:
If my PWM period is the same as t(off)+t(on) then the MOSFET will constantly be in switching state. So it’s never in fully-on region. Other than that I’m going to get a sawtooth wave on the output:

In fig.1 PWM period is same as on+off time. So even at 50% duty cycle I will get a sawtooth wave.
In fig.2 PWM period is 100*(on+off time). In this case I still will get sawtooth wave but if duty cycle is at 1%. Which I’m going to neglect.

If you want to measure rise time + high time + fall time + low time and call that the period, that would be correct.
Going to have to measure those with an oscilloscope tho.

The point was to calculate these tho.

ShermanP:
Well, the NPN has to sink the 20mA coming from the 560R, and up to another 20mA to bring the gate low.

What’s wrong with that? 2N2222 for example can pass 600mA.

pourduino, would something like the CMOS version of the 555 timer be something you have easy access to - if it could be used as a mosfet driver?

Maybe I wasn’t clear enough but my point from making this thread wasn’t for a specific application or a specific MOSFET. I just want to know if those formulas in my first post can correctly calculate if a MOSFET is suitable for a circuit.

Consider for example that:
R1 = 1k
MOSFET = IRFZ44N

Now we use the formulas like so:

Ibase = 12/1000 = 12mA.
Q = It => 6310-9 = 1210-3t => ton = 5.25us => PWM period = 5.252100 = ~1ms => PWM freq. = ~1kHz.

So with this resistor value this MOSFET can switch at 1kHz with no problem.
Now we calculate power dissipation:

Resistive power dissipation: Rds(on)*I = 17.5 * 10 = 175mW.
Switching power dissipation:

1/2 * 12 * 10 * 5.25 * 2 * 10-6 * 1000 = ~600mW.

So the MOSFET is going to dissipate 775mW switching at this frequency with this load.
Everything seems to be fine and as far as my formulas tell me I can use this MOSFET with no problem with this circuit.

However, if I go on a forum and ask people if this will work everybody (like you guys did) will tell me to go get a driver or a CMOS or etc. Why? Are my calculations wrong? Is there something I’m missing?
This is what I’m trying to understand in this thread.

pourduino:
However, if I go on a forum and ask people if this will work everybody (like you guys did) will tell me to go get a driver or a CMOS or etc. Why? Are my calculations wrong? Is there something I'm missing?
This is what I'm trying to understand in this thread.

In my case it's because with no formal training I don't know how to do that calculation. The only way I know to reliably judge this is to pick a candidate and see what the in-circuit gate signal looks like on a scope, and see how hot the mosfet gets. It that's not possible, then I would revert to overkill, which would be a gate driver if PWM is involved. I suspect that even a fair proportion of engineers do the same. Anyway, I hope you find the answer.

In your setup the t_on (time to turn on the MOSFET) and t_off (time to turn it off) will be very unsymmetrical. The t_off will be quite short (the BJT will drain the Gate charge quickly) while t_on will be possibly longer than expected: voltage over R1 will be about (12 - V_threshold). Maybe you also need to consider partially conducting BJT as it is leaving saturation to slow down the turn on (I don't think this is a real issue but I don't know).

Your circuit can be used but it is a bit tricky: too strong R1 wastes to much power while too weak toasts the MOSFET. If possible it is easier to use a MOSFET driver. It doesn't have to be a fancy part named MOSFET driver. It can be a H-bridge, 555 or a 4000 series CMOS logic gate(s) if more than 5V is needed. Surely there is even more options.

Once you start switching large voltages and powers you definitely need a gate-driver to ensure
the gate voltage is pulled around by gate-drain capacitance, blowing the gate oxide (then vaporizing
the whole die usually). Once you are talking about bridge circuits drivers can provide a lot of
circuit-protection functionality very simply and cheaply.

At a push a 555 can be used as a MOSFET driver, it can handle 100mA or more.

At lower voltages and powers MOSFETs are available that are logic-level and will do well
driven through a small resistor from a microcontroller.

A very asymmetric circuit like the transistor/10k resistor may preclude PWM, as its very slow.
You want switching time to be a few percent of PWM cycle time at worst, so a switching time of
50µs implies PWM only below about 100Hz for reasonable efficiency.

You just calculate the conduction losses as I-squared-R and determine the switching times
(and thus switching losses) using the total gate charge and assume the current is limited by any
driver or resistor.

MarkT:
At lower voltages and powers MOSFETs are available that are logic-level and will do well driven through a small resistor from a microcontroller.

If I choose a resistor that will allow 40mA current to the gate, will my circuit be inferior to a logic level MOSFET + Arduino?
(Other than the very unpleasant power loss when BJT is on).

A very asymmetric circuit like the transistor/10k resistor may preclude PWM, as its very slow.
You want switching time to be a few percent of PWM cycle time at worst, so a switching time of 50µs implies PWM only below about 100Hz for reasonable efficiency.

I'm calculating the frequency as 100x the switching speed. In my first post with 50us on-time I calculated a maximum of 10Hz.

Smajdalf:
Your circuit can be used but it is a bit tricky: too strong R1 wastes to much power while too weak toasts the MOSFET. If possible it is easier to use a MOSFET driver. It doesn't have to be a fancy part named MOSFET driver. It can be a H-bridge, 555 or a 4000 series CMOS logic gate(s) if more than 5V is needed. Surely there is even more options.

So after some thought I figured that even tho the circuit seems to be theoretically possible it would be a rather terrible circuit because it wastes so much power through the resistor when the MOSFET is off.
So how does one go about driving a MOSFET with a 555 or a 4x CMOS? It's been mentioned many times in this thread. I will need the PWM duty cycle to be adjustable through an MCU.

It turns out you would use the original 555, not a CMOS version of it:

https://www.electronicdesign.com/power-management/article/21795203/lm555-makes-inexpensive-power-driver

As I understand it, you don't use any of the timing function of the 555. You just bring its output high or low by driving its Reset pin, or something like that.

ShermanP:
It turns out you would use the original 555, not a CMOS version of it:

LM555 Makes Inexpensive Power Driver

As I understand it, you don’t use any of the timing function of the 555. You just bring its output high or low by driving its Reset pin, or something like that.

Interesting.
That gives me an idea, how about using L9110 motor driver?
It can supply 800mA, and has 2 outputs in the same 8-pin package. Pretty cheap too. The only downside is maximum 12v input voltage. Can put a diode to its vcc to bring 12v input down to 11.5 to make it happier.

It’s an h-bridge. It seems to me that an h-bridge is basically a dual push-pull which is perfect for driving a mosfet. I wonder if I can use this ic for this purpose. Much better than the stupidly expensive and big mosfet drivers.

MarkT:
At a push a 555 can be used as a MOSFET driver, it can handle 100mA or more.

This is going a little bit off-topic because this thread was supposed to be about "not" using a driver, but the simple 555 driver was tempting and has got me curious. Can I by any chance use a L9110 h-bridge motor driver to drive 2 MOSFETs?
It can supply 800mA and has 2 outputs which means with 8pins I can control 2 MOSFETs (as opposed to expensive 14 pin dual MOSFET drivers that are available here). Its switching speed is not specified tho, but still, looks very promising to me for low frequencies (a few kHz maybe?)