What to do when your SPICE models run out of gas: Part 4 - Embedded.com

What to do when your SPICE models run out of gas: Part 4

In Part 1 , Part2, and Part 3 of this series, the focuswas on the limitations of SPICE modeling, when to use and when to notuse it, as well how to make best use of it in those applications whereappropriate. Here, the focus will be on the appropriate modelingphilosophies and methods.

Monte Carlo methods
In a microwave interconnect, there are numerous segments of traceseparated by features, passive components, connectors, vias, and suchthings. Each of these is likely to introduce new degrees of freedom.Each is likely to have an independent range of key parameters thatcharacterize the feature or thing.

The simplest simulation is one in which each parameter is set to itstypical value, and a single run is made to determine the performance ofthe link. This is the simplest and always the right place to start. Alink that does not work with typical values is broken.

The next step is to model with variations of the parameters. Everyparameter that is not fixed in value will have a maximum, typical, andminimum value. In most cases, it is not clear which combinations ofparameters will result in the overall best or overall worst case.

There are various strategies that can be used to try to identify thebest or worst cases. One strategy that is often used is to run a largenumber of Monte Carlo simulations.

After these are completed, the results are evaluated and you runanother even longer simulation. You evaluate the output parameters ofthe run. If there is a significant change in the evaluation, repeat theprocedure until no further significant change takes place.

This method has a few problems. One is that it gives no guaranteethat the worst case or best case has actually been found. Another isthat it can involve a very large number of runs of the simulation.

Finally, perhaps the biggest problem is that it does not inherentlyinclude any indication of what to try next. A bunch of runs were madeand perhaps the link is demonstrated marginal. What specific variables,changed in what direction, are likely to improve the result?

An advantage of Monte Carlo simulations is that they automaticallygenerate the variations that are simulated. When you set up tests byhand, there seems to be a tendency to favor some scenarios and ignoresome that are thought unlikely to happen. Yet, it could very well bethat the failure takes place under a scenario that was ignored. MonteCarlo methods can help avoid this inasmuch as they are not likely tohave the pre-conceived notions that people have.

Experimental Design methods
An alternative is to operate in a more systematic manner. Planexperiments that allow you to minimize the number of runs needed tocalculate the sensitivity of the output parameters to variations ofinput parameters.

When the sensitivities have been calculated, they can be used in amaximization or minimization problem to solve for the likely best orworst cases. This approach also directly yields information as to whatparameter changes are likely to best improve the output.

Note that this line of approach usually presumes that theparameters interact in a fairly consistent and predictable manner. Ithas more difficulties when something happens that you didn't expect.

An interaction that was modeled by a linear equation may changedrastically if, for example, a resonance comes along. It is this typeof event, the unexpected resonance, that Monte Carlo is more likely tocatch. A good compromise is to start simulations with a few Monte Carloruns, and then shift to the curve-fitting methods to refine the design.

Using communications theory
In testing a data link, often a significant issue is the inter-symbolinterference. In fact, at high data rates, this interference oftenbecomes the limiting factor establishing the maximum data throughput.The mechanism is the result of the previous data bit not having totallysettled before the current data bit begins.

This causes the waveform of the current data bit to be somewhatdependent on the previous data bit. The previous data bit was dependenton the one that preceded it, and so on.

When an effort is made to achieve the absolute maximum datathroughput on a link, the speeds can be such that the current waveformcould be dependent on data patterns that extend back dozens of bits.

In this case, a common response of the signal integrity engineer isto measure the response to numerous variations of data patterns andsearch for worst-case conditions.

There is an alternative to this, and that is to measure the pulseresponse, as shown in Figure 7.24below , of the interconnect circuit and calculate the worst-caseresponse. Consider for example, a pulse that is one unit interval widein time.

This pulse settles to a steady-state condition in some number ofadditional unit intervals. If the transmission medium—the circuitboard—is mathematically linear, as it probably is, then the voltage atany point in time is the sum of the present response and thetime-shifted responses of all the previous pulses.

Figure7.24. Pulse Response

When the negative parts of all previous pulses are added up andcombined with the current pulse, as depicted in Figure 7.25 below , the result is theworst case of minimum height for the current time interval—the worstcase one.

