Chip with simple program for Toy

more suited to forward converters then....

I'll take it that the rest of the process was reasonable? I realized
quite a few things while writing that document, and did a little
on-the-fly formulation. :)

generally I'v been pretty unimpressed with the documentation(s) I have
found on smps design, every reference seems to miss something.
Antoher method I forgot to mention for finding N is based on target Duty
cycle, but found no guidelines about what a good duty to target is.

dan

Kevin Aylward wrote:
dan williams wrote:


Step 5) missing essentials...

When the power switch turns off, before the output diode engauges,
there's a really big voltage spike on the coil 'o wire. quite capable
of destroying the mosfet. so we add something across (debatable) the
coil to catch the spikes, there are the various types, used in
various times.

snubber ---/\/\/\---||-----

soft clamp ----->|----\/\/\/------
| |
----||----

and Zener clamp ----->|-----Z<----

I know that national designs always use zener clamps, I also know
that every other smps I have seen uses a soft clamp. (computer
supplies, computer monitors (the guys get annoyed with me continiously
disassembing the computers "Yup, see, thats a soft clamp too", "put it
back togethor, I need to check my email!" :) ), industrial supplies,
printers, VCR's)

snubbers always dissipate power, so I'll slide them aside...

Zener's are used to limit voltage, soft clamps and snubbers to
limit voltage and dv/dt, which will break down switches given enough.


The "soft clamp" shown i.e. the one with the diode-R-C is not (usually)
there to reduce the effects of leakage inductance spikes. It is used to
set a clamp voltage that resets the flux in the core and prevents
flux/current walking/ramping to to ET/N offsets.

Kevin Aylward
salesEXTRACT@anasoft.co.uk
http://www.anasoft.co.uk
SuperSpice, a very affordable Mixed-Mode
Windows Simulator with Schematic Capture,
Waveform Display, FFT's and Filter Design.
--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 
I had a similar design problem, but with mine, I couldn't have the
voltage drop of a diode in there... Two mosfets in series would be a
reasonable answer, but drive supplies, and switching become quite a
problem.

they dont make switching relays over about 2A. I have already gone
through this with Omron

g2r 16A series 5V coil .5W over the coil. or have some fun engineering a
mosfet ciucuit.

dan


AC/DCdude17 wrote:
X-No-Archive: Yes

James W wrote:

I'm need to build a circuit that will allow me to control which of
several deep cycle batteries in powering a circuit that can draw as much
as 20 amps at 12-14vdc.

I could use relays.. but I hate to waste battery power to hold the relays..

The circuit needs to allow dc current in either direction ( normally the
batteries are supplying all the power, but on occasion, I do have to
recharge batteries, and would like to use the same 'switch' to select
which battery is being charged.

Would a rippin big MOSFET be reasonable for something like this? Other
ideas?

High current relay is your best bet as the other guy mentioned. It's just like
a toggle switch that is electrically triggered. I'm not sure where you'll find
it however.

If you can't find one, go with a relay. The loss in coil is much lesser than
junction loss in MOSFETs.

You need to use a pair of MOSFETs to allow bidirectional use. Since MOSFETs
are conductive in opposite direction, each MOSFET must have an external diode
to limit current flow to proper direction so that when you want to switch off,
current doesn't go through other MOSFET.
--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 
Roger wrote...
"Ban" <bansuri@web.de> wrote:

The poster states specifically state of *IOs*,
further he states he want to test with an oscilloscope.

So I think Win's warning about Vcc/2 *is* valid. Good if he
mentions it, because you do not seem to know this issue (as
I didn't either to be honest)

Okay, I thought we were only talking about outputs.
When it is about in/output pins I agree.
Hey, I don't know what we're talking about!

Thanks,
- Win
 
dan williams wrote:
(snip)
Please tell me where I go wrong, there are an uncomfortable number of
arbitrary limits made, I dont know if their right. you may want to read
it trough before making comments.
(snip)
Lets take the case at hand:

Input: 10-15VDC
Ouput: 5VDC (30V Isolation) 3A

Just for the sake of it, lets go with a 100Khz switching frequincy, that
way we can compare to NS's SimpleSwitcher Design
The main benefit from using a higher frequency is a smaller
transformer. For a 15 watt, 1 off design, you will almost certainly
use a bigger transformer than is absolutely necessary, just because it
will make it big enough to allow an approximate design with lots of
margin. So you might as well make things a lot simpler to optimize by
lowering the frequency to something just inaudible (20 to 30 kHz
range.) There, at least the magnetics will be more ideal. I am going
to assume that you lower the frequency to 20 kHz (50 us per cycle)

Step 1) An innocent Start...
Choose a Topology.
Because of the isolated nature, we basically have forward or flyback
to choose from. (of the BASIC topologies)
The last time I saw a forward converter, it was in an apple IIe,
(There will be a reason for this, I'm happy not knowing what it is.) so
lets go with flyback.
Usually, the forward converter adds an extra winding to dump the core
magnetization energy back into the supply, but it has some nice
features, like lower peak and ripple currents. But at 15 watts,
flyback is not a bad choice, especially is you back off a bit from 100
kHz.

Step 2) Things get a little harry...
First pass parts selection
we need information about our switches and diodes to run subsiquent
calculations
Switch:
As per motorola's SMPSRM (which nolonger seems to be available)
"Mosfet power switch, Vdss = 1.5Vin(max) Id = 2Pout/Vin(min)"
so we need at least: Vdss = 22.5V Id = 3A
Go for the Kill IRFZ44N Vdss = 55V Id = 49A [Rds(on) = .024 ohms]
That was easy enough... lots of those in the bin.
There is such a thing as too big a transistor. You have to charge all
that gate capacitance up and down every cycle (and fast).

Diode:
As per motorola's SMPSRM "Vr = 10 Vout If = Iout"
so we need at least: Vr = 50V If = 3A
Every reference talk about doide losses, resulting in "use a
shottkey doide." ok. (I'm ignoring synchronous rectification here)
since the IRF cd is already in the drive... how about a 50SQ080 Vr
= 80V Id = 5A [Vf = .52V]
I'v never heard of the diode before, but if nobody else in my end
of Canada can get it (quite likley), I'll substitute (a process I'm
getting good at).
I think the 10 Vout spec is a bit overdone. Especially when you have
such a narrow range od input voltage. A 45 volt unit will have a
lower forward drop and almost certainly handle the reverse voltages it
will see.

Step 3) Spark up the algebra.
(snip)
Next chart the voltage across the inductor vs time.

V

^
|
|
|============
| on |
--------------------------> t
| | off |
| ===========
|
|
|
V
This should include a bit of wasted ringing time (when the inductance
is neither charging up or dumping, but is just waiting) if you want to
stay in the non continuous current mode (that is easier to
stabilize). Your operation should be just approaching full time
utilization at your lowest input voltage, highest output current
condition.

- The Voltage across the primary side of the inductor when the switch
is on, is the supply voltage, Vin minus the drop across the switch,
being that this is a big burly mosfet, I'm approximating this to be 0.
So the charge voltage is Vin.
I think this calculation should use the minimum Vin.

- The Voltage across the primary side of the inductor when the switch
is off, is the output voltage, plus the diodes forward drop, all divided
(turns ratio is 1(primary):N(secondary)) by the turns ratio. ( as you
can quite plainly see from the schematic I didn't draw)

- The Vt area of the on and off time are, for a close approximation,
the same (we have loss via the core, I can't calculate it, so I'm
ignoring it... its small! right?)
Right. The voltage across any good quality inductance (not counting
IR drop) must average zero over a cycle.

From these we get the formula:

ton Vin = toff (Vout + Vfdiode) / N

set that aside,
Under the conditions stated earlier that no time is wasted in the
cycle.

From any physics book, we can obtain the formula

L = V (dt/di)

so whats our charge time?
You pick it and calculate the inductance that produces it.

t = 1/f (ats just the way she iz)f being our switching frequincy.
Because were using PWM, t is the absolute maximum time the indutor would
get in a "cycle" at 100% duty. In order to know our REAL charge time, we
need to multiply t by our duty cycle, D. which goes from 0 to 1.

dt = D/f or tD as in the duties fraction of the maximum time.

so whats our current?

this IS a good question, the answer I find is "20% of the switches
maximum rated" but what!?
Agreed. The average (midpoint in the ramp) of the input current has
to just about equal the average current of the output (after you
account for the turns ratio). Lets pick some times and make this make
more sense.

(Ignoring the turns ration for the moment:) Since the output voltage
will be pretty constant, you won't need its time to vary much. You
input varies over a 2 to 3 ratio, so it will take this range of on
times to produce the same volt seconds area in your timing diagram.
If we allow the full duty cycle (low input voltage, highest output
current) case to reach 50% (because equal charge and discharge times
are pretty efficient and you want efficiency at maximum output). So
the worst case will be 50% duty cycle on the verge of continuous
current operation. 25 us to charge and 25 us to discharge. In order
to have 15 watts to be the average input power at 10 volts in, the
average current (neglecting losses) will be (draw that triangle
current wave and figure out how you get a peak current from the
average) from the 15/10*4=6 amps. Lets guess 20% more for losses. So
the switch must handle 7.2 amps, peak under this case.

(snip painful exercise in futility)

now we know the duty, we can calculate the iductor:

L = (Vin / (0.2 f Id)) * ((Vout + Vfdiode)/(N (Vin - Vs)+(Vout +
Vfdiode)))
or
L = (Vin (Vout + Vfdiode)) / (0.2 f Id N ((Vin - Vs)+(Vout +
Vfdiode)))

step 4) lets get arbitrary...

So what is our inductor size?

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz
Lets try 20 kHz

Lets use 7.2 amps if this is the peak switch current

N = we really havn't a clue, do we?
Vs = 0 (approximation, looking back on this, our iductor current
is 9.8A... which is awefully high, and even across .024 ohms starts to
become significant(.2V))

Now this is a stumbling block... the best references I can find for
choosing N are based on the limitations of the voltage on the switch
when its off (Vswitch_off = (Vout + Vdiode)/N) of which you want to stay
under its rating, which motorola had us choose as 1.5Vin_max
Linear provides a formula for "optimum value" based on Vsnub, which
they calculate from N (oh, thats helpfull)
I would choose N to give a worst case load duty cycle of 50% and see
how badly that treats the switch at turn off. With 9.9 volts in and
5.5 volts out (approximately) it will be very close to a 2:1
transformer.

Its also not logical to be running nearly 10A through the primary,
not for a 15W supply...
Well, 7.2 amps. This is the gotcha in the flyback topology. It has
high (but brief) peak currents since all currents are in the form of
low duty cycle ramp waveforms, but the output current is the average
of this rather sparse wave shape. What you save on magnetics you eat
up in high ripple current capacitors.

It would seem logical to use a formula for the primary current like
(Pout/Vin(min))which seems to result in a much more reasonable current
of 1.5A
With an efficient design, this is the average, but there is always
that 4 to 1 multiplier for a 50% duty cycle ramp wave.

somewhere(forgotton now) I read "bipolar transistors stressed 75%"
something "their maximum rating, are subject to crowding, which is an
instentanious failure mode"
I usually use a rule of thumb to not use any power transistor at a
higher peak current than one which has half of the peak current gain
on the bets versus current graph.

so I'd say 70% of the mosfets Vdss is a safe goal

this puts 0.2Id = 1.5 A
and N = (Vout+Vf)/(0.7Vdss + Vin) = .103 = about 10:1 ratio, awefully
small....

but wait, Ip = Is * N (the secondary current is N times the primary)
so N = Ip/Is resulting in a ratio of 0.5 ... this is much more
reasonable, concidering the simple switcher software suggests about .333
for an equivilent supply.

I'm going to go with the sane numbers:
0.2Id = 1.5A
N = .5

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz

so

L = (Vin (Vout + Vfdiode)) / (0.2 Id f N ((Vin - Vs)+(Vout +
Vfdiode)))

= (10 (5 + .52)) / (1.5 100,000 0.5 ((10 - 0)+(5 + .52)))

= 47.42 uH
For the 20 kHz case with 50% duty cycle at worst case (and throwing in
another .1 volt loss for primary resistance), I would get about:
Lprimary = 9.8 volts*(25 us / 7.2 amps) = 34 uh

If N is the primary / secondary turns, then I need N to be 9.8/5.5=1.8
to allow the 50% duty cycle.

This means, that except for the leakage inductance turn off spike, the
flyback voltage will be about 10 volts, regardless of the input
voltage (added to the input voltage, of course, so at highest input
voltage, the total switch off voltage will be about 15 +10 = 25, so
you have all the rest of the 50 volt mosfet capability to use up on
the snubbing of that leakage inductance.

which, is, atleast, in the same order of magnitude as the
simpleswitcher software comes up with.

Step 5) missing essentials...

When the power switch turns off, before the output diode engauges,
there's a really big voltage spike on the coil 'o wire. quite capable of
destroying the mosfet. so we add something across (debatable) the coil
to catch the spikes, there are the various types, used in various times.
Before you design the snubber, think about how you minimize this
uncoupled energy by optimizing the transformer design. For such a low
isolation voltage requirement, the ultimate in low leakage inductance
would be to wind three wires (trifilar) and use two of them connected
in series as the primary and one as the secondary. This causes other
problems with high coupling capacitance, but it just about eliminates
the snubber problem. Putting half of the primary turns on each side
of the secondary is a more practical possibility.

snubber ---/\/\/\---||-----

soft clamp ----->|----\/\/\/------
| |
----||----

and Zener clamp ----->|-----Z<----

I know that national designs always use zener clamps, I also know that
every other smps I have seen uses a soft clamp. (computer supplies,
computer monitors (the guys get annoyed with me continiously
disassembing the computers "Yup, see, thats a soft clamp too", "put it
back togethor, I need to check my email!" :) ), industrial supplies,
printers, VCR's)
I like the soft clamp too.

snubbers always dissipate power, so I'll slide them aside...

Zener's are used to limit voltage, soft clamps and snubbers to limit
voltage and dv/dt, which will break down switches given enough.

I dont know how to calculate limits for dv/dt, so I'll assume its not
a problem, and go for a zener clamp.

I gather from the linear app note (19) that you want to stay atleast
10V away from the switches max rated voltage. we also have to concider
we need to be above the normal flyback voltage which is
Vp = Vs / N

Vs = Vout + Vdiode_forward

= 5.52/.5 = 11.04V

Based on Vdss = 55V

= 45V

so we want 11.04 > Vsecondary > 45

this is a pretty wide margin! I'll go closer to the 45V, which I
recall an application note from AIC (I think) suggesting to use the
highest possable voltage....

We just happen to have 33V zeners around the shop, I'll go with them
(this design is not quite optimal....)
I would put a small capacitor in parallel with that zener to lower the
peak current it sees.

as a side note I have the following formula for calculating soft
clamp components (no , I dont know where I got it from)

Lp = primary inductance
Ip = peak drive current
Vc = clamping voltage (e.g. 33V)
Vi = supply voltage
Vs = voltage across switch when off (load engauged)

C = (0.2LpIp^2)/(Vc^2 - Vs^2)
R = ((Vc+Vs-Vi)/2)^2 (.0192/(LpIp^2))

I'm not going to work that out, but I would probably end up using a
soft clamp, I have seen a lot of zeners fail over the years (short out)
I see a soft clamp as something much more rugged.

I'm not going to mention PWM control systems, We have some rails of
TL494's at the shop, they work fine.

Step 6) follow through.

ok, but how do we BUILD it. actually I'm only reffering to the
inductor.

This is where the linear app note accels, how to make an inductor

- Calculate a suitable core by volume, from

V = ( Ip ^ 2 L u 0.4 Pi 100000000) / Bo ^ 2

where L = inductance (H)
Ip = peak inductor current
u = permeability (from material datasheet e.g. material #77 =
2000)
Bo = max flux density (from material datasheet e.g. material #77 =
4600)
V = core volume(cm^3)

At the shop we have a set of E cores from CWS bytemark which are 2540
mH/1000T, I know there big enough for this application, so I just need
to put wire on them...

- Apply wire to selected core

Where
Npri is the primary turns
L is primary inductance
Al is from core datasheets

Npri = 1000 * square root of ((L/Al)

so for
Al = 2540mH/1000T
L = 47.42uH

N = .14 turns... ok, well maybe that core is a little big... thats
how I calculate it anyhow.... I suppose we need some new cores.....
darn. (Turns must be an interger, prefferably larger than 0)
I think you are doing this wrong.

Turns = sqrt(47.42uh/2540mh)*1000=4.3 turns

anyhow, the secondary turns would be the primary turns * N (the
winding ratio N...)

well, thats it. how did I do? I would quite like suggestions on
places I went wrong or just was wrong. Its 12:30am, so I'm not going to
list the references I used for this documents formulea, if you want,
ask, I'll tell.
Flyback transformers (or inductors) normally use cores with gaps in
the magnetic path to allow the core to store more energy without
saturation, Of course, this lowers their Al value, requiring more
turns, which requires more air gap to handle the higher amp turns
without saturating, etc. But energy goes as amp turns squared, while
Al drops as amp turns, so it settles down to a solution. Basically,
you can guess a gap, and check how many turns that gap will require to
get the inductance, and then check the peak amp turns and see how high
the core flux will go. For flyback designs, I like to stay below
about half of the saturation flux rating.

provided this process can be nicely nailed down, a minor bit of
software (something I'm actually good at) can quickly take care of the
calculator labor. which I will be happy to share with anyone.
I dont want to have to labor over designing a smps, I dont see why
anyone should after so many years of them being around. NS's
simpleswitcher stuff is nice, but cant help if you need something over
about 30W or 40V input (like an off-line running at 170V)
Descriptions of control circuits could probably easily double the
size of this letter, but as its mearly feedback and stability
calculations, and most controller chips come with one-size-fits-all
sugested filters, and resonably good formulae to boot, I'm not worried
about it.

Thanks for the feedback course, Rod.

Dan Williams






--
Dan Williams
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8

--
John Popelish
 
Winfield Hill <whill@picovolt.com> wrote:

Hey, I don't know what we're talking about!
No problem, if you don't mind, I'll describe the circuits behind such
an I/O pin in an AVR processor.

The pin is connected to both an output stage and an input stage.
The output stage is a traditional logic output which can be put in
low, high, or Hi-Z state.

When it is put in Hi-Z state the input circuit can be used, and the
first stage the input signal gets to is a schmitt-trigger, so it
doesn't matter if the input signal is anywhere in the voltage range
between the rails.

The I/O pin is also connected to a pull-up resistor which can be
activated if the user prefers to use the input as a pulled up input,
otherwise the input is in Hi-Z mode.

To summarize, such an I/O pin will not be damaged by connecting it to
Vc/2 via a 10-100k resistor no matter what state it is in.
If it is in the Hi-Z input mode it will probably get a voltage of Vc/2
and that state can be detected.

On other input pins on other processors such a test method might be
dangerous though, if that input is not protected by a schmitt-trigger,
so maybe we shouldn't recommend it generally for pins connected to
input circuits.
For logic circuits outputs though it is safe.

--
Roger J.
 
On 02 Aug 2003 20:07:12 GMT, eromlignod@aol.com (EROMLIGNOD) wrote:

Hello and thanks John:

Yes I do have details, which I hope don't spur a deluge of questions.

I have invented a self-tuning piano (US pat. #6,559,369). With the help of QRS
Music Technologies I have built a prototype and it works great. I just need to
cut costs. You might have heard interviews with me on NPR or CBC (Canada), or
heard it mentioned on Paul Harvey. There was also an article about it in the
New York Times in January as well as articles in New Scientist, Der Spiegel,
Nikkei Marketing Journal, etc.

I have individual magnetic pickup/drive coils for each string in the piano.
Actually they are merely ferrite-core inductors soldered to a PCB. The signal
is only used for tuning, so you never hear it and very crude (obviously) coils
can be used. The coils are used both to pick up the vibration of the strings
(like a guitar pickup) and to sustain the strings. If you impose a wave onto a
coil and place it near a string, it will cause it to vibrate.

I have a universal signal that can make a coil vibrate any string at its
natural frequency and I apply it to all of the strings at once (it sounds
pretty wild!). I individually poll each pickup by simultaneously disconnecting
it from the driving signal and connecting it to a signal bus (thus the SPDT)
back to my evaluation circuit. The residual vibrating shows up as a signal and
I determine how far out-of-tune it is and go on to the next string. I measure
the period of the string, not the frequency, so it is done very quickly. I can
theoretically measure all 219 strings in about one second. I have been
switching individual strings with a separate, crude circuit up till now. I
need a cheap way to continuously poll the strings during the tuning process.

I tune the strings by passing electrical current through them, which warms them
up, expanding them and lowering their pitch. The piano is initially tuned at
the factory at an elevated temperature, so I also have the option of lowering
the current to cool them and raise the pitch. I keep polling the pickups and
adjusting the PWM to each string until they are all in tune (match a
factory-set tuning), then this duty cycle is maintained while you play. You
shut it off when not in use. It only goes through this tuning cycle when you
first turn it on.

Any more good ideas for polling those coils? I'm actually an ME, so use
little-bitty words!
---
Damn, you're slick!

Using heat to tune the strings is one of the cleverest things I've ever
heard of and I hope it makes you a wealthy, wealthy man.

--
John Fields
 
Because a USB cable has very specific specifications which the cable you
selected may not fall within. But hey, if it works...

"Genejocky" <genejocky2000@yahoo.com> wrote in message
news:5b42948.0308011529.1f3e68b6@posting.google.com...
I hadn't tried ensuring that I used a twisted pair... totally logical
though.
Thank you Lord Garth

Ken,
Why do you say "bad Idea"?


Gene



Ken <___ken3@telia.com> wrote in message
news:<pv7kiv4micf8g3daill1etaprp3ov5u8p2@4ax.com>...
On 31 Jul 2003 23:54:14 -0700, genejocky2000@yahoo.com (Genejocky)
wrote:


I am currently running a printer via usb cable.
I'd like to opperate the printer in another room from the pc.
The total length of the cable should still fall within the maximum
length allowed for the usb specification.
The plan is to create 2 cables by cutting the current usb-A to usb-B
cable in half.
A RJ45 connector is to be attached to each "cut end" to allow the pc
to connect to the usb cable- to the rj45 connector- to the cat5e cable
behind a wall plate- to the other end of the cat5e cable/wall plate in
the other room- to a RJ45 connector- to the 2nd half of the cut
printer cable- to the printer.

Bad idea.
 
dan williams <dan_williams@sunshine.net> wrote in message news:<3F2B680A.8554570@sunshine.net>...
This is the second time I have been called on for a smps design.
Granted, for this one I can use National's design system(s) But I'd like
to know how to do this. (Its easy to be out-of-range of NS's limits for
simple switchers)

Please tell me where I go wrong, there are an uncomfortable number of
arbitrary limits made, I dont know if their right. you may want to read
it trough before making comments.

This may also be good reading for people studdying switchmode supplies,
formulas here have taken me about 48 hours (solid hours) to work out
from many references, and almost all make sense.

I would really like to see an "out with it, already" document on smps,
come to think of it, I didn't do a google search for a smps FAQ
Step2 should be calculation of currents and voltages. You should
really select semiconductors based on a known requirement. If a
junkbox part suffices, fine.

You may want to recognise some mechanical realities before actual part
numbers are selected. How is the thing to be fabricated? All
through-hole or some SMD?

Hv schottky is IR, available in small quantities from Digikey. Click
the maple leaf and pay in Canadian dollars from the Canadian division
without worrying about monetary conversions, duty or border crossings.

Lets not get arbitrary, calculate the requirements with margin. Then
fit in parts you may want to use to see if limits are maintained.

http://focus.ti.com/docs/training/catalog/events/eventsbycategory.jhtml?templateId=5517&navigationId=8455

SEM400 topic2 flyback transformer.
SEM400 topic6 Flback power supply.
MAG100A basic magnetics design.

RL
 
Kevin Aylward wrote:
For flyback designs, I like to stay below
about half of the saturation flux rating.



Imo, I think this is probably a bit conservative. I don't see any main
reason to not go to just below its max flux density rating, having duly
taking into account the worst case operating conditions. Its not like
you get any extra life like you would by derating a transistor. If
your've got the space, you might save a bit on core loss, but as a rule,
you never have enough space:)
The final operating condition is a function of the material loss with
frequency more than anything else. If you are pushing the material in
frequency then you generally can't go near Bsat- unless you really like
burned up wiring and fuming magnetics. Even 1/2 Bsat may not be good
enough. The window area - core cross section product rule used for
initial sizing tells you nothing about ultimate core power dissipation
density- and you have to keep this under control to limit temperature rise.
 
See http://www.national.com/an/AN/AN-1095.pdf#page=1 and follow the
instructions exactly, using off-the-shelf flyback transformers.

dan williams wrote:
This is the second time I have been called on for a smps design.
Granted, for this one I can use National's design system(s) But I'd like
to know how to do this. (Its easy to be out-of-range of NS's limits for
simple switchers)

Please tell me where I go wrong, there are an uncomfortable number of
arbitrary limits made, I dont know if their right. you may want to read
it trough before making comments.

This may also be good reading for people studdying switchmode supplies,
formulas here have taken me about 48 hours (solid hours) to work out
from many references, and almost all make sense.

I would really like to see an "out with it, already" document on smps,
come to think of it, I didn't do a google search for a smps FAQ


Lets take the case at hand:

Input: 10-15VDC
Ouput: 5VDC (30V Isolation) 3A

Just for the sake of it, lets go with a 100Khz switching frequincy, that
way we can compare to NS's SimpleSwitcher Design

Step 1) An innocent Start...
Choose a Topology.
Because of the isolated nature, we basically have forward or flyback
to choose from. (of the BASIC topologies)
The last time I saw a forward converter, it was in an apple IIe,
(There will be a reason for this, I'm happy not knowing what it is.) so
lets go with flyback.

Step 2) Things get a little harry...
First pass parts selection
we need information about our switches and diodes to run subsiquent
calculations
Switch:
As per motorola's SMPSRM (which nolonger seems to be available)
"Mosfet power switch, Vdss = 1.5Vin(max) Id = 2Pout/Vin(min)"
so we need at least: Vdss = 22.5V Id = 3A
Go for the Kill IRFZ44N Vdss = 55V Id = 49A [Rds(on) = .024 ohms]
That was easy enough... lots of those in the bin.
Diode:
As per motorola's SMPSRM "Vr = 10 Vout If = Iout"
so we need at least: Vr = 50V If = 3A
Every reference talk about doide losses, resulting in "use a
shottkey doide." ok. (I'm ignoring synchronous rectification here)
since the IRF cd is already in the drive... how about a 50SQ080 Vr
= 80V Id = 5A [Vf = .52V]
I'v never heard of the diode before, but if nobody else in my end
of Canada can get it (quite likley), I'll substitute (a process I'm
getting good at).

Step 3) Spark up the algebra.
Select a value for your inductor. I shall derive the following
formulae, to prove I do (or don't) know where it comes from, and because
almost none of the 5+ references I'm using factor EVERYTHING in.

Lets Start by drawing 'er out. (I'll save you my ascii art, anyone
who can help me knows what a basic flyback topology looks like, for
everyone else, its like a boost, but the output commes from a secondary
winding on the inductor that engauges when the switch turns off. For
those of you who don't off hand know what a boost topology looks like,
may I suggest taking a look through application note 19 from Linear's
web site.)

Next chart the voltage across the inductor vs time.

V

^
|
|
|============
| on |
--------------------------> t
| | off |
| ===========
|
|
|
V

- The Voltage across the primary side of the inductor when the switch
is on, is the supply voltage, Vin minus the drop across the switch,
being that this is a big burly mosfet, I'm approximating this to be 0.
So the charge voltage is Vin.

- The Voltage across the primary side of the inductor when the switch
is off, is the output voltage, plus the diodes forward drop, all divided
(turns ratio is 1(primary):N(secondary)) by the turns ratio. ( as you
can quite plainly see from the schematic I didn't draw)

- The Vt area of the on and off time are, for a close approximation,
the same (we have loss via the core, I can't calculate it, so I'm
ignoring it... its small! right?)

From these we get the formula:

ton Vin = toff (Vout + Vfdiode) / N

set that aside,

From any physics book, we can obtain the formula

L = V (dt/di)

so whats our charge time?

t = 1/f (ats just the way she iz)f being our switching frequincy.
Because were using PWM, t is the absolute maximum time the indutor would
get in a "cycle" at 100% duty. In order to know our REAL charge time, we
need to multiply t by our duty cycle, D. which goes from 0 to 1.

dt = D/f or tD as in the duties fraction of the maximum time.

so whats our current?

this IS a good question, the answer I find is "20% of the switches
maximum rated" but what!?
it seems to me, that this should be related to, say, the power
output? but such an approch will cause this current to be dependent on
the turns ratio, which I havn't worked out yet! to avoid simotanious
equations, I will use this 20% nonesense, erm, I mean "arbitrary rule of
thumb"

di = .2Id

scoop it all up into a pile:

L = (Vin D) / (0.2 f Id)

hey wait! you didn't say what D is!

thats easy: D = ton/(ton + toff) (ats just the way she iz)
now, previously, we worked out a formula in terms of Vin, Vout, ton,
and toff, plus a few inneficiencies.

Vs is the switches voltage drop...

ton (Vin - Vs) = toff (Vout + Vfdiode) / N

mulled becomes:

(Vin - Vs)/((Vout + Vfdiode) / N) = (toff / ton)

set aside...

D = ton / (ton + toff)

therefore

1/D = (ton + toff) / ton
or
1/D = (ton / ton) + (toff / ton)
or
1/D = 1 + (toff / ton)

so

(1/D) - 1 = (toff / ton) <- third to last step
or
(1/D) - (D/D) = (toff / ton)
or
(1-D)/D = (toff / ton)

and look! we have the same term for our Duty calc and the deriviation
of duty cycle!

(Vin - Vs)/((Vout + Vfdiode) / N) = (toff / ton) = (1-D)/D

crunch crunch crunch!

(Vin - Vs)/((Vout + Vfdiode) / N) = (1/D) - 1 (from third-to-last
step)
or
N (Vin - Vs)/(Vout + Vfdiode) = (1/D) - 1

so

N (Vin - Vs)/(Vout + Vfdiode) + 1 = (1/D)
or
N (Vin - Vs)/(Vout + Vfdiode) + ((Vout + Vfdiode) / (Vout + Vfdiode))
= (1/D)
or
(N (Vin - Vs)+(Vout + Vfdiode))/(Vout + Vfdiode) = (1/D)

so

D = (Vout + Vfdiode)/(N (Vin - Vs)+(Vout + Vfdiode))

now we know the duty, we can calculate the iductor:

L = (Vin / (0.2 f Id)) * ((Vout + Vfdiode)/(N (Vin - Vs)+(Vout +
Vfdiode)))
or
L = (Vin (Vout + Vfdiode)) / (0.2 f Id N ((Vin - Vs)+(Vout +
Vfdiode)))

step 4) lets get arbitrary...

So what is our inductor size?

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz
Id = 49A
N = we really havn't a clue, do we?
Vs = 0 (approximation, looking back on this, our iductor current
is 9.8A... which is awefully high, and even across .024 ohms starts to
become significant(.2V))

Now this is a stumbling block... the best references I can find for
choosing N are based on the limitations of the voltage on the switch
when its off (Vswitch_off = (Vout + Vdiode)/N) of which you want to stay
under its rating, which motorola had us choose as 1.5Vin_max
Linear provides a formula for "optimum value" based on Vsnub, which
they calculate from N (oh, thats helpfull)

Its also not logical to be running nearly 10A through the primary,
not for a 15W supply...

It would seem logical to use a formula for the primary current like
(Pout/Vin(min))which seems to result in a much more reasonable current
of 1.5A

somewhere(forgotton now) I read "bipolar transistors stressed 75%"
something "their maximum rating, are subject to crowding, which is an
instentanious failure mode"

so I'd say 70% of the mosfets Vdss is a safe goal

this puts 0.2Id = 1.5 A
and N = (Vout+Vf)/(0.7Vdss + Vin) = .103 = about 10:1 ratio, awefully
small....

but wait, Ip = Is * N (the secondary current is N times the primary)
so N = Ip/Is resulting in a ratio of 0.5 ... this is much more
reasonable, concidering the simple switcher software suggests about .333
for an equivilent supply.

I'm going to go with the sane numbers:
0.2Id = 1.5A
N = .5

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz

so

L = (Vin (Vout + Vfdiode)) / (0.2 Id f N ((Vin - Vs)+(Vout +
Vfdiode)))

= (10 (5 + .52)) / (1.5 100,000 0.5 ((10 - 0)+(5 + .52)))

= 47.42 uH

which, is, atleast, in the same order of magnitude as the
simpleswitcher software comes up with.

Step 5) missing essentials...

