Projects Research & Design Hub

Create Your Own I-V Curve Tracer

Written by George R. Steber

A $50 Design

Curve tracing is a classic way to learn more about many electronic components. Instead of relying on the documentation of electronic component manufacturers, it’s useful to do the curve tracing yourself. In this project article, George presents an inexpensive curve tracer that plugs into the USB port of your computer and enables you to obtain and compare the I-V curves of many devices.

Curve tracing is essentially a means of making a graph of current (I) versus voltage (V) called an I-V curve, to display the basic characteristics of an electronic device. I-V curves of the components are helpful in understanding their limitations and nonlinear operation. Such curves are also useful in establishing circuit models and for determining bias points, load lines and boundaries of the devices.

But, alas, curve tracing seems to be a lost art, and many engineers rely only on the curves given by the device manufacturer. Unfortunately, the manufacturer’s I-V curves are not always handy, or the devices may not be documented at all. Some fortunate labs have commercial curve tracers that will do the job, but they are outside the realm of many low-budget labs or experimenters.

In this article I will describe an economical way of obtaining the I-V curves of two- and three-terminal devices, using a PC, an economical USB oscilloscope, a simple circuit and a bit of Windows software. It’s a project that should appeal to almost anyone involved in electronics.

With this setup, you will be able to accurately plot, save and compare the I-V characteristics of a variety of devices, including diodes, Zeners, LEDs, transistors, voltage regulators and more. It will also enable you to test some types of integrated circuits. It’s definitely a low-cost project—but one that will produce excellent results. To get started, let’s review some basic concepts of curve tracing.

WHAT IS I-V CURVE TRACING?
An I-V curve is important because it represents all the possible operating points of a device. It’s obtained by continuously varying the voltage of the device under test (DUT) and measuring the amount of current the device permits to flow at each voltage.

— ADVERTISMENT—

Advertise Here

AC curve tracing is the most common way to do this. You need an AC voltage source, a transformer, some resistors and a DC-coupled oscilloscope. Figure 1 shows a classic curve tracer circuit for a two-terminal DUT. Current I(t) and voltage V(t) are the two variables measured. A representative I-V curve is shown on the right side of Figure 1.

FIGURE 1 – Classic circuit for AC curve tracing of device under test (DUT). An exemplary I-V plot is shown on right.

At a given point on the curve, the rate of change, or “slope” of the curve is equal to the reciprocal of the resistance of the DUT. Hence, a “short circuit” DUT would plot as a vertical line through the origin, whereas an “open” DUT would be a horizontal line. Along a curve, a positive slope indicates positive resistance, whereas a negative slope means it has negative resistance at that point. A conventional resistor would plot as a straight line with positive slope.

Transformer T1 is used to provide isolation and voltage reduction from the AC source, usually 120 VAC, 60 Hz. It also nicely allows selecting an arbitrary place for the ground reference point in the secondary circuit. Resistor R1 is used as a current-measuring element, and R2 is used to limit current. An oscilloscope, in DC-coupled X-Y mode, is used to plot the curve. The scope X-input measures the DUT voltage V(t) and the scope Y-input measures the voltage across R1, which is proportional to current I(t). For example, if R1 equals 100 Ω and there is 1 V across it, we can deduce that there is 10 mA in the DUT. Or, we might say we have a sensitivity of 10 mA/V for this channel.

Notice that since the ground point for the scope is at the connection of R1 and DUT, the current signal measured by R1 will be inverted with respect to V(t). This can usually be corrected at the oscilloscope by reversing the polarity of the channel.

When measuring low-voltage parts like diodes and Zeners, a 120 VAC-to-12 VAC step-down transformer is typically used. Note that 12 VAC provides a peak voltage of about 17 V. If larger or smaller AC voltages are needed, a Variac adjustable transformer may be used on the 120 VAC side. Or, as seen later, a voltage divider can also be used.

Resistor R2 is typically around 500 Ω, but depends to some extent on R1, since the sum of R1 and R2 limit the current. You can use convenient values as long as you realize the implications of higher voltages on your components and the power dissipation of the resistors. Assuming the DUT is a direct short is good way of estimating the maximum power lost in these parts.

