Power Supply Module · SCPI command comparison

Keysight N6762A vs N6781A: SCPI commands and remote control compared

In TestFlow's instrument library, the Keysight N6762A takes 135 SCPI commands, 36 of them queries, and the Keysight N6781A takes 155 SCPI commands, 36 of them queries. That is 20 more on the N6781A. Counting distinct command headers (the command path without its arguments), 111 are accepted by both, 3 exist only on the N6762A, and 18 only on the N6781A. 97% of the N6762A's command headers also exist on the N6781A.

Both libraries have commands under SOURce, OUTPut, SENSe, MEASure, TRIGger, FETCh, SYSTem, and INITiate, plus 4 more roots. Neither has a command root the other lacks: the differences are inside shared subsystems.

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

N6762A commands
135
N6781A commands
155
Shared headers
111
Unique headers
21

Run this on your bench

Describe the test; TestFlow's agent uses these command sets to drive your Keysight N6762A or Keysight N6781A and writes the report from the measured results.

Get started

N6762A vs N6781A 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 N6762AKeysight N6781A
Commands in TestFlow's library135155
Queries (read a value or state)3636
Settings and actions99119
Subsystems1616
Distinct command headers114129
Headers the other lacks318
Command languageSCPISCPI
Operation complete*OPC?*OPC?
Error queueSYSTem:ERRor?SYSTem:ERRor?
Models on this command setN6762AN6781A

Commands both accept

111 command headers are in both libraries. Here are 12, taken across subsystems.

CommandWhat it does
SOURce:VOLTage <Volt>,(@<Channel>)Set Voltage. Sets the output voltage in volts (programming range up to 51 V).
OUTPut ON,(@<Channel>)Turn On. Enables the output of the N6762A module in the selected mainframe channel.
SENSe:FUNCtion:VOLTage ON,(@<Channel>)Enable Voltage Measure Function. Enables the voltage measurement function for triggered data acquisitions.
MEASure:VOLTage:DC? (@<Channel>)Measure Voltage. Takes a measurement and returns the average voltage in volts.
TRIGger:ACQuire:SOURce <Source>,(@<Channel>)Set Acquire Trigger Source. Selects the measurement trigger source.
FETCh:VOLTage:DC? (@<Channel>)Fetch Voltage. Returns the average voltage from the last acquisition without re-triggering.
SYSTem:CHANnel:MODel? (@<Channel>)Read Channel Model. Returns the model number of the power module installed in the selected channel.
INITiate:ACQuire (@<Channel>)Initiate Acquisition. Arms the measurement trigger system to receive triggers.
ABORt:ACQuire (@<Channel>)Abort Acquisition. Resets the measurement trigger system to the idle state.
DISPlay:CHANnel <Channel>Set Display Channel. Selects which channel is shown in the single-channel front-panel meter view.
FORMat:DATA ASCIISet Data Format ASCII. Returns measurement array and data log values as comma separated ASCII text.
STATus:QUEStionable? (@<Channel>)Read Questionable Status. Reads and clears the questionable event register that reports OV OC OT and inhibit conditions.

Only on the Keysight N6762A

3 command headers in the N6762A library have no match in the N6781A library. Below are 3 of them from the 3 largest subsystems; the full list is in the Keysight N6762A command reference.

OUTPut (1 only on the N6762A)

CommandWhat it does
OUTPut:PMODe <Mode>,(@<Channel>)Set Turn On Mode. Selects whether the output prioritizes voltage or current during turn-on and turn-off transitions.

SENSe (1 only on the N6762A)

CommandWhat it does
SENSe:CURRent:CCOMpensate ON,(@<Channel>)Enable Current Compensation. Corrects the current measurement for the current flowing into the output capacitor.

SOURce (1 only on the N6762A)

CommandWhat it does
SOURce:POWer:LIMit <Watt>,(@<Channel>)Set Power Limit. Sets the output power limit in watts (100 W maximum on the N6762A).

