Author Topic: Bode plot stability testing of buck converter  (Read 1377 times)

0 Members and 1 Guest are viewing this topic.

Offline tinfeverTopic starter

  • Regular Contributor
  • *
  • Posts: 163
  • Country: us
  • I like to make life harder for myself
Bode plot stability testing of buck converter
« on: May 08, 2024, 05:06:02 am »
I'm doing stability testing of a buck converter and hoping someone can confirm I'm doing and interpreting this correctly. I'm most uncertain about whether the phase margin should be measured relative to 0 degrees or 180 degrees on the phase in this scenario.

I'm practicing on a SIC451 evaluation board (https://www.vishay.com/docs/63102/sic450_sic451_sic453_user_manual.pdf). I've soldered a 10R injection resistor in the Vsen+ path.
Switching frequency is 600kHz, output voltage 3.3V, measurements done at no load.

I'm testing this using an injection transformer I built myself following this thread https://www.eevblog.com/forum/blog/eevblog-1104-omicron-labs-bode-100-teardown/125/

I'm using the bode plot tool in a Siglent signal generator and scope.

Here is the measurement of the injection transformer alone:



The 6dB gain is due to the connection from the signal generator to the scope for the input measurement being 50 Ohm terminated on the scope. However, the injection transformer output to scope has no termination. I'm not sure what the correct way to test this is. The step appearance is probably due to vari-level function of the bode plot configuration, since I'm using the same test configuration as the buck converter measurement.

This is my measurement of the buck converter:



At 63kHz, the gain is 0dB, and the measured phase is 53.3 degrees. The crossover frequency is obviously 63 kHz.  I think this means there is 53 degrees of phase margin?

I'm thinking I should measure compared to 0 degrees on the phase because in that scenario, when the feedback signal increases, the output would increase, so the feedback signal would increase further. i.e. positive feedback. Since I want to measure how far I am from positive feedback, I think I want to measure how far I am from 0 degrees. I see some material online say the measurement should start at 180 degrees and I should measure phase margin relative to -360 degrees, but my measurement doesn't appear to start at 180 degrees so I'm somewhat confused.

At 266kHz, the gain is -19.1dB and the phase is 0.613 degrees, which I think means I have 19.1 degrees of gain margin.

Does this all sound and look right?

« Last Edit: May 08, 2024, 05:10:09 am by tinfever »
 

Offline trtr6842

  • Regular Contributor
  • *
  • Posts: 61
  • Country: us
Re: Bode plot stability testing of buck converter
« Reply #1 on: May 08, 2024, 05:17:02 am »
For the bode plot, you need an "input" and an "output".  The input should be the VSEN+ pin, and the output should be just on the other side of the 10R resistor.

You will not get good results if you connect your signal gen output as the "input" for the bode plot analysis.  Your transformer, while it looks good, will not be perfectly even and without phase changes over the whole frequency sweep, and that's ok!  The bode plotting is supposed to be measuring the magnitude and phase of the whole converter + error amplifiers loop gain, and it shouldn't care too much about your transformer, hence why you measure on each side of the 10R resistor. The transformer is just there to provide a stimulus, not to be some precise reference signal.

Also, measuring at no load should give you a plot that makes sense, but unless the control IC is forcing CCM and fixed frequency operation at no load, then the loop gain will be very different at nominal/full load.
Personal website: eedesignpro.com   Contact me
 

Offline tinfeverTopic starter

  • Regular Contributor
  • *
  • Posts: 163
  • Country: us
  • I like to make life harder for myself
Re: Bode plot stability testing of buck converter
« Reply #2 on: May 08, 2024, 05:29:15 am »
For the bode plot, you need an "input" and an "output".  The input should be the VSEN+ pin, and the output should be just on the other side of the 10R resistor.