Notice that, since the applied voltage is AC, the curve tracer sweeps both positive and negative voltages, which can be instructive in some situations, such as tracing Zener diodes. However, some parts can be damaged by the negative excursions, so a series diode may be used to provide reverse voltage protection. That said, we’ll see that scanning the negative regions for some components can show some interesting characteristics. Next, let’s discuss how this circuit fits into the current project.

HOW THE PROJECT STARTED
With an analog scope, using the curve tracer circuit is straightforward but has some drawbacks. On many older scopes, it is difficult to measure accurately in X-Y mode, and there are no means to save and compare component traces. A digital scope makes things a bit easier.

However, when I tried curve tracing with my old digital scope, the X-Y display was difficult to read, and traces could not be saved. I have since found that digital scopes vary in this capability, with some producing nice X-Y plots and others not. Although my scope performed well for time plots, it was in the “not” category for good X-Y plots!

— ADVERTISMENT—

Advertise Here

Then a spark of an idea occurred, which started this project. I bid on and won a used Hantek 6022BE USB oscilloscope for $20 dollars on an auction site. Although it couldn’t compete with my other digital scopes in overall performance, that didn’t matter, since I was looking for a USB platform to build a component tester that would plug into to my old laptop. The 6022BE has a 20 MHz bandwidth with a sample rate of 48 MS/s. Resolution is 8 bits per sample. It has a dual trace input and works with x1 or x10 probes, has a type B USB 2.0 plug and gets its power from the USB bus.

After looking around the Internet, I found OpenHantek on GitHub. It was primarily for those interested in modifying or creating new oscilloscope software for this instrument. While I was not interested in doing this, it led me to a considerable cache of information on software development and the Hantek SDK. In particular, there was a Visual Basic sample that showed how to use the HTMarch.dll for interfacing to the scope.

After successfully writing a few lines of VB code to see if reliable communication could be established, I decided to write a program for curve tracing using the Hantek. This wasn’t as difficult as it might have been, since I had done this before for a curve tracer using a sound card [1] [2].

Things were progressing smoothly, so I decided to buy a brand new Hantek 6022BE from Circuit Specialists [3] as a backup and to validate the software on another unit. This new one came with all the trimmings, as shown in Figure 2. Although only one probe is shown, it came with two probes. It is compact and ruggedly built.

FIGURE 2 – Hantek 6022BE USB scope used in the project. It came with a complete set of probes, USB cable and software CD.

In addition to the USB scope, some other items are needed for tracing. They consist of a 120 VAC-to-12 VAC wall adapter, a small 3M terminal strip breadboard and a 1,000 Ω resistor (Figure 3). The strip is useful for mounting transistors, regulators and other devices for testing.

FIGURE 3 – These simple parts are all that are needed to do curve tracing. Included are a 120 VAC-to-12 VAC plug in transformer and a 3M circuit strip. Shown on the strip are a diode, a resistor and a small Zener diode waiting to be traced.

SOFTWARE DEVELOPMENT
When writing the software, I came across several unusual properties of the Hantek 6022BE. It seemed to work fast and reliably when set at a high sample rate, but when the rate was decreased, the acquisition time increased dramatically. It would take many tens of seconds to grab, say 500 samples, at the low sample rate, but less than a second at the high rate. Fortunately, this was fixable in software by using sub-sampling.

Another, more pleasant surprise was finding that the effective sample size was greater than 8 bits. Normally, an 8-bit data size implies a range of 256 values. But I was measuring a range of 320 values. This corresponds to slightly more than 8.3 bits per sample! Okay, I’m not complaining. More resolution is better. But I’m still not sure how they are doing it. This was another reason to have another Hantek unit on hand—it verified this unusual property of the scope.

One of my goals was to have a program that would not require Windows Framework or any other bloated installation process. In fact, I wanted it to run on my old laptop in the lab that is still running Windows XP. That way, I could just plug in the Hantek and run the program. Another goal was to make the software run with the classic curve tracer circuit arrangement described in the previous section. This would allow very simple operation, while still permitting small modifications by the user.

