Thursday, February 01, 2007

What Really Matters: Power

This blog was supposed to be about engineering, but there hasn't been a shred of anything remotely scientific here for months. So with this realization-- suspiciously coincidental with the turning of the new year, but let's not make this a Hallmark moment--I have decided to stop talking about my feelings and buckle down to business.

Living in another country and having to adjust to the wall supply of nearly twice the voltage and 10 cycles per second less, I've been thinking about compact efficient power converters. This may be foreign to the younger crowd who's grown up on the 100-240V universal power supplies that power nearly every electronic device these days (notably excepted are those by Nintendo and Microsoft, who were willing to accept the monetary losses of region-specific hardware in order to make our lives more difficult) but if you ask a parent who's used an electric razor overseas--try your dad first--he will probably tell you he bought an over-sized plug which served the dual purpose of physically changing the interface as well as make the razor run instead of smoke.

Phase Control Converters

What's going on inside one of these doohickeys is probably a simple TRIAC circuit. The circuit is set so that it will periodically (mathematically speaking) chop off a portion of the sinusoidal 220V RMS input signal such that the resulting waveform will have a 120V RMS voltage.

In the figure above, the RMS power of the red curve is identical to that of the pure blue sine wave, even though its maximum amplitude is 85% of the red curve. The angle of the delay when the red curve turns on is called the conduction angle α, and this type of power controller falls into the aptly-named class of phase control circuits. The waveform is not a sinusoid anymore, we say it exhibits harmonic distortion, which means the spectrum of this wave has components at frequencies other than 50 or 60Hz.
I've plotted the first nine harmonics of the red waveform above referenced to the power of the first harmonic. The sum of the powers of all the harmonics higher than the first as compared to the power of the first is called total harmonic distortion, or THD.

When the mains line has a lot of harmonic distortion, we colloquially say the power is dirty. Not only is the harmonic distortion a problem, the stock version of this circuit which constitutes all the cheapo power converters out there also has a problem driving certain types of loads which we will discuss in a second.

RFI

We've got so many electronic gizmos these days we have to make sure they don't interfere with each other; specifically, the device must avoid emitting Radio Frequency Interference. I'm not sure if there's a concrete difference between RFI and Electro Magnetic Interference, they seem to be used interchangeably. The FCC--the happy branch of government that's currently slicing and dicing our mm-wave band so we'll be able to stream HD video to our TVs wirelessly--has strict requirements on how much junk a device can radiate into the air. Turn anything electronic over (I just turned my iPaq over and it says FCC ID:NM8BG) and you'll see some sort of obligatory certification from the FCC. This is also why we're not going to see an iPhone for like, forever. That thing is stuffed with so many chips and antennas, the events in Contact will be precipitated by someone posting some video she just edited on her iPhone to YouTube while her iTunes song paused so she could accept an incoming call with her Bluetooth headset, all the while sending an email. I'm pretty sure Jules Verne didn't call that one, at least not to the extent to which we're taking it.

So the problem with chopped sine waves is the sharp transitions mean substantial high frequency content. This high frequency content is on wires and devices that were not originally designed to carry it, thus are not shielded and so the junk radiates off into space, hungry to make your garage door open. (or stranger things, Google it)

Not only is harmonic distortion bad for the environment, it's not good for the device it's powering. For non-electronic appliances, the surges in current which follow the steps in voltage put stress on the wiring and components. This causes losses due to wire heating and the device itself may not last as long. For devices with transformers, not only does the circuit require slightly more advanced phase control (see below) the harmonics do little other than heat the windings and possibly saturate the core, which leads to greatly reduced efficiency.

Electronic devices are also sensitive to dirty power. Switching power supplies often have compensation called Power Factor Correction circuitry at the mains input, which try to make the supply look as much like a resistor as possible. This circuitry, which is FCC-mandatory for supplies over 75W, tries to compensate for the fact that the bridge rectifier in a Buck converter draws current in pulses rather than continuously. A passive PFC circuit is similar to an RF impedance matching circuit. In these passive filters there are capacitors, which have ripple or pulse ratings that are different than DC maximum voltage ratings in that they specify how well the capacitor tolerates transients. When you supply dirty power you are directly challenging this rating, and the caps might just pop.

An active PFC is actually a Boost converter placed right after the bridge rectifier, which dynamically adjusts its output voltage based on the input voltage so that the mains current will be drawn proportionally. This is also why we have universal power supplies: with a single Buck converter we are unable to accommodate a 100-220 input range, but if we use a Boost-Buck topology, we have enough added flexibility with the intermediate voltage that the input range is widened. In any case the bridge rectifier doesn't care about whatever kind of voltage waveform we give it, but the Boost converter does, and at the very least it will run less efficiently.

Inductive Loads

Another problem with phase control supplies is the load has to be well-behaved. Ever notice how the converters explicitly say "non-inductive loads only"? The OK list includes electric razors, water heaters, light fixtures, hair dryers, and coffee makers whereas it's not OK to attach an electric fan, blender, or basically anything with a big motor in it. This is due to the reluctive (do we say that? As in, a reluctive impedance has a positive real part as opposed to a reactive impedance, which has a negative real part? Let me know) impedance of an inductor. Turns out when you apply a sinusoidal voltage to an inductor, current will also be sinusoidal but delayed, the exact time of the delay depending on the inductance and frequency.
The TRIAC is a voltage triggered switch, because the purpose of the circuit is to generate an RMS voltage, not current. On the other hand the TRIAC turns off when the conducting current drops below a certain value. So we have two statements:
  1. The "ON" period of the TRIAC starts when the mains voltage reaches a trigger value, and ends when the mains current drops below a certain value.
  2. With inductive loads, there is a variable amount of phase shift between voltage and current.
