Close

Switched load test with a modified DC-DC converter

A project log for Low-Cost Programmable Power Supply

Chinese "LM2596 DC/DC buck converter with voltmeter" + "some wires" + "Forth" = "programmable power supply"

thomasThomas 03/11/2017 at 16:490 Comments

I modified one of the new "green" DCDC converters along the lines of the solution for a LM2596 based variable DC/DC converter proposed by @K.C. Lee:

This modification replaces the GND of the LM2596 feedback input voltage divider with a variable voltage, controlled by a PWM output of the voltmeter's STM8S003F3P6. The LM2596 compares the feedback voltage with a reference voltage of about 1.25V, and thus adding a bias voltage to the feedback reduces the output voltage of the DC/DC converter

Additional changes were:

With the new firmware, it's possible to establish a half-duplex console session via PC.7 (pin3, DP of the LED display) using a diode (anode PC.7-RxD, cathode TxD). While the session is active, the DP (decimal point) of the 7-LED display remains inactive.

With the Forth script from one of the previous posts, the STM8S main Timer(TIM1) reload value is 1000, and at 16Mhz clock the reload period of TIM1 is T=62.5µs.

For calibration, the output voltage of the DC/DC converter was adjusted to 13V with the trimmer, while the PWM duty cycle was set to 0. The power supply I used is a land-fill grade "wall wart" (i.e. transformer, bridge rectifier, C 470µF, output voltage about 16V), which means that the results can be expected to be on the pessimistic side.

The RC filter used for converting the PWM signal to DC has τ= 47R * 10µF = 470µs. With T/τ= 7.5 the passive filter appears to be sufficient for our needs (33R, or 4.7µF should work, too).

On the serial console, the command line "330 pwm" sets a duty cycle of 33%, which results in a DC/DC converter output voltage of about 3.3V (which is pure coincidence). In order to test the transient response I used a W1209 as a variable pulse generator (10 lines of Forth, including UI, hacked in about 10 minutes, about 30 lines after "beautification"). The NO contact of the W1209 contact switches a resistor of 18R as a variable load.

My trusty old scope (an almost 25 years old Fluke Scopemeter with damaged LCD) reads both the output voltage of the CN2596-2 (AC, 200mV/DIV), and the switched GND of the load resistor. The result isn't pretty. There is an overshoot of 200mV when the load is removed, and the noise under load is quite high (also about 200mV).

For comparison, I repeated the test with an unmodified "green" CN2596-2 adjusted to 3.3V. As expected, both noise, and transient response are much better.

The reason for the much poorer performance is the GND offset of about 1V (33% PWM) in the feedback loop, which forces the output voltage down from 13V to 3.3V. This was expected, as feedback loop amplification is now just about 20% of what it used to be: (1.25V - 1V) / 1.25V = 0.2.

Whether the control performance is good enough, or not, depends on the application. However, the setup represents almost a worst-case situation. If the at 0% PWM the feedback would have been adjusted to a lower value (e.g. 7V), or if the PWM duty cycle would be lower (e.g. 20% PWM for about 9V output voltage), the resulting feedback loop amplification, and therefor noise and transient response, would have been better. In any case, this setup is appears to be sufficient for test automation (especially e.g. brown-out, and bad/noisy power supply simulation).

Level up :-)

Discussions