By the way, the curve tracer software only runs on the Hantek HT6022BE and will not run on the HT6022BL, even though they appear similar to each other. I checked with the factory and they verified that the BL model uses a different DLL not compatible with the BE model. It’s beyond me why they did not make a DLL that would be compatible with both units.

PC CURVE TRACER OPERATION
Basically, the curve tracer software uses the Hantek as a two-channel data acquisition unit. There should be two x10 probes connected to CH1 and CH2, the same as for oscilloscope operation. Before proceeding too far, it should be mentioned that you need to install the oscilloscope driver that comes with the unit. After this, the curve tracer program will recognize the unit and be ready to operate automatically each time the USB cable is plugged in.

The software starts out by initializing all the variables in the instrument and verifies that a unit is connected. If a Hantek unit is not connected, it continues in demo mode, which permits the loading of sample plots for various components like Zener diodes or transistors.

There are refinements in the software to speed up the acquisition rate and perform fast operation. In operation, the software starts by capturing about 850 samples from each channel at a 1 MHz rate. These samples are then decimated and tested for overflow. Finally, they are filtered and processed according to the settings of the user. Results are then presented on the screen of the PC. It all happens in near-real time.

Another thing I noticed was that the accuracy of the 8-bit data, while acceptable, could be improved. Hantek claims a DC accuracy of ±3%. While this is probably true, the volts per bit in my two units differed slightly from each other, particularly on the measurement of negative voltages. So, there is a manufacturing variation. Also, I found that accuracy varies a bit with temperature.

However, if the user is willing to do some calibration, there is a custom calibration procedure in the curve tracer software that can be employed to bring the accuracy closer to 1%. If this seems like too much trouble, it can be skipped, and the normal accuracy will be used.

Other features of the software are the saving of the plot data and printing plots. In the first case the plots are saved in a comma-separated format compatible with Excel. In that way, they can be read and analyzed in that software, including printing and plotting. For printing plots directly, a special routine is used. If printing is done using software such as PDFCreator, you can save plots in PDF format or other formats. This was done to get the plots shown here.

— ADVERTISMENT—

Advertise Here

SOFTWARE INSTALLATION
As mentioned earlier, you need to install the oscilloscope USB driver that comes with the unit. This procedure is explained in the Hantek manual on the CD. It’s probably a good idea to make sure the oscilloscope program is working before trying the curve tracer program.

The Curve Tracer III software is available on the Circuit Cellar’s article code and files webpage and is zipped for fast downloading. Unzip it to a new folder, and you are ready to go. Just run the executable (.exe) program. Hopefully, the software will run just fine. However, in case of problems, continue reading below for possible solutions. It should be noted that I am not a software developer. The software will not be maintained or updated. Life is too short for all that.

The program was tested with Windows XP, Windows 7 and Windows 8.1. When you run the software, you may get a message like “Required DLL file MSVBVM60.DLL was not found.” This is a Visual Basic runtime file and is on many systems. If not found, you will need to obtain it and install it on your system. It is freely available from Microsoft and other sites on the Web. It is usually available as Visual Basic 6.0 SP5: Run-Time Redistribution Pack (VBRun60sp5.exe) and is a self-extracting file.

If you get the message, “Component ‘COMDLG32.OCX’ or one of its dependencies is not correctly registered: a file is missing or invalid” when you try to run the program, you will need to register it on your system. It is freely available from Microsoft and other sites on the web.

The program also requires that the HTMarch.dll and msvcr100.dll (supplied with the curve tracer software) to be in the same folder as the program, or else to be registered somewhere on your computer. My XP system works fine with them in the same folder. You need to have these two DLLs to use the program in demo mode or when an actual unit is plugged in. If you just want to experiment with the Curve Tracer III program, go ahead, since it does not install any other material on your computer. You can remove it by just deleting the entire folder it is located in.

Figure 4 is a screenshot of the curve tracer. The origin is at the center of the screen. Displayed here is a single trace of a 5.6 V Zener diode. In this case, the measuring cursor is off. Enabling it allows measurements of the trace to be performed and displayed in the X and Y boxes. There are four reference memories for saving and displaying device curves. They can be saved and loaded from memory. We’ll see examples of this later on.