Similarly, if the positive parts of the pulse response for allprevious pulses, not including the pulse itself, are added to a zerothat takes place in the current interval, the result is the worst-caselow level that can be achieved—the worst case zero.

The point is that judicious use of the information describing anisolated pulse can yield the worst-case high, the worst-case low, andeven the worst-case data pattern for a particular link.

This information can be a powerful tool in the analysis of a link.In practice, you would perform a SPICE simulation of an isolated pulseand save the data in a file. You would then write a script in yourfavorite computer language to divide the response into unit intervalsof time and add the appropriate portions together.

Advantages of this method are that it can eliminate numerous SPICEruns searching for worst-case patterns, and it yields a waveform thatcan be confidently identified as worst case.

Figure7.25. History of Responses

ImpulseResponse. The response of a system to a pulse that is of unitarea and infinitely short in time is called the impulse response of thesystem. This is not to be confused with the pulse response. The impulseresponse is only of mathematical significance and so is very importantin some applications.

Particularly, the inverse Fourier transform of the S11 data yieldsthe reflected impulse response of the system, or at least the impulseresponse limited by the bandwidth of the data in frequency domain.

Step response. Summing all the samples of the impulse response yields the stepresponse of the system. This one is of more significance, in that it ismeasurable in real laboratories with real test equipment. Time domainreflectometry (TDR) looks at the step response of a system.

Some people say that the pulse response of a system can be obtainedfrom the step response by delaying a second copy of the step responseone unit interval of time, then subtracting from the step response, asin Figure 7.26 below. This is almost true.

Figure7.26. Step Response to Pulse Response

Why, you ask, is it 'almost' true? Well, it would be true if thedriver had the same strength, edge rate, and so on, in both thepositive and negative directions. In a real application, it makes senseto account for these differences. But for the passive part of theinterconnect itself, the assertion will be true.

Worst-CaseResponse. So this is the recommendation for the way to obtaingood confidence that actual worst-case signals are really identifiedand to do so without excessive simulations: Simulate the pulse responseand mathematically manipulate it to extract worst-case-eyemeasurements.

Examine the pulse response; make sure you get the entire pulseresponse, not just the first few unit intervals. Divide it into unitintervals according to the pulse-width of the data of interest to youand calculate worst-case responses by addition of the appropriatesections of the response.

This procedure is valid as long as the transmission medium islinear, allowing total response to be validly characterized as the sumof its parts. In the drivers and receivers themselves, in the silicon,this may not be valid. But in the interconnect circuitry, it probablywill be valid.

The dielectrics are not likely to vary in value as a function ofvoltage. The copper resistance is not likely to be voltage sensitive toany significant degree. The most likely place to find an amplitudedependency in a passive circuit is in a magnetic component.

Though microwave magnetic components exist in forms such asisolators and circulators, they tend to be narrow band and are not muchuse in circuits of interest here. Similarly, isolation transformers areoccasionally used at lower data rates but are not particularlypractical for consumer electronics in the microwave frequency ranges.

Spreadsheets and MathematicsSoftware
Much of the above work can be very nicely done in mathematics packagessuch as Matlab or Octave. Much can even be done in such simple andinexpensive tools as spreadsheets. A spreadsheet program that canoutput a text file can even be used to write code for the SPICEsimulator.

An advantage of this type of approach is that input parameters forthe simulation can be conveniently grouped and displayed. Comments canbe added; calculations can be made.

This is not to say that much of this cannot be done by directlywriting the SPICE code, but often it cannot be done as well. When aparticular code file is viewed and inputted to SPICE, it is seldomconveniently readable. It is organized to be read by the machine ratherthan by a human.

A spreadsheet interface makes it convenient to organize material forviewing by humans. Colors can be used to group and designate particulartypes of data. Boxes are available to further organize it. Fonts andhighlighting add further clarity. These things are not available in theSPICE file. Tastes vary. You may prefer a version of Basic, C, or evenPerl.

Sometimes we get the idea that we are stuck with the userinterfaces provided with our simulators. Often these are not all thatgood. The programmer that is very skilled at writing a particular typeof simulator is likely not going to be very good at writing userinterfaces.

