Oscilloscope · SCPI command comparison

Keysight DSOX3024A vs Rohde & Schwarz RTA4004: SCPI commands and remote control compared

In TestFlow's instrument library, the Keysight DSOX3024A takes 175 SCPI commands, 68 of them queries, and the Rohde & Schwarz RTA4004 takes 83 SCPI commands, 30 of them queries. That is 92 more on the DSOX3024A. Counting distinct command headers (the command path without its arguments), 22 are accepted by both, 134 exist only on the DSOX3024A, and 58 only on the RTA4004. 14% of the DSOX3024A's command headers also exist on the RTA4004.

Both libraries have commands under MEASure, CHANnel, TRIGger, TIMebase, SYSTem, RUN, STOP, and SINGle. Only the DSOX3024A has WAVeform, WGEN, ACQuire, FUNCtion, DISPlay, and DVM and 5 more. Only the RTA4004 has SPECtrum, MMEMory, HCOPy, and EXPort.

Both libraries synchronise with *OPC?. Both libraries read errors with SYSTem:ERRor?.

TestFlow's library gives the DSOX3032A, DSOX3034A, DSOX3052A, DSOX3054A, DSOX3102A, and DSOX3104A the same command set as the DSOX3024A, so the DSOX3024A column applies to them too. TestFlow's library gives the RTA4006, RTA4012, RTA4014, RTA4024, and RTA4044 the same command set as the RTA4004, so the RTA4004 column applies to them too.

DSOX3024A commands
175
RTA4004 commands
83
Shared headers
22
Unique headers
192

Run this on your bench

Describe the test; TestFlow's agent uses these command sets to drive your Keysight DSOX3024A or Rohde & Schwarz RTA4004 and writes the report from the measured results.

Get started

DSOX3024A vs RTA4004 at a glance

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 DSOX3024ARohde & Schwarz RTA4004
Commands in TestFlow's library17583
Queries (read a value or state)6830
Settings and actions10753
Subsystems2216
Distinct command headers15680
Headers the other lacks13458
Command languageSCPISCPI
Operation complete*OPC?*OPC?
Error queueSYSTem:ERRor?SYSTem:ERRor?
Models on this command setDSOX3024A, DSOX3032A, DSOX3034A, DSOX3052A, DSOX3054A, DSOX3102A, DSOX3104ARTA4004, RTA4006, RTA4012, RTA4014, RTA4024, RTA4044

Commands both accept

22 command headers are in both libraries. Here are 12, taken across subsystems. Where the RTA4004 library writes the command differently, its form is shown under the DSOX3024A's.

CommandWhat it does
:MEASure:SOURce <Source>RTA4004: MEASurement1:SOURce CH<Channel> ; ...Measure Source. Selects the source used by subsequent measurement commands.
:CHANnel<Channel>:COUPling <Coupling>Channel Coupling. Selects the input coupling of the specified analog channel.
:TIMebase:SCALe <Scale>RTA4004: TIMebase:SCALe <SecDiv>Timebase Scale. Sets the main timebase in seconds per division.
:SYSTem:ERRor?Get Error. Reads and clears the next entry in the error queue.
:RUNRun. Starts repetitive acquisitions (same as pressing the Run key on the front panel).
:STOPStop. Stops the acquisition system and freezes the last acquired waveform on screen.
:SINGleSingle Trigger. Arms the oscilloscope for a single acquisition and stops after the trigger occurs.
*IDN?Identify. Returns the instrument identification string (manufacturer, model, serial number, firmware version).
:CHANnel<Channel>:COUPling?Get Channel Coupling. Queries the input coupling of the specified analog channel.
:TIMebase:SCALe?Get Timebase Scale. Queries the main timebase in seconds per division.
*RSTReset. Restores the oscilloscope to its factory default state.
:CHANnel<Channel>:SCALe <Scale>RTA4004: CHANnel<Channel>:SCALe <VoltsDiv>Channel Scale. Sets the vertical scale of the specified channel in units per division.

Only on the Keysight DSOX3024A

134 command headers in the DSOX3024A library have no match in the RTA4004 library. Below are 24 of them from the 6 largest subsystems; the full list is in the Keysight DSOX3024A command reference.

MEASure (31 only on the DSOX3024A)