FIGURE 4 – Here is the main window of the curve tracer program. An I-V plot of a Zener diode is being displayed.

In what follows, I’ll describe how to use the curve tracer to measure various devices. The basic curve tracer circuit will need to be modified in some cases to satisfy the demands of the device being measured. These changes are covered in the following sections. Let’s start with the basic setup.

GENERAL PURPOSE I-V CURVE TRACING
Shown in Figure 5 is the circuit used for general purpose curve tracing. It is similar to the classic circuit described earlier. Power is provided by a small, 120 VAC-to-12 VAC 60 Hz wall-type transformer. These can be found at rummage sales and surplus warehouses. The circuit uses only a single resistor, in this case 1,000 Ω. This both limits the current and provides the current-sensing function. Other resistor values can be used as long, as the value is entered in the program where the current in the DUT can be calculated.

FIGURE 5 – This circuit is used for general purpose curve tracing. See main text for details.

A 1N4001 diode D1 can be switched in when the negative voltage excursions should be prohibited. The direction of the DUT in the tester will determine the orientation of the plot. If it is a diode, you will want the anode voltage plotted on the axis plus side.

Connections to the Hantek scope are shown as CH1 and CH2. Two x10 probes must be used. Many kinds of devices can be curve traced. Let’s get started with some examples. It’s a lot of fun and instructive too!

Example 1—Incandescent Bulb: Let’s curve-trace a simple low-voltage incandescent bulb. Science classes tell us that the resistance of the bulb filament changes with the level of the applied voltage. Figure 6 shows the traces for a bulb excited by low and high AC voltages plotted together. The slope of the lines corresponds to the inverse resistance, so it is easily seen that the larger AC voltage (see X-axis) produces the smaller slope and hence the higher resistance. Those teachers were right!

FIGURE 6 – Here are two I-V plots for a low-voltage incandescent bulb.

Example 2ZNR Surge Suppressor: Ever wonder how an AC surge suppressor works? The curve in Figure 7 shows the near-perfect symmetry of an 18 V surge suppressor. There is a small hysteresis in the curve, due to the slight heating of the device.

FIGURE 7 – This is a trace of a ZNR 18 V surge suppressor.

Example 3—Red and Green LEDs: Did you know that red and green LEDs have different voltage drops in the forward direction? This can be seen in Figure 8, which shows curves for the two LEDs. The red LED is the one on the left.

FIGURE 8 – Here are red and green LEDs plotted together.

Example 4—Various Zener Diodes: Up to four saved traces can be shown together at one time. This is clearly illustrated in Figure 9 by the plot of four different Zener diodes, with breakdown voltages from 5.1 V to 15 V. Testing Zener diodes has been one of the most satisfying aspects of this project. Over the years, large numbers of these devices have accumulated, and their values are a bit suspect. Curve tracing clears away all the doubt.

FIGURE 9 – These are the traces for four Zener diodes plotted simultaneously. See main text for details.

Example 5—Transistors as Negative Resistance Devices: Using simple transistor resistor combinations, the negative resistance features of four-layer diodes, SCRs and unijunction transistors (UJT’s) may be simulated. This may be important in teaching about these devices and observing the device parameters. This subject is discussed in more detail elsewhere [4].

Figure 10 shows the circuit of a four-layer diode made with transistors. It consists of two transistors, 2N3906, 2N3904 and a single 100 KΩ resistor. The curve on the right side illustrates the negative resistance region, which bends back to the vertical axis. Figure 11 shows the traced I-V curve of the simulated four-layer diode. It clearly exhibits the same negative resistance part of the curve. Here, both the positive and negative regions are plotted. If the negative region were blocked by using a diode, the device would lock up in the shorted-out state. But here, it is conveniently reset each time through the AC cycle. This is handy for curve tracing.

FIGURE 10 – Equivalent circuit of a four-layer diode made from transistors. See main text for details.
FIGURE 11 – Plot of equivalent four-layer diode showing negative-resistance region.