Sometimes the analysis mode that is required or desired for aparticular problem is not available in the user interface at all. ManySPICE implementations won't display an eye diagram without a whole lotof work. You don't have to be limited by the limitations of the userinterface. Import the data to an alternative tool and display it there.

Use Matlab, a spreadsheet, or Perl; write a short C program.Similarly, most SPICE implementations provide very limited facilitiesfor generating serial bit streams. It is not difficult to write ascript that writes the code to generate a specific or a quasi-randombit-stream in SPICE.

Using Frequency Domain Analysis
Though long experience with time-domain analysis has made many of usprefer that domain, there are very good reasons to also be competent inthe frequency domain. The most obvious advantage is measurementcapabilities. In the frequency domain, measurements can be made over adynamic range of about 80 to over a 100 decibels.

The high end of frequency available for typical network analyzers isin the range of 20 to 50 gigahertz. By comparison, the time domainreflectometer is capable of about a 30-decibel dynamic range and about6-gigahertz equivalent frequency response.

Conversionsbetween Frequency and Time Domains. The main procedure forconverting between frequency domain and time domain is the Fouriertransform and its inverse. These are usually implemented in the form ofthe fast Fourier transform, FFT, and its inverse, the IFFT.

These are not perfect tools inasmuch as they make the presumptionthat the data being analyzed is actually a portion of a repetitive waveand that presumption introduces undesired artifacts.

Dealing with those artifacts sometimes requires procedures that areunpalatable to purists. It was suggested that faking data could be mademore palatable by assigning an alternative name—completing the dataset—to the procedure.

There are some aspects of frequency domain data that are so obviousthat, when you see the graphs, you will immediately recognize theutility of this data format. After all, there is no inherentinformation in the one format that isn't present in the other. It isjust that different uses benefit from the particular manner ofinformation presentation.

Why Frequency Domain?
I've already explained that measurements in the frequency domain can bemade with great precision, dynamic range, and frequency range. Theseare adequate reasons to justify getting familiar with the frequencydomain. There are additional benefits from working in the frequencydomain.

The frequency domain can be very powerful in projecting orextrapolating characteristics beyond the bounds of measurements, as in Figure 7.27 below. Of course, ifthere is a resonance just outside the range you measured, this can getyou in trouble, too. Frequency is also the natural domain for studyingthe quality and range of applicability of models.

Figure7.27. Projecting the Frequency Response

Measurability. Considerthe possibility of designing a better time-domain reflectometer.Presume that you are given the task of designing a TDR that can matchthe performance of a relatively inexpensive network analyzer. Forexample, a network analyzer that measures out to 20 gigahertz, with adynamic range of 80 decibels.

The first task will be to design a step generator that can deliver a25-picosecond rise-time step to its test head. The frequency-dependentloss that will be present in the interconnect between the physical stepgenerator circuitry, and the actual test point will likely require thatthe step generator be capable of internal rise-time of 10 or fewerpicoseconds.

Eighty decibels corresponds to one part in 10,000. To generateaccuracy at that level, the output pulse will need to be calibrated andcompensated by some sort of automatic mechanism. That implies a way ofmeasuring the voltage with about 14-bit accuracy.

This measurement sounds like an analog-to-digital converter: 14bits and perhaps 10 picoseconds settling time. As Shakespeare wouldhave said, “Now there's the rub.” It is not to say that this is theonly issue, nor that this is insurmountable. The point is that it islikely easier to design the network analyzer than the TDR whenfrequencies become high.

This higher level of measurement accuracy and range come at thecost of equally greater care required in making the measurements. Therequirements include such things as the need to calibrate the equipmentat regular intervals. This is typically facilitated by pre-programmedroutines; calibration routines are usually built into the testequipment.

Usually they also provide precision calibration standards with themachine. All this is used in conjunction with test structures that youneed to place on the device under test. In short, the network analyzerrequires you to have a new set of skills even though you may beproficient at making measurements with the time domain reflectometer.The return for those new skills are high-quality measurements.

Qualificationof Models. The bane of signal integrity is the unreliable model.A significant portion of most signal integrity efforts goes intoverifying the accuracy and range of applicability of models.

The network analyzer is very useful in solving this problem. It canprovide an accurately measured characterization of a device. Meanwhile,SPICE itself can be used to generate S parameter data that correspondsto the provided model. Comparing the measured data with the SPICE datathen shows how accurate the model is and how the accuracy varies withfrequency.

Through the peeling algorithm, which will be discussed later inthis series, you also can often directly generate SPICE models fromnetwork analyzer data.

Equalization, extending the useful range of an interconnect circuit bymanipulating its frequency response, can be done with the aid ofnetwork analyzer data.

In most microwave-frequency data interconnect circuits,frequency-dependent loss is the major cause of signal degradation. Thethree main methods to deal with this problem are:

1. Manipulate the transmitspectrum to complement the frequency response of the channel, orpre-emphasis.

2. Manipulate the receiverfrequency response to complement the channel frequency response, oradaptive equalization.

3. Use passive filteringtechniques to complement the frequency response of the channel.

The first two seldom employ network analyzer data, but the thirdusually does. You measure the channel frequency response and thendesign a circuit that complements that response to yield an over-allfrequency response that is suitably flat. This method can be calledpassive equalization.

Pre-emphasisvs. De-emphasis. Manipulation at the transmitter can beimplemented in various ways. This activity usually involvesmanipulating the transmit signal amplitude on a bit-by-bit basis. Onecommon method is to set the amplitude of the first bit of any series ofequal-logic-value bits to a level higher than the remaining bits in theseries.

There are two ways you could do this: boost the leading bit to ahigher level, called pre-emphasis, or reduce the level of the bitssubsequent to the leading bit, called de-emphasis. From outside thepackage, they probably look the same.

If a current driver is used, pre-emphasis or de-emphasis can beachieved by manipulating the current of the current source. This isboth fairly easy to do and fairly economical of silicon area, so somevariation of this is likely to be found in most high-speed drivers.

AdaptiveEqualization. Adaptive equalization usually refers tomanipulations of the data inside the receiver. There are several waysof achieving this, and none of them is the right solution for allcases.

One way is to track the history of past bits and offset the inputsignal to compensate for the part of the input signal that is actuallythe remainder of past bits, as shown in Figure 7.28 below.

This can be very effective. It requires more high-speed circuitrythan the simple receiver does but, that trade-off is available to thesilicon designer.

Figure7.28. An Adaptive Equalizer

One problem related to such receivers is that they can make itdifficult to measure signal quality at the input of the package. In areceiver without internal equalization, the usual measure of signaladequacy is the eye opening at the pins of the receive package.

In a case where adaptive equalization is used, there may be no eyeopening at the input pins. In this case, you may not be able to measuresignal quality with an external tester.

The answer may be that the transmitter and receiver must be able towork together to measure and quantify channel margins. If, for example,the transmitter can reduce the transmit signal by some amount, and thereceiver can then verify that the error rate is still acceptable, thenthat can indicate a level of loss margin.

Dealing with Radiation
Radiation tends to be more serious as frequencies increase. Whencircuit boards were running at speeds of tens of megahertz, finding atrace or any other structure that was as long as a quarter-wavelengthwas rare.

At multiple gigahertz, all sorts of structures can become efficientradiators. At tens of megahertz, signals traveled down wires. Atmicrowave frequencies, signals can travel quite well down the gapformed by the edges of two adjacent planes.

What we used to think of as a plane-split, the microwave people calla slot-line. At the right length, it can make a nice antenna. A signalcan travel around the outside edge of an isolated plane. If thatperiphery is the right length, it can make another nice antenna. Themicrowave guys call it a patch antenna.

The point here is that structures that were of little interest atlower frequencies can become very interesting and perhaps troublesomeat microwave frequencies. These transmission lines that SPICE doesn'tknow about can provide many of the same services, crosstalk and such,that good old wires used to provide.

Circuit solvers such as SPICE do not know anything about radiation.Any time it is necessary to model radiation, expect to be using a 3Dfull-wave field solver.

Of course testing real boards is an important part of studyingemissions. It often is not practical to build a full 3D model of acircuit board with all the components, heat-sinks, cables, chassis, andso on that comprise the end product.

