pyepr.hardware.PyEPR_control.PyEPRControlInterface¶
- class pyepr.hardware.PyEPR_control.PyEPRControlInterface(config_file_path)¶
Bases:
pyepr.classes.Interface
Represents the interface for spectrometers built using PyEPR and connected with a local flask server.
- Parameters:
- config_file_pathfloat
The file path for the spectrometer configuration file.
- Parameters:
config_file_path (str)
- IFgain_options¶
- IFgain = 2¶
- config_file¶
- server = None¶
- property savefolder¶
- connect(ip='localhost', port=5000)¶
- disconnect()¶
- acquire_dataset(verbosity=0, sum_scans=True, **kwargs)¶
Acquires the dataset.
- get_buffer(verbosity=0, sum_scans=True, **kwargs)¶
- set_param(param, value)¶
Set a parameter for the spectrometer.
- Parameters:
- paramstr
The parameter to set. Possible values are ‘LO’, ‘temp’, ‘reptime’, ‘field’, ‘videoGain’.
- valuefloat
The value to set the parameter to.
- Parameters:
param (str)
value (float)
- terminate()¶
Terminates the experiment immediately.
- launch(sequence, savename, IFgain=None, *args, **kwargs)¶
Launches the experiment and initialises autosaving.
- Parameters:
- sequenceSequence
The sequence to be launched
- savenamestr
The savename for this measurement. A timestamp will be added to the value.
- Parameters:
sequence (pyepr.sequences.Sequence)
savename (str)
- _launch(sequence, savename, IFgain=0, reset_cur_exp=True, *args, **kwargs)¶
- Parameters:
sequence (pyepr.sequences.Sequence)
savename (str)
- isrunning()¶
- Return type:
bool
- tune_rectpulse(*, tp, freq, B, reptime, shots=400)¶
Generates a rectangular pi and pi/2 pulse of the given length at the given field position. This value is stored in the pulse cache.
- Parameters:
- tpfloat
Pulse length of pi/2 pulse in ns
- freqfloat
Central frequency of this pulse in GHz
- Bfloat
Magnetic B0 field position in Gauss
- reptime: float
Shot repetion time in us.
- shots: int
The number of shots
- Returns:
- p90: RectPulse
A tuned rectangular pi/2 pulse of length tp
- p180: RectPulse
A tuned rectangular pi pulse of length tp
- tune_pulse(pulse, mode, freq, B, reptime, shots=400)¶
Tunes a single pulse a range of methods.
- Parameters:
- pulsePulse
The Pulse object in need of tuning.
- modestr
The method to be used.
- freqfloat
The local oscilator frequency in GHz
- Bfloat
Magnetic B0 field position in Gauss
- reptimeus
Shot repetion time in us.
- shots: int
The number of shots
- Returns:
- Tunned Pulse: Pulse
The returned pulse object that is now tunned.
- tune(*, sequence=None, mode='amp_hahn', freq=None, gyro=None)¶