Example 6—Tunnel Diode: One of the most storied devices is the venerable tunnel diode. Most of us don’t realize that it was first discovered by the Russian scientist, Oleg Losev, in the 1920s. He was also responsible for observing the first LED, and proposed the first correct model based on quantum mechanics. While the LED went nowhere, he actually built solid-state radios using his tunnel diodes (zinc oxide crystals) that operated up to 5 MHz. He built more than 50 radios, exhibiting them during the 1920’s at many European radio technology expositions.

Hugo Gernsback, the famous American publisher and editor, endorsed Losev’s work in sensational terms. Gernsback coined the word “crystadyne” to describe it, and wrote a major article in Radio News in 1924 titled “A Sensational Invention.” He even had a crystadyne radio constructed to Losev’s exact specifications. Sadly, it was ultimately passed over because it could not compete with the vacuum tube.

This work was all done 25 years before the transistor! It was left to Leo Esaki in 1957 to rediscover this important device, now known as the tunnel diode.

My first encounter with tunnel diodes was the RCA Tunnel Diode Manual [5] which was chock full of applications and theory. But the most perplexing part of the theory was the I-V plot of the device taken on a conventional curve tracer. It consisted of two, seemingly disconnected curves, purportedly generated by the device. They stated that “the negative-resistance portion of the characteristic is not visible because of the speed with which the diode switches from the low-voltage positive-resistance portion of the curve directly to the high-voltage positive resistance region.”

Now, I wanted to check this out myself. However, tunnel diodes are hard to find. After some searching, I located a few Russian 31306M diodes on an auction site. After waiting several weeks for delivery, I placed one in the curve tracer, using the isolation diode to keep away from the negative voltage scan. Also, because of the low voltage of the device, it was necessary to switch to a 1x probe setting on the X-axis. Much to my surprise and happiness, there appeared a curve shown in Figure 12. It was almost exactly the same curve I had seen in the old RCA manual!

FIGURE 12 – These are the unusual traces for a tunnel diode.

VOLTAGE REGULATORS AND TRANSISTORS
It is not well known that a curve tracer can be used to check-out voltage regulator ICs. Since most regulators are three-terminal devices, a slightly different way of connecting the DUT to the tracer needs to be used. The IN and OUT terminals are connected in the usual way, but the ground terminal needs to be routed to another point. Also, if checking a positive regulator, no negative scan voltage is permitted. A typical setup is shown is Figure 13. In this case, the voltage of the regulator is measured by CH2, since R1, acting as the load, is effectively across the output.

FIGURE 13 – Circuit used to check voltage regulators

Figure 14 shows two plots, one of a 5 V regulator and one of a 12 V device. Notice that the 5 V device performs nicely and quickly achieves regulation. But the 12 V device goes through a period of negative resistance before settling at 12 V. A small ceramic capacitor was placed at the input of the 12 V device, and the negative resistance region vanished. Of course, that is what the datasheet tells you to do. It should be mentioned that for negative voltage regulators, the scanning voltage should be negative. This can be accomplished by reversing the direction of the diode D1.

FIGURE 14 – These are 5 V and 12 V regulator curves. See text for more details.

Now, lets look at transistor I-V curve tracing. A bipolar-junction transistor (BJT) can be tested using a circuit similar to the one in Figure 15. Collector current is some multiple of the base current (a factor of beta, the current gain), so the circuit requires some method to inject current into the base terminal. An adjustable resistor, R3, connected to a DC voltage source, is used for this purpose.

FIGURE 15 – Test circuit for bipolar transistors

Although no substitute for a professional transistor curve tracer, this method gets the job done and can easily be adapted for low-power or high-power devices. Collector curves of a 2N3904 transistor are shown in Figure 16. Multiple curves are displayed using the reference memory, with each curve saved separately. Notice how the slope of the I-V curves increases at greater collector current. This indicates that the incremental output resistance is decreasing.

FIGURE 16 – Collector curves for 2N3904 transistor. This example shows the use of 4 memories of the curve tracer.

Observe that in this case, both the positive and negative voltage regions have been scanned. It is interesting to see that after voltage breakdown in the reverse direction, the curve exhibits negative resistance. One must be careful of scanning this negative voltage region, because it can damage or destroy the device. Using a similar circuit setup, FETs can be curve-traced, but with voltage steps on the gate.

