Need Help Converting 150,000hz 3.3V 19.38mA DC Square Wave into 20Volt .2A A.C S - Page 1
Forum section: electronics / rf-microwave

author: z7d8tsg
author_rank: Contributor
timestamp: October 26, 2018, 05:17:30 pm
content: Hi Everyone, Dan Here.I Need Help Converting 150,000hz 3.3V 19.38mA DC Square Wave into 20Volt .2A A.C Square Wave Same Frequency.Anyone have any ideas?Thanks-Dan

author: Beamin
author_rank: Super Contributor
timestamp: October 27, 2018, 07:54:57 am
content: Quote from: z7d8tsg on October 26, 2018, 05:17:30 pmI would like to see how this is done.Since the frequency is high you can use a small transformer or torriod but you have to convert to a sine wave. Then once the voltage is up convert back to square and add some sort of Class D amplifier to get the amps up.Many ways to do this I bet. Or maybe its better to amplify then step up voltage?

author: Ian.M
author_rank: Super Contributor
timestamp: October 27, 2018, 10:52:06 am
content: High speed dual (high side/low side) MOSFET driver with logic level input driving a pair of N-MOSFETS in a push-pull configuration. One possible implementation using the Analog Devices LTC4449 High Speed Synchronous N-Channel MOSFET Driver, is attached below as a LTspice sim. Other manufacturers have comparable drivers, some of which can directly accept 3.3V logic level signals.If by 'AC' you mean the output signal should swing +/-10V either side of the ground your logic signal is referenced to, replace the level shifting buffer with a fast logic output optocoupler, input side referenced to ground and output side referenced to the -10V rail, feed the drain of the top MOSFET +10V, and feed the driver logic supply and output side of the optocoupler with a LM7805 regulator, Com to -10V, in from ground to provide a regulated supply 5V above the -10V rail.If you actually need +/- 20V swing (40V pk-pk) you'll need a driver with a higher voltage rating than the LTC4449.

author: z7d8tsg
author_rank: Contributor
timestamp: October 27, 2018, 06:45:06 pm
content: Ian, Thanks, just opened file. I think I will need to find a higher voltage mosfet driver though (20V not 10V p2p)What do you think will be more efficient? The Design that you posted with the mosfet driver with mosfets, or the NPN and PNP Transistor Circuit that is attached, or an IGBT and IGBT Driver Combo?Beamin, Good Idea, but your idea is too inefficient for what I need here.Efficiency and simplicity is the name of the game right now.I have also found this circuit, now attached to this post, but have not tried it yet. Thoughts?I also tried this with an H Bridge using 3MHZ N Channel Mosfets, but they were too slow.ARGGGG. I've been trying to solve this for the last month, using 555 timer, npn and pnp transistors, op amps, and mosfets, but with no success.

author: IanB
author_rank: Super Contributor
timestamp: October 27, 2018, 07:33:15 pm
content: Quote from: z7d8tsg on October 26, 2018, 05:17:30 pmMaybe I'm missing something, but how can 3.3 V, 20 mA be converted to 20 V, 200 mA?

author: z7d8tsg
author_rank: Contributor
timestamp: October 27, 2018, 09:54:54 pm
content: Ian,I suppose the correct word is Amplify, not Convert.What you are thinking about is that green stuff that turned the Simpson's lake water green.How many Volts and Amps need to be fed into Vlogic5?What do you mean by "and feed the driver logic supply and output side of the optocoupler with a LM7805 regulator"Didn't you say replace the logic supply with the optocoupler?What kind of optocoupler should I use? And should I use it to replace the 74HCT Gate - I'm confused on exact placement??Can I use regular resistors or do they have to be HF Resistors for Rload1 and Rload2?Thanks

