Power Supply · SCPI command reference

Keysight N5767A SCPI commands

The Keysight N5767A power supply is controlled remotely with SCPI commands. TestFlow's instrument library holds 75 commands for it, 39 of them queries that read values or state, grouped below by subsystem with their arguments. It is the same library TestFlow's AI agent uses to drive the N5767A on a real bench.

Commands
75
Queries
39
Subsystems
10
Models covered
1

Control the Keysight N5767A from Python

With PyVISA, any VISA backend, and the instrument on USB, LAN or GPIB, this opens a session, identifies the instrument, sends one setting, and reads one value. Every command in it comes from the reference below. For a full walkthrough, see the PyVISA tutorial and the SCPI command cheat sheet.

import pyvisa

rm = pyvisa.ResourceManager()
print(rm.list_resources())  # find the Keysight N5767A's VISA address

# Paste the address of your Keysight N5767A (USB, LAN or GPIB).
inst = rm.open_resource("PASTE_VISA_ADDRESS_HERE")
inst.timeout = 5000  # ms

print(inst.query("*IDN?"))  # identify the instrument
inst.write("OUTPut:PROTection:CLEar")  # Clear Output Protection
print(inst.query("MEASure:VOLTage:DC?"))  # Measure DC Voltage

inst.close()

Run a N5767A test without writing code

Describe the test in a sentence, for example “clear output protection on the N5767A, then measure dc voltage and log it against a limit”. TestFlow's agent builds the steps from this command library, runs them on your bench through the TestFlow desktop app, and writes the report from the measured values. See AI test automation for lab instruments for how that works and where it stops.

Get started

SCPI command reference

75 commands in 10 groups. A ? marks a query that returns a value. Placeholders in angle brackets take the listed values.

Voltage (VOLTage) (13)

CommandWhat it doesArguments
VOLTage:LEVel <value>Set Voltage. Sets the immediate output voltage level in volts.Number: 0 to rated output voltage; MIN | MAX
VOLTage:LEVel?Query Voltage Setting. Returns the programmed output voltage level in volts.None
VOLTage:LEVel:TRIGgered <value>Set Triggered Voltage. Sets the triggered output voltage level transferred on trigger.Number: 0 to rated output voltage; MIN | MAX
VOLTage:LEVel:TRIGgered?Query Triggered Voltage. Returns the triggered output voltage level in volts.None
VOLTage:LIMit:LOW <value>Set Low Voltage Limit. Sets the low voltage limit below which voltage programming is ignored.Number: 0 to maximum low limit for model; MIN | MAX
VOLTage:LIMit:LOW?Query Low Voltage Limit. Returns the low voltage limit in volts.None
VOLTage:PROTection:LEVel <value>Set Over-Voltage Protection Level. Sets the over-voltage protection trip level in volts.Number: model minimum to model maximum protection limit; MIN | MAX
VOLTage:PROTection:LEVel?Query Over-Voltage Protection Level. Returns the over-voltage protection level in volts.None
VOLT <voltage>Set Voltage (VOLT). Programs the output voltage setpoint.Number: 0 to 60 V
VOLT?Query Voltage Setting (VOLT?). Returns the programmed output voltage setting.None
VOLT:PROT:LEV <voltage>Set Over-Voltage Protection. Sets the over-voltage protection trip level.Number: 0 to 60 V, must be above the voltage setting
VOLT:PROT:LEV?Query Over-Voltage Protection. Returns the over-voltage protection trip level.None
VOLT:LIM:LOW <voltage>Set Under-Voltage Limit. Sets the under-voltage limit for programming the voltage.Number: 0 to 60 V, must be below the voltage setting

Status (STATus) (11)

