The curvetrace program

Schematic of test circuit

The figure shows the circuit used to analyse a device under test (DUT). The curvetrace program controls the voltages \(U_1\) and \(U_2\) at the terminals of the programmable power supplies PSU1 and PSU2, and records the currents \(I_1\) and \(I_2\) using the built-in meters of PSU1 and PSU2. Both \(U_1\) and \(U_2\) are shwon as positive voltages in the figure. Negative voltages are achieved simply by connecting the terminals of the corresponding PSU(s) with inverted polarity.

The resistor \(R_2\) serves multiple purposes:

  • For voltage-controlled DUTs like FETs or vacuum tubes, the resistor prevents high-frequency oscillation at the FET gate or tube grid. An \(R_2\) value of approximately 103 Ω is recommended, but the exact value is not critical and will not have an effect on the test results.

  • For current-controlled DUTs like BJTs, the resistor is used to convert the control voltage to the control current \(I_{\rm B}\). The voltage drop across \(R_2\) is equal to \(U_2\) - \(V_{\rm BE,on}\), where \(V_{\rm BE,on}\) is the base-emitter on voltage of the BJT. Therefore, the control current is given by Ohm’s Law as \(I_{\rm B}\) = (\(U_2\) - \(V_{\rm BE,on}\)) / \(R_2\).

The curvetrace program allows limiting the currents (\(I_1\), \(I_2\)) and power (\(U_1\) × \(I_1\), \(I_2\) × \(U_2\)) to prevent overloading the DUT during testing.

The curvetrace program supports a number of different PSU models. See Supported power supplies for details.

The curvetrace program allows using a heater block to control the temperature of the DUT during curve tracing. See Heater Block for details.

A future version of the curvetrace program will allow compensation of the (small) voltage drops across the wires to connect the terminals of the PSUs to the DUT. The voltage drops due to the resistance of the wires are usually negligible, but can be calculated from the measured \(I_1\) and \(I_2\) values using Ohm’s Law, and subtracted from the measured \(U_1\) and \(U_2\). To avoid interference of the voltage drops due to \(I_1\) on the measurement of \(U_2\) (and vice versa for \(I_1\) and \(U_2\)), separate wires are recommended as shown in the above circuit diagram, especially for tests at high currents.

Test procedure

The procedure implemented in the curvetrace program is as follows:

  1. Read the curvetrace_config.txt configuration file with the PSU details, and connect to the PSUs (see below).

  2. Interactively ask the user for a name or label of the test data, and then open an ASCII data file with that name (an existing file with the same name gets overwritten!).

  3. Determine the test conditions, either by interactively asking for user input, or by reading a DUT configuration file with the test parameters:

    • Start voltages, end voltages, and number of steps for each PSU

    • Max. allowed current and power applied from each PSU to the DUT

    • Polarity of how the PSU terminals are connected to the DUT terminals

    • Optional: number of readings at each voltage step (results will be averaged)

    • Optional: idle time and pre-heat time

    • If idle or pre-heat times are not zero: idle voltage and current conditions for the PSUs

    • Optional: DUT temperature

  4. Check the test configuration versus the limits of the PSUs, and adjust the configuration where needed.

  5. Show a summary of the test configuration and ask the user if it’s okay to start the test.

  6. Run the test:

    • Optional (if a heater block is used): wait until the DUT has attained the specified temperature.

    • Optional: the DUT is conditioned for the test (this is especially useful for vacuum tubes). During a «pre-heat» period, \(U_1\) is set to a predefined value, and and \(U_2\) is automatically adjusted to attain a predefined \(I_1\) value. The \(U_1\), \(I_1\) and \(U_2\) values at the end of the pre-heat are written to the data file.

    • The voltages are stepped in two nested loops. Voltage \(U_1\) is varied in the inner loop, \(U_2\) is varied in the outer loop. Optional: between readings, the DUT is re-conditioned during a (short) idle period in the same way as the pre-heat.

    • The measured data are shown on the screen and saved to the data file.

  7. Once the test is completed, turn off the PSUs.

Power supply configuration

