Issue using Mosfet with Arduino/Ramps board

Hi. Burned up a couple low end SSR (relays) controlling my heated bed for my 3D printer. (400w 12v).
I want to use one or two IRF3205 mosfets to control the load.
I'd like to use the ramps D8 pins to control the mosfet that actually controls the load.
Can setup mosfet with load on either side.

My issue is, D8 on Ramps board has a mosfet output that has an always on 12+ on one pin, and switches the low side to ground when on. If it switched the high side, it would be easy.

So I need to invert the logic of the D8 output, and supply 12V to turn the mosfet fully on, when the ramps D8 negative pin goes low.

I'm not sure if I need a driver, or if the onboard mosfet could handle the turn on rush current. If i use a driver circuit, I still have to invert the logic somehow.
I'm sure there is an easy or elegant way to do this, but I'm out of my depth.
Any advice would be greatly appreciated.
Thanks,
Bryan

What is the p-MOSFET on the board? Probably not up to 33A?

Your heated bed won't have "inrush current" as its not a tungsten bulb or capacitor -
it will take a constant(ish) 33A.

You could use the on-board MOSFET output to drive the gate of external n-MOSFET(s).

If driving multiple MOSFETs add a 10 ohm resistor to each gate to prevent differential-mode
oscillations. You can do much better than the IRF3205 (which has an 8 milliohm on-resistance),
think 2 milliohm or smaller and you won't need a huge heatsink nor two devices. These days
2 milliohms is not rare or expensive. For instance the IRFP3077 is 2.8 milliohm and pretty
nice price.

AOI510 also

Power dissipated by the MOSFET P = I^2 x R, 33x33*.0026 = 2.83W, so heatsinking will be needed, or share the current over multiple devices.

I would vote for single device, simpler and as I suggested you can do better (< milliohm is obtainable
indeed). My example device I had on the bench in front of me which is why I gave it as an example,
I bought them recent because they were cheap to pad out an order to minimum order value! 3W is
plausible for passive cooling, 9W less so...

Attached is the diagram of the N type mosfet on the Ramps board. It is controlled by the Mega number 8 pin.

As I understand it, D8 is normally pulled low. When D8 goes high (12V on Mega) the mosfet turns fully on. The mosfet on the board doesn't have the capacity or cooling to manage 400w. However, two IRF3205's heatsinked to the frame of the printer should work pretty well, I think. I am starting to think I should just run a jumper from the D8 Mega pin to the Gate of the 2 3205's and call it a day. I think this should work. I have a bag of IRF3205 on hand, which is why I want to use them.

By inrush current, I mean the current required to bring the gate high, due to the capacitance of the gate. I'm not sure the Mega can supply this much initial current, without a limiting resistor. It looks like a 10 ohm resistor is used with the original on board transistor. Since the on board mosfet is an N type, and goes to ground, it isn't useful to power the IRF3205 gates which need a high signal. So I would need to invert the logic, and provide enough voltage and current to trigger the 3205s.

If I do use the Mega pin to control the 2 3205s, can anyone tell me the needed resistance value for the gate resistors? Do I have to disconnect the original mosfet which isn't being used? It will add to the current needed, and is pulled low...

Thanks,
Bryan

RAMPS1.4 D8 schematic.pdf (368 KB)

Oh yes, that inrush current - 150 ohms or similar to protect the pin, I though you would use the existing
MOSFET to drive the others though. Are you wanting to use PWM though?

The STP55NF06 has 20 milliohms of resistance, two in parallel gives 10W dissipation for the on-state, so
a fairly large heatsink is advised.

I can't use the existing ramps mosfet, because it sinks current, the 3205 needs 8+ volts to turn on.
Unless there is some clever way to use a voltage divider or something to reverse the logic.
I'm not clear on whether the D8 output is PWM or "bang bang" method. I suspect the latter.

IRF3205 have an min resistance of .008, but more like .010 ohms at temperature. If I use two, then each mosfet has to handle 200w or about 17A. I come up with a value a little under 3watts to be dissipated.

