3.3 volts to 5 volts (and beyond)
LoopyByteloose
Posts: 12,537
Hi,
I have been digging and digging for a good simple way to drive an IRF540 Mosfet from the Propeller (at 12 volts). After bouncing around on the internet and digging through 'The Art of Electronics', I found a few good ways. But one seems extremely attractive.
Has anyone used a 7406 with a pullup resistor? If one wants +5, the pullup is attached to that. If one wants to drive the IRF540, it seems that a pullup to +12 volts is okay as well (the little chip is rated to that up to +18 volts on the open collector).
On the input side, it seem to look at +2 volts as the threshold between high and low logic states. So unlike some other logic families (like the 74HCxx), there is no crowding around the 3.3 volts to signify high.
Of course there is one draw back. It is powered by +5 volts - not +3.3. But all my Prop boards have that.
I have been looking at other choices (such at 2N7000, 2n3904, and 4011 NAND gates), but this really seems quite direct. I suppose the pullup value might require some thought, but I am guessing that 4.7K would likely do fine.
I have been digging and digging for a good simple way to drive an IRF540 Mosfet from the Propeller (at 12 volts). After bouncing around on the internet and digging through 'The Art of Electronics', I found a few good ways. But one seems extremely attractive.
Has anyone used a 7406 with a pullup resistor? If one wants +5, the pullup is attached to that. If one wants to drive the IRF540, it seems that a pullup to +12 volts is okay as well (the little chip is rated to that up to +18 volts on the open collector).
On the input side, it seem to look at +2 volts as the threshold between high and low logic states. So unlike some other logic families (like the 74HCxx), there is no crowding around the 3.3 volts to signify high.
Of course there is one draw back. It is powered by +5 volts - not +3.3. But all my Prop boards have that.
I have been looking at other choices (such at 2N7000, 2n3904, and 4011 NAND gates), but this really seems quite direct. I suppose the pullup value might require some thought, but I am guessing that 4.7K would likely do fine.
Comments
The "off" condition for the mosfet should be considered, or you may destroy the device during testing. (no drive on the 06 and the mosfet is always on).
When some MOSFETs blow they short the gate to either drain or source... then you get 12 volts on the gate circuit... bad
I guess that one might leave the +12 volt supply on while shutting down the Propeller and the logic chip.
I was thinking of having an 'active pullup' by inserting a 2n7000 that would only enable the pullup if and when the +5 is on.
There are other solutions. The simplest is to use a transistor to drive the IRF540, but that creates an inversion in logic (low is on and high is off). So it seems that having another inversion would bring everything back to a safe off condition when the Propeller is independently off.
Here is what appears to be a very complete solution. The schematic came from an Explorer Project (Boy Scouts) for an ROV called 'The Black Perl'.
I am not clear on what a 'pulse transformer' might be. Primarily I was pondering a minimal component solution. I'll try to read up on that as well.
With 2 resistors and 2 transistors you can source up to 20V (limited by MOSFET Vgs limit) and any practical ampage. It has correct logic (high is sourcing, low is off). I have used it to 20+KHz (R72 will need to be reduced to do this).
Nonetheless, it looks like your are talking P-Mos (and that isn't a Zener, you a different graphic style) and I happen to have N-Mos.
If the P-Mos will remain off when the logic is not powered, it certainly is better.
The 7406 may not be ideal for a motor applications, but for driving +5 logic via +5 pullup, it still seems a very simple solution.
This is an excerpt from a schematic I use, and I use this as a simple power switch, so the labels are some what proprietary. IN is voltage from a power supply (Vdd) and out is where the motor goes (between Out and GND). GND is the ground or Vss. 1/0 is controller input.
Reducing the resistance on R72 reduces the time it takes the MOSFET to switch off. A fast recovery diode would also be suggested between Out and your motor to prevent backfeeding.
It really depends on the power MOSFET that is being used and the power requirements of the motor, Loopy, can you let us know.
As usual, I get caught up in 'more is better' syndrome. I began to think I needed to provide 10v or more to the Vgs.
The N-Mosfets I have are IRF540. They are supposed to do quite nicely with 4v to the gate, they don't really need 10v or 12v, but they just cannot use 3.3 volts.
At 4Vgs, the Ron is rated .044 ohms. So I am considering it best to just drive the gate at 5 volts.
And the amps rating is far beyond anything I suspect I will every require (17 or so amps). I did see one posting that 4.5 amps is a realistic use level -- they relatively cool
As I don't have a stepper with that high an amperage rating, I am building for future by providing head room.
I decided a while ago that I would restrict my suggestions to the situations that members present: If a guy's on about 3V and 12V, then I won't introduce 5V.
Head-room, more is better, blah, blah, blah. Tomorrow has worries all its own. There's no panacea; no one-size-fits-all, 0-100A, rock-solid "solution." Are you going to fish or cut bait?
.
Now - regarding the IRF540 - I see that the 0.044 ohm resistance of Rds-ON is at a gate voltage of 10 volts (not 4.0 volts).
And while the minimum gate is 4.0 volts, all the data curves go down to only 4.5 volts for gate.
So maybe I'll simple provide a jumper for both a regulated +5 and an unregulated +12. But I am elated to get it down to one 2n7000 driving the IRF540.
Now I can get into the software - a combined PWM and Stepper cog intended for smooth variable speed.