Noise of a straining transformer

02.09.2010 17:38

My lab power supply is now almost complete. It passes most tests I throw at it with flying colors except for one. When the output is even moderately loaded the toroid mains transformer is giving off a loud 100 Hz hum.

This is usually a sign that the windings are badly overloaded. Another warning sign that pointed in that direction were the thyristors in the preregulation stage that were dissipating more heat than I anticipated. This called for further investigation.

This is how the voltage on transformer secondary (blue trace) and capacitor (yellow) look like when the power supply is in short-circuit with current limit set to maximum. The gray trace shows transformer voltage when the power supply is idle for comparison.

Transformer and capacitor voltage oscillogram

The preregulator is working correctly here - it fires the thyristors in the correct moment so that the sine wave charges the 4700 μF tank capacitor just enough to replace charge lost due to load current during the previous cycle.

But that voltage drop on the transformer looks worrisome. Adjusting my SPICE simulation so it matches these measurements it gives peak transformer current at 17 A and RMS of almost 7 A. This is quite a bit above the 4 A RMS specification of the transformer.

Although I don't trust these simulation results completely they do confirm that components are getting overloaded. This is much more current than I accounted for in the design - I was counting on the stray inductance of the transformer and capacitor ESR to dampen the response a bit. With such current spikes it's no surprise thyristors are heating up.

The solution I'm looking into right now is to put a couple of power inductors between thyristors and the tank capacitor. They should provide enough reactance to smooth out the current.

Unfortunately to lower the RMS current all the way down to 4 A I would need a pretty big inductor. Bigger in fact than I'm willing to invest into right now, considering these things cost and arm and a leg to ship to this end of the world. For a start I'm ordering a pair of cheap bobbin-types from eBay. Although they shouldn't be enough according to SPICE at least I will be able to more accurately estimate the correct value.

Here's the simulation with the 680 μH inductor in place:

Simulated transformer and capacitor voltages

Green - voltage on transformer secondary. Blue - voltage on the tank capacitor.

Simulated transformer current spike

Current through the transformer secondary.

So, a few lessons learned: with a thyristor regulator RMS current can be even 3.5 times higher than the rectified DC current (compare that to the 1.6 derating factor you usually see on transformer datasheets). To get that down to a reasonable level you need expensive inductors, which eliminates one of the advantages over switch-mode regulators.

Posted by Tomaž | Categories: Analog | Comments »

Slices and dices

31.08.2010 19:33

Somehow this little corner of Python successfully evaded my discovery until now. Did you know there's a slice object that describes how an array is sliced? It can be passed in most places where a start:stop construct would go.

For instance:

>>> b = range(10)
>>> b[2:4]
[2, 3]
>>> a = slice(2,4)
>>> b[a]
[2, 3]

But more importantly, also:

>>> from operator import itemgetter
>>> f = itemgetter(slice(2,4))
>>> f(range(10))
[2, 3]

Which somewhat expands the usefulness of itemgetter in combination with itertools functions for efficient inner loops.

Interestingly, start:stop doesn't actually construct a slice object, so this:

>>> a = 2:4

is a syntax error. Funny. As far as I know this is the only place where Python's everything-is-an-object philosophy breaks. I would expect this to create an object just like a comma transparently generates a tuple.

Posted by Tomaž | Categories: Code | Comments »

Lucid Lynx automatic updates

29.08.2010 11:22

In case anyone else will find this helpful: my mum's laptop stopped receiving automatic update notifications after upgrade to Ubuntu 10.4. After digging through the lengthy pipeline that sits between an updated package available on an Ubuntu mirror and a window popping up on the screen the fix was trivial: somewhere during the upgrade process the /etc/cron.daily/apt script lost its execute permission bit. So to fix only run:

$ sudo chmod 755 /etc/cron.daily/apt

Oh, and there's a bug open on Launchpad, of course: #390319. However it's quite impossible to find it unless you know exactly what you are looking for. Search for "automatic updates not working" or something similar just gives you hundreds of forum threads full of clueless people blindly guessing at solutions to this and similar problems.

Posted by Tomaž | Categories: Code | Comments »

Unexpected failure mode

23.08.2010 20:55

Remember the explosive disassembly of a halogen light on my table? The light bulb I replaced the exploded one with also failed in an interesting, unexpected, although silent way.

Interesting failure mode of a halogen light bulb

It appears that the entire, intact filament got detached from the base. Not something you usually see in a burned-out bulb. It's the filament itself that breaks first in most cases.

Any engineers from Philips here? Consider this a bug report.

Posted by Tomaž | Categories: Life | Comments »

HP NMOS-III

13.08.2010 18:43

Last week when I wrote about the Hewlett Packard 9000 I stumbled upon the High-Density Interconnect handbook. I got intrigued by a caption mentioning "stacked transistors" in relation to the HP FOCUS microprocessor that the 9000 series used. I went and dug a little deeper to see if I could find out what was meant by that phrase.

