KeysightElectrometerCommandFactory#
- class lsst.ts.electrometer.KeysightElectrometerCommandFactory#
Bases:
ElectrometerCommandFactoryFormat Keysight-specific SCPI commands for RS-232 control.
This class includes commands that differ from the Keithley command set.
Methods Summary
Returns the command to start acquiring data
activate_filter(mode, filter_type, active)Build a command that enables or disables a digital filter.
Return always read buffer.
Return clear buffer.
Discharges the capacitor.
enable_temperature_reading(enable)Return enable temperature reading.
enable_zero_correction(enable)Return enable zero correction.
format_trac([timestamp, temperature, ...])Return format data stored to the buffer.
get_filter_status(mode, filter_type)Return filter status.
Return get last error.
Returns the format of the trace.
Return a command to query voltage source status.
Return start storing readings into the buffer.
integration_time(mode[, time])Return integration time.
Return the latest measurement data from buffer
Sets output trigger line
perform_zero_calibration(mode, auto, ...)Build the command sequence for zero calibration.
Return read buffer.
Return take infinite measurements
set_mode(mode)Return set mode.
set_timer(mode, value)Return set time command string.
Stops taking measurements
toggle_voltage_source(enable)Return a command to enable or disable the voltage source.
Methods Documentation
- acquire_data()#
Returns the command to start acquiring data
- Returns:
command – The generated command string
- Return type:
str
- activate_filter(mode, filter_type, active)#
Build a command that enables or disables a digital filter.
- always_read()#
Return always read buffer.
- Returns:
command – The generated command string. An array of all data in the buffer.
- Return type:
str
- clear_array()#
Return clear buffer.
- Returns:
command – The generated command string.
- Return type:
str
- discharge_capacitor()#
Discharges the capacitor.
- Returns:
command – The generated command string.
- Return type:
str
- enable_temperature_reading(enable)#
Return enable temperature reading.
- Parameters:
enable (
bool) – Whether to enable temperature reading.- Returns:
command – The generated command string.
- Return type:
str
- enable_zero_correction(enable)#
Return enable zero correction.
- Parameters:
enable (
bool) – Whether to enable zero correction.- Returns:
command – The generated command string.
- Return type:
str
- format_trac(timestamp=True, temperature=False, voltage=False, set_mode=False, mode='VOLT', channel=False)#
Return format data stored to the buffer.
- Parameters:
timestamp (
bool) – Whether to store timestamp data.temperature (
bool) – Whether to store temperature data.voltage (
bool) – Whether to store voltage-source data.set_mode (
bool) – Whether to store data for a specified measurement mode.mode (
str) – Measurement mode to store whenset_modeis true.channel (
bool) – Whether to store channel data.
- Returns:
command – The generated command string.
- Return type:
str
- get_filter_status(mode, filter_type)#
Return filter status.
- get_last_error()#
Return get last error.
- Returns:
command – The generated command string.
- Return type:
str
- get_trace_format()#
Returns the format of the trace.
- Returns:
command – The generated command string.
- Return type:
str
- get_voltage_source_status()#
Return a command to query voltage source status.
- init_buffer()#
Return start storing readings into the buffer.
- Returns:
command – The generated command string.
- Return type:
str
- integration_time(mode, time=0.001)#
Return integration time.
- Parameters:
mode (
UnitMode) – The unit of the aperture to set.time (
float, optional) – The integration time of the aperture. Defaults to 0.001 seconds.
- Returns:
command – The generated command string.
- Return type:
str
- next_read()#
Return the latest measurement data from buffer
- Returns:
command – The generated command string.
- Return type:
str
- output_trigger_line()#
Sets output trigger line
- Returns:
command – The generated command string.
- Return type:
str
- perform_zero_calibration(mode, auto, range_value, int_time)#
Build the command sequence for zero calibration.
Required when setting mode to volts or amps to cancel internal offsets. See page 4-10 of the user manual for the sequence.
- Parameters:
mode (
UnitMode) – Measurement unit for the device.auto (
bool) – Whether auto range is activated.range_value (
float) – The range of the values.int_time (
float) – Integration time to use for the calibration.
- Returns:
command – Generated command string.
- Return type:
str
- read_buffer()#
Return read buffer.
- Returns:
command – The generated command string.
- Return type:
str
- set_infinite_triggers()#
Return take infinite measurements
- Returns:
command – The generated command string.
- Return type:
str
- set_mode(mode)#
Return set mode.
- Parameters:
mode (
UnitMode) – The unit to switch to.- Returns:
command – The generated command string.
- Return type:
str
- set_timer(mode, value)#
Return set time command string.
- Parameters:
mode (
strorenums.UnitMode) – Measurement mode.value (
float) – Timer value in power-line cycles.
- Returns:
command – The generated command string.
- Return type:
str
- stop_taking_data()#
Stops taking measurements
- Returns:
command – The generated command string.
- Return type:
str
- toggle_voltage_source(enable)#
Return a command to enable or disable the voltage source.