Flyback SMPS Magnetics? - Page 1
Forum section: electronics / beginners

author: TheAdmiralty
author_rank: Contributor
timestamp: May 16, 2016, 12:04:18 am
content: Evening, everyone! Been lurking around for a while, figured it was time to join in on the conversation! Looking forward to being a part of the community.I'm not sure the beginners' section is the place for this, but I figure it's better safe than sorry. I'm a senior computer engineering student here at Penn State in PA; I've been working on a design project lately for a switch-mode power supply in my own time, but have basically run out of people here at the university to bother with it. The first design was actually used for an embedded systems class a couple weeks ago where I used a PIC18 MCU as an SMPS controller on a PCB hastily milled on our board router; aside from blowing out the switching FET from leaving out a freewheeling diode by accident, it worked reasonably well for something designed from the ground up in under one week. Even complied with modern medical equipment creepage/clearance/isolation requirements.I've attached a quick schematic capture from DipTrace just for reference. Control unit is on the secondary; yes, it's about as basic as they come, but was made under a significant time crunch.All that out of the way, I have a handful of questions about SMPS designs, particular the flyback topology, that nobody I've talked to seems to have a concise answer. I'll bullet them to avoid a wall of text.I have no clue how to spec that transformer on one of these. Answers I've gotten have ranged from 'you want a coupled inductor, not a transformer' to 'just calculate the magnetic field across the transformer's air gap', and I have no idea how any of these translate to a set of meaningful component values, or even the proper type of component to be using. I understand the concepts regarding finding the maximum Tonfor a given inductance and getting switching frequencies from that, but none of the transformers used in an actual flyback converter are anywhere near what I was expecting, meaning I've obviously got something conceptually wrong.Regarding multi-phase flyback converters. Let's say I want to design a 120VAC to 12VDC power supply with four flyback phases; in my own design, I'd have 170VDC rectified directly from the mains, and then four independent coils switched such that their phase alignment will allow for massively reduced ripple at greater currents. Now, I was told this is a bad idea in that the same load-balancing issues with trying to parallel multiple linear regulators will be present with multiple switched coils, which doesn't sound quite right to me. Can anyone clarify?Those are really the two biggest points; any helpful insight would be appreciated! I'm up here over the summer due to possibly picking up an unexpected double major in electrical engineering, and so I pretty much have free reign of the PCB mill.Looking forward to it! EDIT: Just realized that's the old schematic without the freewheeler and a few other things. Oh well, you get the idea.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: May 16, 2016, 01:04:01 am
content: There are more reasons than just overvoltage, for why using a PIC to run an SMPS will end in explosions...That gate "drive" is one of 'em. It won't work at more than a few kHz, and that's kind of pushing it.Would you like some tutoring on the subject?Tim

author: TheAdmiralty
author_rank: Contributor
timestamp: May 16, 2016, 01:42:08 am
content: I'm not sure if tutoring per se will be necessary, but I'm certainly open to any advice you guys can throw at me! I understand that this is an immensely complicated topic, so I'm mainly here just looking for resources on it. I don't expect anyone to write three paragraphs of explanation.Our course was specifically centered around the PIC18 (for some reason) and so it's what I was stuck with - I mainly just wanted a reason to get into this particular topic, and it seems to have worked. It was an entirely academic project just for demo purposes. </disclaimer> The rest of the class ended up toggling a lightswitch with a raspberry pi or something along those lines.The gate 'drive' divider on there was frankly an "I'm-out-of-time-f***-it" bodge that mustered enough strength to get the job done for a few minutes; I've been doing some reading on how to handle things properly, but am open to any spiels you'd like to throw out.Ordering in parts from Mouser alone took three of the five days in which this was proposed, laid out, milled, soldered, and tested.Here at our campus, we've got Comp-E's like myself that are versed in the VLSI and processor architecture side of things with no training in practical EE whatsoever, and then the EE's that could theorize a hole through your head but think a microprocessor is the box on your desk that displays Facebook. It's sad that there isn't anything inbetween outside of double-majoring in both of them for an actual functioning understanding.

author: Monadnock
author_rank: Contributor
timestamp: May 16, 2016, 01:54:27 am
content: As to your first bullet point. This is my favorite app note on flyback transformer design:https://www.ti.com/lit/ml/slup127/slup127.pdfbut if you just google "how to design a flyback transformer" you'll find tons of info.As to your second point, if the transformers are reasonably matched and the duty cycle you drive each fet with is matched, you'll get reasonable sharing. If you want to guarantee sharing then use a peak current mode control scheme and use a common current programming signal.

author: Dave
author_rank: Super Contributor
timestamp: May 16, 2016, 02:25:06 am
content: Your windings aren't connected correctly. You need to flip the secondaries so the polarity dots are facing away from the rectifier diode.The whole point of a flyback converter is that you induce magnetic flux in the transformer core with the primary winding and then, as you disconnect the primary, use the kickback you get from the collapsing magnetic field to power the circuit on the secondary side.

author: TheAdmiralty
author_rank: Contributor
timestamp: May 16, 2016, 02:34:52 am
content: Quote from: Dave on May 16, 2016, 02:25:06 amI should fix that schematic - the polarities on the transformer I had on hand were correct, but the footprint I had was for a different transformer and so I just re-used it in DipTrace. Sorry.Quote from: Monadnock on May 16, 2016, 01:54:27 amI'll definitely read through that. That's what I was thinking on current sharing; it shouldn't be like a series-pass transistor where you end up splitting 80/20. I'm a bit wary of the one who gave that advice...

author: rbola35618
author_rank: Frequent Contributor
timestamp: May 27, 2016, 02:32:11 pm
content: Hi to all,Here is a link to my YouTube channel. I have a series of videos on how to analyze, design and simulate a flyback converter. Watching the first two videos will give you an understanding of how to design flyback converter. Hope you find the videos useful. I forgot to mention that you need a full set of specifications, voltage output, output current, what switching frequency, voltage ripple, and so on.Best regards, Robert

author: Circlotron
author_rank: Super Contributor
timestamp: May 28, 2016, 11:03:14 pm
content: Quote from: Monadnock on May 16, 2016, 01:54:27 amThat's right. With a flyback topology the transformer output is a current source, not a voltage source. The output current will be whatever the primary side charges up to multiplied by the turns ratio. Keep the primary currents equal and the transformers matched and the secondary currents will look after themselves.