A Dollar Store Switch Mode Buck Power Supply

Karl Berger, W4KRL

While cruising the aisles of a newly opened dollar store I discovered an automotive cigarette lighter adapter with two USB connectors to charge a cell phone or other device. The nameplate claimed that it can provide 1 amp at 5 volts. I bought a couple with the intention of tearing one apart to see what was inside. My experience with other dollar store products led me to expect poor quality construction with unmarked parts and little hope that anything useful could be learned. The dollar store unit (DSU) turned out to have a few surprises. First, it was very easy to open even without tools. The case pried apart after unscrewing the ferrule that holds the fuse. Inside I found a small printed circuit board with a few resistors, disc and electrolytic capacitors, something that looked like it might be an inductor or transformer and an 8-pin DIP integrated circuit. The next surprise was faintly visible markings on the IC. It took a magnifying glass and some guesswork to decode the part number as MC34063, a versatile switch mode converter made by a number of companies with datasheets readily available on the Internet[1]. And then a real surprise - several of the datasheets had schematics for a 12 Volt to 5 Volt converter with parts values identical to the DSU!

The unit is useful as is. A lot of amateur radio stations these days use 12Vdc for their rig power and have 5V accessories. However some accessories often use 6, 7.5 or 9Vdc. A modified DSU provides an efficient and very inexpensive way to power lower voltage accessories from a 12V bus. It turns out that only a few simple modifications are needed to adapt the unit to another output voltage. The job is made even easier by using one of the design tools available on the Internet[2]. First, let’s modify the DSU then look into the theory and design.


The Modification

The amplified speakers for my station computer use a 9V battery so I modified the DSU to output 9V with 12V input. I also tried to reuse as many parts as possible. For example, RSC in the DSU is a current sense resistor with a value of 0.22 Ohms. Equation 7 below tells us that this will limit the peak switch current to 1.36A. Equation 6 says that the peak switch current is twice the output current so maximum is 0.68A, not the 1 Amp nameplate rating but more than enough for most 9V applications. Let’s keep RSC as is. To make a long story short, we are only going to change the voltage feedback resistors (R1 and R2) and the dropping resistor for the LED (R3). The design formulas calculate the minimum values for the inductor and output capacitor. You can reuse the stock components as long as they are larger than the calculated values. You can try changing the frequency to bring the calculated values in line with the stock components. This would require changing the timing capacitor CT.

To modify the unit take off the fuse ferule and pry apart the case. Unsolder the fuse spring, the wired-in USB connector (JB) and the one mounted on the circuit board (JA), resistors R1, R2 and R3, and any wires remaining on the board.

The LED on my DSU was soldered to pads on the back side of the board so that it would not interfere with the USB connectors. To remount the LED to the thru-holes provided on the board, remove the LED and be sure to remember the polarity. There is probably a flat on the cathode side of the cathode side. Reinstall it in the thru-holes.

For 9V operation replace the resistors as follows: R1 = 1K, R2 = 6.2K, R3 = 1.2K. I didn’t have a 6.2K resistor for R2 so I used 5.6K. That reduced the output voltage to 8.25V which is no problem for most 9V devices.

While you are at it you should dress up any of the original components that may be poorly mounted or soldered. I routed the output wires through existing holes in the board to provide some strain relief.

Test your modified unit before going any further. My first test failed because I had the LED in backwards but it didn’t work even after fixing that error. It turned out that the DSU used the shell of the USB connector to pass a ground connection between traces on the board. The unit worked perfectly after soldering in a jumper.

Mounting the modified unit is a personal choice. If you are going to use it in a car then you may come up with some modification of the original case. DO NOT use the USB connectors for any voltage other than 5Vdc; that would be bad practice and you will eventually burn up some expensive device if you plug it into the non-standard voltage. Since everything in my station uses the ARES standard PowerPole connectors, I decided to mount my modified unit on a short length of cable connected to an Anderson PowerPole. A piece of 0.75-inch heat shrink tubing mechanically protects the unit. It looks a little like a snake that swallowed an elephant but it works.


Theory

A little theory will help explain how the converter works and how it can be adapted to other voltages, both input and output.

Switch mode converters come in several varieties generally categorized by the relationship between the input and output voltages. The DSU is configured as a step down or “buck” converter[3]. It reduces or bucks the input voltage to produce a lower output voltage. The chip can be configured as a step up “boost” converter to raise the output voltage above the input voltage. A third configuration produces an output voltage of opposite polarity to the input voltage.

The buck configuration is easy to understand in terms of pulse width modulation[4]. All switch mode converters have a semiconductor switch and one or more inductors or capacitors as energy storage devices. The switch in the MC34063 is the NPN transistor between pins 1 and 2. L and C are the energy storage elements.


The switch can be turned on and off very rapidly and the ratio of the ON duration to the cycle time will determine the ratio of the average output voltage to the input voltage Vout = Vin * ton / (ton + toff).

When the switch is ON the voltage across L1 will be the input voltage minus the output voltage (Vin – Vout) and the current through the inductor will increase at the rate of (Vin – Vout) / L amps per second[5]. When the switch is OFF the inductor will try to keep the same current flowing. Diode D1 provides a path for the current out of the inductor. A diode used like this is often called a freewheeling, flyback or catch diode[6]. Now the voltage across the inductor is –Vout and the current will decrease. The output capacitor CO smoothes out the current ripples to maintain a fairly even output voltage that averages the switched voltage. It is interesting to note that some ripple is required to keep the comparator in the MC34063 actively regulating the output voltage.

Notice there are no deliberate resistances or voltage drops in the circuit so there is no power loss. Since the input power equals the output power the input current will be lower than the output current by the same ratio as the output to input voltage. This is a important advantage of a switch mode converter over a conventional linear regulator where the input current equals the output current and a significant amount of power is lost in the transistor in series between the input and output terminals.

Of course in the real world things are not perfect. The inductor has series resistance, the transistor has a saturation voltage, and the diode has a forward voltage drop. Fortunately, these values are all easy to determine and account for. In practice, it is only necessary to slightly modify the ON/OFF ratio to compensate for these losses. Generally the resistance of the inductor is negligible leaving only the semiconductor drops:

Vout = (ton / (ton + toff)) * (Vin - Vsat - VF)

Converter theory and development of the design equations are nicely explained in ON Semiconductor applications note AN920[7].  The following table summarizes the design equations for the buck converter configuration of the MC34063.


References

[1]MC34063 datasheet http://www.onsemi.com/pub_link/Collateral/MC34063A-D.PDF

[2]MC34063 calculator http://dics.voicecontrol.ro/tutorials/mc34063/

[3]Buck Converter http://en.wikipedia.org/wiki/Buck_converter

[4]Pulse Width Modulation http://en.wikipedia.org/wiki/Pulse-width_modulation

[5]Inductance http://en.wikipedia.org/wiki/Inductance

[6]Freewheeling diode http://en.wikipedia.org/wiki/Free_Wheeling_Diode

[7] Theory and Applications of the MC34063 http://www.intusoft.com/onsemipdfs/AN920-D.pdf