author: Ian.M
author_rank: Super Contributor
timestamp: October 28, 2018, 06:10:45 am
content: There are two Ians in this topic, but I assume you are addressing me.The trouble with BJT based circuits is the Vce_sat drop in the output transistors, or if you use a push-pull emitter follower configuration, the Vbe drop. They are incapable of driving rail-to-rail, and how close they can get to the rails is highly dependent on the load current. If you need a true rail-to-rail output you *MUST* use MOSFET output transistors - no other technology will do. However power MOSFETs are a PITA to drive fast due to the high transient currents required to rapidly charge/discharge their gate capacitance, which is why you need a proper gate driver IC. Forget about IGBTs - they are the worst of both worlds with the voltage drop disadvantage of BJTs and the high gate capacitance of MOSFETs.Considering the 4449.asc circuit I previously posted, everything below the dotted line is simulation only and wont be in your real circuit so the resistor type for Rload1 and Rload2 is irrelevant. OTOH you *will* need extra parts for decoupling and to supply the MOSFET driver with the voltage rails it needs. MOSFET drivers are fast and transiently pull a lot of current when they switch so see datasheet for decoupling and circuit layout requirements.Rather than try to talk you through using an optocoupler for level shifting and finding a comparable but higher voltage driver, I've attached an alternative circuit using theLTC4446 High Voltage High Side/Low Side N-Channel MOSFET Driver, which shows level shifting to get a symmetrical output about 0V with +/-20V amplitude, (40V pk-pk). It uses a PNP transistor in common base for the level shifting, clamped so its output cant go over Vcc. As the LTC4446 doesn't have an internal deadtime generator circuit to prevent shoot-through, I've added an external one using a CD4030 CMOS quad XOR. The second inputs of all the XOR gates except U2B should be tied low so they act as noninverting buffers. U2B's second input should be tied high so it acts as an inverter.If you use an alternative MOSFET driver intended for (half) H-bridge applications, with one inverting input, one non-inverting input (or a single input like the LTC4449) and an internal deadtime generator you can eliminate the CD4030 and the RC-D networks in between them. However, be careful to choose a driver suitable for 150KHz input frequency.The new circuit would use a LM7812 to provide its Vcc rail, IN from Gnd, Com to V-20 and OUT to Vcc. Don't forget the decoupling as per LM7812 datasheet.If you need less amplitude you can reduce the supply rails. Below +/-13V you can omit the LM7812 and connect Vcc direct to ground so the LTC4446 is fed between Ground and the negative rail. Don't use less than +/-8V rails.There are no special requirements for the resistors - any smal through hole or SMD carbon or metal film resistors will do.

author: Beamin
author_rank: Super Contributor
timestamp: October 28, 2018, 10:36:58 am
content: Quote from: z7d8tsg on October 27, 2018, 06:45:06 pmThis circuit seems really simple. I'm trying to follow along this post even though its over my head. With the circuit in the above post does it keep the square wave and just simply amplify it, both current and voltage? I though square waves were hard to amplify and had sine waves worked better. Or is this possible by using really fast transistors/mosfets?IS it easier to amplify a signal increasing both current and voltage vs just increasing one or the other? I understand that you can't just "amplify" current but rather have to have a "bigger" circuit that can handle more load. I thought most amplifiers just allowed more current to flow, like in a circuit where you progressively use larger and larger transistors. Are push-pull amps also A/B amps? Since this is a square wave why wouldn't a D class work or would it but like the OP said that's way too complicated for what hes making.What is this for by the way?

