Use this forum to chat about hardware specific topics for the ESP8266 (peripherals, memory, clocks, JTAG, programming)

User avatar
By wififofum
#43767
lethe wrote:you should add a heatsink. I guess the mosfet is not switched on for any extended period of time, so it would not need to be large (but don't forget tovapply thermal paste).


A heatsink for a 400ma load on a 30a MOSFET already in a to-220 package?
User avatar
By Barnabybear
#43769
markusonfire wrote:Thanks all!
Updated schematic below - taking into account your feedback.

Can someone perhaps suggest which N-Chan mosfet and diode would fit in this schematic - I believe the door strike solenoid doesn't draw more than 400mA @ 12vDC.

Many thanks!

Image

Hi, just a few comments.
It looks like your using R2 to drop the voltage from 5V to 3.3V. Because of the difference in current draw between a normal state and a transmitting state this will not work very well (check the volt drop using ohms law using 50mA for rest & 250mA for transmitting). You would be better with a small voltage regulator (AMS1117 3.3 works well) or a couple of diodes to drop 1.4V (not ideal but better than a resistor).
R1 at 47K might be a little large and slow down the switching off of the FET. 10K is more normal as a resistor to dissipate the gate charge.
There is a thought that with FETs a resistor in series with the gate is a good idea to stop ‘ringing’ on the line (this can cause additional heat as the FET does not switch on or off cleanly). Personally I’ve not had a problem but putting 51 ohms between the GPIO and the gate (closer to the gate the better) would prevent this.
Hope that helps – you can google find out more.
User avatar
By markusonfire
#44045
wififofum wrote:A heatsink for a 400ma load on a 30a MOSFET already in a to-220 package?


So a heatsink won't be required in my case? I wouldn't think so, seeing as though my load is well under the mosfet's rating.


Barnabybear wrote: It looks like your using R2 to drop the voltage from 5V to 3.3V.

R2 is actually a pull-up resistor for GPIO0, which then gets pulled down when the button is pressed.


Barnabybear wrote: There is a thought that with FETs a resistor in series with the gate is a good idea to stop ‘ringing’ on the line (this can cause additional heat as the FET does not switch on or off cleanly).

I've seen people use a pulldown resistor with the mosfet gate (Like my diagram), and other use a resistor in series like you describe.
Are there any pros/cons to each approach?
User avatar
By martinayotte
#44061
markusonfire wrote:I've seen people use a pulldown resistor with the mosfet gate (Like my diagram), and other use a resistor in series like you describe.
Are there any pros/cons to each approach?

I would say that having both would be the best practice.
Having the pulldown is mandatory, because if GPIO become floating, the MOSFET state can become unknown due to ESR.
The series resistor is good to reduce ringing effect as Barnabybear mentioned, it could be as low as 47R.