At that time HP was using the NMOS-III fabrication process, which was the successor to the NMOS-II. This was a 1 μm, two-metal layer process designed specifically for their new 32-bit 500.000 transistor FOCUS microprocessor.

I found a pretty detailed description of the technology in the HP Journal. The August 1983 issue is dedicated to the VLSI process while September 1987 deals with higher-level microprocessor architecture. Both are an interesting read for anyone that is into vintage integrated circuit technology.

Illustration of the NMOS-III process (from HP Journal, August 1983)

For instance, unlike CMOS circuits of today NMOS digital circuits had relatively large output impedance and drew a large quiescent current. First property became apparent when chips where unable to drive long PCB traces. This was especially problematic for the system's 18 MHz clock which had to be distributed throughout the computer. So they made a dedicated clock generator chip with gigantic output transistors (55 mm gate width!) and mounted everything on finistrates - special printed circuit boards with wire bonded dies, very small vias and very high-quality Teflon dielectric - all to decrease trace inductance as much as possible. Finistrates also helped solve the heating problem by having a thick copper core which conducted heat away from the components.

Remember the "self healing" RAM they mention in that advert? That was achieved with special polysilicon fuses which allowed the RAM chip to isolate defective parts by melting a part of the interconnect. Oh, and RAM used a four-transistor dynamic cell, unlike one-transistor commonly used today.

Fascinating stuff. Especially considering this was all published in a journal and not kept as a closely kept company secret.

However I didn't find what I was looking for. There is no mention of transistor stacking. On thing is clear though: NMOS-III process certainly did not have any provisions for vertical stacking of transistors (which is rare even today). So that caption most probably referred to some kind of circuit topology.

Posted by Tomaž | Categories: Digital | Comments »

Lenticular stickers

09.08.2010 21:06

Some time ago the office laser printer ran out of juice. When the replacement toner arrived I found the packaging more interesting than the black powdery stuff inside. It appears some serious effort went into making sure these really are genuine cartridges.

What caught my eye were the really nice security holograms, or more correctly, lenticular prints. I just had to take a few home for further study.

Sticker with lenticular print on a piece of cardboard

First I wanted to try how hard it is to remove one of these from the cardboard box in one piece. Note how it has cuts in it to make that harder.

It turns out its really simple - just put it in a glass of water for a few minutes and it basically floats off.

Sticker with lenticular print from a HP toner cartridge

So while recycling stickers may be simple, replicating them is probably pretty hard. These things are wonderful examples of some pretty high-resolution printing.

First you have a microprint that rivals that of banknotes. And then there's the lenticular print which works in vertical as well as horizontal direction. The hemispherical lenses are so small that they are invisible to the naked eye and appear as a smooth matte surface. There's no visible pixelation or signs of image interlace. Compared to the usual examples of this technology, these stickers really stand out.

Here's a video demonstration of how good they look:

(watch the video on YouTube)

Makes me think that if you have the technology to counterfeit HP toner you can probably go straight to printing money and skip the middle-man.

Posted by Tomaž | Categories: Life | Comments »

One diode patent

05.08.2010 21:07

Everybody is talking about software patents and how big USA sue-me-sue-you companies are acquiring them in bulk for the most trivial methods and algorithms. Here's something that made me think that perhaps the "One click shopping" problem isn't limited to just the world of software.

Cut-out from Charging Specification for VL Series

This is a cut-out from Panasonic's Charging Specification for VL Series for their rechargeable Vanadium-Lithium batteries:

Notice the little notes below the schematics saying "Patent acquired"?

A couple of things don't make sense here. First, these circuits are so simple that most electronics engineers would probably came up with them given the specifications. There are a few circuits in that document that are actually more complicated than these and aren't marked as patented.

Secondly, why patent these in the first place? Isn't the goal of the manufacturer of batteries to sell as many as possible? Scaring potential costumers with potential for patent infringement in their products seems like bad practice. Is it just to prevent a rival from patenting it first?

Then again, after some searching on Google patent search I was unable to actually find the patent application for these.

Posted by Tomaž | Categories: Analog | Comments »

27 years later

02.08.2010 19:29

Recently I came across this vintage advertisement for a Hewlett Packard 9000 computer at the (virtual) HP Computer Museum:

Hewlett Packard 9000 advertisement

The ad is quite an interesting read. For instance it mentions that the computer's integrated circuits used NMOS technology, which provided for copious amounts of heat, which in turn required a special PCB.

It's also interesting to compare it with this modern advertisement that happens to be on my table at the moment:

Microway advertisement

I can't help but think that the HP advertisement tries to help you make an informed decision while the new ad blinds you with bulleted lists full of trademarked names and buzz words. HP says they use a memory controller that can correct 32 bad memory locations, not that they have a SuperSelfHealMemTech™. Also it seems like HP advertised these computers to people that will actually use them (note how they mention finite element analysis, systems of equations, etc.) not some IT management that is only looking for a good deal on gigabytes per monetary unit.

Oh and HP 9000 name was more recently recycled for a series of printers. How sad is that?

Update: Figure 1 in the HDI Handbook I linked above says "HP FOCUS chip ... NMOS III (stacked transistors). What is "stacked transistors" referring to here? I can find no mentions of HP NMOS III process using any kind of vertical transistor stacking like ST-CMOS.

Posted by Tomaž | Categories: Digital | Comments »

Leaky thyristors

29.07.2010 19:52

As you might remember, my lab power supply in-the-making utilizes a thyristor pre-regulator stage. When I soldered the circuit together on the final version of the printed circuit board it had an interesting glitch. Occasionally it would get into a mode where the regulation circuitry completely failed to work, pegging the output voltage to the maximum with ill effects to the longevity of the linear regulator down-stream.

The solution, as you will see, was simple, but the exact cause still puzzles me.

This is the critical part of the circuit:

Simplified thyristor regulator diagram

Here you see the transformer with a 30 V secondary and two full rectifier bridges with a common return path. The lower bridge simply produces a pulsating voltage (SYNC) serving as a synchronization signal for the control circuit. The upper bridge creates the regulated voltage over the tank capacitor. It has thyristors instead of diodes on the positive side which are triggered in the right moment with current provided by the control circuit.

Now here's what it looks like on the scope:

Thyristor regulator oscillogram

The regulator is working correctly on the left half of the picture. Set point is 8 V (as shown by the yellow trace) and almost no load. The control fires thyristors when the AC waveform on anode falls a little bit above 8 V (just before the blue or gray trace crosses the yellow trace) to cover for the negligible loss of charge on the tank capacitor.

But what happens at the third cycle? The gray thyristor fires at the correct moment, however the blue thyristor fires as well as soon its anode voltage gets high enough, charging the output capacitor way above the set voltage.

The immediate reason for this fault is because the combined blue and gray lines never fell to 0 V at the same time. Here's a close-up of the oscillogram: you can clearly see that the blue and gray waveforms intersect at 8 V, not 0 V. Since the control circuit depends on the SYNC signal (which basically provides max(Ublue, Ugray) function) falling near zero it never switches off the trigger current and mistakenly triggers the blue thyristor too soon.

Thyristor regulator oscillogram, detail

So the blue thyristor firing is a secondary effect. The problem already shows itself well before that, when the gray voltage gets pegged at 8 V. So what's happening here?

If it weren't for the SYNC bridge the blue and gray voltages would be weakly defined when the voltage over the transformer secondary is less than 8 V because all diodes in the bridge would be closed. However, the SYNC bridge diodes are conducting down to 0.7 V above ground, so the voltages should not be floating at 8 V as the 10 kΩ resistor makes a good connection to the ground.

Take a look at the instant marked with the red line. Here are the voltages at that instant on all the active components:

Thyristor regulator diagram, annotated

Note that the voltage on the SYNC bridge's 10 kΩ load is 7.4 V, meaning 0.7 mA is flowing through it.

Kirchhoff's current law says this current must come from somewhere. Where? At that moment voltages on all elements point away from the bridge, so it can't be a large leakage current because it would point into the wrong direction.

The only exception is the blue thyristor, however it would have to leak pretty badly to account for almost a milliamp of current. These thyristors are rated at 1 mA reverse current at 800 V. And furthermore it appears as if the current starts the moment trigger current starts flowing into the gate.

As I said, the practical discussion ends with the finding that some stray source of current is affecting the circuit. The obvious solution is to decrease the load resistance of the SYNC bridge so far that it is able to sink the additional leakage current. And it worked - after decreasing the resistance to 5 kΩ the problem went away.

However, the underlying cause of this anomaly remains a mystery to me.

Posted by Tomaž | Categories: Analog | Comments »

New Nelma release

27.07.2010 12:27

This is a kind of a late announcement: A few weeks ago I released version 3.2 of Nelma, the numerical electromagnetics package. Changelog isn't very impressive, with the most significant change being a patch that fixes compilation on libpng 1.4.x (contributed by Thomas Klausner of the NetBSD's pkgsrc team).

To put some light in this almost forgotten project, here's a brief description:

Nelma is a command line tool for numerically calculating various electrical properties of printed circuit boards.

It is currently capable of calculating capacitances between objects - nets on a PCB. It returns a spice-compatible description of an equivalent circuit of stray capacitances that can be for example used for more accurate circuit simulation. Alternatively it can also produce field data that can be plotted for example with Gnuplot.

There's an export plugin available for gEDA PCB software that automatically creates a Nelma configuration from a PCB layout.

Nelma is available under the GNU General Public License version 2.

I admit I haven't really used this since I left the Faculty, but back then it did help me with a couple of projects. The emphasis was mostly on the simplicity of the algorithm, so I stuck with the relatively inefficient finite difference method (ouch, O(n3) complexity) instead of the usual finite elements. Right now it could really use some love in form of algorithm parallelization or conversion to finite elements method. Any takers for a summer project?

Posted by Tomaž | Categories: Code | Comments »