The basic configuration required for curvetrace to work is to specify the PSU models used, and their communication port is connected to the computer. To specify these configurations, create a file curvetrace_config.txt and enter the PSU configurations as follows::

[PSU1]
TYPE           = ...
COMPORT        = ...
WIRERESISTANCE = ...

[PSU2]
TYPE    = ...
COMPORT = ...
WIRERESISTANCE = ...
  • TYPE: the type or model of the PSU. See Supported power supplies for details.

  • COMPORT: path of the virtual file corresponding to the serial port of the PSU

  • WIRERESISTANCE: resistance of each wire used to connect the PSU terminal to the DUT (in Ω)

See Working with the curvetrace program for examples of curvetrace_config.txt files.

Note that it is possible to connect multiple PSU units in series to each other to accomplish a higher voltage range. Such a series combination of multiple PSU units can be configured as a single PSU object by specifying their TYPE and COMPORT fields as follows:

  • TYPE = ( "<type_psu1>" , "<type_psu2>" )

  • COMPORT = ( "<comport_psu1>" , "<comport_psu2>" )

There are further configuration options to improve the the quality of the the PSU data (FULL DOCUMENTATION FOR THESE IS UNDER CONSTRUCTION):

  • NUMSTABLEREAD: number of readings that must have identical values in order to accept the reading.

  • V_SET_CALPOLY, I_SET_CALPOLY, V_READ_CALPOLY and I_READ_CALPOLY: coefficients to specify external calibration data to set and read the voltage and current values at the PSU.

Heater block configuration

The configuration of the heater block is only required if a heater block is used. The heater block configuration is also specified in the curvetrace_config.txt file. See Heater Block for details.

DUT test configuration

While it is possible to run pypsucurvetrace by manually entering all the test parameters, it is usually more convenient to use configuration files that contain all the DUT specific test parameters.

A test configuration file contains three sections [PSU1], [PSU2], and [EXTRA] (see also Examples):

[PSU1]
POLARITY    = ...
VSTART      = ...
VEND        = ...
VSTEP       = ...
IMAX        = ...
PMAX        = ...
IIDLE       = ...
VIDLE       = ...

[PSU2]
POLARITY    = ...
VSTART      = ...
VEND        = ...
VSTEP       = ...
IMAX        = ...
PMAX        = ...
IIDLE       = ...
VIDLE       = ...
VIDLE_MIN   = ...
VIDLE_MAX   = ...
IDLE_GM     = ...

[EXTRA]
PREHEATSECS = ...
IDLESECS    = ...
NREP        = ...
T_TARGET    = ...
T_TOL       = ...

Parameters in the [PSU1] section:

  • POLARITY is either 1 for normal polarity, or -1 for inverted polarity

  • VSTART and VEND are the start and stop values of \(U_1\), and VSTEP is the \(U_1\) increment size.

  • IMAX and PMAX are the \(I_1\) and \(U_1\) × \(I_1\) limits to prevent overloading the DUT.

  • IIDLE and VIDLE are the \(I_1\) and \(U_1\) values for the pre-heat and idle periods.

The parameters in the [PSU2] section for PSU2 are analogous to the [PSU1] parameters. The [PSU2] section may contain the following additional parameters:

  • VIDLE_MIN and VIDLE_MAX indicate the range of allowed idle voltages during pre-heat and idle periods.

  • IDLE_GM is the transconductance value (in A/V) to be used for regulation of \(I_1\) during pre-heat and idle by adjusting the \(U_2\) voltage: IDLE_GM = \(\Delta I_1\) / \(\Delta U_2\) at the idle operating point.

Parameters in the [EXTRA] section:

  • PREHEATSECS and IDLESECS are the length (seconds) of the pre-heat and idle periods.

  • NREP is the number of repeated readings at each measurement step. Note that each reading is preceeded by an idle period if IDLECECS > 0.

  • Optional: T_TARGET and T_TOL are the temperature target value and tolerance of the heater block (°C).

Running curvetrace

The curvetrace program is invoked from the command line. Full documentation is not yet available in this document, but can be accessed from the curvetrace program directly:

curvetrace --help