qcodes_contrib_drivers.drivers.StanfordResearchSystems package¶
Submodules¶
qcodes_contrib_drivers.drivers.StanfordResearchSystems.CS580 module¶
QCoDeS-Driver for Stanford Research Systems CS580 current source: https://www.thinksrs.com/products/cs580.html
- Authors:
Julien Barrier, <julien@julienbarrier.eu>
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.CS580.CS580(*args: Any, **kwargs: Any)[source]¶
Bases:
VisaInstrument
Class to represent an SRS CS580 current source
status: beta-version
- Parameters:
qcodes_contrib_drivers.drivers.StanfordResearchSystems.DG645 module¶
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.DG645.DG645(*args: Any, **kwargs: Any)[source]¶
Bases:
VisaInstrument
Qcodes driver for SRS DG645 digital delay generator.
- save_settings(location: int) None [source]¶
Save instrument settings to given location.
- Parameters:
location – Location to which to save the settings (in [1..9]).
- CHANNEL_MAPPING = {'A': 2, 'B': 3, 'C': 4, 'D': 5, 'E': 6, 'F': 7, 'G': 8, 'H': 9, 'T0': 0, 'T1': 1}¶
- DISPLAY_MAPPING = {'advanced_trig_enable': 4, 'burst_T0_config': 14, 'burst_count': 9, 'burst_delay': 8, 'burst_mode': 7, 'burst_period': 10, 'channel_delay': 11, 'channel_output_levels': 12, 'channel_output_polarity': 13, 'prescale_config': 6, 'trig_holdoff': 5, 'trig_line': 3, 'trig_rate': 0, 'trig_single_shot': 2, 'trig_thresh': 1}¶
- OUTPUT_MAPPING = {'AB': 1, 'CD': 2, 'EF': 3, 'GH': 4, 'T0': 0}¶
- POLARITY_MAPPING = {'+': 1, '-': 0}¶
- PRESCALE_MAPPING = {'AB': 1, 'CD': 2, 'EF': 3, 'GH': 4, 'trig': 0}¶
- TRIGGER_MAPPING = {'ext_falling': 2, 'ext_rising': 1, 'internal': 0, 'line': 6, 'single': 5, 'single_ext_falling': 4, 'single_ext_rising': 3}¶
qcodes_contrib_drivers.drivers.StanfordResearchSystems.SIM928 module¶
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.SIM928.SIM928(*args: Any, **kwargs: Any)[source]¶
Bases:
VisaInstrument
A driver for Stanford Research Systems SIM 928 DC source modules installed in a SIM900 mainframe.
- Parameters:
name (str) – An identifier for this instrument, particularly for attaching it to a
Station
.address (str) – The visa resource name to use to connect.
slot_names (Dict[int]) – An dictionary that optionally maps slot numbers to user-defined module names. Default
{}
.timeout (int, float) – Seconds to allow for responses. Default
5
.metadata (Optional[Dict]) – Additional static metadata to add to this instrument’s JSON snapshot.
- check_module_errors(i, raiseexc=True)[source]¶
Check if any errors have occurred on module
i
and clear the status registers.
- find_modules()[source]¶
Query the SIM900 mainframe for which slots have a SIM928 module present.
- Returns:
- A list of slot numbers where a SIM928 module is present (starting
from 1)
- get_module_status(i)[source]¶
Gets and clears the status bytes corresponding to the registers ESR, CESR and OVSR of module
i
.
- reset_module(i)[source]¶
Sends the SIM Reset signal to module i.
Causes a break signal (MARK level) to be asserted for 100 milliseconds to module i. Upon receiving the break signal the modul will flush its internal input buffer, reset its command parser, and default to 9600 baud communications.
- set_smooth(voltagedict, equitime=False)[source]¶
Set the voltages as specified in
voltagedict` smoothly, by changing the output on each module at a rate ``volt_#_step/smooth_timestep
.
qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR570 module¶
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR570.SR570(*args: Any, **kwargs: Any)[source]¶
Bases:
VisaInstrument
QCoDeS driver for the Stanford Research Systems SR570 Low-Noise Current Preamplifier.
This is a real driver and it will talk to your instrument (as opposed to SR560 from QCoDeS).
It can’t listen to it, so make sure that you either reset or set parameters before reading them.
(Resetting the device will update the parameters’ value with their reset value as per documentation.)
The device can also be accessed via TCP/IP if exposed via something like:
socat /dev/ttyUSB0,echo=0,b9600,cstopb=1,parenb=0,raw tcp-listen:20570,reuseaddr,nodelay
- get_idn() dict[str, str | None] [source]¶
Parse a standard VISA
*IDN?
response into an ID dict.Even though this is the VISA standard, it applies to various other types as well, such as IPInstruments, so it is included here in the Instrument base class.
Override this if your instrument does not support
*IDN?
or returns a nonstandard IDN string. This string is supposed to be a comma-separated list of vendor, model, serial, and firmware, but semicolon and colon are also common separators so we accept them here as well.- Returns:
A dict containing vendor, model, serial, and firmware.
qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR844 module¶
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR844.ChannelTrace(name: str, channel: int, **kwargs: Any)[source]¶
Bases:
ParameterWithSetpoints
Parameter class for the two channel buffers
- __init__(name: str, channel: int, **kwargs: Any) None [source]¶
- Parameters:
name – The name of the parameter
channel – The relevant channel (1 or 2). The name should match this.
- get_raw() Any [source]¶
get_raw
is called to perform the actual data acquisition from the instrument. This method should either be overwritten to perform the desired operation or alternatively forParameter
a suitable method is automatically generated ifget_cmd
is supplied to the parameter constructor. The method is automatically wrapped to provide aget
method on the parameter instance.
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR844.GeneratedSetPoints(sweep_array: Iterable[float | int] = array([0., 0.11111111, 0.22222222, 0.33333333, 0.44444444, 0.55555556, 0.66666667, 0.77777778, 0.88888889, 1.]), *args: Any, **kwargs: Any)[source]¶
Bases:
Parameter
A parameter that generates a setpoint array from start, stop and num points parameters.
- get_raw() Any [source]¶
get_raw
is called to perform the actual data acquisition from the instrument. This method should either be overwritten to perform the desired operation or alternatively forParameter
a suitable method is automatically generated ifget_cmd
is supplied to the parameter constructor. The method is automatically wrapped to provide aget
method on the parameter instance.
- set_raw(value: Iterable[float | int]) None [source]¶
set_raw
is called to perform the actual setting of a parameter on the instrument. This method should either be overwritten to perform the desired operation or alternatively forParameter
a suitable method is automatically generated ifset_cmd
is supplied to the parameter constructor. The method is automatically wrapped to provide aset
method on the parameter instance.
- class qcodes_contrib_drivers.drivers.StanfordResearchSystems.SR844.SR844(*args: Any, **kwargs: Any)[source]¶
Bases:
VisaInstrument
This is the qcodes driver for the Stanford Research Systems SR844 Lock-in Amplifier
- decrement_sensitivity() bool [source]¶
Decrement the sensitivity setting of the lock-in. This is equivalent to pushing the sensitivity down button on the front panel. This has no effect if the sensitivity is already at the minimum.
- Returns:
Whether or not the sensitivity was actually changed.
- increment_sensitivity() bool [source]¶
Increment the sensitivity setting of the lock-in. This is equivalent to pushing the sensitivity up button on the front panel. This has no effect if the sensitivity is already at the maximum.
- Returns:
Whether or not the sensitivity was actually changed.
- set_sweep_parameters(sweep_param: Parameter, start: float, stop: float, n_points: int = 10, label: str | None = None) None [source]¶
- snap(*parameters: str) Tuple[float, ...] [source]¶
Get between 2 and 6 parameters at a single instant. This provides a coherent snapshot of measured signals. Pick up to 6 from: X, Y, R, θ, the aux inputs 1-2, frequency, or what is currently displayed on channels 1 and 2.
Reading X and Y (or R and θ) gives a coherent snapshot of the signal. Snap is important when the time constant is very short, a time constant less than 100 ms.
- Parameters:
*parameters – From 2 to 6 strings of names of parameters for which the values are requested. including: ‘x’, ‘y’, ‘r’, ‘p’, ‘phase’ or ‘θ’, ‘aux1’, ‘aux2’, ‘freq’, ‘ch1’, and ‘ch2’.
- Returns:
A tuple of floating point values in the same order as requested.
Examples
>>> lockin.snap('x','y') -> tuple(x,y)
>>> lockin.snap('aux1','aux2','freq','phase') >>> -> tuple(aux1,aux2,freq,phase)
Note
Volts for x, y, r, and aux 1-4 Degrees for θ Hertz for freq Unknown for ch1 and ch2. It will depend on what was set.
If X,Y,R and θ are all read, then the values of X,Y are recorded approximately 10 µs apart from R,θ. Thus, the values of X and Y may not yield the exact values of R and θ from a single snap.
The values of the Aux Inputs may have an uncertainty of up to 32 µs.
The frequency is computed only every other period or 40 ms, whichever is longer.
- SNAP_PARAMETERS = {'aux1': '6', 'aux2': '7', 'ch1': '9', 'ch2': '10', 'freq': '8', 'p': '5', 'phase': '5', 'r_dbm': '4', 'r_v': '3', 'x': '1', 'y': '2', 'θ': '5'}¶
- sensitivity_value_map = {1e-07: 0, 3e-07: 1, 1e-06: 2, 3e-06: 3, 1e-05: 4, 3e-05: 5, 0.0001: 6, 0.0003: 7, 0.001: 8, 0.003: 9, 0.01: 10, 0.03: 11, 0.1: 12, 0.3: 13, 1: 14}¶
- value_sensitivity_map = {0: 1e-07, 1: 3e-07, 2: 1e-06, 3: 3e-06, 4: 1e-05, 5: 3e-05, 6: 0.0001, 7: 0.0003, 8: 0.001, 9: 0.003, 10: 0.01, 11: 0.03, 12: 0.1, 13: 0.3, 14: 1}¶