This results in some whacky behavior when the TRIAC circuit wasn't designed to account for this variable phase shift.


As much as I don't like these TRIAC and SCR circuits from an aesthetic perspective, they aren't going anywhere. Turns out we can make SCRs capable of handling heinous amounts of power, many many many many kW. For industrial heating applications like furnaces and welders, it's the most efficient way to regulate their power. Moreover even for big motors, there are ways to make sure the switches operate properly with a bit of control circuitry.

The Problem

As it just so happened, I got an American Xbox 360 while I was in Europe, and the jerks at Microsoft make the power brick 100-120V only. (Japan and US/Canada) It continuously draws 180W, which is more than my Mac Mini AND laptop AND monitor draw put together. Given that thing is big enough to backstop as a tire block you'd think they'd make it multinational. Jerks.

A phase control converter just isn't going to cut it. First, the radiated EMI is going to be huge. Just like light dimmers hum when the lamp is not set to full brightness, every piece of audio equipment nearby--and possibly the power cord connecting the Xbox--will hum loudly. Furthermore, the Xbox power supply is notoriously sensitive to dirty power, and when it's not happy the brick shuts down and you'll lose that 3.2GHz triple-core of awesome computing power.

The simple recourse is to buy a step-down transformer. This is the no-brainer brute force solution in every possible sense; you take two inductors, couple them magnetically, and thanks to a lot of theory a sine wave should pass losslessly from one to the other. It's also monstrous, heavy, and in fact does waste a bit of power. As an added bonus now you've got very clean but nonetheless strong 60Hz EMI radiating from that little beast and probably some mechanical noise from the windings vibrating, unless you pay big bucks for a nicely shielded and mechanically dampened transformer. As a side note, feeding a transformer dirty power is a great way to make it sing in all sorts of funny ways.

The Solution

Here comes the awesomeness of electronics, it's very exciting. Let's start with a basic Buck converter. It takes a DC input voltage, and produces a DC output voltage of lower potential. What if instead of fixing the output voltage, we tell it to produce 220/120=0.545 times the input voltage? Then if we get a 220V RMS sine wave in, we'll get a 120V RMS sine wave out. This isn't the optimal solution because the output integrity of the sine wave is entirely dependent on the input, but knowing that this will only be plugged into AC mains we can overlook this. If we were cooler, we would take the input voltage, rectify it to some intermediate filtered DC voltage, then reconstruct a 120V RMS pure sine wave at the output. But we'll leave that to the UPS guys. No, not that UPS, this UPS.

There are a few implementation hurdles to overcome. First, we'll need to make sure the feedback control of the converter works properly with a 60Hz AC reference, which actually shouldn't be a problem since DC converters normally have a high enough bandwidth to reject AC line ripple. The other is to make a bipolar switch to accommodate an AC input. A generic buck converter looks like this:

The problem with this converter is it can only convert higher potentials to lower ones, i.e. it has unidirectional power flow. During half the sine wave that's not true. Either we will have to do some fancy switching at the input of the converter, or we will need to make a bidirectional buck converter. Here is a slight modification to the topology that allows this:
Our input to the switches is full-wave rectified AC, broken into two alternating phases.
Then, we drive the switches like this:

Phase1
ϕ1:d ϕ2:0 p:1
Phase2
ϕ1:0 ϕ2:d p:0

In phase one, the upper left MOSFET and lower left diode form the Buck converter, and the lower right MOSFET is the return path. In the second phase, the upper right MOSFET and lower right diode form the Buck converter, and the lower left MOSFET is the return path. By switching between phase one and two, the load sees an alternating polarity.

Even this simple circuit isn't a piece of cake. Because this device will be working off 220V mains, the sine wave has a peak voltage of 310V. For safety margins, the absolute minimum voltage rating of all the devices should be 500V but no commercial product would use less than 600V. Turns out 600V is high as mainstream MOSFETs go, and they get expensive. Although working at a cocaine plant might be a different story, when you work for a large electronics company you get a few perks, one being free samples. So getting the switches for this circuit shouldn't be a problem. Now I just have to design the drive electronics.

To be continued... feedback controllers, snubbers, resonant conversion and novel power supplies.

As an aside if I ever got into a position of extreme power at the IEEE, for fun one year I would mandate that all papers submitted for the ISSCC (International Solid State Circuits Conference) may not contain any instances of the following words/phrases:
  • new
  • novel
  • adaptive
  • high-performance
  • mitigate
  • investigate
  • any restatement of Moore's Law
  • ultra (unless the word immediately following is "sucky", because let's face it sometimes breaking the monotony is fun)
This is nowhere complete, but with just these changes I would watch a normally 800+ page publication shrink to the size of a Newsweek. Just to clarify: if you're shooting to get your work published in the world's premiere circuits journal, there is absolutely no reason to include the phrase "high-performance" in the TITLE! Do you think they're going to let you publish An All-Digital PLL with Narrow Lock-Range, Above-Average Performance and Middling Power Consumption?

1 comments:

Satya said...

hi, i came across your post while searching for info using a dirty power supply as an input to the xbox 360. my country uses 230-240v and i can get a relatively cheap step-down transformer to get the 110v input. But the transformer outputs non-sinusoidal waveforms. Do you have a sense of whether the xbox360's power brick can handle harmonics in the input power waveform? with such a huge power rectifier i am hpoing they have a decent capacitor filtering out high frequencies before and after rectification. cheers.
satya