Sometimes the right answer is to take it to the lab and makemeasurements. But you need to know the buzzwords so, when a regionstarts radiating, you know that it might be acting as a patch antennaor a slot antenna. That is, so you know what to look up for answers.

Crosstalk .Ifyou look at a broad definition, radiation can be a contributor even tocrosstalk in the circuitry. If a signal gets launched into thedielectric region between two reference planes, that signal can getreflected by various structures, and standing waves can develop.

Those standing waves can cause enhanced crosstalk between thecircuitry that inadvertently launched the wave and the circuitry thatintercepts it. A similar situation could exist for things likeslot-lines. The first line of defense is to minimize the amount ofsignal that is launched into such structures. Again, this usuallycorresponds to minimizing the common-mode component in the differentialsignals.

Planar Waveguide
One structure that can nicely transport a microwave signal is a planarwaveguide. This device is a dielectric that is bounded top and bottomby a conductive plane.

When a signal is introduced to this waveguide, it travels radiallyoutward from the point of introduction. At frequencies and dimensionsthat are found in the printed circuits of computer systems, it will bea TEM wave.

TEM waves follow all the capacitance, inductance, and velocityequations. The significance of this is that, at the edge of the plane,there will be a sudden drop in capacitance so there will be a suddenincrease in transmission line impedance. There will thus be areflection in the signal. If the overall planar structure has lowenough loss, it will be a resonator


Figure7.29. A Dielectric Resonator—Less the Dielectric

The way you launch a signal into this structure is to run a currentbetween the planes in the direction normal to the two planes. A way oflooking at it is that the magnetic field surrounding this currentpropagates out through the waveguide, carrying energy with it.

However you choose to view it, the simple mechanism of running thiscurrent from one side to the other is an effective way of injecting asignal to this waveguide. To physically accomplish this, you would makea small hole in each plane and then run a wire through that hole.Current in this wire would then inject or extract energy from thiswaveguide.

Since the edges of this waveguide are typically open circuits,while some of the energy gets reflected, some gets radiated and becomesradio interference. There are several mechanisms that can extractenergy from this waveguide. Energy will leak out through holes, ifthere are holes in the planes.

Energy will be coupled into other wires that happen to pass throughthe planes. Energy will be lost in the dielectric and the copper lossesof the planes themselves. To make this structure resonate well, youwould minimize the number of holes through the waveguide and the numberof wires through it.

Then you would make it small so signal doesn't have to travelthrough too much loss before it gets reflected. Of course, to minimizethe resonances, you would do the exact opposite. This isn't only oftheoretical interest. Many power fills and such structures onmulti-layer circuit boards fit very well the description of a reallygood microwave resonator.

Dealing with Vias
What has been described earlier, signal insertion to a planarwaveguide, is precisely what many signal vias do. So the via can be agood mechanism for inserting or extracting signal. Note that it is notthe fact that the via passes through the planar waveguide that injectssignal, it is the fact that the signal current passes through thatinjects the signal.

A good way of minimizing the energy that is coupled into thiswaveguide is to always use well-balanced, closely-coupled differentialsignals where signals must pass through such a structure. If the signalis a closely-coupled differential signal, it becomes nearly true thatonly the common-mode AC part of the signal couples into the waveguide.For engineering purposes, it can be considered true.

The energy coupled into such waveguides can be the major part ofthe loss in high-frequency vias. Keeping differential signals wellbalanced helps to minimize the loss through vias. Another way to reducesignal injection and so minimize loss is to short the two planessurrounding the waveguide together at a point near where the signalpasses through. If both the planes happen to be grounds, this ispractical and is recommended.

Modeling of a single via in a particular application is not toodifficult on a 3D field solver. The problem is that, though the viageometry may remain the same in various instances of its use, the modeland the response for the case of a signal flowing from one surface tothe other will be very different than the model and response for thecase of a signal flowing from one layer to another nearby layer. Whenviewed this way, you can see that a single via geometry may requiredozens of variations in the simulation and the model.

