Hi, I'm Roland van Roy.
In a previous tutorial video I showed you how to make this DC/DC buck converter prototype,
and quickly check the converter stability by measuring the step-load response.
In this tutorial video I'll show you how to measure the converter loop gain and phase, which can
tell you more about the converter stability.
For the test equipment, I'll use a PicoScope with a Frequency Response Analyzer add-on utility.
I'll also show you how to make this signal injection transformer that you need for the measurement.
In this example we'll check the stability of a current mode buck converter, which consists
of a power stage with inductor and output capacitor and the load.
In a current mode buck converter, the internal clock determines the switching frequency and
activates the high side MOSFET.
The current in the high-side MOSFET is sensed and fed with some slope compensation to a comparator.
A portion of the output voltage is fed back to an error amplifier which compares the feedback signal
with a fixed reference voltage and adjusts its output accordingly.
The output of the error amplifier is compared with the current sense ramp,
and the high-side MOSFET is switched of when the current ramp exceeds the error amplifier voltage.
When the output voltage drops due to a load increase, the error amplifier output will increase.
This means that the current needs to ramp higher, so the converter duty-cycle will temporarily
increase, thereby increasing the output voltage to regulate the output back to the target value.
The control loop consists of the modulator + power stage and the feedback network,
error amplifier and compensation.
The Modulator/power stage has a dominant low frequency load pole and a sample & hold high
frequency double pole.
When using ceramic output capacitors, the output capacitor ESR zero will lie at a relatively
high frequency, often above the switching frequency, so you won't see it in this gain-phase graph.
The error amplifier inverts the feedback signal and provides high loop gain at low frequency
to achieve good voltage regulation.
The Ccomp capacitor forms an integrator at low frequency resulting dropping gain.
A zero formed by Ccomp and Rcomp sets the mid frequency gain and provides a phase boost.
The compensation parallel capacitor then forms a high frequency pole to make the system
less sensitive to high frequency noise.
The sum of the modulator and compensator gain and phase gives the total loop gain and phase
The loop gain gradually drops, and the point where it crosses the 0dB is called
the unity gain frequency or crossover frequency.
The total phase shift of the loop should never reach 360 degrees at this frequency,
because this would create positive feedback and make the system oscillate.
A robust design needs a certain phase margin with respect to the oscillation point.
In most current mode buck converters, we set the unity gain frequency around 1/10 of the
switching frequency, which is a good compromise between converter speed and stability.
This is done by adjusting the compensator mid frequency gain: lower compensator gain
reduces the unity gain frequency.
For most designs at least 45 degrees of phase margin is needed.
You can also look at the slope of the gain curve where it crosses the 0dB line
which should be 20dB/decade for good stability.
When you set the compensator zero frequency to coincide with the modulator load pole frequency,
the loop gain drops at a steady 20dB/decade and phase is relatively flat.
Converter loop gain and phase can be measured by injecting a small sine wave signal into
the loop and measuring the converter output signal versus the input signal.
The amplitude ratio of output vs. input is the loop gain and the phase difference between
the output and input is the loop phase delay.
In practice we use a network analyzer or frequency response analyzer with tracking generator.
A small resistor is inserted in the loop and the sine wave signal is applied across this
resistor via a transformer to provide isolation between the equipment and device under test.
The insertion point should have low output impedance and high input impedance.
The sine wave frequency is swept and the input and output signals are measured over the sweep frequency.
The loop gain and phase are calculated and shown versus frequency as a bode-plot.
Gain-phase measurements are often performed using network analyzers or frequency response analyzers.
Drawback of these devices is that they only show the results in the frequency domain.
For this video I'll use a Picoscope and with a Frequency Response Analyzer (FRA) utility.
The advantage of this equipment is that it lets you look at the signals
both in time domain and frequency domain, which gives you a better understanding of the measurement
and can be used to check the converter operation during the gain-phase measurement.
Picoscopes are PC oscilloscopes: The hardware is connected to your PC which runs the Picoscope software.
For the gain-phase measurement, the scope channel A is connected to the loop input and
channel B is connected to the converter output.
Picoscopes have a build-in generator, which is used for the injection signal,
so the generator output is connected to the signal injection transformer input.
You can use another channel to measure the converter switching signal to check the converter
operation at different injection signal frequencies and amplitudes.
In this video I'm using a Picoscope 5444B which has high resolution and low noise floor
which is beneficial for gain-phase measurements, but you can also use the lower end Picoscopes.
The Picoscope Frequency Response Analyzer utility
was developed by Aaron Hexamer who is a member of the Picoscope online community.
He graciously shared his work for free; please see the description below this video for the download link.
After installing the utility, it will search for a connected Picoscope and you will see the main menu.
You can select the input and output channels and probe attenuation.
Since the measured signals are quite small, it is best to use 1:1 probes and settings.
The stimulus sets the generator sine wave amplitude during the measurement.
Here you can set the start and stop frequencies.
Note that low frequency measurements take more time than high frequency measurements.
In the tools – settings menu, you can choose more advanced settings, I'll mention the most important ones:
For gain-phase measurements in switch-mode power converters you should
always choose the noise reject mode.
Minimum cycles captured can be kept around 16: keep in mind that a 1Hz stimulus measurement
would take at least 16 seconds.
Lower noise reject bandwidth will improve signal noise ratio, but requires more samples.
A good value is the minimum measurement frequency divided by the number of captured cycles.
The noise reject time base must be set low enough to get a sample rate
that is at least double the converter switching frequency.
The axis setting menu let's you set the plot scale and grid.
I recommend using symmetrical scales for gain and phase so the zero dB and zero degrees line-up.
Let me first show you how to make the signal injection transformer.
To make a transformer that can achieve a flat response over a wide frequency range you need
to have high primary inductance and very good winding coupling to minimize the leakage inductance.
You can use the core of a high current common mode choke: In this case I used the core of
a coilcraft CMT4 10mH toroid common mode choke.
First remove the plastic and the wires.
For the windings I used a twisted wire pair from a CAT5 Ethernet cable.
For this transformer I needed around 7.5 meters of wire.
Start in the middle of the wire and start winding one end to fill the complete core.
Place the windings tight.
Then start with the other wire end and wind the second layer, finishing close
to the previous finished winding end.
Now separate the twisted wire ends.
Then twist the wires with the same color, to form the primary and secondary winding.
Let's use the picoscope with the sinewave generator to look at the transformer input and output signals.
Connect the Picoscope generator to the transformer input,
connect channel A to the transformer input and Channel B to the transformer output.
Terminate the transformer with 10 ohms.
I have set the generator at 10kHz and 1V peak.
Top blue waveform is input signal, red bottom is output signal.
If the signals are out of phase, just reverse the probe connection at the transformer output.
You can see there is some attenuation from transformer input to output:
this is caused by the transformer wire resistance which is around 2 ohms.
When we increase the frequency you can see the output voltage starts to drop above 100k,
while the input voltage increases.
This is due to the increasing impedance of the leakage inductance
which forms a low-pass filter with termination resistance.
Let's look at the low frequency range:
When going lower than 5Hz you can see some distortion in the waveforms.
This is caused by transformer core saturation: at low frequency the magnetization current
in the primary increases, and the high mu core saturates.
To measure accurately at very low frequencies you should reduce the signal generator amplitude:
A 100mV peak generator setting will not cause saturation.
You can also use the Picoscope FRA utility to measure the transformer input to output transfer:
We sweep from 1Hz to 1MHz.
To avoid saturation set the stimulus at 200mVpp which is the same as 100mV peak.
For this measurement you don't need noise reject mode,
and I set minimum cycles captured at 4 to speed up the low frequency measurement.
You can see from the results that the response is quite flat from 3Hz to 100kHz,
which is good enough for gain-phase measurements on most converters.
If you need flatter response in the high frequency range you can reduce the number of windings,
which lowers the leakage inductance.
Note that you don't see the attenuation caused by the 50 ohm generator impedance in
the FRA result, because the blue reference signal is connected after the 50 ohm generator impedance.
Let's measure the loop gain and phase of the RT7257G 800kHz 5V / 2A buck converter prototype
that I introduced in a previous video, where I used Richtek Designer
to generate the schematics, and showed you how to adjust the compensation gain with respect to the effective output capacitance,
basically to keep the crossover frequency around 1/10 of the switching frequency.
You can also see that the tool has set the compensation zero frequency to coincide with
the converter load pole.
Note that the IC internally has 11pF capacitance from COMP to ground which gives a high frequency pole at 880kHz.
The simulation AC analysis shows good stability:
The crosssover frequency is at 83Khz and phase margin is 62 degrees.
You can see that the gain shows a steady 20dB/decade drop.
The phase starts to drop quickly above 100kHz, and the gain margin where phase crosses zero degrees is 16dB
To verify these results via real gain-phase measurements, we need to insert
the small 10 ohm resistor in the feedback loop of the self-made prototype board.
It is best to place this resistor close to the output capacitors, away from the inductor
to minimize noise pick-up from stray magnetic field.
Then connect the transformer output to this resistor and measure the loop input
and converter output signals with the Picoscope.
Let's first check the loop input and output signals in time domain via the Picoscope in scope mode.
For this measurement, it is best to ground the picoscope to your working table earth connection.
I have set the probes at 1:1.
(please keep in mind that the scope inputs can handle up to 20V).
I set channels A and B at 20MHz bandwidth limit.
Don't connect the probes with long ground wires directly to the measurement points:
the inductor stray-field will couple noise into the probe loops.
It is better to bring the two measurement points and ground away from the inductor via
a three wires twisted together, and connect the probes here, which reduces noise pick-up.
I apply a 5 ohm load to the converter, for a 1A load current.
This will keep the converter in continuous condition mode, which is the operation mode
we want to check for stability.
I set the generator at 1kHz and 500mVp which gives a transformer output signal of around 90mVpeak.
Before we switch-on the converter, the output signal is basically grounded
for AC signals due to the converter output capacitors, and you only see the loop input signal.
When we switch-on the converter, you now see that the converter generates an output signal
which basically cancels the injection signal, so the loop input signal is almost gone.
At 1kHz, the loop gain is very high so the ratio Vout over Vin is very large.
It's also a good idea to look at the converter switching signal,
to see the effect of the injection signal on the converter duty-cycle.
Note that when you connect Channel C probe directly to
the switching signal channels A and B show more noise.
This is caused by the capacitive current in the Channel C probe which induces ground noise
that influences the other channels.
It is better to measure the switching signal by capacitive pick-up:
place the isolated probe tip close to the switching node.
Now you can see the switching signal without inducing noise in the other two channels.
When you trigger on the switching signal you can see that at 1kHz injection signal,
the converter duty-cycle hardly needs to change to generate the 90mVp output signal.
Let's increase the injection signal frequency: you can now see that the converter input signal
slowly increases, which means that the loop gain reduces.
Above 30kHz, you also see that the switching signal duty-cycle varies more.
This is caused by the attenuation of the Buck LC filter above its resonance frequency:
At higher injection frequencies the converter will need to increase the duty-cycle swing
to generate the sinewave output signal.
At 200kHz injection frequency you now see that the switching signal duty-cycle
shows extreme fluctuations, hitting minimum and maximum duty-cycle limits,
and at some points the converter even goes into discontinuous mode.
For accurate Gain-phase measurement results, the converter operation must stay within
its linear operation range over the entire sweep frequency range and should not switch from
one operation mode to another.
To accomplish this reduce the injection signal amplitude
to keep the worst case duty-cycle variation at moderate levels.
By showing the the switching signal in persistence mode and sweeping the generator frequency
from 10Khz to 200kHz you can easily check the duty-cycle variation.
In this case 100mVp injection amplitude keeps the converter duty-cycle variation within acceptable limits.
You can see that the input and output sinewaves have equal amplitudes around 80kHz injection signal frequency.
It means that the converter unity gain frequency lies around this frequency.
We can now use the FRA utility to measure the converter loop gain and phase accurately.
I set the injection signal at 200mVpp, sweep from 100Hz to 1MHz with 100steps per decade.
In advanced settings choose the noise reject mode, set minimum cycles captured at 16,
noise reject bandwidth at 6Hz, and Noise reject time base at 52 for 2.5MHz
noise reject sample rate to avoid aliasing with the 800kHz converter switching frequency.
I set symmetrical vertical scales with similar values as the simulation result.
The plot shows that the gain indeed drops at a steady 20dB/decade up to the crossover point.
At low frequency, the plot shows some noise:
this is due to the very small input signal amplitude in the high gain region.
In the high frequency area, the phase drops fast and wraps around the plot.
You can unwrap the phase if you want.
Check the phase margin and gain margin boxes to show the values in the plot.
Use the mouse to zoom in: The crossover frequency is 78kHz ,
the phase margin is 52 degrees and the gain margin is 13dB.
The simulated values showed slightly higher phase margin: 62 degrees.
This difference is probably caused by tolerances or model inaccuracies.
Just to show you what will happen when you use too large stimulus amplitude we set the stimulus at 1Vpp:
you now see that the curves show irregularities in the mid and high frequency area
caused by converter non linear behavior.You also see lower crossover frequency and higher phase margin.
It is best to always check the time domain signals before running the FRA.
You would expect that at higher load, the load pole will shift to higher frequency and
result in a higher crossover frequency.
But this is not the case, because higher load will also reduce the modulator gain,
and the crossover frequency will remain unchanged.
An actual measurement at higher load shows a lower crossover frequency and better phase margin.
This is caused by temperature drift of IC internal parameters
due to the higher silicon die temperature at higher load.
Note that at very light load, RT7257G will automatically enter discontinuous pulse skipping mode.
In this mode, the error amplifier is bypassed and the IC regulates on the output ripple valley.
Gain-phase measurements in pulse skipping mode can give in strange results and are not really meaningful.
Let's have a look at a marginal stability case:
I increase the compensation gain by increasing Rcomp from 15kΩ to 33kΩ.
This will push the cross-over frequency to a higher value, into the region
where the phase has dropped quickly.
It will result in very low phase margin.
Before we run the FRA let's quickly double check the signals in time domain:
We sweep with 100mV peak generator amplitude in persistence mode.
You can see that the duty-cycle in the high frequency range shows much larger deviation than before.
Due to the lower phase margin, the converter will now show a tendency to oscillate around the crossover frequency.
This results in peaking of the stimulus signal around this frequency, and leads to larger duty-cycle variation.
For accurate results, we need to reduce the stimulus more to keep the duty-cycle variation moderate.
In this case I reduced the stimulus to around 30mV peak.
We can now run the FRA set stimulus at 60mVpp which is the same as 30mV peak.
The FRA clearly shows a higher crossover frequency and worse phase margin: 115kHz and 26 degrees.
This is not a good design and you should reduce the compensation gain
to reduce the crossover frequency and get better phase margin.
I recommend checking the converter load step response as well.
Here I'm using the Richtek Fast Load Transient tool to apply a 1A static load
and a fast 1A load step by selecting the 4.7 ohm dynamic load resistor.
I measure the converter load current and output voltage response.
You can see the step load response shows severe ringing, which is a clear sign of insufficient stability.
The ringing frequency will normally be slightly higher than the converter crossover frequency.
In this case I measured 138kHz ringing frequency.
I hope you found this video helpful.
Please stay tuned for more tutorial videos at Richtek, your power partner.
Không có nhận xét nào:
Đăng nhận xét