CommandWhat it does
:MEASure:SOURce?Get Measure Source. Queries the source currently selected for measurements.
:MEASure:WINDow <Window>Measure Window. Selects whether measurements are made in the main window, the zoomed window or gated by markers.
:MEASure:VPP? <Source>Measure Vpp. Measures the peak-to-peak voltage of the selected source.
:MEASure:VMAX? <Source>Measure Vmax. Measures the maximum voltage of the selected source.

TRIGger (17 only on the DSOX3024A)

CommandWhat it does
:TRIGger:FORCeForce Trigger. Forces an immediate trigger event regardless of whether the trigger condition is met.
:TRIGger:MODE <Mode>Trigger Mode. Selects the trigger type used by the oscilloscope.
:TRIGger:MODE?Get Trigger Mode. Queries the currently selected trigger type.
:TRIGger:SWEep <Sweep>Trigger Sweep. Selects auto or triggered (normal) sweep mode.

WAVeform (14 only on the DSOX3024A)

CommandWhat it does
:WAVeform:SOURce <Source>Waveform Source. Selects the source of the waveform data read back over the bus.
:WAVeform:FORMat <Format>Waveform Format. Sets the data transmission format of the waveform data.
:WAVeform:POINts <Points>Waveform Points. Sets the number of waveform points transferred from the oscilloscope.
:WAVeform:POINts:MODE <Mode>Waveform Points Mode. Selects whether measurement-record, maximum or raw acquisition-record points are transferred.

CHANnel (13 only on the DSOX3024A)

CommandWhat it does
:CHANnel<Channel>:DISPlay ONChannel On. Turns on the display of the specified analog channel.
:CHANnel<Channel>:DISPlay?Get Channel State. Queries whether the specified analog channel is displayed (1) or not (0).
:CHANnel<Channel>:IMPedance <Impedance>Channel Impedance. Selects the input impedance of the specified analog channel (1 MOhm or 50 Ohm).
:CHANnel<Channel>:IMPedance?Get Channel Impedance. Queries the input impedance of the specified analog channel.

WGEN (12 only on the DSOX3024A)

CommandWhat it does
:WGEN:FUNCtion <Function>Wgen Function. Selects the waveform shape produced by the built-in waveform generator.
:WGEN:FREQuency <Frequency>Wgen Frequency. Sets the waveform generator output frequency in hertz.
:WGEN:VOLTage <Amplitude>Wgen Amplitude. Sets the waveform generator output amplitude in volts peak-to-peak.
:WGEN:VOLTage:OFFSet <Offset>Wgen Offset. Sets the waveform generator DC offset voltage.

ACQuire (10 only on the DSOX3024A)

CommandWhat it does
:ACQuire:TYPE <Type>Acquire Type. Selects the acquisition type used to build each waveform record.
:ACQuire:TYPE?Get Acquire Type. Queries the acquisition type currently selected.
:ACQuire:COUNt <Count>Acquire Count. Sets the number of acquisitions averaged per time bucket in AVERage acquisition type (2 to 65536).
:ACQuire:COUNt?Get Acquire Count. Queries the averaging count currently selected.

Only on the Rohde & Schwarz RTA4004

58 command headers in the RTA4004 library have no match in the DSOX3024A library. Below are 24 of them from the 6 largest subsystems; the full list is in the Rohde & Schwarz RTA4004 command reference.

SPECtrum (23 only on the RTA4004)

CommandWhat it does
SPECtrum:STATe <OnOff>Spectrum Enable. Enable/disable spectrum (FFT) analysis.
SPECtrum:SOURce <Source>Spectrum Source. Set spectrum analysis source waveform.
SPECtrum:FREQuency:CENTer <CenterHz>Spectrum Center Frequency. Set center frequency (Hz).
SPECtrum:FREQuency:SPAN <SpanHz>Spectrum Span. Set frequency span (Hz).

MMEMory (10 only on the RTA4004)

CommandWhat it does
MMEMory:NAME <FileName>Screenshot FileName. Set the filename used by HCOPy[:IMMediate].
MMEMory:DRIVes?List Drives. List available storage devices/drives.
MMEMory:MDIRectory <DirPath>Make Directory. Create a directory.
MMEMory:CDIRectory <DirPath>Change Directory. Change current directory.

TRIGger (8 only on the RTA4004)