Only on the Keysight N6781A

18 command headers in the N6781A library have no match in the N6762A library. Below are 9 of them from the 3 largest subsystems; the full list is in the Keysight N6781A command reference.

SOURce (13 only on the N6781A)

CommandWhat it does
SOURce:FUNCtion <Mode>,(@<Channel>)Set Priority Mode. Selects voltage priority or current priority mode for the source/measure unit.
SOURce:EMULation <Type>,(@<Channel>)Set Emulation Mode. Selects the operating mode that the SMU emulates, such as a power supply, battery, load or meter.
SOURce:CURRent:LIMit:POSitive <Amp>,(@<Channel>)Set Positive Current Limit. Sets the positive current limit in amps used in voltage priority mode.
SOURce:CURRent:LIMit:NEGative <Amp>,(@<Channel>)Set Negative Current Limit. Sets the negative (sinking) current limit in amps used in voltage priority mode.

SENSe (3 only on the N6781A)

CommandWhat it does
SENSe:FUNCtion:VOLTage:INPut <Input>,(@<Channel>)Set Voltage Measure Input. Selects the main output terminals or the auxiliary voltage input for voltage measurements.
SENSe:VOLTage:RANGe:AUTO ON,(@<Channel>)Enable Voltage Measure Autorange. Enables seamless voltage measurement autoranging on the selected channel.
SENSe:CURRent:RANGe:AUTO ON,(@<Channel>)Enable Current Measure Autorange. Enables seamless current measurement autoranging on the selected channel.

OUTPut (2 only on the N6781A)

CommandWhat it does
OUTPut:TMODe <Mode>,(@<Channel>)Set Turn Off Impedance. Specifies the high-impedance or low-impedance output state used during turn-on and turn-off.
OUTPut:PROTection:OSCillation ON,(@<Channel>)Enable Oscillation Protection. Enables output oscillation protection which trips if the output oscillates.

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 OUTPut:COUPle (enable output coupling), and the same line runs on each. For the reading, both libraries hold MEASure:VOLTage:DC? (measure voltage), 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_N6762A_ADDRESS")  # Keysight N6762A
b = rm.open_resource("PASTE_N6781A_ADDRESS")  # Keysight N6781A
for inst in (a, b):
    inst.timeout = 5000  # ms
    print(inst.query("*IDN?"))

# The same setting on both: Enable Output Coupling
a.write("OUTPut:COUPle ON")
b.write("OUTPut:COUPle ON")

# The same reading on both: Measure Voltage
print(a.query("MEASure:VOLTage:DC? (@1)"))
print(b.query("MEASure:VOLTage:DC? (@1)"))

a.close()
b.close()

Run this on your bench

Describe the test; TestFlow's agent uses these command sets to drive your Keysight N6762A or Keysight N6781A and writes the report from the measured results.

Get started

Frequently asked questions

What is the difference between the Keysight N6762A and the Keysight N6781A for remote control?

In TestFlow's library the N6762A has 135 SCPI commands and the N6781A has 155 SCPI commands. 111 command headers are common to both, 3 are only on the N6762A (mostly OUTPut and SENSe), and 18 are only on the N6781A (mostly SOURce and SENSe).

Can I use the same SCPI code for the Keysight N6762A and the Keysight N6781A?

Partly. 111 command headers are accepted by both, including SOURce:VOLTage, OUTPut, and SENSe:FUNCtion:VOLTage. 21 are not, for example OUTPut:PMODe on the N6762A and SOURce:FUNCtion on the N6781A, so a script that uses those needs a separate branch for each instrument.

Which has more remote commands, the N6762A or the N6781A?

The N6781A: 135 commands for the N6762A against 155 for the N6781A in TestFlow's library. Of those, 36 on the N6762A and 36 on the N6781A are queries that read a value or state, and the library splits them into 16 and 16 subsystems.

How do the N6762A and N6781A 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.