In TestFlow's instrument library, the Keithley 2000 takes 91 SCPI commands, 25 of them queries, and the Keysight 34401A takes 94 SCPI commands, 27 of them queries. That is 3 more on the 34401A. Counting distinct command headers (the command path without its arguments), 39 are accepted by both, 23 exist only on the 2000, and 40 only on the 34401A. 63% of the 2000's command headers also exist on the 34401A.
Both libraries have commands under SENSe, MEASure, SYSTem, CALCulate, SAMPle, TRIGger, READ, and FETCh, plus 1 more root. Only the 2000 has UNIT, TRACe, and ABORt. Only the 34401A has CONFigure, DISPlay, INPut, and DATA.
Both libraries synchronise with *OPC?. Both libraries read errors with SYSTem:ERRor?.
Describe the test; TestFlow's agent uses these command sets to drive your Keithley 2000 or Keysight 34401A and writes the report from the measured results.
Counts come from TestFlow's instrument library, the command sets its AI agent uses to drive each instrument. A distinct command header is the command path without its arguments, so :OUTPut ON and :OUTPut OFF count once.
| Keithley 2000 | Keysight 34401A | |
|---|---|---|
| Commands in TestFlow's library | 91 | 94 |
| Queries (read a value or state) | 25 | 27 |
| Settings and actions | 66 | 67 |
| Subsystems | 16 | 17 |
| Distinct command headers | 62 | 79 |
| Headers the other lacks | 23 | 40 |
| Command language | SCPI | SCPI |
| Operation complete | *OPC? | *OPC? |
| Error queue | SYSTem:ERRor? | SYSTem:ERRor? |
| Models on this command set | 2000 | 34401A |
39 command headers are in both libraries. Here are 12, taken across subsystems. Where the 34401A library writes the command differently, its form is shown under the 2000's.
| Command | What it does |
|---|---|
| :SENSe:FUNCtion "VOLT:DC"34401A: SENSe:FUNCtion "<Function>" | Func DCV. Selects DC voltage as the active measurement function. |
| :MEASure:VOLTage:DC?34401A: MEASure:VOLTage:DC? <Range>,<Resolution> | Measure DCV. Sets the function to DC voltage and returns one measured reading in volts. |
| :SYSTem:BEEPer:STATe ON | Continuity Beeper On. Enables the audible beeper used during continuity testing. |
| :SAMPle:COUNt <Count> | Set Sample Count. Sets the number of measurements made when a measurement is requested (1 to 1000000). |
| :TRIGger:SOURce <Source> | Set Trigger Source. Defines a trigger-model block that makes measurements at the specified block number. |
| :READ? | Read. Triggers and returns one reading from the active function using the default reading buffer. |
| :FETCh? | Fetch. Returns the latest reading from the buffer without triggering a new measurement. |
| :INITiate | Init Trigger Model. Starts the trigger model and begins the configured measurement sequence. |
| *IDN? | Identify. Returns the instrument identification string (manufacturer, model, serial, firmware). |
| :SENSe:FUNCtion? | Read Function. Queries the currently selected measurement function string. |
| :MEASure:VOLTage:AC?34401A: MEASure:VOLTage:AC? <Range>,<Resolution> | Measure ACV. Sets the function to AC voltage and returns one measured reading in volts. |
| :SAMPle:COUNt? | Read Sample Count. Queries the number of measurements made per measurement request. |
23 command headers in the 2000 library have no match in the 34401A library. Below are 15 of them from the 6 largest subsystems; the full list is in the Keithley 2000 command reference.
| Command | What it does |
|---|---|
| :SENSe:VOLTage:AC:DETector:BANDwidth <Bandwidth> | Set ACV Detector BW. Sets the AC voltage detector bandwidth in Hz (3, 30 or 300). |
| :SENSe:CURRent:AC:DETector:BANDwidth <Bandwidth> | Set ACI Detector BW. Sets the AC current detector bandwidth in Hz (3, 30 or 300). |
| :SENSe:VOLTage:DC:AVERage:COUNt <Count> | Set DCV Average Count. Sets the number of readings in the DC voltage filter average (1 to 100). |
| :SENSe:VOLTage:DC:AVERage:TCONtrol <Type> | Set DCV Average TCon. Sets the DC voltage averaging filter type to repeating or moving. |
| Command | What it does |
|---|---|
| :UNIT:VOLTage:AC DB | Set ACV Unit dB. Sets the AC voltage measurement unit to dB. |
| :UNIT:VOLTage:AC:DB:REFerence <Reference> | Set ACV dB Reference. Sets the dB reference voltage for the AC voltage function (1e-7 to 1000 V). |
| :UNIT:VOLTage:AC:DBM:IMPedance <Impedance> | Set ACV dBm Reference. Sets the dBm reference impedance for the AC voltage function (1 to 9999 ohms). |
| :UNIT:TEMPerature <Unit> | Set Temp Unit. Sets the units used for temperature measurements. |
| Command | What it does |
|---|---|
| :MEASure? | Measure. Makes a measurement using the active function and returns the reading. |
| :MEASure:TEMPerature? | Measure Temperature. Sets the function to temperature and returns one reading in the configured units. |
| Command | What it does |
|---|---|
| :SYSTem:AZERo:STATe ON | Set DCV AZero On. Enables autozero for the DC voltage function. |
| :SYSTem:ERRor:NEXT? | Read Error. Reads and removes the oldest message from the error queue (0,"No error" if empty). |
| Command | What it does |
|---|---|
| :TRACe:CLEar | Clear Buffer. Clears all readings and statistics from the default reading buffer. |
| :TRACe:FREE? | Read Buffer Actual. Returns the number of readings currently stored in the default reading buffer. |
| Command | What it does |
|---|---|
| :ABORt | Abort Trigger Model. Stops all trigger-model commands and returns the instrument to idle. |
40 command headers in the 34401A library have no match in the 2000 library. Below are 21 of them from the 6 largest subsystems; the full list is in the Keysight 34401A command reference.
| Command | What it does |
|---|---|
| CALCulate:STATe ON | Math Null On. Enables the scaling (null/dB/dBm) math operation on measurements. |
| CALCulate:FUNCtion <Function> | Set Scale Function. Selects the scaling function applied to measurements. |
| CALCulate:NULL:OFFSet <Reference> | Set Null Reference. Sets the reference (null) value used by the scaling function. |
| CALCulate:DB:REFerence <Reference> | Set dBm Reference. Sets the relative dB reference value in dBm. |
| Command | What it does |
|---|---|
| CONFigure:VOLTage:DC <Range>,<Resolution> | Conf DCV. Configures the instrument for DC voltage measurement with the given range and resolution. |
| CONFigure:VOLTage:AC <Range>,<Resolution> | Conf ACV. Configures the instrument for AC voltage measurement with the given range and resolution. |
| CONFigure:CURRent:DC <Range>,<Resolution> | Conf DCI. Configures the instrument for DC current measurement with the given range and resolution. |
| CONFigure:CURRent:AC <Range>,<Resolution> | Conf ACI. Configures the instrument for AC current measurement with the given range and resolution. |
| Command | What it does |
|---|---|
| SYSTem:BEEPer | Beep. Issues a single beep from the instrument. |
| SYSTem:ERRor? | Read Error. Reads and clears one error from the error queue (returns 0,"No error" if empty). |
| SYSTem:VERSion? | Read SCPI Version. Returns the SCPI version to which the instrument complies. |
| SYSTem:LOCal | Local. Returns the instrument to local (front-panel) control. |
| Command | What it does |
|---|---|
| DISPlay:STATe ON | Display On. Turns the front-panel display on. |
| DISPlay:TEXT "<Message>" | Set Display Text. Displays the specified text message on the front-panel display. |
| DISPlay:TEXT:CLEar | Clear Display Text. Clears the text message shown on the front-panel display. |
| Command | What it does |
|---|---|
| SENSe:VOLTage:DC:RESolution <Resolution> | Set DCV Resolution. Sets the measurement resolution for DC voltage measurements. |
| SENSe:DETector:BANDwidth 3 | ACV Filter 3Hz. Sets the AC voltage filter bandwidth to 3 Hz (slow). |
| SENSe:ZERO:AUTO <State> | Set AutoZero. Enables or disables the autozero mode for DC voltage measurements. |
| Command | What it does |
|---|---|
| TRIGger:SOURce? | Read Trigger Source. Returns the present trigger source. |
| TRIGger:DELay <Seconds> | Set Trigger Delay. Sets the delay between the trigger signal and the first measurement. |
| TRIGger:DELay:AUTO ON | Trigger Delay Auto On. Enables automatic trigger delay based on function and range. |
With PyVISA and any VISA backend, this opens both instruments, identifies them, sends one setting, and reads one value from each. For the setting, both libraries hold :SENSe:FUNCtion (func dcv); the 34401A library writes it as SENSe:FUNCtion "VOLTage:DC". For the reading, both libraries hold :MEASure:VOLTage:DC? (measure dcv); the 34401A library writes it as MEASure:VOLTage:DC? AUTO,MIN. For the basics, see the PyVISA tutorial.
import pyvisa
rm = pyvisa.ResourceManager()
print(rm.list_resources()) # find both VISA addresses
a = rm.open_resource("PASTE_2000_ADDRESS") # Keithley 2000
b = rm.open_resource("PASTE_34401A_ADDRESS") # Keysight 34401A
for inst in (a, b):
inst.timeout = 5000 # ms
print(inst.query("*IDN?"))
# The same setting on both: Func DCV
a.write(":SENSe:FUNCtion \"VOLT:DC\"")
b.write("SENSe:FUNCtion \"VOLTage:DC\"")
# The same reading on both: Measure DCV
print(a.query(":MEASure:VOLTage:DC?"))
print(b.query("MEASure:VOLTage:DC? AUTO,MIN"))
a.close()
b.close()Describe the test; TestFlow's agent uses these command sets to drive your Keithley 2000 or Keysight 34401A and writes the report from the measured results.
In TestFlow's library the 2000 has 91 SCPI commands and the 34401A has 94 SCPI commands. 39 command headers are common to both, 23 are only on the 2000 (mostly SENSe and UNIT), and 40 are only on the 34401A (mostly CALCulate and CONFigure).
Partly. 39 command headers are accepted by both, including :SENSe:FUNCtion, :MEASure:VOLTage:DC?, and :SYSTem:BEEPer:STATe. 63 are not, for example :SENSe:VOLTage:AC:DETector:BANDwidth on the 2000 and CALCulate:STATe on the 34401A, so a script that uses those needs a separate branch for each instrument.
The 34401A: 91 commands for the 2000 against 94 for the 34401A in TestFlow's library. Of those, 25 on the 2000 and 27 on the 34401A are queries that read a value or state, and the library splits them into 16 and 17 subsystems.
Both libraries synchronise with *OPC?. Both libraries read errors with SYSTem:ERRor?. Each command named here is listed in the tables on this page and on each instrument's command reference.
Describe the test. TestFlow builds the workflow, runs it on your instruments, and writes the report. See it on a bench like yours.