CommandWhat it does
TRIGger:A:TYPE <Type>Trigger Type. Set trigger type (edge/pulse/etc.).
TRIGger:A:TYPE?Read Trigger Type. Query trigger type.
TRIGger:A:SOURce <Source>Trigger Source. Set trigger source.
TRIGger:A:SOURce?Read Trigger Source. Query trigger source.

HCOPy (6 only on the RTA4004)

CommandWhat it does
HCOPy:CWINdow <OnOff>Screenshot Close Windows. Close dialog boxes/menus before saving screenshot.
HCOPy:IMMediateScreenshot Save To File. Save screenshot to file using current directory and filename settings.
HCOPy:FORMat PNGCapture. Return screenshot image data as IEEE 488.2 block data.
HCOPy:COLor:SCHeme <ColorScheme>Screenshot Color Scheme. Set screenshot color scheme.

CHANnel (5 only on the RTA4004)

CommandWhat it does
CHANnel<Channel>:STATe <OnOff>Channel Enable. Enable/disable an analog channel.
CHANnel<Channel>:STATe?Read Channel Enable. Query enable/disable state of an analog channel.
CHANnel<Channel>:POSition <Div>Channel Position. Set channel trace position (div).
CHANnel<Channel>:POSition?Read Channel Position. Query channel trace position (div).

EXPort (5 only on the RTA4004)

CommandWhat it does
EXPort:WAVeform:SOURce <WaveformSource>Waveform Export Source. Select waveform source for export.
EXPort:WFMSave:DESTination <DirPath>Waveform Export Destination. Set directory path where waveform files are saved (must exist).
EXPort:WAVeform:NAME <FileName>Waveform Export Name. Set waveform file path/name (extension defined by FORMat[DATA]).
EXPort:WAVeform:SAVEWaveform Export Save. Execute saving waveform to the previously defined name/path.

Control both from Python

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 :CHANnel<Channel>:COUPling (channel coupling); the RTA4004 library writes it as CHANnel1:COUPling DCLimit. For the reading, both libraries hold :CHANnel<Channel>:COUPling? (get channel coupling), and the same line runs on each. 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_DSOX3024A_ADDRESS")  # Keysight DSOX3024A
b = rm.open_resource("PASTE_RTA4004_ADDRESS")  # Rohde & Schwarz RTA4004
for inst in (a, b):
    inst.timeout = 5000  # ms
    print(inst.query("*IDN?"))

# The same setting on both: Channel Coupling
a.write(":CHANnel1:COUPling AC")
b.write("CHANnel1:COUPling DCLimit")

# The same reading on both: Get Channel Coupling
print(a.query(":CHANnel1:COUPling?"))
print(b.query("CHANnel1:COUPling?"))

a.close()
b.close()

Run this on your bench

Describe the test; TestFlow's agent uses these command sets to drive your Keysight DSOX3024A or Rohde & Schwarz RTA4004 and writes the report from the measured results.

Get started

Frequently asked questions

What is the difference between the Keysight DSOX3024A and the Rohde & Schwarz RTA4004 for remote control?

In TestFlow's library the DSOX3024A has 175 SCPI commands and the RTA4004 has 83 SCPI commands. 22 command headers are common to both, 134 are only on the DSOX3024A (mostly MEASure and TRIGger), and 58 are only on the RTA4004 (mostly SPECtrum and MMEMory).

Can I use the same SCPI code for the Keysight DSOX3024A and the Rohde & Schwarz RTA4004?

Partly. 22 command headers are accepted by both, including :MEASure:SOURce, :CHANnel<Channel>:COUPling, and :TIMebase:SCALe. 192 are not, for example :MEASure:SOURce? on the DSOX3024A and SPECtrum:STATe on the RTA4004, so a script that uses those needs a separate branch for each instrument.

Which has more remote commands, the DSOX3024A or the RTA4004?

The DSOX3024A: 175 commands for the DSOX3024A against 83 for the RTA4004 in TestFlow's library. Of those, 68 on the DSOX3024A and 30 on the RTA4004 are queries that read a value or state, and the library splits them into 22 and 16 subsystems.

How do the DSOX3024A and RTA4004 signal operation complete and report errors?

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.

Your next test, automated today

Describe the test. TestFlow builds the workflow, runs it on your instruments, and writes the report. See it on a bench like yours.