You will not get good results if you connect your signal gen output as the "input" for the bode plot analysis.  Your transformer, while it looks good, will not be perfectly even and without phase changes over the whole frequency sweep, and that's ok!  The bode plotting is supposed to be measuring the magnitude and phase of the whole converter + error amplifiers loop gain, and it shouldn't care too much about your transformer, hence why you measure on each side of the 10R resistor. The transformer is just there to provide a stimulus, not to be some precise reference signal.

Also, measuring at no load should give you a plot that makes sense, but unless the control IC is forcing CCM and fixed frequency operation at no load, then the loop gain will be very different at nominal/full load.

Thank you. That's a good point about measuring the "output" on the opposite side of the 10R resistor from the Vsen+ pin. Right now I'm just measuring the "output" off of the output caps directly.

I only used the signal gen second output directly as the "input" when testing the injection transformer, because if I used a tee on the input of the injection transformer as the "input" measurement, the result seemed unnaturally good up to about 2MHz.

Is it correct that I should measure the phase margin relative to 0 degrees in this case with the buck converter?
 

Offline jonpaul

  • Super Contributor
  • ***
  • Posts: 3591
  • Country: fr
Re: Bode plot stability testing of buck converter
« Reply #3 on: May 08, 2024, 06:29:55 am »
bad transformer design and wdg.

Check trsf BW, phase, charastics

j
Jean-Paul  the Internet Dinosaur
 

Offline voltsandjolts

  • Supporter
  • ****
  • Posts: 2437
  • Country: gb
Re: Bode plot stability testing of buck converter
« Reply #4 on: May 08, 2024, 07:37:02 am »
bad transformer design and wdg.

Could you give us some insight into how you came to that conclusion?

It looks to be of similar construction as some very good diy s.i. transformers shown here.
 

Offline trtr6842

  • Regular Contributor
  • *
  • Posts: 61
  • Country: us
Re: Bode plot stability testing of buck converter
« Reply #5 on: May 08, 2024, 08:29:18 am »
I initially didn't see the small capacitor that appears to be in series with one of your transformer windings, what value is it?  In my experience no series capacitor is needed, so long as your signal generator as a truly low DC offset when it's set for 0V. 

Not all your pictures loaded when I first responded, the included screenshots help clarify what's going on.  If your loop-gain measurements were made from the VSENS+ pin to the actual output, that's probably fine up to 1MHz or so, which is where your bode plot ends.  For good high frequency results makes sure the scope probe GND lead is short (ideally two spring-tip probes, if you happen to have more than two hands), but I do think the results you got are usable.

I would like to emphasize that precise transformer gain and phase characteristics are not at all important to this kind of measurement. The transformer's only job is to transfer some of the signal generator stimulus to the 10Ω injection resistor with galvanic isolation.  As long as whatever it spits out is mostly the same frequency as the input, it's good enough for this job.  Ridley engineering and the like like to toot their own horn for making a very expensive and very nice isolation transformer claiming ridiculous gain and phase flatness, but those features do not help these measurements at all!  These bode plots are purely ratiometric.  The absolute magnitude or phase of the stimulus is not important, it just needs to be enough to get the resulting signals above the noise floor of the scope, and not too much to push the converter into some nonlinear response mode.  The only actually good thing about theirs is the low frequency range, which is only useful if you are working with mains PFC converters and need to measure loop gains with 0db crossovers well below 60Hz. 

Your transformer-only gain phase plots look promising, but the seemingly tiny series capacitor and the same wire colors for primary and secondary make it hard to judge just from a picture. If you can label each wire in that picture, and maybe sketch the exact schematic, noting which wires are twisted, and which is connected to the signal generator and the 10Ω resistor, then I could confirm for you.

Regarding the actual bode plot you got, it looks reasonable enough for a voltage-mode converter (as apposed to peak current-mode).  I actually think with the polarity you have, 0° as shown on your bode plot corresponds to -180° in terms of loop gain.  I think that because you can see a clear near 180° phase drop around 10kHz, which means that the phase is moving in the direction we expect when it hits the buck inductor + output capacitor resonance (as apposed to moving up 180­°). 

The reason why these bode plots often come out inverted is because feedback is negative.  You get the same thing if you simulate a converters loop gain in LTspice.  Try inverting one of your channels and the phase should flip, or at least that works on my RTB2004.  Otherwise just go with what makes sense.  First make sure you have the input and output specified correctly, which you do.  The gain generally decreases to higher frequencies, which we expect from the low-pass nature of the LC filter.  If you flipped input and output, you'd get a wacky gain curve.  After you have that checked, you know that no buck converter operates with positive loop phase, the LC lowpass always adds some delay, and the error amp always just barely recovers enough phase margin to remain stable.  So you can be sure that the phases in your measured bode plot are off by 180°.  No big deal, invert a channel, or just measure phase margin to 0° instead of -180°, either are equivalent and fine.  That being said, having the phase appear correctly is nice if you have to document these plots for you work.  A final sanity check would be the basic load step response, a test you should do anyways, even though a bode plot is way more helpful for tuning.

All that said, at the operating point you made that bode plot at, it appears you have about 55° of phase margin at ~70kHz and 20dB of gain margin at ~300kHz, not too bad.  Since that control IC has fixed internal compensation, the only way you might improve that would be to increase your output capacitance or inductance, which would keep a similar phase-vs-frequency curve round 50+kHz, but would decrease gain at all frequencies above the resonant point by lowering the LC low-pass resonant frequency.  You can see that phase peaks around 50kHz, so ideally your 0dB crossover would be at 50kHz and not 70kHz, but honestly you're pretty close already.

Hopefully that makes sense, and happy testing!

« Last Edit: May 08, 2024, 08:35:16 am by trtr6842 »
Personal website: eedesignpro.com   Contact me
 
The following users thanked this post: mawyatt, tinfever

Offline mawyatt

  • Super Contributor
  • ***
  • Posts: 3895
  • Country: us
Re: Bode plot stability testing of buck converter
« Reply #6 on: May 08, 2024, 01:42:52 pm »
@ tinfever,

Your transformer seems fine for your intended purpose, not sure the purpose of the capacitor tho, what core did to use?

Read in detail everything trtr6842 above mentions, spot on :-+

Please note the mentioned Transformer is for Isolation Only and the measurement is Ratio-metric, which reduces/eliminates most of the transformer effects over this frequency range.

Siglent employs a very good algorithm within the Bode Function for resolving the signal of interest, which works quite well in the presence of unwanted signals/interference. We demonstrated this ability showing Oscillator Injection Locking characteristics.

https://www.eevblog.com/forum/projects/injection-locked-peltz-oscillator-with-bode-analysis/ 
https://www.eevblog.com/forum/testgear/siglent-sds800x-hd-12-bit-dsos-coming/msg5441336/#msg5441336

Best,
Curiosity killed the cat, also depleted my wallet!
~Wyatt Labs by Mike~
 
The following users thanked this post: tinfever

Offline youngda9

  • Contributor
  • Posts: 32
  • Country: us
Re: Bode plot stability testing of buck converter
« Reply #7 on: May 08, 2024, 07:38:37 pm »
Going to start simple here, so don't be offended.

10R resistor should be at R3 location.

You can check that you get 0dB Gain and 0deg Phase by clipping both of your probes together (grounds to grounds, and tip to tip) and doing a sweep, you should get flat-line across your scope.

Next, hook up the injection transformer output across the R3 resistor.  Hook up one probe on either side of the resistor.  Connect the scope ground clips close to a ground plane for minimal noise.

Start with 0.25V stimulus and run a plot.  There shouldn't be a lower frequency resonance like you're showing.

Is the above the steps that you've taken?  I can't quite tell.
 

Offline tinfeverTopic starter

  • Regular Contributor
  • *
  • Posts: 163
  • Country: us
  • I like to make life harder for myself
Re: Bode plot stability testing of buck converter
« Reply #8 on: May 12, 2024, 02:59:07 am »
I initially didn't see the small capacitor that appears to be in series with one of your transformer windings, what value is it?  In my experience no series capacitor is needed, so long as your signal generator as a truly low DC offset when it's set for 0V. 

