5: Leakage current and insulation resistance Model 2470 High Voltage SourceMeter Instrument
5-8 2470-900-01 Rev. A / May 2019
To enable TSP commands:
1. Press the MENU key.
2. Under System, select Settings.
3. Set the Command Set to TSP.
4. At the prompt to reboot, select Yes.
The following TSP code performs a capacitor leakage measurement by sourcing 300 V and
measuring the resulting leakage current. The DurationLoop trigger model template applies the voltage
for 30 seconds and makes measurements at 200 ms intervals. After the duration time, the capacitor is
discharged at 0 V and the output is turned off.
After the code is executed, the measurement results are displayed in the Instrument Console of Test
Script Builder. From the Instrument Console, you can copy the data into a spreadsheet for graphing.
Send the following commands for this example application:
-- Reset the instrument, which also clears the buffer.
reset()
-- Set up the source function.
smu.source.func = smu.FUNC_DC_VOLTAGE
smu.source.ilimit.level = 10e-3
smu.source.level = 300
-- Set up measure function.
smu.measure.func = smu.FUNC_DC_CURRENT
smu.terminals = smu.TERMINALS_REAR
smu.measure.autorange = smu.ON
smu.measure.nplc = 1
-- Turn on the output and initiate readings.
trigger.model.load("DurationLoop", 30, 0.2)
trigger.model.initiate()
-- Wait for the trigger model to complete.
waitcomplete()
-- Parse index and data into three columns.
print("Rdg #,", "Time (s),", "Current (A)")
for i = 1, defbuffer1.n do
print(i, defbuffer1.relativetimestamps[i], defbuffer1[i])
end
-- Discharge the capacitor to 0 V and turn off the output.
smu.source.level = 0
smu.source.output = smu.ON
delay(2)
smu.source.output = smu.OFF