dcbias module¶
DC-bias waveform generation
- class presto.dcbias.DcBiasWaveform(edges, polys)¶
Bases:
objectA waveform that is output from the DC-bias ports.
Used as input to
Hardware.setup_dcbias_waveform().Examples
Output a sawtooth during a lockin measurement
>>> with Lockin(address=ADDRESS) as lck: >>> wave = DcBiasWaveform.sawtooth(-0.5, 0.5) >>> lck.hardware.setup_dcbias_waveform(DC_PORT, wave, DC_FREQ) >>> >>> rf_freq, df = lck.tune(RF_FREQ, DF) >>> lck.set_df(df) >>> >>> og = lck.add_output_group(RF_OUT_PORT, 1) >>> og.set_amplitudes(RF_AMP).set_frequencies(RF_FREQ) >>> >>> ig = lck.add_input_group(RF_IN_PORT, 1) >>> ig.set_frequencies(rf_freq) >>> >>> lck.apply_settings() >>> freqs, data_i, data_q = lck.get_pixels(NR_PIX)[RF_IN_PORT] >>> >>> lck.hardware.stop_dcbias_waveform(0.0)
- classmethod cos(amp)¶
Generate a cosine waveform on the DC-bias output.
- Parameters:
amp (
float) – amplitude (peak) value in volts- Return type:
- classmethod piecewise_linear(x, y)¶
Generate a piece-wise linear waveform on the DC-bias output.
- Parameters:
x (
TypeAliasType) – time points at which output should have value y. See Notes section for restrictions.y (
TypeAliasType) – value at timexin volts. Must have same length asx.
- Return type:
Notes
Time values in
xare in units of the repetition period and must be between0.0and1.0. The first valuex[0]must be0.0and the last valuex[-1]must be1.0. Values inxmust be sorted.- Raises:
- classmethod pulse(v1, v2, *, td=0.0, tr=0.0, tf=0.0, pw=None)¶
Generate a pulse waveform on the DC-bias output.
- Parameters:
- Return type:
Note
All times are dimensionless, in unit of the repetition period.
Notes
A single pulse, without repetition count or phase offset, is described by the following table:
Time
Value
0.0
v1
td
v1
td + tr
v2
td + tr + pw
v2
td + tr + pw + tf
v1
1.0
v1
Rise and fall segments are described by a cubic polynomial with derivative zero at the extremes. The pulse segment is constant at v2. The initial delay segment and the final filling segment are constant at v1.
- Raises:
- classmethod sawtooth(v1, v2)¶
Generate a sawtooth waveform on the DC-bias output.
- Parameters:
- Return type: