Model 2651A High Power System SourceMeter® Instrument Reference Manual
Section 2: General operation
2651A-901-01 Rev. A / March 2011
2-27
Source-measure programming example
The following programming example illustrates the setup and command sequence of a basic
source-measure procedure with the following parameters:
•
Source function and range: volts, autorange
•
Source output level: 5 V
•
Current compliance limit: 10 mA
•
Measure function and range: current, 10 mA
-- Restore Model 2651A defaults.
smua.reset()
-- Select voltage source function.
smua.source.func = smua.OUTPUT_DCVOLTS
-- Set source range to auto.
smua.source.autorangev = smua.AUTORANGE_ON
-- Set voltage source to 5 V.
smua.source.levelv = 5
-- Set current limit to 10 mA.
smua.source.limiti = 10e-3
-- Set current range to 10 mA.
smua.measure.rangei = 10e-3
-- Turn on output.
smua.source.output = smua.OUTPUT_ON
-- Print and place current reading in buffer.
print(smua.measure.i(smua.nvbuffer1))
-- Turn off output.
smua.source.output = smua.OUTPUT_OFF
-- Beep.
beeper.enable = beeper.ON
beeper.beep(1, 1200)
beeper.enable = beeper.OFF
Triggering in local mode
It is not necessary to change any trigger settings to use the basic source and measurement
procedures covered in this section, however it is important to reset the instrument before triggering in
local mode.
Press the
MENU
key, and then select
SETUP > RECALL > INTERNAL > FACTORY
to reset the
factory default conditions.