One solution is to solve a bunch of cases and form a look-up tablethat can be interpolated. Reasonable results can be achieved by thismethod. The via can be decomposed to geometrically simple primitives,as depicted in Figure 7.30 below, and multi-dimensional tables generated of the electricalcharacteristics of those primitives.

Through scaling and table lookup, this makes it possible to generatea spreadsheet that can generate a reasonable SPICE model of the via,given only the geometric description of key parameters. This method canreduce the time required to generate acceptable models, from weeks tominutes.

Figure7.30.Simple Primitives that Model a Via

Getting familiar with patch antennae
You need to be familiar with the concept of a patch antenna—an antennathat can be fabricated as an integral part of the surface of a printedcircuit board. Occasionally you will find that things you intended asplane-fills act as patch antennae.

You get the subject of the patch antenna here because you needfamiliarity with the term. The subject is too complex to be reasonablycovered within the scope of this book. The patch antenna is the answerto the question: “How can I build a good antenna on planar media, orcircuit boards?”

An antenna is not necessarily a big tower or a long pole extendinginto the air. An antenna might be as inconspicuous as a square ofcopper on a circuit board, especially at microwave frequencies.

The point is this: if it looks like a patch antenna and signal isinjected to it, it is going to radiate.Submit the phrase “patchantenna” to a favorite search engine on the web and you will getthousands of responses.

Slot Antennae and Hole Size
This subject is introduced much like the patch antenna was introduced.A slot antenna is simply a hole in a conducting surface. If it is theright size, it can be a very good antenna. Many of the connector holesfound in the chassis of older personal computers are, at microwavefrequencies, really good slot antennae.

As frequencies increase, the size of holes in the chassis, bothintentional and inadvertent, must proportionally decrease. Recall thatfree-space velocity is a little less than 12 inches per nanosecond. A 6gigahertz harmonic will have a free-space half wavelength of one inch.

Common-Mode on Cables
The shielding on inexpensive microwave-frequency data cables can bequite good. Usually a very significant proportion of emissions comesfrom the connectors or from the way the connectors are mounted.

The most important source of emissions is the common-mode signalthat leaks onto the outer surface of the cable shield. It is estimatedthat somewhere around 2 to 5 micro-amps of signal on the shield of acable is all that is required to fail FCC emissions standards.

It is a very good idea to carefully model the entire cableconnector region to examine the leakage characteristics. This includesnot only the electrical connections of the signal lines, but also theconnections of the ground pins, the shell to the chassis, and anythingelse that is involved in maintaining proper shielding.

In the past it was seldom necessary to specify the electricalconnectivity of the connector shell-to-chassis path. Simulation willshow that at microwave frequencies this can be a major source ofemissions. You will want to examine this characteristic of connectorsand their shell-connections to the chassis.

This series so far has not been about how to use a particularsimulator—the vendors provide extensive literature and classes to coverthat. Rather, it has presumed that you are already familiar with thebasic tools but need information as to how those tools can be appliedto digital interconnect design at microwave frequencies.

I wouldn't expect you to be able to smoothly transition to everhigher frequencies without aid. This chapter addressed various issuesthat you may never have seen unless you spent time talking to microwaveengineers.

Sure, eventually we would all have heard of slot lines and patchantennae, but here is a leg up. Many of the subjects introduced hereare also covered in tomes of mathematics and theory.

This book should not be the final look you take at many of thesesubjects. On the other hand, not everyone has the time to read a dozenmicrowave books to discover the source of that peculiar resonance onthe new circuit board.

Next in Part 5: “Peeling andMason'sRule.
To read Part 1, go to “Unmodelable featuresof high performance designs
To read Part 2: go to: “Differiental transmission lines and receivers.”
To read Part 3, go to: “Modelable Features

Dennis Miller has worked in electronics since 1963. His earlyengineering interests and education centered on control theory andnumerical analysis. Now his interests are signal integrity andnumerical analysis. Since joining IntelCorp. in 1991, he has been instrumental in the development ofInfiniband technology and similar high speed signaling technologies.

This articlewas excerpted from Designing HighSpeed Interconnect Circuits, by Dennis Miller.Copyright © 2004-2006 Intel Corporation. All rights reserved.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.