labdrivers.keithley

class labdrivers.keithley.keithley2400.Keithley2400(gpib_addr=23)[source]
abort_cycle()[source]

Aborts the source or measure cycle, bringing the SourceMeter back into an idle state.

buffer_memory_status()[source]

Check buffer memory status.

clear_status()[source]

Clears all event registers and Error Queue.

clear_trace()[source]

Clear the buffer.

current_compliance

Sets or gets the current compliance level in Amperes.

disable_buffer()[source]

Disables the buffer.

expected_current_reading

Gets or sets the expected current reading from the device under test.

expected_ohms_reading

Gets or sets the expected range of a resistance reading from the device under test.

expected_voltage_reading

Gets or sets the expected voltage reading from the device under test.

fill_buffer()[source]

Fill buffer and stop.

four_wire_sensing

Gets the status of or sets four-wire sensing.

Expected booleans for setting: True, False.

gpib_addr

Returns the GPIB address of the Keithley 2400 Sourcemeter.

identify()[source]

Returns manufacturer, model number, serial number, and firmware revision levels.

initiate_cycle()[source]

Initiates source or measure cycle, taking the SourceMeter out of an idle state.

measure_type

The type of measurement the Keithley 2400 SourceMeter will make.

Expected strings for setting: ‘voltage’, ‘current’, ‘resistance’

num_readings_in_buffer

Gets the number of readings that are stored in the buffer.

output

Gets or sets the source output of the Keithley 2400.

Expected input: boolean

Returns:boolean
output_off_mode

Gets or sets the output mode when the output is off.

Expected input strings: ‘himp’, ‘normal’, ‘zero’, ‘guard’

Returns:description of the output’s off mode
ramp_to_setpoint(setpoint: float, step: float, wait: float)[source]
ramp_to_zero()[source]
read(*measurements)[source]

Reads data from the Keithley 2400. Equivalent to the command :INIT; :FETCH?

Multiple string arguments may be used. For example:

keithley.read('voltage', 'current')
keithley.read('time')

The first line returns a list in the form [voltage, current] and the second line returns a list in the form [time].

Note: The returned lists contains the values in the order that you requested.

Parameters:*measurements (str) –

Any number of arguments that are from: ‘voltage’, ‘current’, ‘resistance’, ‘time’

Return list measure_list:
 A list of the arithmetic means in the order of the given arguments
Return list measure_stdev_list:
 A list of the standard deviations (if more than 1 measurement) in the order of the given arguments
read_trace()[source]

Read contents of buffer.

reset_to_defaults()[source]

Resets to defaults of Sourcemeter.

resistance_ohms_mode

Gets or sets the resistance mode.

Expected strings for setting: ‘manual’, ‘auto’

send_bus_trigger()[source]

Sends a bus trigger to SourceMeter.

source_mode

Gets or sets the mode of the source.

Expected strings for setting: ‘fixed’, ‘sweep’, ‘list’

source_type

Gets or sets the source type of the Keithley 2400 SourceMeter.

Expected strings for setting: ‘voltage’, ‘current’

source_value

Get or set the numeric value of the source chosen from Keithley2400.source_type.

sweep_center

To be implemented.

sweep_direction

To be implemented.

sweep_end

To be implemented.

sweep_points

To be implemented.

sweep_ranging

To be implemented.

sweep_scale

To be implemented.

sweep_span

To be implemented.

sweep_start

To be implemented.

trace_delay

The amount of time the SourceMeter waits after the trigger to perform Device Action.

trace_feed_source(value)[source]

Sets the source of the trace feed.

Expected strings: ‘sense’, ‘calculate1’, ‘calculate2’

trace_points

Gets or sets the size of the buffer

Expected integer value range: 1 <= n <= 2500

trigger

Gets or sets the type of trigger to be used.

Expected strings for setting: ‘immediate’, ‘tlink’, ‘timer’, ‘manual’, ‘bus’, ‘nst’, ‘pst’, ‘bst’ (see source code for other possibilities)

trigger_count

Gets or sets the number of triggers

Expected integer value range: 1 <= n <= 2500

voltage_compliance

Gets or sets the voltage compliance.

Expected range of floats: 200e-6 <= x <= 210

within_current_compliance()[source]

Queries if the measured current is within the set compliance.

Returns:boolean
within_voltage_compliance()[source]

Queries if the measured voltage is within the set compliance.

Returns:boolean