When the power switch turns off, before the output diode engauges,
there's a really big voltage spike on the coil 'o wire. quite capable of
destroying the mosfet. so we add something across (debatable) the coil
to catch the spikes, there are the various types, used in various times.

snubber ---/\/\/\---||-----

soft clamp ----->|----\/\/\/------
| |
----||----

and Zener clamp ----->|-----Z<----

I know that national designs always use zener clamps, I also know that
every other smps I have seen uses a soft clamp. (computer supplies,
computer monitors (the guys get annoyed with me continiously
disassembing the computers "Yup, see, thats a soft clamp too", "put it
back togethor, I need to check my email!" :) ), industrial supplies,
printers, VCR's)

snubbers always dissipate power, so I'll slide them aside...

Zener's are used to limit voltage, soft clamps and snubbers to limit
voltage and dv/dt, which will break down switches given enough.

I dont know how to calculate limits for dv/dt, so I'll assume its not
a problem, and go for a zener clamp.

I gather from the linear app note (19) that you want to stay atleast
10V away from the switches max rated voltage. we also have to concider
we need to be above the normal flyback voltage which is
Vp = Vs / N

Vs = Vout + Vdiode_forward

= 5.52/.5 = 11.04V

Based on Vdss = 55V

= 45V

so we want 11.04 > Vsecondary > 45

this is a pretty wide margin! I'll go closer to the 45V, which I
recall an application note from AIC (I think) suggesting to use the
highest possable voltage....

We just happen to have 33V zeners around the shop, I'll go with them
(this design is not quite optimal....)

as a side note I have the following formula for calculating soft
clamp components (no , I dont know where I got it from)

Lp = primary inductance
Ip = peak drive current
Vc = clamping voltage (e.g. 33V)
Vi = supply voltage
Vs = voltage across switch when off (load engauged)

C = (0.2LpIp^2)/(Vc^2 - Vs^2)
R = ((Vc+Vs-Vi)/2)^2 (.0192/(LpIp^2))

I'm not going to work that out, but I would probably end up using a
soft clamp, I have seen a lot of zeners fail over the years (short out)
I see a soft clamp as something much more rugged.

I'm not going to mention PWM control systems, We have some rails of
TL494's at the shop, they work fine.

Step 6) follow through.

ok, but how do we BUILD it. actually I'm only reffering to the
inductor.

This is where the linear app note accels, how to make an inductor

- Calculate a suitable core by volume, from

V = ( Ip ^ 2 L u 0.4 Pi 100000000) / Bo ^ 2

where L = inductance (H)
Ip = peak inductor current
u = permeability (from material datasheet e.g. material #77 =
2000)
Bo = max flux density (from material datasheet e.g. material #77 =
4600)
V = core volume(cm^3)

At the shop we have a set of E cores from CWS bytemark which are 2540
mH/1000T, I know there big enough for this application, so I just need
to put wire on them...

- Apply wire to selected core

Where
Npri is the primary turns
L is primary inductance
Al is from core datasheets

Npri = 1000 * square root of ((L/Al)

so for
Al = 2540mH/1000T
L = 47.42uH

N = .14 turns... ok, well maybe that core is a little big... thats
how I calculate it anyhow.... I suppose we need some new cores.....
darn. (Turns must be an interger, prefferably larger than 0)

anyhow, the secondary turns would be the primary turns * N (the
winding ratio N...)

well, thats it. how did I do? I would quite like suggestions on
places I went wrong or just was wrong. Its 12:30am, so I'm not going to
list the references I used for this documents formulea, if you want,
ask, I'll tell.

provided this process can be nicely nailed down, a minor bit of
software (something I'm actually good at) can quickly take care of the
calculator labor. which I will be happy to share with anyone.
I dont want to have to labor over designing a smps, I dont see why
anyone should after so many years of them being around. NS's
simpleswitcher stuff is nice, but cant help if you need something over
about 30W or 40V input (like an off-line running at 170V)
Descriptions of control circuits could probably easily double the
size of this letter, but as its mearly feedback and stability
calculations, and most controller chips come with one-size-fits-all
sugested filters, and resonably good formulae to boot, I'm not worried
about it.

Thanks for the feedback course, Rod.

Dan Williams
 
Unfortunately no
You can't create voltage with a regulator it can only regulate what
you put into it.
The 78XX series voltage regulator requires approximately 2 VDC drop
across it to function. On the 5 volt regulator you would be fine
assuming the regulator is heat sinked well enough to handle power
dissipated in it (In this case about 7V drop x whatever current you
are pulling through it).
You cannot however just add an 8 V regulator "on top" of the five and
expect it to work. To get the 8 V regulator to regulate you would need
an input of about 15 volts in to get the 13VDC out. What's going to
happen with your circuit is that the 8 volt regulator will just appear
as a voltage drop and where you are expecting to see 13V you will see
something more than 5 and less than 10VDC. It will not be regulated
either.
You circuit will work if you can find an input voltage source of >=
15VDC and assuming the regulators are heat sinked sufficiently for the
load current you are pulling.


On Wed, 30 Apr 2003 04:41:09 GMT, Charles Jean
<alchemcj@earthlink.net> wrote:

I am building a PIC programmer and need both +5 and +13 volts to make
it work. I have 12 volts unregulated from a wall wort. Would the
attached circuit work for this? Can one simply series connect
regulator chips for a desired voltage? Thanks for any help.

(I left out smoothing capacitors for clarity sake)
The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all progress depends on the
unreasonable.

- George Bernard Shaw (1856-1950)
 
While we are on this subject, I'm looking for a mould/box/whatever that I can
put my small circuit board into, and fill it with epoxy, then remove the
mould/box/whatever, and just leave the epoxy cube. What material can I use,
so the epoxy won't stick to it?

Dave
 
On Sun, 03 Aug 2003 10:51:50 +0800, Dave Baker <dpbaker@streamyx.com>
wrote:

While we are on this subject, I'm looking for a mould/box/whatever that I can
put my small circuit board into, and fill it with epoxy, then remove the
mould/box/whatever, and just leave the epoxy cube. What material can I use,
so the epoxy won't stick to it?

Dave
Use a potting shell if you possibly can; just stick the board in the
shell, fill, and you're done. Robison makes a jillion sizes and shapes
of potting shells.

Molds, especially hard molds, are a nasty mess. If you do want to use
a mold, use silicone rubber. Plastics supply houses (Tap Plastics, out
here) have cool molding silicone. Make a prototype shapr out of
anything, cast the silicone around it, and pull it out when it cures.
Voila, a mold that *releases*. Doesn't even need draft angles, and you
can include fancy things like logos or bosses or textures.

Vacuum degass the epoxy for the ultimate bubble-free fill. Messy, too.

Potting loses its charm fast.

John
 
On Sat, 02 Aug 2003 20:26:10 -0700, John Larkin
<jjlarkin@highlandSNIPtechTHISnologyPLEASE.com> wrote:

On 02 Aug 2003 20:07:12 GMT, eromlignod@aol.com (EROMLIGNOD) wrote:

Hello and thanks John:

Yes I do have details, which I hope don't spur a deluge of questions.

I have invented a self-tuning piano (US pat. #6,559,369). With the help of QRS
Music Technologies I have built a prototype and it works great. I just need to
cut costs. You might have heard interviews with me on NPR or CBC (Canada), or
heard it mentioned on Paul Harvey. There was also an article about it in the
New York Times in January as well as articles in New Scientist, Der Spiegel,
Nikkei Marketing Journal, etc.

I have individual magnetic pickup/drive coils for each string in the piano.
Actually they are merely ferrite-core inductors soldered to a PCB. The signal
is only used for tuning, so you never hear it and very crude (obviously) coils
can be used. The coils are used both to pick up the vibration of the strings
(like a guitar pickup) and to sustain the strings. If you impose a wave onto a
coil and place it near a string, it will cause it to vibrate.

I have a universal signal that can make a coil vibrate any string at its
natural frequency and I apply it to all of the strings at once (it sounds
pretty wild!). I individually poll each pickup by simultaneously disconnecting
it from the driving signal and connecting it to a signal bus (thus the SPDT)
back to my evaluation circuit. The residual vibrating shows up as a signal and
I determine how far out-of-tune it is and go on to the next string. I measure
the period of the string, not the frequency, so it is done very quickly. I can
theoretically measure all 219 strings in about one second. I have been
switching individual strings with a separate, crude circuit up till now. I
need a cheap way to continuously poll the strings during the tuning process.

I tune the strings by passing electrical current through them, which warms them
up, expanding them and lowering their pitch. The piano is initially tuned at
the factory at an elevated temperature, so I also have the option of lowering
the current to cool them and raise the pitch. I keep polling the pickups and
adjusting the PWM to each string until they are all in tune (match a
factory-set tuning), then this duty cycle is maintained while you play. You
shut it off when not in use. It only goes through this tuning cycle when you
first turn it on.

Any more good ideas for polling those coils? I'm actually an ME, so use
little-bitty words!

Don


Diode matrix, for sure. That requires 2*sqrt(n) drivers, instead of n.
If you address the drivers properly, you can enable all coils,
selected rows, or just one. Not truly SPDT, so might take a bit
longer, but that's probably not a big deal.

Uh, how many keys are there in a piano?
I'll answer that...88 in a standard piano, most with multiple strings
for each note, I think, although perhaps this one is different.

Tom

 
There are 88 "notes" in a piano, but each hammer strikes more than one string.
The majority of notes in a piano have three strings per note...all struck by
the same hammer. As you go lower, there are two strings per note and then
finally, in the lowest register, there are single strings.

It adds up to 219 strings in a Story & Clark grand piano.

Don
 
I've never been able to resolve those myself but I simply do not worry. In
Protel I've been able to, say, use VDD then join it to V+ and it works out
that they are one and same but it does not seem to work with Eagle. Try the
eagle newsgroups if you are really keen to work this out, you can link to
them from their support page. However, if you know your cct is correct, then
it doesn't really matter, the warnings do not really break anything as far
as I can see. BTW, I had a look at the cct, and tried deleting all PEs and
placing them all in again and it got rid of one of the warnings... I don't
know why though, I am unclear on the net stuff in Eagle.

"Owen Lawrence" <owen@nospam.iosphere.net> wrote in message
news:3f2c72a2_2@corp.newsgroups.com...
Hi. I've been trying to design this board for a couple of weeks now.
This is my first ever design in Eagle, so I've suffered through a lot of
fumbling about to arrive at this point. Please check the design found at

http://www.iosphere.net/~owen/OwenCLP_02-aug-2003.zip

When I press the ERC button, it tells me there are still some warnings
and an error. I just can't figure out how to resolve them. Since they're
related to the power supply, can somebody please explain to me what I
should
have been doing instead of what I did? For example, what's the difference
between "POWER" and "SUPPLY"? What is PE? Why VDD and VSS, not V+ and
V-?
etc. etc. I eliminated one warning by changing the device to VDD instead
of
V+, but it doesn't let me specify a value.

Also, how should I be specifying the power lines in the schematic?
You
can see that I just stuck V+ and PE wherever I needed them. The
autorouter
seemed to know that some of them should be connected together, but it
didn't
figure out all of them. (That could have been my mistake, though; when I
was eliminating warnings I found some things weren't connected properly.
I
ended up routing the missing pieces manually.)

I widened a number of the lines because I'm expecting them to supply
larger currents. Care to comment?

This is probably all pretty basic stuff, but until I know the tricks,
or
have the basic knowledge, I'm frustrated. Any help will be much
appreciated, but please be kind; I'm expecting that I've probably broken
every rule in the book.

By the way, this circuit shows PIC16F84, but I intend to use
PIC16F628.
It's meant to control a bipolar stepper motor and a solenoid, and sense
the
state of a switch. The solenoid will be switched by a relay, but the
stepper motor will be driven by the H-bridges I've conconcted on the
board.

Thanks for any help you can give me.

- Owen -


--
mailto: owen@nospam.iosphere.net
//http:www.iosphere.net/~owen




-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
-----== Over 80,000 Newsgroups - 16 Different Servers! =-----
 
John Popelish wrote:
dan williams wrote:
(snip)
Please tell me where I go wrong, there are an uncomfortable number of
arbitrary limits made, I dont know if their right. you may want to read
it trough before making comments.
(snip)
Lets take the case at hand:

Input: 10-15VDC
Ouput: 5VDC (30V Isolation) 3A

Just for the sake of it, lets go with a 100Khz switching frequincy, that
way we can compare to NS's SimpleSwitcher Design

The main benefit from using a higher frequency is a smaller
transformer. For a 15 watt, 1 off design, you will almost certainly
use a bigger transformer than is absolutely necessary, just because it
will make it big enough to allow an approximate design with lots of
margin. So you might as well make things a lot simpler to optimize by
lowering the frequency to something just inaudible (20 to 30 kHz
range.) There, at least the magnetics will be more ideal. I am going
to assume that you lower the frequency to 20 kHz (50 us per cycle)
I arrived at 100K after a having to do tweeking with a test supply I
constucted, I see your point (though I hadn't thought of it earlier) and
will go back to 20-30Khz range.

Step 1) An innocent Start...
Choose a Topology.
Because of the isolated nature, we basically have forward or flyback
to choose from. (of the BASIC topologies)
The last time I saw a forward converter, it was in an apple IIe,
(There will be a reason for this, I'm happy not knowing what it is.) so
lets go with flyback.

Usually, the forward converter adds an extra winding to dump the core
magnetization energy back into the supply, but it has some nice
features, like lower peak and ripple currents. But at 15 watts,
flyback is not a bad choice, especially is you back off a bit from 100
kHz.
I have lots of extra room on the core I mentioned, another of the main
reasons for staying away from a forward is that I'm not entirly sure of
how to size the indictance (being that its not used for power storage,
all the stuff I worked out for inductor sizing is based on magnetic
storage) I would almost prefer to use a forward based on its outputs
being more capable of filtering.
to say more...
as I understand it, the output will act like a buck sully when the
switch is off. giving it a more continious output

Step 2) Things get a little harry...
First pass parts selection
we need information about our switches and diodes to run subsiquent
calculations
Switch:
As per motorola's SMPSRM (which nolonger seems to be available)
"Mosfet power switch, Vdss = 1.5Vin(max) Id = 2Pout/Vin(min)"
so we need at least: Vdss = 22.5V Id = 3A
Go for the Kill IRFZ44N Vdss = 55V Id = 49A [Rds(on) = .024 ohms]
That was easy enough... lots of those in the bin.
There is such a thing as too big a transistor. You have to charge all
that gate capacitance up and down every cycle (and fast).
at 20Khz I wouldn't think there much loss during switching transitions,
but I can see it for a point of optimization. and there arn't swithces
much bigger for me to use...

Diode:
As per motorola's SMPSRM "Vr = 10 Vout If = Iout"
so we need at least: Vr = 50V If = 3A
Every reference talk about doide losses, resulting in "use a
shottkey doide." ok. (I'm ignoring synchronous rectification here)
since the IRF cd is already in the drive... how about a 50SQ080 Vr
= 80V Id = 5A [Vf = .52V]
I'v never heard of the diode before, but if nobody else in my end
of Canada can get it (quite likley), I'll substitute (a process I'm
getting good at).

I think the 10 Vout spec is a bit overdone. Especially when you have
such a narrow range od input voltage. A 45 volt unit will have a
lower forward drop and almost certainly handle the reverse voltages it
will see.
I agree, I dont know why motorola uses 10.

Step 3) Spark up the algebra.
(snip)
Next chart the voltage across the inductor vs time.

V

^
|
|
|============
| on |
--------------------------> t
| | off |
| ===========
|
|
|
V

This should include a bit of wasted ringing time (when the inductance
is neither charging up or dumping, but is just waiting) if you want to
stay in the non continuous current mode (that is easier to
stabilize). Your operation should be just approaching full time
utilization at your lowest input voltage, highest output current
condition.

- The Voltage across the primary side of the inductor when the switch
is on, is the supply voltage, Vin minus the drop across the switch,
being that this is a big burly mosfet, I'm approximating this to be 0.
So the charge voltage is Vin.

I think this calculation should use the minimum Vin.

- The Voltage across the primary side of the inductor when the switch
is off, is the output voltage, plus the diodes forward drop, all divided
(turns ratio is 1(primary):N(secondary)) by the turns ratio. ( as you
can quite plainly see from the schematic I didn't draw)

- The Vt area of the on and off time are, for a close approximation,
the same (we have loss via the core, I can't calculate it, so I'm
ignoring it... its small! right?)

Right. The voltage across any good quality inductance (not counting
IR drop) must average zero over a cycle.

From these we get the formula:

ton Vin = toff (Vout + Vfdiode) / N

set that aside,

Under the conditions stated earlier that no time is wasted in the
cycle.

From any physics book, we can obtain the formula

L = V (dt/di)

so whats our charge time?

You pick it and calculate the inductance that produces it.

t = 1/f (ats just the way she iz)f being our switching frequincy.
Because were using PWM, t is the absolute maximum time the indutor would
get in a "cycle" at 100% duty. In order to know our REAL charge time, we
need to multiply t by our duty cycle, D. which goes from 0 to 1.

dt = D/f or tD as in the duties fraction of the maximum time.

so whats our current?

this IS a good question, the answer I find is "20% of the switches
maximum rated" but what!?

Agreed. The average (midpoint in the ramp) of the input current has
to just about equal the average current of the output (after you
account for the turns ratio). Lets pick some times and make this make
more sense.

(Ignoring the turns ration for the moment:) Since the output voltage
will be pretty constant, you won't need its time to vary much. You
input varies over a 2 to 3 ratio, so it will take this range of on
times to produce the same volt seconds area in your timing diagram.
If we allow the full duty cycle (low input voltage, highest output
current) case to reach 50% (because equal charge and discharge times
are pretty efficient and you want efficiency at maximum output). So
the worst case will be 50% duty cycle on the verge of continuous
current operation. 25 us to charge and 25 us to discharge. In order
to have 15 watts to be the average input power at 10 volts in, the
average current (neglecting losses) will be (draw that triangle
current wave and figure out how you get a peak current from the
average) from the 15/10*4=6 amps. Lets guess 20% more for losses. So
the switch must handle 7.2 amps, peak under this case.
now I'm interested, NONE of the docs I can find take this obvious
approach...

The only sense I can make of the four multiplier is via the following:
Iave = Ipk/2
so
Ipk = 2 Iave
this needs to be multipled again by 2 because of the 50% duty cycle.
so
Ipk = 4 Iave

is that right?

(snip painful exercise in futility)

now we know the duty, we can calculate the iductor:

L = (Vin / (0.2 f Id)) * ((Vout + Vfdiode)/(N (Vin - Vs)+(Vout +
Vfdiode)))
or
L = (Vin (Vout + Vfdiode)) / (0.2 f Id N ((Vin - Vs)+(Vout +
Vfdiode)))

step 4) lets get arbitrary...

So what is our inductor size?

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz

Lets try 20 kHz

Id = 49A

Lets use 7.2 amps if this is the peak switch current

N = we really havn't a clue, do we?
Vs = 0 (approximation, looking back on this, our iductor current
is 9.8A... which is awefully high, and even across .024 ohms starts to
become significant(.2V))

Now this is a stumbling block... the best references I can find for
choosing N are based on the limitations of the voltage on the switch
when its off (Vswitch_off = (Vout + Vdiode)/N) of which you want to stay
under its rating, which motorola had us choose as 1.5Vin_max
Linear provides a formula for "optimum value" based on Vsnub, which
they calculate from N (oh, thats helpfull)

I would choose N to give a worst case load duty cycle of 50% and see
how badly that treats the switch at turn off. With 9.9 volts in and
5.5 volts out (approximately) it will be very close to a 2:1
transformer.

Its also not logical to be running nearly 10A through the primary,
not for a 15W supply...

Well, 7.2 amps. This is the gotcha in the flyback topology. It has
high (but brief) peak currents since all currents are in the form of
low duty cycle ramp waveforms, but the output current is the average
of this rather sparse wave shape. What you save on magnetics you eat
up in high ripple current capacitors.
or additional output filters, which seem to be resonably common on
flyback supplies

It would seem logical to use a formula for the primary current like
(Pout/Vin(min))which seems to result in a much more reasonable current
of 1.5A

With an efficient design, this is the average, but there is always
that 4 to 1 multiplier for a 50% duty cycle ramp wave.

somewhere(forgotton now) I read "bipolar transistors stressed 75%"
something "their maximum rating, are subject to crowding, which is an
instentanious failure mode"

I usually use a rule of thumb to not use any power transistor at a
higher peak current than one which has half of the peak current gain
on the bets versus current graph.

so I'd say 70% of the mosfets Vdss is a safe goal

this puts 0.2Id = 1.5 A
and N = (Vout+Vf)/(0.7Vdss + Vin) = .103 = about 10:1 ratio, awefully
small....

but wait, Ip = Is * N (the secondary current is N times the primary)
so N = Ip/Is resulting in a ratio of 0.5 ... this is much more
reasonable, concidering the simple switcher software suggests about .333
for an equivilent supply.

I'm going to go with the sane numbers:
0.2Id = 1.5A
N = .5

Vin = 10 (this is a worst case thing)
Vout = 5
Vfdoide = Vf = .52V as per spec sheet
f = 100Khz

so

L = (Vin (Vout + Vfdiode)) / (0.2 Id f N ((Vin - Vs)+(Vout +
Vfdiode)))

= (10 (5 + .52)) / (1.5 100,000 0.5 ((10 - 0)+(5 + .52)))

= 47.42 uH

For the 20 kHz case with 50% duty cycle at worst case (and throwing in
another .1 volt loss for primary resistance), I would get about:
Lprimary = 9.8 volts*(25 us / 7.2 amps) = 34 uh

If N is the primary / secondary turns, then I need N to be 9.8/5.5=1.8
to allow the 50% duty cycle.

This means, that except for the leakage inductance turn off spike, the
flyback voltage will be about 10 volts, regardless of the input
voltage (added to the input voltage, of course, so at highest input
voltage, the total switch off voltage will be about 15 +10 = 25, so
you have all the rest of the 50 volt mosfet capability to use up on
the snubbing of that leakage inductance.
which is an interesing point on selecting a switch. One makes a tradeoff
between gate capacitance and snubbers for leakage inductance. (mosfets
provided)

which, is, atleast, in the same order of magnitude as the
simpleswitcher software comes up with.

Step 5) missing essentials...

When the power switch turns off, before the output diode engauges,
there's a really big voltage spike on the coil 'o wire. quite capable of
destroying the mosfet. so we add something across (debatable) the coil
to catch the spikes, there are the various types, used in various times.

Before you design the snubber, think about how you minimize this
uncoupled energy by optimizing the transformer design. For such a low
isolation voltage requirement, the ultimate in low leakage inductance
would be to wind three wires (trifilar) and use two of them connected
in series as the primary and one as the secondary. This causes other
problems with high coupling capacitance, but it just about eliminates
the snubber problem. Putting half of the primary turns on each side
of the secondary is a more practical possibility.
Interesting insight into coil winding, I fear to think what you might
say if you saw the transformers I have put togethor so far.

a clarification on leakage inductance, during "that spike", is or isn't
there a potential on the secondary of scaled magnitude? As I understood
leakage inductance thus far, the output rectifier simply hasn't kicked
in yet, (making the term leakage inductance quite inapproprite)

snubber ---/\/\/\---||-----

soft clamp ----->|----\/\/\/------
| |
----||----

and Zener clamp ----->|-----Z<----

I know that national designs always use zener clamps, I also know that
every other smps I have seen uses a soft clamp. (computer supplies,
computer monitors (the guys get annoyed with me continiously
disassembing the computers "Yup, see, thats a soft clamp too", "put it
back togethor, I need to check my email!" :) ), industrial supplies,
printers, VCR's)

I like the soft clamp too.

snubbers always dissipate power, so I'll slide them aside...

Zener's are used to limit voltage, soft clamps and snubbers to limit
voltage and dv/dt, which will break down switches given enough.

I dont know how to calculate limits for dv/dt, so I'll assume its not
a problem, and go for a zener clamp.

I gather from the linear app note (19) that you want to stay atleast
10V away from the switches max rated voltage. we also have to concider
we need to be above the normal flyback voltage which is
Vp = Vs / N

Vs = Vout + Vdiode_forward

= 5.52/.5 = 11.04V

Based on Vdss = 55V

= 45V

so we want 11.04 > Vsecondary > 45

this is a pretty wide margin! I'll go closer to the 45V, which I
recall an application note from AIC (I think) suggesting to use the
highest possable voltage....

We just happen to have 33V zeners around the shop, I'll go with them
(this design is not quite optimal....)

I would put a small capacitor in parallel with that zener to lower the
peak current it sees.
I like that!

as a side note I have the following formula for calculating soft
clamp components (no , I dont know where I got it from)

Lp = primary inductance
Ip = peak drive current
Vc = clamping voltage (e.g. 33V)
Vi = supply voltage
Vs = voltage across switch when off (load engauged)

C = (0.2LpIp^2)/(Vc^2 - Vs^2)
R = ((Vc+Vs-Vi)/2)^2 (.0192/(LpIp^2))

I'm not going to work that out, but I would probably end up using a
soft clamp, I have seen a lot of zeners fail over the years (short out)
I see a soft clamp as something much more rugged.

I'm not going to mention PWM control systems, We have some rails of
TL494's at the shop, they work fine.

Step 6) follow through.

ok, but how do we BUILD it. actually I'm only reffering to the
inductor.

This is where the linear app note accels, how to make an inductor

- Calculate a suitable core by volume, from

V = ( Ip ^ 2 L u 0.4 Pi 100000000) / Bo ^ 2

where L = inductance (H)
Ip = peak inductor current
u = permeability (from material datasheet e.g. material #77 =
2000)
Bo = max flux density (from material datasheet e.g. material #77 =
4600)
V = core volume(cm^3)

At the shop we have a set of E cores from CWS bytemark which are 2540
mH/1000T, I know there big enough for this application, so I just need
to put wire on them...

- Apply wire to selected core

Where
Npri is the primary turns
L is primary inductance
Al is from core datasheets

Npri = 1000 * square root of ((L/Al)

so for
Al = 2540mH/1000T
L = 47.42uH

N = .14 turns... ok, well maybe that core is a little big... thats
how I calculate it anyhow.... I suppose we need some new cores.....
darn. (Turns must be an interger, prefferably larger than 0)

I think you are doing this wrong.

Turns = sqrt(47.42uh/2540mh)*1000=4.3 turns
I seem to have had my units wrong... I ran into it again today while
working on test supplies. I dont see 4 turns as a verry optimal core
design, though I suppose it keeps the dc resistance down. That and
having a core big enough to use #8 wire. :)

anyhow, the secondary turns would be the primary turns * N (the
winding ratio N...)

well, thats it. how did I do? I would quite like suggestions on
places I went wrong or just was wrong. Its 12:30am, so I'm not going to
list the references I used for this documents formulea, if you want,
ask, I'll tell.

Flyback transformers (or inductors) normally use cores with gaps in
the magnetic path to allow the core to store more energy without
saturation, Of course, this lowers their Al value, requiring more
turns, which requires more air gap to handle the higher amp turns
without saturating, etc. But energy goes as amp turns squared, while
Al drops as amp turns, so it settles down to a solution. Basically,
you can guess a gap, and check how many turns that gap will require to
get the inductance, and then check the peak amp turns and see how high
the core flux will go. For flyback designs, I like to stay below
about half of the saturation flux rating.
I have teh formulae for this. With those inductors I have it may be a
good idea to gap them for the sole purpose of bringing the number of
windings to a more reasonable amount for creating the desired ratio.
Clear Scotch tape is about 2 thou thick. :)

this is verry helpfull, I have a 5W (12V -> 5V 1A) converter I'v been
proofing design with. After a day that has created a pile of shorted
diodes, open resistors, singed breadboards, and burt fingers, I'm glad
to have a new approach.

Defn. "1 ohm resitor"
"cheaper than a fuse"

Dan

provided this process can be nicely nailed down, a minor bit of
software (something I'm actually good at) can quickly take care of the
calculator labor. which I will be happy to share with anyone.
I dont want to have to labor over designing a smps, I dont see why
anyone should after so many years of them being around. NS's
simpleswitcher stuff is nice, but cant help if you need something over
about 30W or 40V input (like an off-line running at 170V)
Descriptions of control circuits could probably easily double the
size of this letter, but as its mearly feedback and stability
calculations, and most controller chips come with one-size-fits-all
sugested filters, and resonably good formulae to boot, I'm not worried
about it.

Thanks for the feedback course, Rod.

Dan Williams






--
Dan Williams
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8

--
John Popelish
--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 
John Popelish wrote:
"Kevin Aylward" <kevin@anasoft.co.uk> wrote in message news:<QDSWa.1846$LQ4.143820@newsfep2-gui.server.ntli.net>...
John Popelish wrote:

{snip}

Wow...you read all this, in detail....
My appologies for it being so long, it didn't get that way until I was
done, and I did cut it short.

Flyback transformers (or inductors) normally use cores with gaps in
the magnetic path to allow the core to store more energy without
saturation, Of course, this lowers their Al value, requiring more
turns, which requires more air gap to handle the higher amp turns
without saturating, etc. But energy goes as amp turns squared, while
Al drops as amp turns, so it settles down to a solution. Basically,
you can guess a gap, and check how many turns that gap will require to
get the inductance, and then check the peak amp turns and see how high
the core flux will go. For flyback designs, I like to stay below
about half of the saturation flux rating.


Imo, I think this is probably a bit conservative. I don't see any main
reason to not go to just below its max flux density rating, having duly
taking into account the worst case operating conditions. Its not like
you get any extra life like you would by derating a transistor. If
your've got the space, you might save a bit on core loss, but as a rule,
you never have enough space:)

This rule of thumb is for a hand made one off, where I might change my
mind a bit about the worst case or have misjudged something else. It
saves having to go back an wind another transformer. A design for
mass production would squeeze things a bit more. Running closer to
saturation also increases the energy to be dumped into any snubber.
Is there a guideline for max power dissipated in a snubber? not that I
had a chance to apply some of these new techniques, but today I was
running some pretty cooking snubbers. Just one of the ways I'm learning
that its not designed right.

Dan

--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 
Fred Bloggs wrote:
Kevin Aylward wrote:
For flyback designs, I like to stay below
about half of the saturation flux rating.



Imo, I think this is probably a bit conservative. I don't see any main
reason to not go to just below its max flux density rating, having duly
taking into account the worst case operating conditions. Its not like
you get any extra life like you would by derating a transistor. If
your've got the space, you might save a bit on core loss, but as a rule,
you never have enough space:)


The final operating condition is a function of the material loss with
frequency more than anything else. If you are pushing the material in
frequency then you generally can't go near Bsat- unless you really like
burned up wiring and fuming magnetics. Even 1/2 Bsat may not be good
enough. The window area - core cross section product rule used for
initial sizing tells you nothing about ultimate core power dissipation
density- and you have to keep this under control to limit temperature rise.
Here is another little tidbit I know of, but havn't found any
information on, what are the guidelines to do with core losses?
so far all my cores have been made of #77, #75, #63, #61. and I make
sure the volumes are atleast

V = ((Ipeak)^2 L u .4 Pi) / (B^2 * 10^-8)

thats almost the only factor I take in consideration when selecting a
core...

dan

--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 
James Meyer wrote:
On Sat, 02 Aug 2003 00:28:10 -0700, dan williams <dan_williams@sunshine.net
wroth:

This is the second time I have been called on for a smps design.
Granted, for this one I can use National's design system(s) But I'd like
to know how to do this. (Its easy to be out-of-range of NS's limits for
simple switchers)

Please tell me where I go wrong, there are an uncomfortable number of
arbitrary limits made, I dont know if their right. you may want to read
it trough before making comments.

To paraphrase Shakespear when he said, "Get thee to a nunnery.", I
suggest you "Get thee to Linear Technology's web site."

Download all their application notes regarding SMPS. Once you've at
least skimmed them, download their excellent CAD program for SMPS. With that,
you can accomplish in a day what it looks like will take you several weeks the
way you've gotten started.

Jim
There be more? The linear app WAS one of the top two docs I found...
Have to go-a-browsing...


dan

--
Dan Williams, Owner
Electronic Device Services
(604) 741 8431
RR8 855 Oshea rd
Gibsons BC Canada
V0N 1V8
 

Welcome to EDABoard.com

Sponsor

Back
Top