In TestFlow's instrument library, the Keysight N5172B takes 193 SCPI commands, 64 of them queries, and the Rohde & Schwarz SMBV100B takes 124 SCPI commands, 53 of them queries. That is 69 more on the N5172B. Counting distinct command headers (the command path without its arguments), 42 are accepted by both, 126 exist only on the N5172B, and 68 only on the SMBV100B. 25% of the N5172B's command headers also exist on the SMBV100B.
Both libraries have commands under SOURce, OUTPut, and SYSTem. Only the N5172B has MMEMory. Only the SMBV100B has TRIGger.
Both libraries synchronise with *OPC?. Both libraries read errors with SYSTem:ERRor?.
TestFlow's library gives the N5182B the same command set as the N5172B, so the N5172B column applies to it too.
Describe the test; TestFlow's agent uses these command sets to drive your Keysight N5172B or Rohde & Schwarz SMBV100B 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 N5172B | Rohde & Schwarz SMBV100B | |
|---|---|---|
| Commands in TestFlow's library | 193 | 124 |
| Queries (read a value or state) | 64 | 53 |
| Settings and actions | 129 | 71 |
| Subsystems | 8 | 8 |
| Distinct command headers | 168 | 110 |
| Headers the other lacks | 126 | 68 |
| Command language | SCPI | SCPI |
| Operation complete | *OPC? | *OPC? |
| Error queue | SYSTem:ERRor? | SYSTem:ERRor? |
| Models on this command set | N5172B, N5182B | SMBV100B |
42 command headers are in both libraries. Here are 12, taken across subsystems.
| Command | What it does |
|---|---|
| :SOURce:FREQuency:MODE <Mode> | Set Frequency Mode. Sets the frequency entry mode (fixed CW value or list/step sweep). |
| :OUTPut:STATe ON | Turn On RF Output. Enables the RF output signal. |
| *IDN? | Identify. Returns the instrument identification string (manufacturer, model, serial, firmware). |
| :SOURce:FREQuency:MODE? | Read Frequency Mode. Reads the current frequency entry mode. |
| :OUTPut:STATe? | Read RF Output State. Reads whether the RF output is currently ON or OFF. |
| *RST | Reset. Resets the instrument to its default state. |
| :SOURce:FREQuency:CENTer <Freq> | Set Frequency Center. Sets the center frequency of the frequency sweep range in Hz. |
| *CLS | Clear Status. Clears all event registers and the error queue. |
| :SOURce:FREQuency:CENTer? | Read Frequency Center. Reads the sweep center frequency in Hz. |
| *TST? | Self Test. Runs the self-test and returns 0 for pass or 1 for failure. |
| :SOURce:FREQuency:SPAN <Freq> | Set Frequency Span. Sets the span of the frequency sweep range in Hz. |
| *OPC? | Operation Complete. Returns 1 when all pending operations are complete. |
126 command headers in the N5172B library have no match in the SMBV100B library. Below are 17 of them from the 5 largest subsystems; the full list is in the Keysight N5172B command reference.
| Command | What it does |
|---|---|
| :SOURce:FREQuency:FIXed <Freq> | Set Frequency. Sets the CW/fixed RF output frequency in Hz (9 kHz to 6 GHz). |
| :SOURce:FREQuency:FIXed? | Read Frequency. Reads the current CW/fixed RF output frequency in Hz. |
| :SOURce:POWer:LEVel:IMMediate:OFFSet <Offset> | Set Power Offset. Sets a power offset in dB added to the displayed RF level to account for external gain or loss. |
| :SOURce:POWer:LEVel:IMMediate:OFFSet? | Read Power Offset. Reads the current RF power offset in dB. |
| Command | What it does |
|---|---|
| :OUTPut:MODulation:STATe ON | Turn On Modulation. Enables the modulation of the RF output signal (front-panel MOD ON/OFF). |
| :OUTPut:MODulation:STATe? | Read Modulation State. Reads whether RF modulation is enabled. |
| :OUTPut:BLANking:STATe ON | Turn On Output Blanking. Enables RF output blanking so the RF is muted while the synthesizer settles. |
| :OUTPut:BLANking:STATe? | Read Output Blanking State. Reads the RF output blanking state. |
| Command | What it does |
|---|---|
| :SYSTem:ERRor:NEXt? | Read Error. Reads and removes the next entry from the error queue. |
| :SYSTem:PRESet | System Preset. Returns the instrument to its preset state. |
| :SYSTem:PRESet:TYPE <Type> | Set Preset Type. Selects whether preset restores the factory (normal) or a user-defined state. |
| :SYSTem:CAPability? | Read Capability. Returns the instrument capability string. |
| Command | What it does |
|---|---|
| *SAV <Reg>,<Seq> | Save State Slot. Saves the current instrument state to an internal register. |
| *RCL <Reg>,<Seq> | Recall State Slot. Recalls the instrument state from an internal register. |
| *OPT? | Read Options. Returns the list of options installed in the instrument. |
| Command | What it does |
|---|---|
| :MMEMory:DELete <File> | Delete File. Deletes the named file from instrument memory. |
| :MMEMory:CATalog? | List Files. Lists the files in the current instrument directory. |
68 command headers in the SMBV100B library have no match in the N5172B library. Below are 12 of them from the 4 largest subsystems; the full list is in the Rohde & Schwarz SMBV100B command reference.
| Command | What it does |
|---|---|
| SOURce:FREQuency:CW <Freq> | Set Frequency. Sets the frequency of the RF output signal in CW/fixed mode in Hz (8 kHz to 6 GHz depending on installed options). |
| SOURce:FREQuency:CW? | Read Frequency. Reads the current CW/fixed RF output frequency in Hz. |
| SOURce:ROSCillator:EXTernal:FREQuency <Freq> | Set External Reference Frequency. Selects the expected frequency of the external reference input signal (10 MHz, 5 MHz, 13 MHz, or a variable/user-defined value). |
| SOURce:ROSCillator:EXTernal:FREQuency? | Read External Reference Frequency. Reads the configured external reference input frequency setting. |
| Command | What it does |
|---|---|
| OUTPut:STATe:PON <Pon> | Set Power On Output State. Defines the state of the RF output signal when the instrument is switched on. |
| OUTPut:STATe:PON? | Read Power On Output State. Reads the configured RF output state used at power-on. |
| OUTPut:AMODe FIXed | Set Attenuator Mode Manual. Sets the RF output attenuator to manual mode so the attenuation value can be fixed. |
| OUTPut:AMODe? | Read Attenuator Mode. Reads the current RF output attenuator mode. |
| Command | What it does |
|---|---|
| SYSTem:ERRor:ALL? | Read Error Queue. Queries and clears all unread entries from the error/event queue; returns 0,'No error' if the queue is empty. |
| SYSTem:ERRor:COUNt? | Read Error Count. Reads the number of entries currently in the error/event queue. |
| Command | What it does |
|---|---|
| TRIGger:FSWeep:SOURce <Source> | Set Frequency Sweep Trigger Source. Selects the trigger source for the RF frequency sweep (free-running, single/bus, external, or external-auto). |
| TRIGger:FSWeep:SOURce? | Read Frequency Sweep Trigger Source. Reads the current RF frequency sweep trigger source. |
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 :OUTPut:STATe (turn on rf output), and the same line runs on each. For the reading, both libraries hold :OUTPut:STATe? (read rf output state), 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_N5172B_ADDRESS") # Keysight N5172B
b = rm.open_resource("PASTE_SMBV100B_ADDRESS") # Rohde & Schwarz SMBV100B
for inst in (a, b):
inst.timeout = 5000 # ms
print(inst.query("*IDN?"))
# The same setting on both: Turn On RF Output
a.write(":OUTPut:STATe ON")
b.write("OUTPut:STATe ON")
# The same reading on both: Read RF Output State
print(a.query(":OUTPut:STATe?"))
print(b.query("OUTPut:STATe?"))
a.close()
b.close()Describe the test; TestFlow's agent uses these command sets to drive your Keysight N5172B or Rohde & Schwarz SMBV100B and writes the report from the measured results.
In TestFlow's library the N5172B has 193 SCPI commands and the SMBV100B has 124 SCPI commands. 42 command headers are common to both, 126 are only on the N5172B (mostly SOURce and OUTPut), and 68 are only on the SMBV100B (mostly SOURce and OUTPut).
Partly. 42 command headers are accepted by both, including :SOURce:FREQuency:MODE, :OUTPut:STATe, and :SOURce:FREQuency:MODE?. 194 are not, for example :SOURce:FREQuency:FIXed on the N5172B and SOURce:FREQuency:CW on the SMBV100B, so a script that uses those needs a separate branch for each instrument.
The N5172B: 193 commands for the N5172B against 124 for the SMBV100B in TestFlow's library. Of those, 64 on the N5172B and 53 on the SMBV100B are queries that read a value or state, and the library splits them into 8 and 8 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.