IC I-V TROUBLE SHOOTING
Curve tracing of integrated circuits (ICs) under various conditions has been described for purposes of rework [6]. Tracing the inputs and outputs of logic ICs, under power-on and -off conditions, produced some diode-like curves. So, I decided to try it myself.

Since many ICs operate at lower voltages, it was necessary to lower the AC scanning voltage. This can be accomplished with an adjustable transformer on the primary side. Alternately, a simple technique can be used to make a voltage divider formed by R2 and R3 as shown in Figure 17. Two test leads are brought out to probe the IC.

FIGURE 17 – Test circuit for integrated circuits

For this test, a 74HCT00 was used. Tracing between one of the inputs and ground with the power (VC) on and off produced the two curves shown in Figure 18. The same technique can be used at the device output. According to Mathews and Toroni [6], this procedure should help identify bad ICs or other problems on the PCB. By focusing on the health of the low-side input diode of the DUT, this approach may eliminate the need to power the board for testing.

Furthermore, the approach should be the same for most ICs, because these devices rarely omit ESD protection, even in RF ICs. On the one hand, if you endeavor to try this, be prepared for unusual curves and possible destroyed ICs. On the other hand, you might learn how to test and repair some circuits using a radical new method!

FINAL THOUGHTS
Various versions of curve tracers have been around for a long time. Many of them are complicated and costly. However, this one is special, because it is easy to understand and use. In addition, it is low cost, using just an inexpensive USB oscilloscope that is readily available all over the world, and a few, easy-to-acquire, parts.

For the beginning curve tracer user, this provides an inexpensive way to get started and learn about electronic devices. But even seasoned engineers may want to experiment with it. There is a lot of room to modify the basic curve tracer circuit. For example, it could be adapted to accommodate lower- or higher-power devices or higher-voltage parts. This could lead to many interesting results!

Only a fraction of the possible devices were curve-traced here. Many other parts are just as interesting. For example, there was an old 2N28 Western Electric germanium transistor in my collection. It was nice to see this old transistor come to life again. Another unusual application might involve curve-tracing special minerals such as iron pyrite, which, in some cases, can form semiconductor diodes. Early crystal radios used galena crystals as a detector, which may prove interesting. Another application might be in the area of analog signature analysis. The list goes on.

I hope you enjoyed reading about this curve tracer. I hope I haven’t thrown too many curves your way. In any case, take heart—there might be a curve tracer in your future! 

For detailed article references and additional resources go to:
www.circuitcellar.com/article-materials
References [1] through [6] as marked in the article can be found there.

RESOURCES
Hantek | www.hantek.com

PUBLISHED IN CIRCUIT CELLAR MAGAZINE• DECEMBER 2019 #353 – Get a PDF of the issue


Don't miss out on upcoming issues of Circuit Cellar. Subscribe today!

 
 
Note: We’ve made the October 2017 issue of Circuit Cellar available as a free sample issue. In it, you’ll find a rich variety of the kinds of articles and information that exemplify a typical issue of the current magazine.


Would you like to write for Circuit Cellar? We are always accepting articles/posts from the technical community. Get in touch with us and let's discuss your ideas.

Become a Sponsor
Professor of Electrical Engineering and Computer Science at University of Wisconsin-Milwaukee

George R. Steber, Ph.D., is Emeritus Professor of Electrical Engineering and Computer Science at the University of Wisconsin-Milwaukee. He is now semi-retired, having worked over 35 years. George is a life member of ARRL and IEEE and is a professional engineer. He has also worked for NASA and the USAF.

George recently penned an article on the hidden story behind “The Discovery of Radio Waves” in the January/February 2019 issue of Nuts and Volts magazine. He also wrote a science-oriented article on “Dark Energy and the Expanding Universe” in the March/April 2019 issue of Nuts and Volts.

George still lectures occasionally on science and engineering topics at the University. He is currently involved in cosmic ray research and, is developing methods to study them on a global basis. When not dodging protons, pions and muons, he enjoys amateur radio, racquet sports, astronomy and jazz. You may reach him at [email protected] with “Curve Tracer” in subject line and email mode set to text.