In TestFlow's instrument library, the Keysight 34401A takes 94 SCPI commands, 27 of them queries, and the Keysight 34460A takes 50 SCPI commands, 18 of them queries. That is 44 more on the 34401A. Counting distinct command headers (the command path without its arguments), 32 are accepted by both, 47 exist only on the 34401A, and 14 only on the 34460A. 41% of the 34401A's command headers also exist on the 34460A.
Both libraries have commands under SENSe, CONFigure, MEASure, SYSTem, TRIGger, DISPlay, SAMPle, and INITiate, plus 2 more roots. Only the 34401A has CALCulate, INPut, and DATA.
Both libraries synchronise with *OPC?. Both libraries read errors with SYSTem:ERRor?.
TestFlow's library gives the 34470A the same command set as the 34460A, so the 34460A column applies to it too.
Describe the test; TestFlow's agent uses these command sets to drive your Keysight 34401A or Keysight 34460A 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.
| Keysight 34401A | Keysight 34460A | |
|---|---|---|
| Commands in TestFlow's library | 94 | 50 |
| Queries (read a value or state) | 27 | 18 |
| Settings and actions | 67 | 32 |
| Subsystems | 17 | 14 |
| Distinct command headers | 79 | 46 |
| Headers the other lacks | 47 | 14 |
| Command language | SCPI | SCPI |
| Operation complete | *OPC? | *OPC? |
| Error queue | SYSTem:ERRor? | SYSTem:ERRor? |
| Models on this command set | 34401A | 34460A, 34470A |
32 command headers are in both libraries. Here are 12, taken across subsystems. Where the 34460A library writes the command differently, its form is shown under the 34401A's.
| Command | What it does |
|---|---|
| SENSe:FUNCtion "<Function>"34460A: :SENS:FUNC "<Sense>" | Set Function. Selects the active measurement function using the SENSe function name. |
| CONFigure:VOLTage:DC <Range>,<Resolution>34460A: :CONF:VOLT:DC <Range>,<Resolution> | Conf DCV. Configures the instrument for DC voltage measurement with the given range and resolution. |
| MEASure:VOLTage:DC? <Range>,<Resolution>34460A: :MEAS:VOLT:DC? <Range>,<Resolution> | Measure DCV. Configures and returns a one-shot DC voltage measurement in volts. |
| SYSTem:ERRor?34460A: :SYST:ERR? | Read Error. Reads and clears one error from the error queue (returns 0,"No error" if empty). |
| TRIGger:SOURce <Source>34460A: :TRIG:SOUR <Source> | Set Trigger Source. Selects the trigger source for measurements. |
| DISPlay:TEXT "<Message>"34460A: :DISP:TEXT "<Message>" | Set Display Text. Displays the specified text message on the front-panel display. |
| SAMPle:COUNt <Count>34460A: :SAMP:COUN <Count> | Set Sample Count. Sets the number of measurements taken per trigger. |
| INITiate34460A: :INIT | Init. Places the instrument in the wait-for-trigger state and stores readings in memory when triggered. |
| READ? | Read. Starts a new measurement and returns the reading directly without storing it in reading memory. |
| FETCh? | Fetch. Returns measurements stored in reading memory by the INITiate command. |
| *IDN? | Identify. Returns the instrument identification string (manufacturer, model, serial, firmware). |
| SENSe:VOLTage:DC:RANGe <Range>34460A: :SENS:VOLT:DC:RANG <Range> | Set DCV Range. Sets the manual range for DC voltage measurements. |
47 command headers in the 34401A library have no match in the 34460A library. Below are 22 of them from the 6 largest subsystems; the full list is in the Keysight 34401A command reference.
| Command | What it does |
|---|---|
| SENSe:FUNCtion? | Read Function. Returns the present measurement function as a quoted string. |
| SENSe:VOLTage:AC:RANGe <Range> | Set ACV Range. Sets the manual range for AC voltage measurements. |
| SENSe:CURRent:DC:RANGe <Range> | Set DCI Range. Sets the manual range for DC current measurements. |
| SENSe:CURRent:AC:RANGe <Range> | Set ACI Range. Sets the manual range for AC current measurements. |
| 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:PERiod <Range>,<Resolution> | Conf Period. Configures the instrument for period measurement with the given range and resolution. |
| CONFigure:CONTinuity | Conf Continuity. Configures the instrument for continuity measurement. |
| CONFigure:DIODe | Conf Diode. Configures the instrument for diode test measurement. |
| CONFigure? | Read Conf. Returns the present function and configuration as a quoted string. |
| Command | What it does |
|---|---|
| SYSTem:BEEPer:STATe ON | Beeper On. Enables the beeper for continuity and other audible alerts. |
| SYSTem:BEEPer | Beep. Issues a single beep from the instrument. |
| SYSTem:VERSion? | Read SCPI Version. Returns the SCPI version to which the instrument complies. |
| SYSTem:REMote | Remote. Places the instrument in remote control and disables front-panel keys except Local. |
| Command | What it does |
|---|---|
| MEASure:PERiod? <Range>,<Resolution> | Measure Period. Configures and returns a one-shot period measurement in seconds. |
| MEASure:CONTinuity? | Measure Continuity. Configures and returns a one-shot continuity measurement in ohms. |
| MEASure:DIODe? | Measure Diode. Configures and returns a one-shot diode test measurement in volts. |
| 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. |
14 command headers in the 34460A library have no match in the 34401A library. Below are 10 of them from the 5 largest subsystems; the full list is in the Keysight 34460A command reference.
| Command | What it does |
|---|---|
| *ESE <Mask> | Standard Event Enable. Sets the Standard Event Status Enable register mask. |
| *ESE? | Standard Event Enable Query. Queries the Standard Event Status Enable register. |
| *ESR? | Event Status Register Query. Queries the Standard Event Status Register. |
| *OPC | Operation Complete. Sets the Operation Complete flag when pending operations finish. |
| Command | What it does |
|---|---|
| :SENS:VOLT:NPLC <NPLC> | Volt NPLC. Sets the integration time in number of power line cycles. |
| :SENS:VOLT:DC:ZERO:AUTO <ON_OFF> | Auto zero. Enables or disables DC voltage autozero (ON, OFF, or ONCE). |
| :SENS:<Function>:RES <Resolution> | Resolution. Sets the resolution for the selected measurement function. |
| Command | What it does |
|---|---|
| :CONF:TEMP <Probe>,<Type> | Configure Temperature. Configures temperature: probe FRTD/RTD (type 85), FTHermistor/THERmistor (type 5000). |
| Command | What it does |
|---|---|
| :DISP <ON_OFF> | Display OnOff. Enables or disables the display. |
| Command | What it does |
|---|---|
| :MEAS:TEMP? <Probe>,<Type> | Measure Temperature. Measures temperature: probe FRTD/RTD (type 85), FTHermistor/THERmistor (type 5000). |
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 (set function); the 34460A library writes it as :SENS:FUNC "VOLT:DC". For the reading, both libraries hold SYSTem:ERRor? (read error); the 34460A library writes it as :SYST:ERR?. 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_34401A_ADDRESS") # Keysight 34401A
b = rm.open_resource("PASTE_34460A_ADDRESS") # Keysight 34460A
for inst in (a, b):
inst.timeout = 5000 # ms
print(inst.query("*IDN?"))
# The same setting on both: Set Function
a.write("SENSe:FUNCtion \"VOLTage:DC\"")
b.write(":SENS:FUNC \"VOLT:DC\"")
# The same reading on both: Read Error
print(a.query("SYSTem:ERRor?"))
print(b.query(":SYST:ERR?"))
a.close()
b.close()Describe the test; TestFlow's agent uses these command sets to drive your Keysight 34401A or Keysight 34460A and writes the report from the measured results.
In TestFlow's library the 34401A has 94 SCPI commands and the 34460A has 50 SCPI commands. 32 command headers are common to both, 47 are only on the 34401A (mostly SENSe and CALCulate), and 14 are only on the 34460A (mostly IEEE 488.2 common (*) and SENS).
Partly. 32 command headers are accepted by both, including SENSe:FUNCtion, CONFigure:VOLTage:DC, and MEASure:VOLTage:DC?. 61 are not, for example SENSe:FUNCtion? on the 34401A and *ESE on the 34460A, so a script that uses those needs a separate branch for each instrument.
The 34401A: 94 commands for the 34401A against 50 for the 34460A in TestFlow's library. Of those, 27 on the 34401A and 18 on the 34460A are queries that read a value or state, and the library splits them into 17 and 14 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.