# SR830 Lock-in Amplifier

class pymeasure.instruments.srs.SR830(adapter, name='Stanford Research Systems SR830 Lock-in amplifier', **kwargs)

  Bases: `Instrument`

  property adc1

    Reads the Aux input 1 value in Volts with 1/3 mV resolution.

  property adc2

    Reads the Aux input 2 value in Volts with 1/3 mV resolution.

  property adc3

    Reads the Aux input 3 value in Volts with 1/3 mV resolution.

  property adc4

    Reads the Aux input 4 value in Volts with 1/3 mV resolution.

  auto_offset(channel)

    Offsets the channel (X, Y, or R) to zero

  property aux_in_1

    Reads the Aux input 1 value in Volts with 1/3 mV resolution.

  property aux_in_2

    Reads the Aux input 2 value in Volts with 1/3 mV resolution.

  property aux_in_3

    Reads the Aux input 3 value in Volts with 1/3 mV resolution.

  property aux_in_4

    Reads the Aux input 4 value in Volts with 1/3 mV resolution.

  property aux_out_1

    A floating point property that controls the output of Aux output 1 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property aux_out_2

    A floating point property that controls the output of Aux output 2 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property aux_out_3

    A floating point property that controls the output of Aux output 3 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property aux_out_4

    A floating point property that controls the output of Aux output 4 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  buffer_measure(count, stopRequest=None, delay=0.001)

    Start a fast measurement mode and transfers data from buffer to extract mean and std measurements

    Return the mean and std from both channels

  property channel1

    A string property that represents the type of Channel 1, taking the values X, R, X Noise, Aux In 1, or Aux In 2. This property can be set.

  property channel2

    A string property that represents the type of Channel 2, taking the values Y, Theta, Y Noise, Aux In 3, or Aux In 4. This property can be set.

  clear()

    Clear the instrument status byte.

  property dac1

    A floating point property that controls the output of Aux output 1 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property dac2

    A floating point property that controls the output of Aux output 2 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property dac3

    A floating point property that controls the output of Aux output 3 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property dac4

    A floating point property that controls the output of Aux output 4 in Volts, taking values between -10.5 V and +10.5 V. This property can be set.

  property err_status

    Reads the value of the lockin error (ERR) status byte. Returns an IntFlag type with positions within the string corresponding to different error flags:

    Bit | Status
    --- | ---
    0 | unused
    1 | backup error
    2 | RAM error
    3 | unused
    4 | ROM error
    5 | GPIB error
    6 | DSP error
    7 | DSP error

  fill_buffer(count: int, has_aborted=<function SR830.<lambda>>, delay=0.001)

    Fill two numpy arrays with the content of the instrument buffer

    Eventually waiting until the specified number of recording is done

  property filter_slope

    An integer property that controls the filter slope, which can take on the values 6, 12, 18, and 24 dB/octave. Values are truncated to the next highest level if they are not exact.

  property filter_synchronous

    A boolean property that controls the synchronous filter. This property can be set. Allowed values are: True or False

  property frequency

    A floating point property that represents the lock-in frequency in Hz. This property can be set.

  get_buffer(channel=1, start=0, end=None)

    Acquires the 32 bit floating point data through binary transfer

  get_scaling(channel)

    Returns the offset percent and the expansion term that are used to scale the channel in question

  property harmonic

    An integer property that controls the harmonic that is measured. Allowed values are 1 to 19999. Can be set.

  property id

    Get the identification of the instrument.

  property input_config

    An string property that controls the input configuration. Allowed values are: [‘A’, ‘A - B’, ‘I (1 MOhm)’, ‘I (100 MOhm)’]

  property input_coupling

    An string property that controls the input coupling. Allowed values are: [‘AC’, ‘DC’]

  property input_grounding

    An string property that controls the input shield grounding. Allowed values are: [‘Float’, ‘Ground’]

  property input_notch_config

    An string property that controls the input line notch filter status. Allowed values are: [‘None’, ‘Line’, ‘2 x Line’, ‘Both’]

  is_out_of_range()

    Returns True if the magnitude is out of range

  property lia_status

    Reads the value of the lockin amplifier (LIA) status byte. Returns a binary string with positions within the string corresponding to different status flags:

    Bit | Status
    --- | ---
    0 | Input/Amplifier overload
    1 | Time constant filter overload
    2 | Output overload
    3 | Reference unlock
    4 | Detection frequency range switched
    5 | Time constant changed indirectly
    6 | Data storage triggered
    7 | unused

  load_setup(setup_number: int)

    Load a previously saved instrument configuration from the memory referred to by an integer

    Parameters:

      setup_number – the integer referring to the memory (between 1 and 9 (included))

  property magnitude

    Reads the magnitude in Volts.

  output_conversion(channel)

    Returns a function that can be used to determine the signal from the channel output (X, Y, or R)

  pause_scan()

    Pause the data recording

  property phase

    A floating point property that represents the lock-in phase in degrees. This property can be set.

  quick_range()

    While the magnitude is out of range, increase the sensitivity by one setting

  property reference_source

    An string property that controls the reference source. Allowed values are: [‘External’, ‘Internal’]

  property reference_source_trigger

    A string property that controls the reference source triggering. Allowed values are: [‘SINE’, ‘POS EDGE’, ‘NEG EDGE’]

  reset()

    Reset the instrument.

  property sample_frequency

    Gets the sample frequency in Hz

  save_setup(setup_number: int)

    Save the current instrument configuration (all parameters) in a memory referred to by an integer

    Parameters:

      setup_number – the integer referring to the memory (between 1 and 9 (included))

  property sensitivity

    A floating point property that controls the sensitivity in Volts, which can take discrete values from 2 nV to 1 V. Values are truncated to the next highest level if they are not exact.

  set_scaling(channel, precent, expand=0)

    Sets the offset of a channel (X=1, Y=2, R=3) to a certain percent (-105% to 105%) of the signal, with an optional expansion term (0, 10=1, 100=2)

  property sine_voltage

    A floating point property that represents the reference sine-wave voltage in Volts. This property can be set.

  snap(val1='X', val2='Y', *vals)

    Method that records and retrieves 2 to 6 parameters at a single instant. The parameters can be one of: X, Y, R, Theta, Aux In 1, Aux In 2, Aux In 3, Aux In 4, Frequency, CH1, CH2. Default is “X” and “Y”.

    Parameters:

      - val1 – first parameter to retrieve

      - val2 – second parameter to retrieve

      - vals – other parameters to retrieve (optional)

  start_scan()

    Start the data recording into the buffer

  property status

    Get the status byte and Master Summary Status bit.

  property theta

    Reads the theta value in degrees.

  property time_constant

    A floating point property that controls the time constant in seconds, which can take discrete values from 10 microseconds to 30,000 seconds. Values are truncated to the next highest level if they are not exact.

  wait_for_buffer(count, has_aborted=<function SR830.<lambda>>, timeout=60, timestep=0.01)

    Wait for the buffer to fill a certain count

  property x

    Reads the X value in Volts.

  property xy

    Reads the X and Y values in Volts.

  property y

    Reads the Y value in Volts.