
Section 2: Linear Parametric Test Library
S530/S540 KTE Linear Parametric Test Library (LPTLib) User's Manual
2-6
S530-900-01 Rev. E / September 2017
Triggers
Several Linear Parametric Test Library (LPTLib) commands use triggers. Triggers are Boolean
conditions, but to fully understand them you must understand how the LPTLib processes them.
Triggers are registered with the system using the
trig
XY
commands. This creates an entry in a
trigger table. During processing of multiple LPTLib commands, the system evaluates the triggers.
This is done by examining each entry in the trigger table to see if its condition is true or false. If any of
the triggers are true, the trigger evaluation is true. Based on the evaluation of the triggers, the LPTLib
command may alter how it continues processing.
The trigger table is cleared automatically when the
devint
command is called. Note that previous
entries are not cleared by adding a new trigger. The new trigger is appended to the existing trigger
table and it is used with the rest of the trigger table entries the next time triggers are evaluated. This
is a common mistake among even experienced LPTLib users. The trigger table can be cleared
explicitly by calling the
clrtrg
command.
Most triggers are set up to monitor when a measurement on a specified instrument goes above or
below a specified value. For example, calling
trigvg (SMU1, 2.0)
registers a trigger that is true
when the voltage measured by SMU1 goes above 2 V.
When evaluating this type of trigger, the system does not monitor any measurements made by you.
Instead, it requests a fresh reading from the triggering instrument, which it then compares to the
threshold value. This means that while evaluating triggers, the system implicitly makes a
measurement for each entry in the trigger table, for all entries of this type of trigger.
The measurement is made using the
meas
X
command of the triggering instrument. You can use the
setmode
command to force the LPTLib to use the
intg
X
or
avg
X
command of the triggering
instrument instead. To do this, all triggering instruments must support the
intg
X
or
avg
X
command,
respectively.
This type of trigger uses real numbers for the comparison. You can use the
setmode
command to
make all triggers evaluate based on the absolute value of the measurement instead of the polarized
measurement. You can clear this
setmode
option and the other triggering options mentioned above
using the
clrtrg
and
devint
commands.
GPIB
The kibXXX commands allow you to control general purpose interface bus (GPIB) instruments that do
not have Linear Parametric Test Library (LPTLib) drivers. Because the instruments controlled this way
do not have drivers that automatically interact with matrix control, you must clear all sources before
performing any matrix operations.
You must also ensure that the instruments are returned to their default state at the end of a test
sequence. You can use the
kibdefclr
and
kibdefint
commands to do this. These commands
allow you to define strings that are sent to GPIB instruments any time the system is executing a
devclr
or
devint
command.
Failure to clear active GPIB-based sources before a matrix operation is performed could result in
damage to the matrix.