...

Thank you for such a thorough response! That makes a lot of sense.

There are a two things still puzzling me:

  • Why do we measure the Vsen+ terminal as the input signal, when that doesn't reflect that actual injected signal? If I look at the measurements in the time domain, the input signal looks like 0 at low frequencies even when injecting a 1.5V p-p signal. This makes sense because the control loop is "doing whatever it can" to keep the feedback signal it receives constant at the set Vout. But then why do we measure this constant signal?

    I'm guessing the input signal must not actually be flat and my eyes aren't the right tool for measuring that, since at higher frequencies the input signal is definitely not flat. If there is some remnant of the actual injected signal that appears on the Vsen+ terminal, wouldn't that be error we're measuring, the part of the injected signal that the control loop couldn't perfectly compensate for?

    This is showing the input (CH4) and output (CH1) measurements in the time domain with the sig. gen. outputting 100Hz at 5V p-p. Input shows no signal by eye.



  • I can't figure out why my phase measurement is off by 180°. The obvious answer is that the polarity of my injected signal across R3 is backwards, but since I was quite careful about the polarity of the injection transformer build and connections, that means I'm misunderstanding something.

    The injection transformer is wired so that the output is in phase with the input. Then the positive transformer output terminal is connected to R3 on the Vsen+ side. It would seem to me that when the signal generator sine wave output is high, the transformer positive output is high, and so Vsen+ should see a positive perturbation. The control loop should then cause Vout to decrease so that Vsen+ sees the correct setpoint. So sig. gen output goes high, Vout goes low, that's a -180° phase shift.

    However, the actual measurement at low frequencies shows a phase shift of +20° at 500Hz. You pointed out why that makes no sense, and yet it's definitely what the scope says. So the measurement is wrong, but why?

    Here is a sketch of the entire measurement setup:



Some setup clarification:

There isn't a capacitor in series with the injection transformer, that is just a 500mA polyfuse for protection. The wires are just a blue and blue/white twisted pair from some cat3 cable I had laying around.

For each measurement probe on the board, I've soldered a twisted pair to the board and then I wrap those wires around the probe tip accordingly to get low noise measurements. I've found this to be better than using the spring-tip probes by picking up less switching noise and also not requiring so many hands.
 

Offline trtr6842

  • Regular Contributor
  • *
  • Posts: 61
  • Country: us
Re: Bode plot stability testing of buck converter
« Reply #9 on: May 12, 2024, 03:30:53 am »
For why you can't see anything on the "input", there is a signal there, it's just very small at that low frequency.  Your loop gain plot shows 40db of gain at 500hz, so you're going to have even more gain at 100hz.  Clearly there is some signal at the "input", it's just 500x smaller than the one at the "output".  Do the same thing at ~70kHz and you will see the input and output have the same magnitude!  We use that as the input because that's the direction of the "loop". 

The phase will always be off by 180° with this setup because the error amp in the control IC inverts the feedback input.  When we look at a classic plant+feedback control loop block diagram, we measure the loop gain as the plant * feedback, but we do not include the subtraction node.  We do all of our analysis for gain and phase margin ignoring the subtraction node.  So from analysis we expect negative phase, but in practice we have to make our measurements with the inverting error amplifiers in the loop, so the phase is flipped.

This has nothing to do with the polarity of the injected signal.  If you flip your injection transformer polarity you'll get the same results.  The bode plot doesn't care about the absolute amplitude or phase of the injected signal, just the ratio and phase of input to output. 

Every bode plot measurement of any converter made this way will show that flipped phase, it's not something you messed up.  To make the results easier to read, you can invert one of your scope channels.  Or you can just get used to it and make your measurements with respect to 0° instead of -180°
« Last Edit: May 12, 2024, 05:52:35 am by trtr6842 »
Personal website: eedesignpro.com   Contact me
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf