You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The keithley_driver.py drastically simplifies working with Keithley 2651A when performing DC sweep. But running the "voltageSweepSingleSMU" with "pulsed" setting, such that the power source operates only in "pulsed mode area" (outside of DC area) causes that the function hangs on keithley_driver.py line 927:
# while loop that runs until the sweep begins
while self.status.operation.sweeping.condition == 0:
time.sleep(0.1)
OR the function "voltageSweepSingleSMU" returns successfully, but after the execution, the error codes are set:
-286: TSP Runtime error at line 1: attempt to index field `smub' (a nil value)
5028: SMU A: Cannot perform requested operation while source autorange is enabled
1011: Parameter too big
The measured values re being often (not always!) incorrect (the sweep is not finished, the higher values, usually above 20 [V] are change and go back to 0[V]). Keithley 2651A should be able to perform "pulsed" sweep up to 40[V] and 50[A]. The test is performed for a device that reaches 5[A] at 27[V], which is above the DC operation, but well within the "pulsed" mode limit.
The code below should reproduce the behavior.
#%% Import
from keithley2600 import Keithley2600 # uses pyvisa to produce an object/session to represent Keithley 2651A
import numpy as np # arrays and operations on arrays
import time # timing (sleep)
import matplotlib.pyplot as plt # plotting
#%% User input
v_reverse = 15.0 # [V] (less than 40 [V])
v_reverse_max = 40 # [V]
i_reverse_max = 20 # [V] Only pulsed operation
v_reverse_len = 5
#%% Perform measurement
k = Keithley2600('TCPIP0::192.168.0.101::inst0::INSTR')
k.connect()
time.sleep(1.0)
if( not k.connected ):
raise TypeError("Device not connected")
print('connect: OK')
k.smua.reset()
print('reset: OK')
k.smua.source.output = k.smua.OUTPUT_ON # turn on SMUA
print('measure: START')
#%% Memory allocation
v_meas = np.zeros((v_reverse_len,1))
i_meas = np.zeros((v_reverse_len,1))
#%% reverse measurement
k.smua.source.limitv = v_reverse_max # set voltage limit
k.smua.source.limiti = i_reverse_max # set current limit
#[v_meas, i_meas] = k.voltageSweepSingleSMU(smu=k.smua, smu_sweeplist=np.arange(0,v_reverse,3), t_int=0.001, delay=0.1, pulsed=True)
#print('measure: reverse END')
[v_meas, i_meas] = k.voltageSweepSingleSMU(smu=k.smua, smu_sweeplist=[20], t_int=0.001, delay=0.1, pulsed=True)
print('measure: reverse END')
errs_end = k.readErrorQueue() # gets all entries from error queue
print('read errors: OK')
#k.smua.nvbuffer1.clear() # clears nvbuffer1 of SMUA
#print('clear buffer: OK')
k.smua.source.output = k.smua.OUTPUT_OFF # turn off SMUA
print('output off: OK')
k.disconnect()
print('disconnect: OK')
#%% Plotting
plt.plot(v_meas, i_meas)
plt.plot(v_meas, i_meas, 'ro')
plt.ylabel('I [A]')
plt.xlabel('V [V]')
plt.xlim(-5, 40)
plt.ylim(-0.2, 0.2)
plt.show()
The text was updated successfully, but these errors were encountered:
I have never tested the driver with the 2651A model and the available commands are generated from the reference manual for the series 2600B. While the instruments share most commands, the availability of some settings seems to be different (e.g., voltage limits, etc), causing issues with the custom sweep functions.
The measured values re being often (not always!) incorrect
This is very confusing. It looks some state may be retained from a previous sweep but I am not sure how. As for the specific errors:
-286: TSP Runtime error at line 1: attempt to index field 'smub' (a nil value). This occurs because the 2651A model only has a single SMU and the sweep script tells the Keithley to display the currents from both SMUs. The error is safe to ignore.
5028: SMU A: Cannot perform requested operation while source autorange is enabled: Not sure where this is coming from.
1011: Parameter too big: also no idea. But I suspect this may be related to the issue with the sweeps.
Could set raise_keithley_errors to True and run through the sweep line by line to see which lines exactly raise errors on the Keithley?
The keithley_driver.py drastically simplifies working with Keithley 2651A when performing DC sweep. But running the "voltageSweepSingleSMU" with "pulsed" setting, such that the power source operates only in "pulsed mode area" (outside of DC area) causes that the function hangs on keithley_driver.py line 927:
# while loop that runs until the sweep begins
while self.status.operation.sweeping.condition == 0:
time.sleep(0.1)
OR the function "voltageSweepSingleSMU" returns successfully, but after the execution, the error codes are set:
-286: TSP Runtime error at line 1: attempt to index field `smub' (a nil value)
5028: SMU A: Cannot perform requested operation while source autorange is enabled
1011: Parameter too big
The measured values re being often (not always!) incorrect (the sweep is not finished, the higher values, usually above 20 [V] are change and go back to 0[V]). Keithley 2651A should be able to perform "pulsed" sweep up to 40[V] and 50[A]. The test is performed for a device that reaches 5[A] at 27[V], which is above the DC operation, but well within the "pulsed" mode limit.
The code below should reproduce the behavior.
The text was updated successfully, but these errors were encountered: