Switching 3.3v logic level with a 12v source / Higher Amperage Voltage Regulati
CharlieII
Posts: 70
I have been using a voltage divider circuit to pull the voltage on the output wires from a shifter down to 3.3volts so they could be used as inputs to the propeller.· However, I am now at the point of applying my breadboard circuit to a PCB and would like to do away with all the resistors and extra traces they require by hopefully using some kind of mosfet.
I only have 4 of these 12v inputs to cope with.· So if there is possibly some form of quad driver that can switch 3.3v outputs with 3.3v VDD while taking a 12v input I could really clean things up on my circuit layout, and also fully isolate things such that voltage fluctuations on the input device side wouldn't carry over to the propeller.
I have never had an issue of trying to switch a lower voltage with a higher.· And as such the transistors I have been using are not going to work out according to what I've read from their data sheets.
Any help would be greatly appreciated.
Thanks guys,
Charlie
Post Edited (CharlieII) : 12/4/2008 2:06:31 PM GMT
I only have 4 of these 12v inputs to cope with.· So if there is possibly some form of quad driver that can switch 3.3v outputs with 3.3v VDD while taking a 12v input I could really clean things up on my circuit layout, and also fully isolate things such that voltage fluctuations on the input device side wouldn't carry over to the propeller.
I have never had an issue of trying to switch a lower voltage with a higher.· And as such the transistors I have been using are not going to work out according to what I've read from their data sheets.
Any help would be greatly appreciated.
Thanks guys,
Charlie
Post Edited (CharlieII) : 12/4/2008 2:06:31 PM GMT
Comments
Another option is a quad 3v3 zener IC, and 4 resistors. The opto is a safer bet for high voltage buffering though.
This is rather frustrating to be honest.· I need the equivelent of a 10 dollar autoparts store relay.· Even the cycle time of a relay is fine.· And it doesn't need to be solid state even.
Is there no semiconductor equivelent to the lowly autoparts store, normally open·relay?
Even it can switch 3.3v with a 12volt signal.
Maybe I'll have 4 wires running outside the case to 4 relays with 4 return wires coming back in with 3.3 volts on them.
But seriously.· Is there not a nice 4 channel·device in a nice dip package·that can switch a 3.3v output with a 12 volt input?
The amperage is basically·non-existent here.··The only amperage will be two rather large pull down resistors.· One for each prop pin and one for each output pin from the 12volt·device.
And again, thanks for any·help here.
I don't mean to sound rude, I honestly just think it·borderline absurd that·such an IC does not exist in mass.· I guess voltage divider resistance circuits are not so bad afterall.·
In the fact that I still need the pulldown resistors... I can't get away from the resistors.· And in that case, I'm merely looking to swap 4 resistors for one IC with likely just as many or more pins.
I"ll just stick to the voltage divider.
(smacks forehead)
Yes, a qaud opto in 16 pin dip. Use pull downs on the output, feed the LED's with 12 and use a 330-470 ish resistor to get the LED hot enough to turn on the transistor fully. 1 IC, 4 pull down resisters, 4 current limiting resisters on the input to the LED's.
The voltage divider is OK, but does not offer any protection in case there is an over voltage spike, or if one side of the divider to GND gets lifted accidentally, your chip is dead.
-Phil
May still need pull up/down on the inputs of the 4050 depending on the source.
I was hoping such an integrated circuit existed.· I"ll try it for sure.
*Peter*
Hmm, not a bad idea. The MC1489 is certainly more rugged than a '4050 and includes input hystersis, but it requires a 5V Vdd. This is an easily surmountable difficulty, given a 5V supply and some current limiting resistors on its outputs.
-Phil
*Peter*
If so, the benefit of using an IC would be isolation.· If some stray voltage hits anything on the 12v side and spikes the voltage the resistors won't account for it and the voltage hitting the prop pins will also rise.· Depending on how much they jump, it could hurt the prop.
I'll look up that one you posted.· Although I'm starting to think about just using a zener on each input to the prop for protection.· To do that would I just choose a Zener with an "avalanch" voltage roughly equivelent to the voltage maximum I want to let the pins see?
While I've got you guys thinking in terms of power and such, where can I find voltage regulators capable of more than the common 1A output current?
I need to drive a fairly strong servo and I would like more than a 1A rated regulator to power it.· It needs to be a 6v output reg with preferably a 12v input.· Same goes for the 12v reg, I would like one capable of more than 1A as the 6 volt reg will be getting power from it.
Thanks for any suggestions.·
Yes, resnet is jargon for "resistor network". Really, resistors are all that you need for +12V inputs. In fact I usually don't even worry about resistor dividers but simply rely on the intrinsic clamp diodes that are part of the silicon substrate. As long as you limit the current using a suitable value resistor then there isn't a problem. Take 10K for instance, if you apply +12V through a 10K resistor straight to a Propeller pin without any other resistors or diodes then the input on the Propeller will be clamped to around 3.6V and the current would be limited to (12V-3.6V)/10K = 840ua. In theory you could apply 120V to that same input (don't do it) and everything would be fine. (Problems might arise during reset and other times when the Propeller doesn't draw much current from the 3.3V supply and that "clamp current" can end up pushing up the 3.3V supply which could affect operation although a clamp diode on the supply is all you really need)
In regards to the servo, I'm not really sure what kind etc but usually with motors it is very easy to drive them in pulse-width modulation fashion to control the speed from a higher voltage. If the servo was connected to +12V but driven from a 50% on 50% off repetitive signal then the "average voltage" would be 6V. In this case the motor is happy as it probably ends up with more torque (+12V peak pulses) and you are happy because you didn't need to supply the 6 volts. You can use a suitable NPN or N-channel MOSFET driven directly from the Prop to control even very heavy motors.
*Peter*
So there is a diode built into each input pin on the prop that clamps the input voltage?· And then I just have to ensure that the amperage is controlled with ample resistance.
I didn't realize there was a "clamp" on the input pins that would yank excess voltage to ground (assuming amperage doesn't burn this little guy up).
And as for the servo, I can drive it directly, as there is little to no amperage on the "control" or signal wire.· My issue is with the actual power output wires.· I need to literally drive the servo from my PCB as well.· I had though that I would need a voltage regulator capable of dropping the voltage to 6v that was also capable of handling the current as well.
But are you suggesting that aside from the signal wire to the servo, that I use the PWM of a transistor to produce an average voltage to the servo and let it be my regulator?· If so, I wonder what an acceptable frequency would be to avoid any noise and to keep the servo from "seeing" the switching.
Interesting.· Along those lines, what would be a good transistor to use for switching a 12v source with the prop?· Or should I be switching the ground side and just letting the prop pull the gate to ground?
I am as "green" as it comes here, so keep my inexperience in mind when reading my responses and questions
I'm still waaaaay low on the learning curve with electronics.
Thanks.
As regards to the "clamp" diode, it's not really designed into the circuit but it's intrinsic (part of it's nature) to the whole process used to produce CMOS ICs. Being intrinsic they are not designed as clamp diodes but we can use this characteristic of CMOS if we are mindful of the limitations. So certainly I wouldn't be asking the "clamp diode" to handle more than a few milliamps but usually less than a milliamp. For low-speed signals it wouldn't hurt if you used even higher value resistors of around 100K for your inputs.
With PWM and motors it is usual to run the frequency at around a few KHz but it is easy to experiment yourself.
We are all green in some subject until we learn and gain experience and knowledge and understanding (then we are just another shade of green with some really green patches too). Just make sure you do your own research rather than asking too many questions or jumping to hasty conclusions. Test out your knowledge and gain experience and understanding, if you need a lead or you are stumped or curious then please ask.
Here is a suggested workable circuit based on what we are talking about.
*Peter*
BTW, the excess clamp current flows into the VDD supply not ground. Also, you may need a diode across the motor.
Post Edited (Peter Jakacki) : 11/19/2008 10:59:49 PM GMT
I should mention, when I said drive it directly, I meant the control wire.· The servo control wire has little to no amperage on it.· I have a 1k resistor between it and the prop for good measure, but the amperage is miniscule.
The only meaningful amperage is in the positive and negative wires to the actual motor of the servo.
I'll look over the schematic you posted before I ask anymore questions.
Thanks a lot.
Charlie
Oh, and the servo is 6v.
Okay, I checked out the schematic.· That appears to be a diagram for controlling the speed of a standard 12v electric motor by switching·a transistor with varied duty cycle on a PWM signal to a transistor.· Make's sense.· And I notice it's switching the low side.· I'm guessing this is easier to do?· Because of the gate voltage needing to be high in order to switch the high side?
Thanks.
Also, is the prop pin sinking the voltage to the transistor?
Post Edited (CharlieII) : 11/21/2008 3:37:19 PM GMT
So the prop is "sourcing" current into the transistor through the base to ground. In other words you need a positive voltage through the resistor to develop a limited current flow. Think water flowing through the pipes, the pressure is analogous to voltage or the potential while the current is actually work or flow. Bigger pipes, less resistance. More pressure, more current. Too much current for the reservoir (power source) and the pressure (voltage) drops. Short out a little 9V battery and the terminal voltage drops to near zero while the current flow is at maximum.
Whew, it's easier to say all this than it is to type it.
*Peter*
And based on this number, I can always choose the correct combination of voltage/resistance·to apply toward the·base·that will produce current·through the·emitter to ground proportionate to the current I plan to switch, plus some safety factor.· And as you stated, hopefully plus a rather large safety factor, such as 2, as to avoid overheating and loss of transistor efficiency.
If my conception thus far is correct, I have a much better view of transistor function now.
So this leaves me with a Good part number to accomplish most all the switching I will need to do.
So for this circuit, the only thing I'm still somewhat puzzled with, is how to get a solid 6v power source from my 12v (13 - 14v in reality) DC source that has enough amperage capacity for a 330+oz servo.· All I can find are 1A regulators.· Maybe that is plenty?
I will check the maximum servo current draw when I bind it up and it attempt to right itself.· That should give me an idea of what I'm up against in terms of amperage to shoot for.
Thanks again.
*Peter*
I think his motor is a large hobby-type RC servo that has a logic-level input and requires a constant supply voltage of 6V. In this case, PWMing the supply line is not a good idea, since it also supplies the internal logic circuitry.
CharlieII,
For your current requirements, a switching regulator is probably your best bet. Here is one rated for 1.5A, but I'm not sure that will be enough for such a large motor. You will have to find the specs for your motor first, before you set about finding a regulator for it.
-Phil
I will grab my DVOM before I leave this morning so I can physically check it's amperage draw when at full load. Then we will have a good ballpark of where I should be looking in terms of current requirements.
And yes, the servo has three wires, positive, negative and signal. The signal is now connected to a prop pin through a 1kohm resistor. The power wires are run directly to my 5v reg that came with the propeller dip kit. Maybe the amperage is actually rather low. I will find out.
One other thing. If it did turn out that I needed more than 1A of current, or close to it at full load, could I simply parallel regulators, such that by using two 1A regs in parallel I could apply up to a 2A load?
Thanks.
Anyway, I finally checked out the amperage required to drive the little servo.· I bound it so that it could not move, and then commanded a position far from where I bound it.· With my DVOM connected in series with ground it showed just a shade over 2.3 amps right before the little 5v reg I was using started smelling a bit hot, lol.· (it was fried).
So what should I do now?· This goes on a vehicle, so I have a "12v" system, but in reality it's between 13 and 14.5 volts.· So even for the 12v controller I would still need a regulator.· And assuming I pull my 6v servo power from this same regulated 12v source on my board, then it too will have to endure a worst case scenario amperage of 2.3.
So how do I go about getting 12v and 6v regulators capable of 3A current draw?
Thanks.
BTW, I think that little sucker tried to break my finger.· [noparse]:)[/noparse]
With the amount of voltage to be dropped (turned into heat) and the current, you might consider a switching regulator (http://www.national.com/pf/LM/LM2676.html).· With a voltage drop of 8V at 3A, your LM350 would have to dissipate 24W of power.· You'll need a big heatsink.
Post Edited (Mike Green) : 12/3/2008 1:18:41 AM GMT
As Mike pointed out you could use a switching regulator which is really the only option for higher input/output differentials and higher current. There is also the venerable LT1074 in a 5-pin TO220 that is bullet proof and easily handles 5A from 10V to 40V input. Haven't used them in a while but I can swear by them. Take your pick but I'd factor in such things as normal operating current and duty cycle to come up with a simple and practical solution.
BTW, this thread is more about running 6V servos from 12V rather than switching 3.3V logic. If you think this thread will go on for a bit it might be an idea to start a new thread for the benefit of the rest of the group who might be unaware about this aspect of the thread.
*Peter*
-Phil
Although when I look this morning on Google, I must be using different wording as I was finding datasheets galore last night, and can't find a thing now.
Anyway, I remember finding a few capable of up to 40 amps in a TO 262?, package.· Assuming I can use something similar (although not necessarily with that kind of amperage capacity) could I have the prop run a high frequency PWM to it, and then just read the output voltage with an ADC channel and write something that will alter the duty cycle vs output voltage and hold 6v on the output?
Or is it the case that for a given duty cycle the output voltage will remain constant and only amperage will fluctuate with load?
If this is the case, I can just use the transistor that Peter already showed me and just do a PWM "regulator" for the servo power and leave the rest of the board powered from Standard regulators like came with the Prop Dip Kit as there is very little amperage on any of that being that it's all logic level.
Also, I have to make the circuit capable of withstand a sustained situation where the servo is "bound".· Since it will be physically cycling the valvebody on the transmission itself, I can forsee a situation where the Parking Paw could become bound on a hill and be reluctant to come out.· In that case, if the servo torque isn't sufficient it will sit in full load until the shifter is moved back to park, it comes out of Park..... or it lets the smoke out of the wires.· ·· lol
I would just test this stuff, but I don't have a transistor capable of it at the moment.· I will order a few of the ones Peter suggested earlier that can handle a 3A load and can be switched from the 3.3v prop.··But I still don't know if you leave the duty cycle constant, and vary the load on the line, does the voltage drop?··I would think so?· In this case, do you have to integrate closed loop control like I mentioned above?
Thanks.
Also, I don't see a place to modify the title.
Post Edited (CharlieII) : 12/4/2008 2:01:29 PM GMT
I don't know if this is what you found with Google, but International Rectifier has a line of Power MOSFETs called HEXFETs. Here is the link to their web site on the Power MOSFET page: http://www.irf.com/product-info/hexfet/
I hope that's what you were seeking.
Regards,
Bruce Bates
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When all else fails, try inserting a new battery.
One thing you need to learn is when you are working on a new design is to concentrate on the core objectives instead of being sidetracked or taking shortcuts that could jeopardize the whole project.
Please take the extra effort and use a switching regulator that is guaranteed to work, you probably have more than enough variables to deal with without introducing extra magic smoke.
*Peter*
I thought the switching transistor to control the motor voltage was your idea.·
I just want 6v on the dang servo any way I can get it.· And I haven't found a regulator capable of handling the 3A load I need it to.· I have done some looking (granted I'm fishing in the dark given my lack of experience) and can't find too many rated over 1A, and even fewer rated to 2A.· The servo will pull a minimum of 2.3A at full load (which will happen anytime I move the shifter and·the servo·gets hung).
So even 3A seems a bit marginal.· Combine this with the fact that the only high amperage voltage source I have is the automobile electrical system running between 10 and 14.5 or so volts and 6v regulator options seem to dwindle.
I'm sitting here trying to lay out the PCB now and not knowing how I'm controlling the servo power is making it a bit hard.
If a good Reg for this has already been suggested then I'll use it.· I'll look back to see.·
I wondered once before, and still now, can you simply parallel the regulators for more amperage?· I just don't know how to do what I need here.· I've got the input voltage mentioned, and I need 6v to power the servo and it will draw 2.3A when bound.· Whatever ways exist to meet that need I'm all ears.
Thanks.
But there is a difference between PWM regulation for a motor and regulation for servos which required a stabilized and smooth DC supply. That is why we have been talking about switch-mode regulators such as the lm2676 that Mike mentioned and the LT1074. There are many many others besides.
Yes, you can parallel regulators but your biggest single problem with linear regulators is the amount of power that they have to dissipate as they are brute force devices. 14V-6V = 8V times 3A = 24W and that is a lot of heat indeed.
Most switch-mode regulator datasheets or their appnotes also contain some info on pcb layout.
*Peter*
P.S. Your system shouldn't have to cope with overload currents continually if you monitor a fault and continually pulse the servo on briefly to see if the jam is cleared.
Post Edited (Peter Jakacki) : 12/5/2008 1:40:59 AM GMT
Can I search Newark, Digikey or the like and expect results·for Switching Regulator?· If you have a part number in mind to do it I will check it out.· I just have no idea what a switching regulator is.· Although it sure sounds like a transistor with a feedback loop to control voltage.
I'll try and find specs on them right now.
Thanks.