author: z7d8tsg
author_rank: Contributor
timestamp: October 29, 2018, 12:02:32 am
content: Ian M, Thanks for the help! I will check out your circuit and get back to you.Beamin, you need to do some research on amplifying voltage and amperage for A.C and D.C Waves for multiple frequency ranges. Electricity apparently acts differently at different frequencies. There are different class amplifiers for different frequencies as well. I am noob too. Apparently there are a lot of signal treatment options, in order to have a nice and clean final square wave, out there.This signal generator will be powering 4 air pumps that are being used to power a device that demonstrates mid frequency waves interaction. (underwater in a fish tank) (Its for my physics project Check out this guy's software version one here:https://youtu.be/WRMhFUoPXyQ)I call it the Waves Demonstrator.

author: z7d8tsg
author_rank: Contributor
timestamp: October 29, 2018, 01:16:15 am
content: Ian, how do I hook up the CD4030 to your circuit? I am a bit confused.Thanks for posting a circuit with a LTC4446, the 100V Switching Power will definitely come in handy.What do you think about using a Triac Optocoupler Without Zero-Crossing Component? Will it work here? And will it make my life easier?Specifically this K3011Phttps://www.mouser.com/ProductDetail/78-K3011PThanks

author: Ian.M
author_rank: Super Contributor
timestamp: October 29, 2018, 06:02:31 am
content: TRIAC output optocouplers are only for mains frequency switching (if they have zero crossing detection) or power control (no ZC detection). They would be absolutely useless for level shifting a 150KHz logic signal.Now we know what you are doing with the output signal, I can categorically say you are on the wrong track. Its a classicX-Y problemsituation.You don't need all that messing around to get a squarewave of exactly +/-20V amplitude, as the pumps wont care if there is a few percent variation in applied voltage, so it doesn't matter if there's a bit of voltage drop in the driver circuit.Also, it seems likely that the pumps each have two wires, which would mean you don't need the squarewave to be balanced about zero as you can simply drive each wire with antiphase unipolar squarewaves from an H-bridge and the pump will 'see' the desired balanced squarewave.Unfortunately 150KHz is a bit on the fast side for the classic L298N H-bridge, which is a pity, because its dirt cheap and readily available as assembled modules. If you are looking for a suitable H-Bridge, check it can be PWMed at 150KHz or higher as many top out somewhere between 20KHz and 100Khz.I've attached a diagram of how to wire XOR gates as inverting and non-inverting buffers + a LTspice sim of an H-bridge circuit based on a pair of LTC4449 chips and four MOSFETs. Its output is differential, so when you run the sim and plot it, click on OutA and drag across to OutB before releasing the button to get the voltage between them.N.B. this circuit needs continuous input signal as it isn't safe to leave a LTC4449 IN pin at a steady DC logic '1' level.That's a limitation of H-bridge drivers designed to use N-MOSFETs on the high side, that don't either have steady state input detection triggering safe shutdown, or an internal charge pump to keep the BOOST pin for the top MOSFET gate supply well above its drain supply rail. As-is the top MOSFET's steady state gate drive would be limited to one diode drop below the rail feeding the boost diode, which would put the MOSFET in its linear region and lead to overheating and probable device destruction*.If you need to shut off the output safely, either use separate antiphase signals to drive the two 4449 chips IN pins so you can set them both to logic '0' to disable the output (both lower MOSFETs turned on), or add two AND gates after the XORs to add in an active high ENABLE signal, which when '0' will force both 4449 IN pins to '0', or add a pair of buffers with output enable, as the 4449 goes into a shutdown mode with all MOSFETs off if you float its input.I haven't diagrammed the enable or shutdown logic as the LTspice built-in logic primitives don't include Tristate buffers, and their AND gate is actually an AND/NAND gate with complimentary outputs which IMHO would add confusion. If you *really* need it I can find the URL for a 74HCT library and draw it up, but IMHO it would be preferable to look at other manufacturers for single-chip fast H-bridge driver solutions that have a separate enable pin, as its only the convenience of being able to sim them for free that has kept us with Analog Devices (ex. Linear Technology) parts.* To see the effect of a missing input signal, modify the sim's signal source to be:Code:PULSE(0 3.3 {2/freq} 10n 10n {.5/freq} {1/freq})which adds a two cycle delay before it starts, then plot V(OutB) and the power dissipated in MOSFET Q3 (Alt-click it).P.S.Beamin is in my kill-file (Ignore list in forum profile) as I found their ethics to be totally incompatible with mine so I wont respond to anything they raise unless they are sending you off down the wrong track.

author: Beamin
author_rank: Super Contributor
timestamp: October 29, 2018, 11:10:44 am
content: Quote from: z7d8tsg on October 29, 2018, 12:02:32 amNoob with 1000 posts is also known as a retard. "She's just not getting it. Why does she keep trying?"An idea for showing the waves in the tank: Put water in the bottom half with blue food color. Put a clear oil like baby oil or kerosene or what ever doesn't stink up the place on top and you will be able to see the waves better. You could also add nonpolar dyes(get them off ebay they are sold for that, see the "colorful smoke device" video by tech ingredients for more info on dyes) to the oil layer for more color effects or better visuals of the waves. You can also float things in between this layer like small plastic beads that float on water but sink in the oil. Will look a lot better then just clear water.

author: Beamin
author_rank: Super Contributor
timestamp: October 29, 2018, 11:22:27 am
content: Quote from: Ian.M on October 29, 2018, 06:02:31 amI'm sorry I offended I do learn a lot from your posts. But why do you have to say "they"? Sounds like "it" which is dehumanizing at best. I'm not going to derail the thread just wanted to point that out that my intention is not to piss people off. I do ask that people respect pronouns I'm not PC police or subscribe to that but sometimes people intentionally will use the wrong pronouns, which also applies to the dozen or so transgender people here. If Fran from FranLab posted here would you call her "they"? Hope not.Anyways I was going to ask you a question about your post as I was reading about somethings you suggested but I guess that would be pointless.

author: z7d8tsg
author_rank: Contributor
timestamp: October 29, 2018, 05:43:34 pm
content: Everyone Relax.Beamin, you need to do some research for a week or two. These guys are generally pro's and their time is valuable.Ian, the pumps are old - I got them from a lot wholesale online for old components from the Soviet Union. and how I have them set up right now, the A.C Square Wave needs to be as accurate as possible, because the pumps are inductance sensitive (the price of getting really fast pumps). The pumps are being used for 1 experiment where 4 of the pumps turn off and on, very quickly, then we monitor and record what happens to the wave 5 meters away from the 4 pumps.I already tried the pumps with a high quality A.C Wave function generator, and it worked. I tried it with a lower quality 555 timer wave function generator, and it made a noticeable difference in the quality of the waves that resulted.Thanks

author: Ian.M
author_rank: Super Contributor
timestamp: October 29, 2018, 10:06:00 pm
content: So I assume waveform symmetry is important, as that's probably where a naive 555 circuit would have let you down. It may be worth posting the 555 + pump driver circuit you used so we can see what its deficiencies were.What are you using to generate the 150KHz 3.3V logic level squarewave signal? If its a MCU, does it support generating complimentary PWM signals with deadtime control? If so there may be some other options.Also, have you categorically rejected non-squarewave excitation and any need for amplitude control other than by varying the overall supply voltage? If not, note that the MOSFET + driver circuits we've discussed are *ONLY* suitable for generating rail to rail squarewaves and similar signals. They cant for instance output a sinewave, nor easily vary the amplitude in response to that of the input signal, so if anything like that is a requirement, we are *way* off down the wrong track.What do you mean by "... the pumps areinductance sensitive(the price of getting really fast pumps)"? I assume the pumps have a diaphragm or plunger driven by a solonoid, so they have their own internal inductance, but you seem to be implying some effect due to external inductance in the driver circuit.So far the dual LTC4449 circuit looks like the best bet, modified with gating to add an enable signal so you can start/stop the output waveform quickly and cleanly. New sim attached.However, I think at this point, if any of the other experts here is aware of an H-bridge (or half H-bridge) driver for complimentary MOSFETs (rather than all N-channel) and >20V supply, *WITH* deadtime control, that will support operation at up to say 200KHz, and has 3.3V logic level drive and enable control, it would be very helpful to hear their suggestions.

author: z7d8tsg
author_rank: Contributor
timestamp: November 02, 2018, 09:54:01 pm
content: ian M, Thanks for post.What circuit design software do you use?I am using an Arduino Due to generate signal.Already tried all forms of waves, square wave has been working best.The Pumps are magnetic inductance sensitive. I'm not sure, there are no model numbers or writing on the pumps and there are 3 different fibre optical wires that literally don't do anything - I have already tried, in addition with the 3 electrical wires. Probably was created for a flux capacitor then they sold all of these off when it didn't work.I'm sure there are H bridge Drivers out there that will work for this. I will post if I find any that work.

author: z7d8tsg
author_rank: Contributor
timestamp: November 02, 2018, 10:00:21 pm
content: Ian, Why can't I just use one ltc4446? it is 0 to 100V mosfet drive capabilities, so 2x 4446's do not need to be used... I don't have a circuit simulator so idk if there are atomic intricacies that make this have to be done this way.Also, Ian, in your dual 4449 circuit, What is the difference between V2 and v4??Also, side topic, does anyone know where I can buy or make a 5V 1uA power supply for the 4446? I don't want to use a 7805 then amp limiter then 2 resistors, because the 1uA would be uncertain and there will be voltage drop. Sorry I am noob. Thanks

author: Beamin
author_rank: Super Contributor
timestamp: November 04, 2018, 01:47:27 am
content: Quote from: z7d8tsg on November 02, 2018, 10:00:21 pmWhen you say "power supply" do you mean a one chip solution like an LMXXX type part that could easily fit and use very little power or/and space on the board? As 1 micro amp power supply would be quite small. I always think ATX or SMPS when I hear power supply.

author: Ian.M
author_rank: Super Contributor
timestamp: November 04, 2018, 08:30:55 am
content: I'm *ASSUMING* your objective is still a 150KHz, 20V amplitude (40V peak to peak) squarewave, centered about 0V, capable of driving a load with 200mA, with no DC offset when its not being output. If not, please clarify your requirements immediately.Quote from: z7d8tsg on November 02, 2018, 10:00:21 pmTo produce the above waveform, a LTC4446 requires either two series connected PSUs or a fairly expensive dual output PSU to get the +20V and -20V rails centered about 0V (Gnd). It also requires level shifting on its inputs and a somewhat tricky circuit to provide deadtime to prevent shootthrough that is likely to require some file-tuning to get right (unless you have a MCU that can output a pair of antiphase PWM signals with added deadtime).OTOH for the price of an extra chip and an extra pair of MOSFETs, the dual LTC4449 circuit has many advantages:It only needs a single 20V supply rail, so will run from a much cheaper single PSU.It doesn't need a fancy level shifter to get the logic signals down to the negative rail.It doesn't need a circuit to add deadtime to the drive waveforms as that's internal in the LTC4449 chips.You need to balance the costs vs benefits for the project as a whole, which will be dependent on the number of these drive circuits you require and on what other voltage rails your project needs. If you need lots of these drivers, and other circuits need +/-20V rails (or low current +/-18V or lower rails that can reasonably be provided from the +/-20V rails by linear regulators, you'll probably want to go for something like the LTC4446 circuit. OTOH for only four pumps, the dual LTC4449 circuit for each is probably still cheaper, even though it requires four logic level MOSFETs per pump rather than the two ordinary MOSFETs required by the LTC4446 circuit.A further note here: at 150KHz with an inductive load you probably cant rely on the MOSFET internal body diodes for clamping the resulting inductive spikes when it switches, as their reverse recovery time will be too long and you'll get a massive current spike as charge is cleared out of the junction when it gets suddenly reverse biassed when the opposing MOSFET switches on. Therefore each MOSFET will require a Schottky diode across it in parallel with its body diode.Quote from: z7d8tsglink=topic=147143.msg1936033#msg1936033 date=1541196021Errrr. . . . . you seem to be openingLTspiceschematics OK. LTspice *IS* a circuit simulator, free to use unless you are designing ICs (silicon chips) commercially. For any of my posted circuits in LTspice .asc format, simply click the 'Run' icon on its toolbar, then click any of the nodes (signals) in the circuit to plot them.Quote from: z7d8tsg on November 02, 2018, 10:00:21 pmV2 and V4 provide input signals to control the simulated circuit. V2 provides 'In' the 150KHz logic level squarewave signal. V4 provides 'Gate' which is the signal to switch the pump on or off (Logic '1' = On).Quote from: z7d8tsg on November 02, 2018, 10:00:21 pmYou don't need a 5V 1uA supply for the LTC4446 and if you had one it probably wouldn't work. In fact, that circuit doesn't even need a 5V rail. It does however need a supply in the 9V to 12V range to provide the Vcc supply to the LTC4446 and the CD4030. A single LM7812 would be suitable to power *all* your pump drivers Vcc supplies. It draws an approx 2A transient from Vcc when the output switches low, to charge the boost capacitor, so the Vcc supply must be very well decoupled right at each LTC4446 chip - I'd suggest a 22uF ceramic with a 0.1uF in parallel if you are building the drivers on sepeate boards, or 100uF output capacitor on the LM7812 and 0.1uF ceramic at each LTC4446 if you are building all four drivers on a single board with a groundplane.The LTC4449 based circuits do need a 5V supply, but not a 1uA one. They'll also need a high transient current from the 5V rail when the output switches low. A LM7805 is the easiest option to meet their 5V supply requirements.Neither circuit needs a heatsink on the LM78xx regulator as the average current consumption will be pretty low. Make sure you meet the minimum load current requirement for the regulator - you may need an extra load resistor on the regulator output, possibly feeding a 'power on' LED.

author: z7d8tsg
author_rank: Contributor
timestamp: November 08, 2018, 01:11:17 am
content: Does anyone want to send me a circuit diagram or build an extremely efficient amplifier for me, in exchange for money?I will give you a gift if you are in the Northern Illinois USA Area.If so,Please email me at:z7d8tsg87oh2g92h9p38fh@gmail.comIan,You are assuming correctly.Also, How are you generating V4 the Gate Signal?Having to additionally generate V4 seems extremely inefficient.I am honestly curious as to how your solution idea works and if it has any efficiency viability.Thanks

author: z7d8tsg
author_rank: Contributor
timestamp: November 08, 2018, 01:22:31 am
content: Why can't I just use the 3.3V 150khz signal from the Arduino and run it through a L6385E H Bridge Driver, and use that to run 2 mosfets???Also, Maybe I am missing something, but please take a look at the attached datasheet for the LTC4449. The printed Supply Current (Ivcc) is different that what you are stating.Thanks

author: z7d8tsg
author_rank: Contributor
timestamp: November 08, 2018, 01:50:53 am
content: Attached is a circuit for Driving a H bridge with 2 Optocouplers.I haven't tried it yet, but I see no reason why it cannot work.Also attached is a circuit for a Full Bridge (Transistor) Circuit, I got from:https://www.edaboard.com/showthread.php?380933-Need-Help-Converting-150-000hz-3-3V-19-38mA-DC-Square-Wave-into-20Volt-2A-A-C&p=1633140#post1633140Apparently, there are also many Full Bridge Mosfet Driver Chips Out there on the market, that can be easily fashioned for this. I'm not sure, I don't have tested and documented proof of this yet.I feel like someone who has asked directions to the library, and a gang of Genophobic teenagers have given me instructions on how to get there, but I need to drive under the lake, under Sealab, eat some peyote, and acquire a slight cancer - when I could have just walked 2 blocks East.Anyways,Which circuit do you guys think is best for efficiency? I would like my wave pool to be standalone, So i can travel with it.After school, I will most likely convert the Science Demo into a laser/light show or some sort of 19th Century Torture Device or Something. Physicists make Electrics more Fun

author: Ian.M
author_rank: Super Contributor
timestamp: November 09, 2018, 01:14:39 pm
content: Your topic on Edaboard seems to have attracted a number of low quality replies. I'm not going to go over it in detail as I'm not an Edaboard user, and have no desire to interact with its participants.However the proposed BJT H-bridge is disastrously bad - it looks possible on paper, but when you sim it with realistic transistor models in LTspice, you'll see that when driven by a 150KHz 50% squarewave, the duty cycle has been distorted to 65%, and its acquired 1.5V of DC offset, resulting in an average of 10V DC across a resistive load. Also the transistor dissipations are excessive - Q3 is particularly bad because of its comically weak base drive.Switch the load to an inductive one (already present in the sim as Lload - just rewire OutB) and it will fail disastrously as the right-hand side transistors will be destroyed by the back-EMF spikes from the load.You could add anti-parallel diodes across each transistor in the H-bridge to suppress the back-EMF spikes, but you'll still be gilding a turd, and its performance can only get worse if you use power transistors that can handle the dissipation without blowing, due to their typically lower ftand hFEthan the general purpose 40V 600mA transistors I chose for the sim.Redesigned a bit so the transistors actually saturate, it might be usable at 15KHz but the redesign to get enough base drive for full saturation without further slowing the edges will make it a lot more complex and I doubt you'll ever get it to work well at 150KHz.