Hewlett-Packard¶
HP3456a
Digital Voltmeter¶
-
class
instruments.hp.
HP3456a
(filelike)¶ The
HP3456a
is a 6 1/2 digit bench multimeter.It supports DCV, ACV, ACV + DCV, 2 wire Ohms, 4 wire Ohms, DCV/DCV Ratio, ACV/DCV Ratio, Offset compensated 2 wire Ohms and Offset compensated 4 wire Ohms measurements.
Measurements can be further extended using a system math mode that allows for pass/fail, statistics, dB/dBm, null, scale and percentage readings.
HP3456a
is a HPIB / pre-448.2 instrument.-
class
MathMode
¶ Enum with the supported math modes
-
db
= <MathMode.db: 9>¶
-
dbm
= <MathMode.dbm: 4>¶
-
null
= <MathMode.null: 3>¶
-
off
= <MathMode.off: 0>¶
-
pass_fail
= <MathMode.pass_fail: 1>¶
-
percent
= <MathMode.percent: 8>¶
-
scale
= <MathMode.scale: 7>¶
-
statistic
= <MathMode.statistic: 2>¶
-
thermistor_c
= <MathMode.thermistor_c: 6>¶
-
thermistor_f
= <MathMode.thermistor_f: 5>¶
-
-
class
HP3456a.
Mode
¶ Enum containing the supported mode codes
-
acv
= <Mode.acv: 'S0F2'>¶
-
acvdcv
= <Mode.acvdcv: 'S0F3'>¶
-
dcv
= <Mode.dcv: 'S0F1'>¶
-
oc_resistence_2wire
= <Mode.oc_resistence_2wire: 'S1F4'>¶
-
oc_resistence_4wire
= <Mode.oc_resistence_4wire: 'S1F5'>¶
-
ratio_acv_dcv
= <Mode.ratio_acv_dcv: 'S1F2'>¶
-
ratio_acvdcv_dcv
= <Mode.ratio_acvdcv_dcv: 'S1F3'>¶
-
ratio_dcv_dcv
= <Mode.ratio_dcv_dcv: 'S1F1'>¶
-
resistance_2wire
= <Mode.resistance_2wire: 'S0F4'>¶
-
resistance_4wire
= <Mode.resistance_4wire: 'S0F5'>¶
-
-
class
HP3456a.
Register
¶ Enum with the register names for all
HP3456a
internal registers.-
count
= <Register.count: 'C'>¶
-
delay
= <Register.delay: 'D'>¶
-
lower
= <Register.lower: 'L'>¶
-
mean
= <Register.mean: 'M'>¶
-
nplc
= <Register.nplc: 'I'>¶
-
number_of_digits
= <Register.number_of_digits: 'G'>¶
-
number_of_readings
= <Register.number_of_readings: 'N'>¶
-
r
= <Register.r: 'R'>¶
-
upper
= <Register.upper: 'U'>¶
-
variance
= <Register.variance: 'V'>¶
-
y
= <Register.y: 'Y'>¶
-
z
= <Register.z: 'Z'>¶
-
-
class
HP3456a.
TriggerMode
¶ Enum with valid trigger modes.
-
external
= <TriggerMode.external: 2>¶
-
hold
= <TriggerMode.hold: 4>¶
-
internal
= <TriggerMode.internal: 1>¶
-
single
= <TriggerMode.single: 3>¶
-
-
class
HP3456a.
ValidRange
¶ Enum with the valid ranges for voltage, resistance, and number of powerline cycles to integrate over.
-
nplc
= <ValidRange.nplc: (0.1, 1.0, 10.0, 100.0)>¶
-
resistance
= <ValidRange.resistance: (100.0, 1000.0, 10000.0, 100000.0, 1000000.0, 10000000.0, 100000000.0, 1000000000.0)>¶
-
voltage
= <ValidRange.voltage: (0.1, 1.0, 10.0, 100.0, 1000.0)>¶
-
-
HP3456a.
auto_range
()¶ Set input range to auto. The
HP3456a
should upscale when a reading is at 120% and downscale when it below 11% full scale. Note that auto ranging can increase the measurement time.
-
HP3456a.
fetch
(mode=None)¶ Retrieve n measurements after the HP3456a has been instructed to perform a series of similar measurements. Typically the mode, range, nplc, analog filter, autozero is set along with the number of measurements to take. The series is then started at the trigger command.
Example usage:
>>> dmm.number_of_digits = 6 >>> dmm.auto_range() >>> dmm.nplc = 1 >>> dmm.mode = dmm.Mode.resistance_2wire >>> n = 100 >>> dmm.number_of_readings = n >>> dmm.trigger() >>> time.sleep(n * 0.04) >>> v = dmm.fetch(dmm.Mode.resistance_2wire) >>> print len(v) 10
Parameters: mode ( HP3456a.Mode
) – Desired measurement mode. If not specified, the previous set mode will be used, but no measurement unit will be returned.Returns: A series of measurements from the multimeter. Return type: Quantity
-
HP3456a.
measure
(mode=None)¶ Instruct the HP3456a to perform a one time measurement. The measurement will use the current set registers for the measurement (number_of_readings, number_of_digits, nplc, delay, mean, lower, upper, y and z) and will immediately take place.
Note that using
HP3456a.measure()
will override thetrigger_mode
toHP3456a.TriggerMode.single
Example usage:
>>> dmm = ik.hp.HP3456a.open_gpibusb("/dev/ttyUSB0", 22) >>> dmm.number_of_digits = 6 >>> dmm.nplc = 1 >>> print dmm.measure(dmm.Mode.resistance_2wire)
Parameters: mode ( HP3456a.Mode
) – Desired measurement mode. If not specified, the previous set mode will be used, but no measurement unit will be returned.Returns: A measurement from the multimeter. Return type: Quantity
-
HP3456a.
autozero
¶ Set the autozero mode.
This is used to compensate for offsets in the dc input amplifier circuit of the multimeter. If set, the amplifier”s input circuit is shorted to ground prior to actual measurement in order to take an offset reading. This offset is then used to compensate for drift in the next measurement. When disabled, one offset reading is taken immediately and stored into memory to be used for all successive measurements onwards. Disabling autozero increases the
HP3456a
“s measurement speed, and also makes the instrument more suitable for high impendance measurements since no input switching is done.
-
HP3456a.
count
¶ Get the number of measurements taken from
HP3456a.Register.count
when inHP3456a.MathMode.statistic
.Return type: int
-
HP3456a.
delay
¶ Get/set the delay that is waited after a trigger for the input to settle using
HP3456a.Register.delay
.Type: As specified, assumed to be s
otherwiseReturn type: s
-
HP3456a.
filter
¶ Set the analog filter mode.
The
HP3456a
has a 3 pole active filter with greater than 60dB attenuation at frequencies of 50Hz and higher. The filter is applied between the input terminals and input amplifier. When in ACV or ACV+DCV functions the filter is applied to the output of the ac converter and input amplifier. In these modes select the filter for measurements below 400Hz.
-
HP3456a.
input_range
¶ Set the input range to be used.
The
HP3456a
has separate ranges forohm
and forvolt
. The range value sent to the instrument depends on the unit set on the input range value.auto
selects auto ranging.Type: Quantity
-
HP3456a.
lower
¶ Get/set the value in
HP3456a.Register.lower
, which indicates the lowest value measurement made while inHP3456a.MathMode.statistic
, or the lowest value preset forHP3456a.MathMode.pass_fail
.Type: float
-
HP3456a.
math_mode
¶ Set the math mode.
The
HP3456a
has a number of different math modes that can change measurement output, or can provide additional statistics. Interaction with these modes is done via theHP3456a.Register
.Type: HP3456a.MathMode
-
HP3456a.
mean
¶ Get the mean over
HP3456a.Register.count
measurements fromHP3456a.Register.mean
when inHP3456a.MathMode.statistic
.Return type: float
-
HP3456a.
mode
¶ Set the measurement mode.
Type: HP3456a.Mode
-
HP3456a.
nplc
¶ Get/set the number of powerline cycles to integrate per measurement using
HP3456a.Register.nplc
.Setting higher values increases accuracy at the cost of a longer measurement time. The implicit assumption is that the input reading is stable over the number of powerline cycles to integrate.
Type: int
-
HP3456a.
number_of_digits
¶ Get/set the number of digits used in measurements using
HP3456a.Register.number_of_digits
.Set to higher values to increase accuracy at the cost of measurement speed.
Type: int
-
HP3456a.
number_of_readings
¶ Get/set the number of readings done per trigger/measurement cycle using
HP3456a.Register.number_of_readings
.Type: float
Return type: float
-
HP3456a.
r
¶ Get/set the value in
HP3456a.Register.r
, which indicates the resistor value used while inHP3456a.MathMode.dbm
or the number of recalled readings in reading storage mode.Type: float
Return type: float
-
HP3456a.
trigger_mode
¶ Set the trigger mode.
Note that using
HP3456a.measure()
will override thetrigger_mode
toHP3456a.TriggerMode.single
.Type: HP3456a.TriggerMode
-
HP3456a.
upper
¶ Get/set the value in
HP3456a.Register.upper
, which indicates the highest value measurement made while inHP3456a.MathMode.statistic
, or the highest value preset forHP3456a.MathMode.pass_fail
.Type: float
Return type: float
-
HP3456a.
variance
¶ Get the variance over
HP3456a.Register.count
measurements fromHP3456a.Register.variance
when inHP3456a.MathMode.statistic
.Return type: float
-
HP3456a.
y
¶ Get/set the value in
HP3456a.Register.y
to be used in calculations when inHP3456a.MathMode.scale
orHP3456a.MathMode.percent
.Type: float
Return type: float
-
HP3456a.
z
¶ Get/set the value in
HP3456a.Register.z
to be used in calculations when inHP3456a.MathMode.scale
or the first reading when inHP3456a.MathMode.statistic
.Type: float
Return type: float
-
class
HP6624a
Power Supply¶
-
class
instruments.hp.
HP6624a
(filelike)¶ The HP6624a is a multi-output power supply.
This class can also be used for HP662xa, where x=1,2,3,4,7. Note that some models have less channels then the HP6624 and it is up to the user to take this into account. This can be changed with the
channel_count
property.Example usage:
>>> import instruments as ik >>> psu = ik.hp.HP6624a.open_gpibusb('/dev/ttyUSB0', 1) >>> psu.channel[0].voltage = 10 # Sets channel 1 voltage to 10V.
-
class
Channel
(hp, idx)¶ Class representing a power output channel on the HP6624a.
Warning
This class should NOT be manually created by the user. It is designed to be initialized by the
HP6624a
class.-
query
(cmd)¶ Function used to send a command to the instrument while wrapping the command with the neccessary identifier for the channel.
Parameters: cmd (str) – Command that will be sent to the instrument after being prefixed with the channel identifier Returns: The result from the query Return type: str
-
reset
()¶ Reset overvoltage and overcurrent errors to resume operation.
-
sendcmd
(cmd)¶ Function used to send a command to the instrument while wrapping the command with the neccessary identifier for the channel.
Parameters: cmd (str) – Command that will be sent to the instrument after being prefixed with the channel identifier
-
current
¶ Gets/sets the current of the specified channel. If the device is in constant voltage mode, this sets the current limit.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{A}\) otherwise. Type: float
orQuantity
-
current_sense
¶ Gets the actual output current as measured by the instrument for the specified channel.
Units: \(\text{A}\) (amps) Return type: Quantity
-
mode
¶ Gets/sets the mode for the specified channel.
-
output
¶ Gets/sets the outputting status of the specified channel.
This is a toggle setting. True will turn on the channel output while False will turn it off.
Type: bool
-
overcurrent
¶ Gets/sets the overcurrent protection setting for the specified channel.
This is a toggle setting. It is either on or off.
Type: bool
-
overvoltage
¶ Gets/sets the overvoltage protection setting for the specified channel.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{V}\) otherwise. Type: float
orQuantity
-
voltage
¶ Gets/sets the voltage of the specified channel. If the device is in constant current mode, this sets the voltage limit.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{V}\) otherwise. Type: float
orQuantity
-
voltage_sense
¶ Gets the actual voltage as measured by the sense wires for the specified channel.
Units: \(\text{V}\) (volts) Return type: Quantity
-
-
class
HP6624a.
Mode
¶ Enum holding typical valid output modes for a power supply.
However, for the HP6624a I believe that it is only capable of constant-voltage output, so this class current does not do anything and is just a placeholder.
-
current
= <Mode.current: 0>¶
-
voltage
= <Mode.current: 0>¶
-
-
HP6624a.
clear
()¶ Taken from the manual:
Return the power supply to its power-on state and all parameters are returned to their initial power-on values except the following:
- The store/recall registers are not cleared.
- The power supply remains addressed to listen.
- The PON bit in the serial poll register is cleared.
-
HP6624a.
channel
¶ Gets a specific channel object. The desired channel is specified like one would access a list.
Return type: HP6624a.Channel
See also
HP6624a
for example using this property.
-
HP6624a.
channel_count
¶ Gets/sets the number of output channels available for the connected power supply.
Type: int
-
HP6624a.
current
¶ Gets/sets the current for all four channels.
Units: As specified (if a Quantity
) or assumed to be of units Amps.Type: list
ofQuantity
with units Amp
-
HP6624a.
current_sense
¶ Gets the actual current as measured by the instrument for all channels.
Units: \(\text{A}\) (amps) Return type: tuple
ofQuantity
-
class
HP6632b
Power Supply¶
-
class
instruments.hp.
HP6632b
(filelike)¶ The HP6632b is a system dc power supply with an output rating of 0-20V/0-5A, precision low current measurement and low output noise.
According to the manual this class MIGHT be usable for any HP power supply with a model number
- HP663Xb with X in {1, 2, 3, 4},
- HP661Xc with X in {1,2, 3, 4} and
- HP663X2A for X in {1, 3}, without the additional measurement capabilities.
HOWEVER, it has only been tested by the author with HP6632b supplies.
Example usage:
>>> import instruments as ik >>> psu = ik.hp.HP6632b.open_gpibusb('/dev/ttyUSB0', 6) >>> psu.voltage = 10 # Sets voltage to 10V. >>> psu.output = True # Enable output >>> psu.voltage array(10.0) * V >>> psu.voltage_trigger = 20 # Set transient trigger voltage >>> psu.init_output_trigger() # Prime instrument to initiated state, ready for trigger >>> psu.trigger() # Send trigger >>> psu.voltage array(10.0) * V
-
class
ALCBandwidth
¶ Enum containing valid ALC bandwidth modes for the hp6632b
-
fast
= <ALCBandwidth.fast: 60000>¶
-
normal
= <ALCBandwidth.normal: 15000>¶
-
-
class
HP6632b.
DFISource
¶ Enum containing valid DFI sources for the hp6632b
-
event_status_bit
= <DFISource.event_status_bit: 'ESB'>¶
-
off
= <DFISource.off: 'OFF'>¶
-
operation
= <DFISource.operation: 'OPER'>¶
-
questionable
= <DFISource.questionable: 'QUES'>¶
-
request_service_bit
= <DFISource.request_service_bit: 'RQS'>¶
-
-
class
HP6632b.
DigitalFunction
¶ Enum containing valid digital function modes for the hp6632b
-
data
= <DigitalFunction.data: 'DIG'>¶
-
remote_inhibit
= <DigitalFunction.remote_inhibit: 'RIDF'>¶
-
-
class
HP6632b.
ErrorCodes
¶ Enum containing generic-SCPI error codes along with codes specific to the HP6632b.
-
block_data_error
= <ErrorCodes.block_data_error: -160>¶
-
block_data_not_allowed
= <ErrorCodes.block_data_not_allowed: -168>¶
-
cal_not_enabled
= <ErrorCodes.cal_not_enabled: 403>¶
-
cal_password_incorrect
= <ErrorCodes.cal_password_incorrect: 402>¶
-
cal_switch_prevents_cal
= <ErrorCodes.cal_switch_prevents_cal: 401>¶
-
character_data_error
= <ErrorCodes.character_data_error: -140>¶
-
character_data_not_allowed
= <ErrorCodes.character_data_not_allowed: -148>¶
-
character_data_too_long
= <ErrorCodes.character_data_too_long: -144>¶
-
command_error
= <ErrorCodes.command_error: -100>¶
-
command_header_error
= <ErrorCodes.command_header_error: -110>¶
-
command_only_applic_rs232
= <ErrorCodes.command_only_applic_rs232: 602>¶
-
computed_prog_cal_constants_incorrect
= <ErrorCodes.computed_prog_cal_constants_incorrect: 405>¶
-
computed_readback_cal_const_incorrect
= <ErrorCodes.computed_readback_cal_const_incorrect: 404>¶
-
curr_or_volt_fetch_incompat_with_last_acq
= <ErrorCodes.curr_or_volt_fetch_incompat_with_last_acq: 603>¶
-
cv_or_cc_status_incorrect
= <ErrorCodes.cv_or_cc_status_incorrect: 407>¶
-
data_out_of_range
= <ErrorCodes.data_out_of_range: -222>¶
-
data_type_error
= <ErrorCodes.data_type_error: -104>¶
-
digital_io_selftest
= <ErrorCodes.digital_io_selftest: 80>¶
-
execution_error
= <ErrorCodes.execution_error: -200>¶
-
exponent_too_large
= <ErrorCodes.exponent_too_large: -123>¶
-
expression_error
= <ErrorCodes.expression_error: -170>¶
-
expression_not_allowed
= <ErrorCodes.expression_not_allowed: -178>¶
-
front_panel_uart_buffer_overrun
= <ErrorCodes.front_panel_uart_buffer_overrun: 223>¶
-
front_panel_uart_framing
= <ErrorCodes.front_panel_uart_framing: 221>¶
-
front_panel_uart_overrun
= <ErrorCodes.front_panel_uart_overrun: 220>¶
-
front_panel_uart_parity
= <ErrorCodes.front_panel_uart_parity: 222>¶
-
front_panel_uart_timeout
= <ErrorCodes.front_panel_uart_timeout: 224>¶
-
get_not_allowed
= <ErrorCodes.get_not_allowed: -105>¶
-
header_separator_error
= <ErrorCodes.header_separator_error: -111>¶
-
header_suffix_out_of_range
= <ErrorCodes.header_suffix_out_of_range: -114>¶
-
illegal_macro_label
= <ErrorCodes.illegal_macro_label: -273>¶
-
illegal_parameter_value
= <ErrorCodes.illegal_parameter_value: -224>¶
-
incorrect_seq_cal_commands
= <ErrorCodes.incorrect_seq_cal_commands: 406>¶
-
ingrd_recv_buffer_overrun
= <ErrorCodes.ingrd_recv_buffer_overrun: 213>¶
-
invalid_block_data
= <ErrorCodes.invalid_block_data: -161>¶
-
invalid_character
= <ErrorCodes.invalid_character: -101>¶
-
invalid_character_data
= <ErrorCodes.invalid_character_data: -141>¶
-
invalid_character_in_number
= <ErrorCodes.invalid_character_in_number: -121>¶
-
invalid_expression
= <ErrorCodes.invalid_expression: -171>¶
-
invalid_inside_macro_definition
= <ErrorCodes.invalid_inside_macro_definition: -183>¶
-
invalid_outside_macro_definition
= <ErrorCodes.invalid_outside_macro_definition: -181>¶
-
invalid_separator
= <ErrorCodes.invalid_separator: -103>¶
-
invalid_string_data
= <ErrorCodes.invalid_string_data: -151>¶
-
invalid_suffix
= <ErrorCodes.invalid_suffix: -131>¶
-
macro_error_180
= <ErrorCodes.macro_error_180: -180>¶
-
macro_error_270
= <ErrorCodes.macro_error_270: -270>¶
-
macro_execution_error
= <ErrorCodes.macro_execution_error: -272>¶
-
macro_parameter_error
= <ErrorCodes.macro_parameter_error: -184>¶
-
macro_recursion_error
= <ErrorCodes.macro_recursion_error: -276>¶
-
macro_redefinition_not_allowed
= <ErrorCodes.macro_redefinition_not_allowed: -277>¶
-
measurement_overrange
= <ErrorCodes.measurement_overrange: 604>¶
-
missing_parameter
= <ErrorCodes.missing_parameter: -109>¶
-
no_error
= <ErrorCodes.no_error: 0>¶
-
numeric_data_error
= <ErrorCodes.numeric_data_error: -120>¶
-
numeric_data_not_allowed
= <ErrorCodes.numeric_data_not_allowed: -128>¶
-
operation_complete
= <ErrorCodes.operation_complete: -800>¶
-
out_of_memory
= <ErrorCodes.out_of_memory: -225>¶
-
output_mode_must_be_normal
= <ErrorCodes.output_mode_must_be_normal: 408>¶
-
ovdac_selftest
= <ErrorCodes.ovdac_selftest: 15>¶
-
parameter_not_allowed
= <ErrorCodes.parameter_not_allowed: -108>¶
-
power_on
= <ErrorCodes.power_on: -500>¶
-
program_mnemonic_too_long
= <ErrorCodes.program_mnemonic_too_long: -112>¶
-
query_deadlocked
= <ErrorCodes.query_deadlocked: -430>¶
-
query_error
= <ErrorCodes.query_error: -400>¶
-
query_interrupted
= <ErrorCodes.query_interrupted: -410>¶
-
query_unterminated
= <ErrorCodes.query_unterminated: -420>¶
-
query_unterminated_after_indefinite_response
= <ErrorCodes.query_unterminated_after_indefinite_response: -440>¶
-
ram_cal_checksum_failed
= <ErrorCodes.ram_cal_checksum_failed: 3>¶
-
ram_config_checksum_failed
= <ErrorCodes.ram_config_checksum_failed: 2>¶
-
ram_rd0_checksum_failed
= <ErrorCodes.ram_rd0_checksum_failed: 1>¶
-
ram_rst_checksum_failed
= <ErrorCodes.ram_rst_checksum_failed: 5>¶
-
ram_selftest
= <ErrorCodes.ram_selftest: 10>¶
-
ram_state_checksum_failed
= <ErrorCodes.ram_state_checksum_failed: 4>¶
-
request_control_event
= <ErrorCodes.request_control_event: -700>¶
-
rs232_recv_framing_error
= <ErrorCodes.rs232_recv_framing_error: 216>¶
-
rs232_recv_overrun_error
= <ErrorCodes.rs232_recv_overrun_error: 218>¶
-
rs232_recv_parity_error
= <ErrorCodes.rs232_recv_parity_error: 217>¶
-
string_data_error
= <ErrorCodes.string_data_error: -150>¶
-
string_data_not_allowed
= <ErrorCodes.string_data_not_allowed: -158>¶
-
suffix_error
= <ErrorCodes.suffix_error: -130>¶
-
suffix_not_allowed
= <ErrorCodes.suffix_not_allowed: -138>¶
-
suffix_too_long
= <ErrorCodes.suffix_too_long: -134>¶
-
syntax_error
= <ErrorCodes.syntax_error: -102>¶
-
system_error
= <ErrorCodes.system_error: -310>¶
-
too_many_digits
= <ErrorCodes.too_many_digits: -124>¶
-
too_many_errors
= <ErrorCodes.too_many_errors: -350>¶
-
too_many_sweep_points
= <ErrorCodes.too_many_sweep_points: 601>¶
-
too_much_data
= <ErrorCodes.too_much_data: -223>¶
-
undefined_header
= <ErrorCodes.undefined_header: -113>¶
-
unexpected_number_of_parameters
= <ErrorCodes.unexpected_number_of_parameters: -115>¶
-
user_request_event
= <ErrorCodes.user_request_event: -600>¶
-
vdac_idac_selftest1
= <ErrorCodes.vdac_idac_selftest1: 11>¶
-
vdac_idac_selftest2
= <ErrorCodes.vdac_idac_selftest2: 12>¶
-
vdac_idac_selftest3
= <ErrorCodes.vdac_idac_selftest3: 13>¶
-
vdac_idac_selftest4
= <ErrorCodes.vdac_idac_selftest4: 14>¶
-
-
class
HP6632b.
RemoteInhibit
¶ Enum containing vlaid remote inhibit modes for the hp6632b.
-
latching
= <RemoteInhibit.latching: 'LATC'>¶
-
live
= <RemoteInhibit.live: 'LIVE'>¶
-
off
= <RemoteInhibit.off: 'OFF'>¶
-
-
class
HP6632b.
SenseWindow
¶ Enum containing valid sense window modes for the hp6632b.
-
hanning
= <SenseWindow.hanning: 'HANN'>¶
-
rectangular
= <SenseWindow.rectangular: 'RECT'>¶
-
-
HP6632b.
abort_output_trigger
()¶ Set the output trigger system to the idle state.
-
HP6632b.
check_error_queue
()¶ Checks and clears the error queue for this device, returning a list of
ErrorCodes
orint
elements for each error reported by the connected instrument.
-
HP6632b.
init_output_trigger
()¶ Set the output trigger system to the initiated state. In this state, the power supply will respond to the next output trigger command.
-
HP6632b.
current_sense_range
¶ Get/set the sense current range by the current max value.
A current of 20mA or less selects the low-current range, a current value higher than that selects the high-current range. The low current range increases the low current measurement sensitivity and accuracy.
Units: As specified, or assumed to be \(\text{A}\) otherwise. Type: float
orQuantity
-
HP6632b.
current_trigger
¶ Gets/sets the pending triggered output current.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{A}\) otherwise. Type: float
orQuantity
-
HP6632b.
digital_data
¶ Get/set digital in+out port to data. Data can be an integer from 0-7.
Type: int
-
HP6632b.
digital_function
¶ Get/set the inhibit+fault port to digital in+out or vice-versa.
Type: DigitalFunction
-
HP6632b.
display_brightness
¶
-
HP6632b.
display_contrast
¶
-
HP6632b.
init_output_continuous
¶ Get/set the continuous output trigger. In this state, the power supply will remain in the initiated state, and respond continuously on new incoming triggers by applying the set voltage and current trigger levels.
Type: bool
-
HP6632b.
line_frequency
¶
-
HP6632b.
output_dfi
¶ Get/set the discrete fault indicator (DFI) output from the dc source. The DFI is an open-collector logic signal connected to the read panel FLT connection, that can be used to signal external devices when a fault is detected.
Type: bool
-
HP6632b.
output_dfi_source
¶ Get/set the source for discrete fault indicator (DFI) events.
Type: DFISource
-
HP6632b.
output_protection_delay
¶ Get/set the time between programming of an output change that produces a constant current condition and the recording of that condigition in the Operation Status Condition register. This command also delays over current protection, but not overvoltage protection.
Units: As specified, or assumed to be \(\text{s}\) otherwise. Type: float
orQuantity
-
HP6632b.
output_remote_inhibit
¶ Get/set the remote inhibit signal. Remote inhibit is an external, chassis-referenced logic signal routed through the rear panel INH connection, which allows an external device to signal a fault.
Type: RemoteInhibit
-
HP6632b.
sense_sweep_interval
¶ Get/set the digitizer sample spacing. Can be set from 15.6 us to 31200 seconds, the interval will be rounded to the nearest 15.6 us increment.
Units: As specified, or assumed to be \(\text{s}\) otherwise. Type: float
orQuantity
-
HP6632b.
sense_window
¶ Get/set the measurement window function.
Type: SenseWindow
-
HP6632b.
voltage_alc_bandwidth
¶ Get the “automatic level control bandwidth” which for the HP66332A and HP6631-6634 determines if the output capacitor is in circuit.
Normal
denotes that it is, andFast
denotes that it is not.Type: ALCBandwidth
HP6652a
Single Output Power Supply¶
-
class
instruments.hp.
HP6652a
(filelike)¶ The HP6652a is a single output power supply.
Because it is a single channel output, this object inherits from both PowerSupply and PowerSupplyChannel.
According to the manual, this class MIGHT be usable for any HP power supply with a model number HP66XYA, where X is in {4,5,7,8,9} and Y is a digit(?). (e.g. HP6652A and HP6671A)
HOWEVER, it has only been tested by the author with an HP6652A power supply.
Example usage:
>>> import time >>> import instruments as ik >>> psu = ik.hp.HP6652a.open_serial('/dev/ttyUSB0', 57600) >>> psu.voltage = 3 # Sets output voltage to 3V. >>> psu.output = True >>> psu.voltage array(3.0) * V >>> psu.voltage_sense < 5 True >>> psu.output = False >>> psu.voltage_sense < 1 True >>> psu.display_textmode=True >>> psu.display_text("test GOOD") 'TEST GOOD' >>> time.sleep(5) >>> psu.display_textmode=False
-
display_text
(text_to_display)¶ Sends up to 12 (uppercase) alphanumerics to be sent to the front-panel LCD display. Some punctuation is allowed, and can affect the number of characters allowed. See the programming manual for the HP6652A for more details.
Because the maximum valid number of possible characters is 15 (counting the possible use of punctuation), the text will be truncated to 15 characters before the command is sent to the instrument.
If an invalid string is sent, the command will fail silently. Any lowercase letters in the text_to_display will be converted to uppercase before the command is sent to the instrument.
No attempt to validate punctuation is currently made.
Because the string cannot be read back from the instrument, this method returns the actual string value sent.
Parameters: text_to_display ('str') – The text that you wish to have displayed on the front-panel LCD Returns: Returns the version of the provided string that will be send to the instrument. This means it will be truncated to a maximum of 15 characters and changed to all upper case. Return type: str
-
reset
()¶ Reset overvoltage and overcurrent errors to resume operation.
-
channel
¶ Return the channel (which in this case is the entire instrument, since there is only 1 channel on the HP6652a.)
Return type: ‘tuple’ of length 1 containing a reference back to the parent HP6652a object.
-
current
¶ Gets/sets the output current.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{A}\) otherwise. Type: float
orQuantity
-
current_sense
¶ Gets the actual output current as measured by the sense wires.
Units: \(\text{A}\) (amps) Return type: Quantity
-
display_textmode
¶ Gets/sets the display mode.
This is a toggle setting. True will allow text to be sent to the front-panel LCD with the display_text() method. False returns to the normal display mode.
See also
Type: bool
-
mode
¶ Unimplemented.
-
name
¶ The name of the connected instrument, as reported by the standard SCPI command
*IDN?
.Return type: str
-
output
¶ Gets/sets the output status.
This is a toggle setting. True will turn on the instrument output while False will turn it off.
Type: bool
-
overcurrent
¶ Gets/sets the overcurrent protection setting.
This is a toggle setting. It is either on or off.
Type: bool
-
overvoltage
¶ Gets/sets the overvoltage protection setting in volts.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{V}\) otherwise. Type: float
orQuantity
-
voltage
¶ Gets/sets the output voltage.
Note there is no bounds checking on the value specified.
Units: As specified, or assumed to be \(\text{V}\) otherwise. Type: float
orQuantity
-
voltage_sense
¶ Gets the actual output voltage as measured by the sense wires.
Units: \(\text{V}\) (volts) Return type: Quantity
-