atomiq.components.electronics.rfsource¶
An RFSource has the properties frequency, amplitude and phase these can either be set or ramped linearly.
Classes¶
Abstract class to represent an RF source. Typical examples of components inheriting this class |
|
General frequency mixer with an RF, an IF and an LO port. |
|
Abstract class to represent an RF source. Typical examples of components inheriting this class |
|
An RF source controlled by an analog voltage |
Module Contents¶
- class atomiq.components.electronics.rfsource.RFSource(default_frequency=100000000.0, default_amplitude=0.0, default_phase=0.0, freq_limit=(0.0, float('inf')), amp_limit=(0.0, 1.0), blind=False, default_ramp_steps=30, *args, **kwargs)[source]¶
Bases:
atomiq.components.primitives.Component,atomiq.components.primitives.ParametrizableAbstract class to represent an RF source. Typical examples of components inheriting this class could be a DDS, a standalone AOM driver, an AWG etc.
- Parameters:
default_frequency (float) -- Default frequency of the source.
default_amplitude (float) -- Default amplitude of the source.
default_phase (float) -- Default phase of the source.
freq_limit (tuple) -- Tuple of the minimum and maximum allowed frequency.
amp_limit (tuple) -- Tuple of the minimum and maximum allowed amplitude.
blind (bool) -- Whether the source is set to its default values in each prerun phase. If True, the source is unchanged during prerun, as for example necessary to generate a continuous laser lock signal. Defaults to False.
default_ramp_steps (numpy.int32) -- Number of constant value intervals a ramp is discretized into by default.
- kernel_invariants¶
- _shape_changing_arguments = ('blind',)¶
Names of the constructor arguments whose value (not only their type) changes the shape of the component, i.e. change the types and signatures of class members. The component factory gives objects of the same shape a shared class (and thus a shared compiler specialization). Arguments listed here are compared by value. Definitions along the inheritance hierarchy are merged.
- amplitude = 0.0¶
- frequency = 100000000.0¶
- phase = 0.0¶
- default_ramp_steps = 30¶
- blind = False¶
- _prerun()[source]¶
Specify here what should be done for this component before the run starts. In contrast to the _build() method, the _prerun() routine is executed on the core device before the actual experiment starts.
- set(frequency=float('nan'), amplitude=float('nan'), phase=0.0)[source]¶
Set the frequency and amplitude of the DDS channel
Frequency/amplitude are set to the last known value if
float("nan")is passed (default).- Parameters:
frequency (float) -- Frequency in Hz (
nanto use previous value)amplitude (float) -- Amplitude (
nanto use previous value)phase (float) -- Phase in rad (default 0.0)
- _ramp(duration, frequency_start, frequency_end, amplitude_start, amplitude_end, ramp_timestep=0.0002)[source]¶
This method implements a stupid ramp on an abstract level. This will most likely work but be slow. If your hardware has native support for ramping, please override this function when you inherit from RFSource
- Parameters:
duration (float)
frequency_start (float)
frequency_end (float)
amplitude_start (float)
amplitude_end (float)
ramp_timestep (float)
- ramp(duration, frequency_start=float('nan'), frequency_end=float('nan'), amplitude_start=float('nan'), amplitude_end=float('nan'), ramp_timestep=float('nan'), ramp_steps=-1)[source]¶
Ramp frequency and amplitude over a given duration. Parameters default to
-1ornanto indicate no change. If the start frequency/amplitude is set tonan, the ramp starts from the last frequency/amplitude which was set. This method advances the timeline by ´duration´- Parameters:
duration (float) -- ramp duration [s]
frequency_start (float) -- initial frequency [Hz]
frequency_end (float) -- end frequency [Hz]
amplitude_start (float) -- initial amplitude [0..1]
amplitude_end (float) -- end amplitude [0..1]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- _arb(duration, samples_amp, samples_freq, samples_phase, repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)[source]¶
- Parameters:
duration (float)
samples_amp (list[float])
samples_freq (list[float])
samples_phase (list[float])
repetitions (numpy.int32)
prepare_only (bool)
run_prepared (bool)
- arb(duration, samples_amp=[], samples_freq=[], samples_phase=[], repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)[source]¶
Play Arbitrary Samples from a List
This method allows to set the output amplitude, frequency an phase according to the values specified in respective lists. The whole sequence is played in the specified duration. The pattern store in the sample list can also be repeated.
Tip
We supports a scheme to prepare the arb function before it is actually used. If that is needed, run this function with
prepapre_only = Truewhen the arb should be prepared and withrun_prepared = Truewhen the prepared arb should be played. In both calls the other parameters have to be passed.- Parameters:
samples_amp (list[float]) -- List of amplitude samples. If this list is empty (default), the amplitude is not modified.
samples_freq (list[float]) -- List of frequency samples. If this list is empty (default), the frequency is not modified.
samples_phase (list[float]) -- List of phase samples. If this list is empty (default), the phase is not modified.
duration (float) -- The time in which the whole sequence of samples should be played back [s].
repetitions (numpy.int32) -- Number of times the sequence of all samples should be played. (default 1)
prepare_only (bool) -- Only write the sequence to RAM, don't play it.
run_prepared (bool) -- Play arb sequence previously prepared with
prepare_only.transform_amp -- Function to transform amplitude samples, must take a single argument of type
floatand return a singlefloat.transform_freq -- Function to transform frequency samples (see
transform_amp).transform_phase -- Function to transform phase samples (see
transform_amp).
- experiment¶
- identifier¶
- debug_output = False¶
- core¶
- _kernel_invariants¶
- _prepare_done = False¶
- _build_done = False¶
- _hooks_done = []¶
- children = []¶
- __in_build = True¶
- set_parameter(value, channel=None)¶
- Parameters:
value (float)
channel (str)
- class atomiq.components.electronics.rfsource.RFMixer(if_source, lo_source, sideband=-1, frequency_control_port='if', amplitude_control_port='if', blind_source=False, *args, **kwargs)[source]¶
Bases:
RFSourceGeneral frequency mixer with an RF, an IF and an LO port.
This component represents the signal at the RF port of a frequency mixer, i.e. the mixer is an RFSource itself and can e.g. be used as the rfsource of an AOM. The port frequencies always obey the mixing equation
\[f_\mathrm{rf} = f_\mathrm{lo} + \mathrm{sideband} * f_\mathrm{if}\]where
sideband = -1corresponds to difference (down-)conversion,sideband = +1to sum (up-)conversion and highersidebandto harmonics of the IF.The IF and LO ports are connected to RFSource components:
set_frequency()adjusts the frequency of thefrequency_control_portinput such that the RF output frequency matches the request, given the current frequency of the second input. That frequency is read from the component at kernel runtime (viaRFSource.get_frequency()), i.e. the mixer always follows the frequency attribute of that component.set_amplitude()is forwarded to theamplitude_control_portinput.
Since this is an RFSource, ramps and arbs work through the usual machinery and are forwarded to the corresponding input ports.
- Parameters:
if_source (RFSource) -- RFSource component connected to the IF port
lo_source (RFSource) -- RFSource component connected to the LO port
sideband (int) -- nonzero integer, +1 for sum (up-), -1 for difference (down-)conversion (default -1)
frequency_control_port (str) -- input port which is adjusted to set the RF output frequency, "if" or "lo" (default "if")
amplitude_control_port (str) -- input port which is adjusted to set the RF output amplitude, "if" or "lo" (default "if")
blind_source (bool) -- Control whether the static source frequency is queried for every frequency update. For slow RPC devices which do not change unexpectedly this can be set to
Falseto avoid unnecessary RPC calls. The frequency must then by synced manually by usingRFMixer.sync_static_source().
- kernel_invariants¶
- _shape_changing_arguments = ('frequency_control_port', 'amplitude_control_port')¶
Names of the constructor arguments whose value (not only their type) changes the shape of the component, i.e. change the types and signatures of class members. The component factory gives objects of the same shape a shared class (and thus a shared compiler specialization). Arguments listed here are compared by value. Definitions along the inheritance hierarchy are merged.
- static_frequency: float = 0.0¶
- if_source¶
- lo_source¶
- sideband = -1¶
- frequency_control_port = 'if'¶
- amplitude_control_port = 'if'¶
- _frequency_source¶
- _frequency_static_source¶
- _amplitude_source¶
- blind_source = False¶
- _driven_frequency(frequency_out, frequency_static)[source]¶
- Parameters:
frequency_out (float)
frequency_static (float)
- Return type:
float
- sync_static_source()[source]¶
Sync the frequency from the static frequency source.
This function is meant to be used with
blind_source=Truewhen using a non-realtime device as a static RF source at IF or LO. If the static source is a sinara device,blind_source=Falseis recommended.
- amplitude = 0.0¶
- frequency = 100000000.0¶
- phase = 0.0¶
- default_ramp_steps = 30¶
- blind = False¶
- _prerun()¶
Specify here what should be done for this component before the run starts. In contrast to the _build() method, the _prerun() routine is executed on the core device before the actual experiment starts.
- _prerun_blind()¶
- set_frequency(frequency)¶
- Parameters:
frequency (float)
- _check_frequency(frequency)¶
- get_frequency()¶
- Return type:
float
- set_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- _check_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- get_amplitude()¶
- Return type:
float
- set_phase(phase)¶
- Parameters:
phase (float)
- get_phase()¶
- Return type:
float
- set(frequency=float('nan'), amplitude=float('nan'), phase=0.0)¶
Set the frequency and amplitude of the DDS channel
Frequency/amplitude are set to the last known value if
float("nan")is passed (default).- Parameters:
frequency (float) -- Frequency in Hz (
nanto use previous value)amplitude (float) -- Amplitude (
nanto use previous value)phase (float) -- Phase in rad (default 0.0)
- _ramp(duration, frequency_start, frequency_end, amplitude_start, amplitude_end, ramp_timestep=0.0002)¶
This method implements a stupid ramp on an abstract level. This will most likely work but be slow. If your hardware has native support for ramping, please override this function when you inherit from RFSource
- Parameters:
duration (float)
frequency_start (float)
frequency_end (float)
amplitude_start (float)
amplitude_end (float)
ramp_timestep (float)
- ramp(duration, frequency_start=float('nan'), frequency_end=float('nan'), amplitude_start=float('nan'), amplitude_end=float('nan'), ramp_timestep=float('nan'), ramp_steps=-1)¶
Ramp frequency and amplitude over a given duration. Parameters default to
-1ornanto indicate no change. If the start frequency/amplitude is set tonan, the ramp starts from the last frequency/amplitude which was set. This method advances the timeline by ´duration´- Parameters:
duration (float) -- ramp duration [s]
frequency_start (float) -- initial frequency [Hz]
frequency_end (float) -- end frequency [Hz]
amplitude_start (float) -- initial amplitude [0..1]
amplitude_end (float) -- end amplitude [0..1]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- _arb(duration, samples_amp, samples_freq, samples_phase, repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
- Parameters:
duration (float)
samples_amp (list[float])
samples_freq (list[float])
samples_phase (list[float])
repetitions (numpy.int32)
prepare_only (bool)
run_prepared (bool)
- arb(duration, samples_amp=[], samples_freq=[], samples_phase=[], repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
Play Arbitrary Samples from a List
This method allows to set the output amplitude, frequency an phase according to the values specified in respective lists. The whole sequence is played in the specified duration. The pattern store in the sample list can also be repeated.
Tip
We supports a scheme to prepare the arb function before it is actually used. If that is needed, run this function with
prepapre_only = Truewhen the arb should be prepared and withrun_prepared = Truewhen the prepared arb should be played. In both calls the other parameters have to be passed.- Parameters:
samples_amp (list[float]) -- List of amplitude samples. If this list is empty (default), the amplitude is not modified.
samples_freq (list[float]) -- List of frequency samples. If this list is empty (default), the frequency is not modified.
samples_phase (list[float]) -- List of phase samples. If this list is empty (default), the phase is not modified.
duration (float) -- The time in which the whole sequence of samples should be played back [s].
repetitions (numpy.int32) -- Number of times the sequence of all samples should be played. (default 1)
prepare_only (bool) -- Only write the sequence to RAM, don't play it.
run_prepared (bool) -- Play arb sequence previously prepared with
prepare_only.transform_amp -- Function to transform amplitude samples, must take a single argument of type
floatand return a singlefloat.transform_freq -- Function to transform frequency samples (see
transform_amp).transform_phase -- Function to transform phase samples (see
transform_amp).
- experiment¶
- identifier¶
- debug_output = False¶
- core¶
- _kernel_invariants¶
- _prepare_done = False¶
- _build_done = False¶
- _hooks_done = []¶
- children = []¶
- __in_build = True¶
- set_parameter(value, channel=None)¶
- Parameters:
value (float)
channel (str)
- class atomiq.components.electronics.rfsource.RPCRFSource(rpc_rfsource, *args, **kwargs)[source]¶
Bases:
RFSourceAbstract class to represent an RF source. Typical examples of components inheriting this class could be a DDS, a standalone AOM driver, an AWG etc.
- Parameters:
default_frequency -- Default frequency of the source.
default_amplitude -- Default amplitude of the source.
default_phase -- Default phase of the source.
freq_limit -- Tuple of the minimum and maximum allowed frequency.
amp_limit -- Tuple of the minimum and maximum allowed amplitude.
blind -- Whether the source is set to its default values in each prerun phase. If True, the source is unchanged during prerun, as for example necessary to generate a continuous laser lock signal. Defaults to False.
default_ramp_steps -- Number of constant value intervals a ramp is discretized into by default.
rpc_rfsource (Component)
- kernel_invariants¶
- rfsource¶
- _shape_changing_arguments = ('blind',)¶
Names of the constructor arguments whose value (not only their type) changes the shape of the component, i.e. change the types and signatures of class members. The component factory gives objects of the same shape a shared class (and thus a shared compiler specialization). Arguments listed here are compared by value. Definitions along the inheritance hierarchy are merged.
- amplitude = 0.0¶
- frequency = 100000000.0¶
- phase = 0.0¶
- default_ramp_steps = 30¶
- blind = False¶
- _prerun()¶
Specify here what should be done for this component before the run starts. In contrast to the _build() method, the _prerun() routine is executed on the core device before the actual experiment starts.
- _prerun_blind()¶
- set_frequency(frequency)¶
- Parameters:
frequency (float)
- _check_frequency(frequency)¶
- get_frequency()¶
- Return type:
float
- set_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- _check_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- get_amplitude()¶
- Return type:
float
- set_phase(phase)¶
- Parameters:
phase (float)
- get_phase()¶
- Return type:
float
- set(frequency=float('nan'), amplitude=float('nan'), phase=0.0)¶
Set the frequency and amplitude of the DDS channel
Frequency/amplitude are set to the last known value if
float("nan")is passed (default).- Parameters:
frequency (float) -- Frequency in Hz (
nanto use previous value)amplitude (float) -- Amplitude (
nanto use previous value)phase (float) -- Phase in rad (default 0.0)
- _ramp(duration, frequency_start, frequency_end, amplitude_start, amplitude_end, ramp_timestep=0.0002)¶
This method implements a stupid ramp on an abstract level. This will most likely work but be slow. If your hardware has native support for ramping, please override this function when you inherit from RFSource
- Parameters:
duration (float)
frequency_start (float)
frequency_end (float)
amplitude_start (float)
amplitude_end (float)
ramp_timestep (float)
- ramp(duration, frequency_start=float('nan'), frequency_end=float('nan'), amplitude_start=float('nan'), amplitude_end=float('nan'), ramp_timestep=float('nan'), ramp_steps=-1)¶
Ramp frequency and amplitude over a given duration. Parameters default to
-1ornanto indicate no change. If the start frequency/amplitude is set tonan, the ramp starts from the last frequency/amplitude which was set. This method advances the timeline by ´duration´- Parameters:
duration (float) -- ramp duration [s]
frequency_start (float) -- initial frequency [Hz]
frequency_end (float) -- end frequency [Hz]
amplitude_start (float) -- initial amplitude [0..1]
amplitude_end (float) -- end amplitude [0..1]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- _arb(duration, samples_amp, samples_freq, samples_phase, repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
- Parameters:
duration (float)
samples_amp (list[float])
samples_freq (list[float])
samples_phase (list[float])
repetitions (numpy.int32)
prepare_only (bool)
run_prepared (bool)
- arb(duration, samples_amp=[], samples_freq=[], samples_phase=[], repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
Play Arbitrary Samples from a List
This method allows to set the output amplitude, frequency an phase according to the values specified in respective lists. The whole sequence is played in the specified duration. The pattern store in the sample list can also be repeated.
Tip
We supports a scheme to prepare the arb function before it is actually used. If that is needed, run this function with
prepapre_only = Truewhen the arb should be prepared and withrun_prepared = Truewhen the prepared arb should be played. In both calls the other parameters have to be passed.- Parameters:
samples_amp (list[float]) -- List of amplitude samples. If this list is empty (default), the amplitude is not modified.
samples_freq (list[float]) -- List of frequency samples. If this list is empty (default), the frequency is not modified.
samples_phase (list[float]) -- List of phase samples. If this list is empty (default), the phase is not modified.
duration (float) -- The time in which the whole sequence of samples should be played back [s].
repetitions (numpy.int32) -- Number of times the sequence of all samples should be played. (default 1)
prepare_only (bool) -- Only write the sequence to RAM, don't play it.
run_prepared (bool) -- Play arb sequence previously prepared with
prepare_only.transform_amp -- Function to transform amplitude samples, must take a single argument of type
floatand return a singlefloat.transform_freq -- Function to transform frequency samples (see
transform_amp).transform_phase -- Function to transform phase samples (see
transform_amp).
- experiment¶
- identifier¶
- debug_output = False¶
- core¶
- _kernel_invariants¶
- _prepare_done = False¶
- _build_done = False¶
- _hooks_done = []¶
- children = []¶
- __in_build = True¶
- set_parameter(value, channel=None)¶
- Parameters:
value (float)
channel (str)
- class atomiq.components.electronics.rfsource.VoltageControlledRFSource(freq_voltage_source=None, freq_calibration=None, amp_voltage_source=None, amp_calibration=None, *args, **kwargs)[source]¶
Bases:
RFSourceAn RF source controlled by an analog voltage
A frequent use case for this class are AOM drivers whose frequency and amplitude can be controlled via analog voltages.
- Parameters:
freq_voltage_source (VoltageSource) -- Voltage source that controls the frequency of the rf source
amp_voltage_source (VoltageSource) -- Voltage source that controls amplitude of the rf source
freq_calibration (Calibration) -- Calibration U = f(freq) to give the control voltage U for a desired frequency in Hz
amp_calibration (Calibration) -- Calibration U = f(amp) to give the control voltage U for a desired amplitude in full scale [0..1]
- kernel_invariants¶
- ramp_frequency(duration, frequency_start, frequency_end, ramp_timestep=float('nan'), ramp_steps=-1)[source]¶
Ramp only the frequency of the RF source
This function can possibly ramp the RF source faster than the generic
ramp()method if the connected DAC can do fast ramps.- Parameters:
duration (float) -- ramp duration [s]
frequency_start (float) -- initial frequency [Hz]
frequency_end (float) -- end frequency [Hz]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- ramp_amplitude(duration, amplitude_start, amplitude_end, ramp_timestep=float('nan'), ramp_steps=-1)[source]¶
Ramp only the amplitude of the RF source
This function can possibly ramp the RF source faster than the generic
ramp()method if the connected DAC can do fast ramps.- Parameters:
duration (float) -- ramp duration [s]
amplitude_start (float) -- initial amplitude [0..1]
amplitude_end (float) -- end amplitude [0..1]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- _shape_changing_arguments = ('blind',)¶
Names of the constructor arguments whose value (not only their type) changes the shape of the component, i.e. change the types and signatures of class members. The component factory gives objects of the same shape a shared class (and thus a shared compiler specialization). Arguments listed here are compared by value. Definitions along the inheritance hierarchy are merged.
- amplitude = 0.0¶
- frequency = 100000000.0¶
- phase = 0.0¶
- default_ramp_steps = 30¶
- blind = False¶
- _prerun()¶
Specify here what should be done for this component before the run starts. In contrast to the _build() method, the _prerun() routine is executed on the core device before the actual experiment starts.
- _prerun_blind()¶
- set_frequency(frequency)¶
- Parameters:
frequency (float)
- _check_frequency(frequency)¶
- get_frequency()¶
- Return type:
float
- set_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- _check_amplitude(amplitude)¶
- Parameters:
amplitude (float)
- get_amplitude()¶
- Return type:
float
- set_phase(phase)¶
- Parameters:
phase (float)
- get_phase()¶
- Return type:
float
- set(frequency=float('nan'), amplitude=float('nan'), phase=0.0)¶
Set the frequency and amplitude of the DDS channel
Frequency/amplitude are set to the last known value if
float("nan")is passed (default).- Parameters:
frequency (float) -- Frequency in Hz (
nanto use previous value)amplitude (float) -- Amplitude (
nanto use previous value)phase (float) -- Phase in rad (default 0.0)
- _ramp(duration, frequency_start, frequency_end, amplitude_start, amplitude_end, ramp_timestep=0.0002)¶
This method implements a stupid ramp on an abstract level. This will most likely work but be slow. If your hardware has native support for ramping, please override this function when you inherit from RFSource
- Parameters:
duration (float)
frequency_start (float)
frequency_end (float)
amplitude_start (float)
amplitude_end (float)
ramp_timestep (float)
- ramp(duration, frequency_start=float('nan'), frequency_end=float('nan'), amplitude_start=float('nan'), amplitude_end=float('nan'), ramp_timestep=float('nan'), ramp_steps=-1)¶
Ramp frequency and amplitude over a given duration. Parameters default to
-1ornanto indicate no change. If the start frequency/amplitude is set tonan, the ramp starts from the last frequency/amplitude which was set. This method advances the timeline by ´duration´- Parameters:
duration (float) -- ramp duration [s]
frequency_start (float) -- initial frequency [Hz]
frequency_end (float) -- end frequency [Hz]
amplitude_start (float) -- initial amplitude [0..1]
amplitude_end (float) -- end amplitude [0..1]
ramp_timesteps -- time between steps in the ramp [s]
ramp_steps (numpy.int32) -- number of steps the whole ramp should have. This takes precedence over ramp_timesteps
ramp_timestep (float)
- _arb(duration, samples_amp, samples_freq, samples_phase, repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
- Parameters:
duration (float)
samples_amp (list[float])
samples_freq (list[float])
samples_phase (list[float])
repetitions (numpy.int32)
prepare_only (bool)
run_prepared (bool)
- arb(duration, samples_amp=[], samples_freq=[], samples_phase=[], repetitions=1, prepare_only=False, run_prepared=False, transform_amp=identity_float, transform_freq=identity_float, transform_phase=identity_float)¶
Play Arbitrary Samples from a List
This method allows to set the output amplitude, frequency an phase according to the values specified in respective lists. The whole sequence is played in the specified duration. The pattern store in the sample list can also be repeated.
Tip
We supports a scheme to prepare the arb function before it is actually used. If that is needed, run this function with
prepapre_only = Truewhen the arb should be prepared and withrun_prepared = Truewhen the prepared arb should be played. In both calls the other parameters have to be passed.- Parameters:
samples_amp (list[float]) -- List of amplitude samples. If this list is empty (default), the amplitude is not modified.
samples_freq (list[float]) -- List of frequency samples. If this list is empty (default), the frequency is not modified.
samples_phase (list[float]) -- List of phase samples. If this list is empty (default), the phase is not modified.
duration (float) -- The time in which the whole sequence of samples should be played back [s].
repetitions (numpy.int32) -- Number of times the sequence of all samples should be played. (default 1)
prepare_only (bool) -- Only write the sequence to RAM, don't play it.
run_prepared (bool) -- Play arb sequence previously prepared with
prepare_only.transform_amp -- Function to transform amplitude samples, must take a single argument of type
floatand return a singlefloat.transform_freq -- Function to transform frequency samples (see
transform_amp).transform_phase -- Function to transform phase samples (see
transform_amp).
- experiment¶
- identifier¶
- debug_output = False¶
- core¶
- _kernel_invariants¶
- _prepare_done = False¶
- _build_done = False¶
- _hooks_done = []¶
- children = []¶
- __in_build = True¶
- set_parameter(value, channel=None)¶
- Parameters:
value (float)
channel (str)