CommandWhat it doesArguments
STATus:OPERation:EVENt?Read Operation Event Register. Returns the operation event register, which clears on read (CC, CV, WTG bits).None
STATus:OPERation:CONDition?Read Operation Condition Register. Returns the live operation condition register (CC, CV, WTG bits).None
STATus:OPERation:ENABle <value>Set Operation Enable Mask. Sets the operation enable mask for the operation summary bit.Number: 0 to 32767
STATus:OPERation:ENABle?Query Operation Enable Mask. Returns the operation enable mask.None
STATus:QUEStionable:EVENt?Read Questionable Event Register. Returns the questionable event register (OV, OC, PF, OT, INH, UNR), clears on read.None
STATus:QUEStionable:CONDition?Read Questionable Condition Register. Returns the live questionable condition register.None
STATus:QUEStionable:ENABle <value>Set Questionable Enable Mask. Sets the questionable enable mask for the questionable summary bit.Number: 0 to 32767
STATus:QUEStionable:ENABle?Query Questionable Enable Mask. Returns the questionable enable mask.None
STATus:PRESetPreset Status Registers. Sets defined PTR bits and clears NTR and enable registers.None
STAT:OPER?Operation Status Query. Returns the operation status register value.None
STAT:QUES?Questionable Status Query. Returns the questionable status register value.None

Current (CURRent) (10)

CommandWhat it doesArguments
CURRent:LEVel <value>Set Current. Sets the immediate output current level in amperes.Number: 0 to rated output current; MIN | MAX
CURRent:LEVel?Query Current Setting. Returns the programmed output current level in amperes.None
CURRent:LEVel:TRIGgered <value>Set Triggered Current. Sets the triggered output current level transferred on trigger.Number: 0 to rated output current; MIN | MAX
CURRent:LEVel:TRIGgered?Query Triggered Current. Returns the triggered output current level in amperes.None
CURRent:PROTection:STATe <state>Enable Over-Current Protection. Enables or disables over-current protection.Text: ON | OFF
CURRent:PROTection:STATe?Query Over-Current Protection State. Returns the over-current protection enable state.None
CURR <current>Set Current (CURR). Programs the output current limit setpoint.Number: 0 to 25 A
CURR?Query Current Setting (CURR?). Returns the programmed output current setting.None
CURR:PROT:STAT <state>Set Over-Current Protection. Enables or disables over-current protection.Text: ON or OFF
CURR:PROT:STAT?Query Over-Current Protection. Returns the over-current protection state.None

Output (OUTPut) (9)

CommandWhat it doesArguments
OUTPut:STATe <state>Set Output Enable. Enables or disables the power supply output.Text: ON | OFF
OUTPut:STATe?Query Output Enable. Returns 1 if the output is on, 0 if off.None
OUTPut:PON:STATe <mode>Set Power-On State. Selects reset state or last-off state at power-on.Text: RST | AUTO
OUTPut:PON:STATe?Query Power-On State. Returns the power-on state mode.None
OUTPut:PROTection:CLEarClear Output Protection. Clears latched protection signals that disabled the output.None
OUTP:STAT ONOutput On. Turns the power supply output on.None
OUTP:STAT OFFOutput Off. Turns the power supply output off.None
OUTP:STAT?Output State Query. Returns 1 when the output is on and 0 when it is off.None
OUTP:PROT:CLEClear Protection. Clears a tripped protection condition.None

System (SYSTem) (5)

CommandWhat it doesArguments
SYSTem:ERRor?Query Error. Returns the next error number and message from the error queue.None
SYSTem:VERSion?Query SCPI Version. Returns the SCPI version number the instrument complies with.None
SYSTem:COMMunicate:RLSTate <mode>Set Remote Local State. Sets front panel control, remote control, or remote with front panel locked.Text: LOCal | REMote | RWLock
SYSTem:COMMunicate:RLSTate?Query Remote Local State. Returns the remote/local state of the instrument.None
SYST:ERR?Error Query. Returns and clears the most recent error from the error queue.None

Measurement (MEASure) (4)

CommandWhat it doesArguments
MEASure:VOLTage:DC?Measure DC Voltage. Performs a measurement and returns the DC output voltage in volts.None
MEASure:CURRent:DC?Measure DC Current. Performs a measurement and returns the DC output current in amperes.None
MEAS:VOLT?Measure Voltage. Returns the measured output voltage.None
MEAS:CURR?Measure Current. Returns the measured output current.None