Ramps is putting out 5v on the pin 8, I thought it was 12v. So i can't directly drive the irf3205, or they will be only partially on, and the resistance will be too high. So I guess I need a driver IC, or perhaps a NPN transistor to switch the 12v for the gate... Will a MPS2222A transistor work? It looks like it uses a 5v base voltage/current. Since the 2222 is current controlled, I think, what resistor should I use between the 5v output pin and the base pin? According to the chart, 2ma of current yields an hfe of 100, so transistor would pass about 200ma to the gate pins? Would a 2.5k resistor to the base be about right?

Will it work correctly with the emitter connected to the gate of the 2 IRF3205s? I have a 100k resistor pulling the gates low, so would the 2222 function correctly? Or would it turn off as soon as the 5v reached the emitter?

Thanks,
Bryan

I found this circuit, which looks like it might work??

Yes, but note it will be on by default - until the PIN goes HIGH the load is switched on.

So, if I pull the pin (actually the base pin of the 2222A) High, the mosfet would be off.
When the onboard mosfet went to ground, the circuit would turn on.
This sounds like what I need, unless I'm missing something...
I'll just adjust the 4k7 resistor for 12v, and add a much higher resistor to pull the transistor base high by default.
Any reason this shouldn't work?
Thanks
Bryan

Happy holidays!

If you have an onboard n-MOSFET you don't need or want to use an external 2222, the MOSFET
can level shift for you. Is the on-board MOSFET already able to low-side switch a 12V load?

There is an onboard Mosfet, which I think is an N type. When the mosfet is OFF, no continuity. When the Mosfet is ON, it sinks to ground. Is set up to sink 12v.

So how would you setup the circuit?

Thanks,
Bryan

Just use it in place of the NPN, change the 2k resistor to say 470 ohm (1/3W) for faster switching too if you
like.

If you can attach the mosfet (or any cheap transistor) to the heated bed you'll put that extra heat to good use. The bed will typically be set to 100C and that's not a problem for any TO-220 style transistor.

I finally built the circuit with a 2N3906 PNP transistor. The problem is, I don't see how to reverse the logic otherwise. When the onboard mosfet goes to ground, that would normally turn the heater on. When the mosfet is OFF, the pin is neither grounded nor pulled high.
I need the heater on when the onboard mosfet goes low, and off when the mosfet is off. Using the PNP transistor allowed me to use 12v to drive the 3205 mosfet with 12v and invert the logic all at once.The base of the PNP connects to the onboard mosfet using a resistor. When the base goes low, 12v flows thru the transistor to the gate of the 3205 mosfet, turning on the heater. A bleed resistor on the gate makes sure it turns off otherwise.

I have also ordered a mosfet driver, TC4420CPA, DIP-8, 6A, which looks like a very robust solution for $1.49 from Jameco. It is also possible to buy an inverted driver if needed.

Thanks for all the help.
Have a better understanding of transistors and Mosfets than when I started.

Thanks for all your help.

Bryan

The output will be going to the 2k (or 470 ohm) pull-up resistor between p-MOSFET gate and source,
so it will work just fine - the n-channel goes on, the p-channel goes on too.

OK, circuit worked for a while, then promptly burned up, despite being heatsinked.

Drivers came in, was planning to drive the mosfet driver from the Arduino pin directly, bypassing the onboard mosfet. Since I'm driving a resistive load, do i need any other circuitry to use the driver IC? I an assuming I need a resistor between the driver and the gate of the driver. Do I need any other pullup/pulldown resistors or diodes?

Any advice would be appreciated.
Thanks,
Bryan

Sketch out and post your circuit so everyone is up to speed on what you're doing. The last couple of replies or so mention component changes and so on.

Here's the proposed circuit, perhaps with two 3205's, each with their own resistor...

circuit diagram driver-fet.pdf (41.9 KB)

You can use larger R1 if you want, the internal gate spreading resistance is of
the order of a few ohms as well. 1A drive is probably plenty for one MOSFET.

You must have decoupling on the load and right next to the MIC4420 - for the latter
10uF ceramic might be a reasonable value, within a few mm of the power and ground pins
is important.

The load could use some bulk decoupling to reduce noise from the supply wiring, 1000uF 16V or
more. All high current wiring should be twisted pair (from the supply, to the load). Avoid making
large current loops or you'll likely interfere badly with the rest of the system at there current levels.
Best to site the MOSFET and driver remote from the microcontroller too, 10cm or more would be
wise. You can add a 4k7 resistor in series with the MIC4420 input to protect the Arduino pin
should the mosfet fail and take the driver with it.