Initiate (INITiate) (3)

CommandWhat it doesArguments
INITiateInitiate Trigger System. Initiates the trigger system so the next trigger changes the output.None
INITiate:CONTinuous <state>Set Continuous Trigger Initiation. Enables or disables continuous initiation of output triggers.Text: ON | OFF
INITiate:CONTinuous?Query Continuous Trigger Initiation. Returns the continuous trigger initiation state.None

Trigger (TRIGger) (3)

CommandWhat it doesArguments
TRIGgerImmediate Trigger. Generates an immediate output trigger if the trigger system is initiated.None
TRIGger:SOURce BUSSet Trigger Source. Selects the bus as the output trigger source.None
TRIGger:SOURce?Query Trigger Source. Returns the output trigger source.None

Abort (1)

CommandWhat it doesArguments
ABORtAbort Trigger. Cancels trigger actions in progress and returns the trigger system to idle.None

IEEE 488.2 common commands (16)

CommandWhat it doesArguments
*IDN?Identify Instrument. Returns manufacturer, model, serial number and firmware revision.None
*RSTReset Instrument. Resets the power supply to its factory-defined state.None
*TRGGenerate Trigger. Generates a bus trigger when the trigger source is BUS.None
*CLSClear Status. Clears event registers, status byte and error queue.None
*ESR?Read Standard Event Register. Returns the standard event status register and clears it.None
*ESE <value>Set Standard Event Enable. Sets the standard event status enable register mask.Number: 0 to 255
*ESE?Query Standard Event Enable. Returns the standard event status enable register mask.None
*SRE <value>Set Service Request Enable. Sets the service request enable register mask.Number: 0 to 255
*SRE?Query Service Request Enable. Returns the service request enable register mask.None
*STB?Read Status Byte. Returns the status byte register without clearing it.None
*OPCOperation Complete. Sets the OPC bit in the standard event register when pending operations complete.None
*OPC?Operation Complete Query. Returns 1 when all pending operations are complete.None
*WAIWait To Continue. Holds off further commands until all pending operations complete.None
*OPT?Query Option Numbers. Returns installed option identifiers; 0 means none.None
*RCL <state>Recall Instrument State. Restores a previously saved instrument state from memory location.Number: 0 to 15
*SAV <state>Save Instrument State. Stores the present instrument state to memory location.Number: 0 to 15

Where these commands come from

This reference is generated from TestFlow's instrument library, which is drafted from Keysight's programming documentation for the N5767A and checked when the agent runs it. The library marks this instrument as supporting *OPC? for operation-complete synchronisation. It reads errors back with SYSTem:ERRor?. Ranges, timing, and option-dependent commands are defined by Keysight's programming manual: check it before you rely on an edge case. Last updated November 12, 2026.

Frequently asked questions

Does the Keysight N5767A support SCPI remote control?

Yes. The Keysight N5767A accepts SCPI commands over its remote interfaces. TestFlow's instrument library holds 75 SCPI commands for it: 39 queries that read values or state, and 36 settings and actions.

How do I control the Keysight N5767A from Python?

Install PyVISA and a VISA backend, find the instrument's address with ResourceManager().list_resources(), open it, then send commands with write() and read values with query(). The example on this page sends *IDN?, OUTPut:PROTection:CLEar and MEASure:VOLTage:DC?.

Which command reads a value from the Keysight N5767A?

MEASure:VOLTage:DC? (measure dc voltage). Performs a measurement and returns the DC output voltage in volts. The full list of queries is in the command reference on this page, grouped by subsystem.

Can I automate the Keysight N5767A without writing code?

Yes. TestFlow is an AI agent for electronics testing: you describe the test, and it builds the automation from this command library, runs it on the Keysight N5767A through the TestFlow desktop app, and writes the report from the measured results.

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.