Qudi
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
fastcomtecp7887.FastComtec Class Reference

Hardware Class for the FastComtec Card. More...

Inheritance diagram for fastcomtecp7887.FastComtec:
Inheritance graph
[legend]
Collaboration diagram for fastcomtecp7887.FastComtec:
Collaboration graph
[legend]

Public Member Functions

def __init__ (self, config, kwargs)
 
def on_activate (self)
 Initialisation performed during activation of the module.
 
def on_deactivate (self)
 Deinitialisation performed during deactivation of the module.
 
def get_constraints (self)
 Retrieve the hardware constrains from the Fast counting device. More...
 
def configure (self, bin_width_s, record_length_s, number_of_gates=0, filename=None)
 Configuration of the fast counter. More...
 
def get_status (self)
 
def get_current_runtime (self)
 Returns the current runtime. More...
 
def get_current_sweeps (self)
 Returns the current runtime. More...
 
def start_measure (self)
 Start the measurement. More...
 
def pause_measure (self)
 Make a pause in the measurement, which can be continued. More...
 
def stop_measure (self)
 Stop the measurement. More...
 
def continue_measure (self)
 Continue a paused measurement. More...
 
def get_binwidth (self)
 Returns the width of a single timebin in the timetrace in seconds. More...
 
def is_gated (self)
 Check the gated counting possibility. More...
 
def get_data_trace (self)
 
def get_data_testfile (self)
 Load data test file.
 
def get_bitshift (self)
 Get bitshift from Fastcomtec. More...
 
def set_bitshift (self, bitshift)
 Sets the bitshift properly for this card. More...
 
def set_binwidth (self, binwidth)
 Set defined binwidth in Card. More...
 
def set_length (self, length_bins, preset=None, cycles=None, sequences=None)
 Sets the length of the length of the actual measurement. More...
 
def set_preset (self, preset)
 
def set_cycles (self, cycles)
 
def get_length (self)
 Get the length of the current measurement. More...
 
def change_sweep_mode (self, gated)
 
def change_save_mode (self, mode)
 Changes the save mode of p7887. More...
 
def set_delay_start (self, delay_s)
 Sets the record delay length. More...
 
def get_delay_start (self)
 Returns the current record delay length. More...
 
def SetDelay (self, t)
 
def GetDelay (self)
 
def SaveData_locally (self, filename, laser_index)
 
def SetLevel (self, start, stop)
 
def GetLevel (self)
 
def Running (self)
 
def GetStatus (self)
 
def load_setup (self, configname)
 
- Public Member Functions inherited from core.module.BaseMixin
def __init__ (self, manager, name, config=None, callbacks=None, kwargs)
 Initialise Base class object and set up its state machine. More...
 
def log (self)
 Returns a logger object.
 
def is_module_threaded (self)
 Returns whether the module shall be started in a thread.
 
def on_activate (self)
 Method called when module is activated. More...
 
def on_deactivate (self)
 Method called when module is deactivated. More...
 
def getStatusVariables (self)
 Return a dict of variable names and their content representing the module state for saving. More...
 
def setStatusVariables (self, variableDict)
 Give a module a dict of variable names and their content representing the module state. More...
 
def getConfiguration (self)
 Return the configration dictionary for this module. More...
 
def get_connector (self, connector_name)
 Return module connected to the given named connector. More...
 
- Public Member Functions inherited from core.module.ModuleMeta
def __new__ (cls, name, bases, attrs)
 Collect declared Connectors, ConfigOptions and StatusVars into dictionaries. More...
 

Public Attributes

 stopped_or_halt
 
 timetrace_tmp
 
 dll
 
- Public Attributes inherited from core.module.BaseMixin
 module_state
 
 connectors
 

Static Public Attributes

 gated = ConfigOption('gated', False, missing='warn')
 
 trigger_safety = ConfigOption('trigger_safety', 200e-9, missing='warn')
 
 aom_delay = ConfigOption('aom_delay', 400e-9, missing='warn')
 
 minimal_binwidth = ConfigOption('minimal_binwidth', 0.25e-9, missing='warn')
 

Detailed Description

Hardware Class for the FastComtec Card.

unstable Jochen Scheuer, Simon Schmitt

Example config for copy-paste:

fastcomtec_p7887: module 'fastcomtec.fastcomtecp7887.FastComtec' gated False trigger_safety 200e-9 aom_delay 400e-9 minimal_binwidth 0.25e-9

Member Function Documentation

◆ change_save_mode()

def fastcomtecp7887.FastComtec.change_save_mode (   self,
  mode 
)

Changes the save mode of p7887.

Parameters
intmode: Specifies the save mode (0: No Save at Halt, 1: Save at Halt, 2 Write list file, No Save at Halt, 3: Write list file, Save at Halt
@return int mode: specified save mode

◆ configure()

def fastcomtecp7887.FastComtec.configure (   self,
  bin_width_s,
  record_length_s,
  number_of_gates = 0,
  filename = None 
)

Configuration of the fast counter.

Parameters
floatbin_width_s: Length of a single time bin in the time trace histogram in seconds.
floatrecord_length_s: Total length of the timetrace/each single gate in seconds.
intnumber_of_gates: optional, number of gates in the pulse sequence. Ignore for not gated counter.
Returns
tuple(binwidth_s, record_length_s, number_of_gates): binwidth_s float the actual set binwidth in seconds gate_length_s the actual record length in seconds number_of_gates the number of gated, which are accepted, None if not-gated

◆ continue_measure()

def fastcomtecp7887.FastComtec.continue_measure (   self)

Continue a paused measurement.

◆ get_binwidth()

def fastcomtecp7887.FastComtec.get_binwidth (   self)

Returns the width of a single timebin in the timetrace in seconds.

Returns
float: current length of a single bin in seconds (seconds/bin)

The red out bitshift will be converted to binwidth. The binwidth is defined as 2**bitshift*minimal_binwidth.

◆ get_bitshift()

def fastcomtecp7887.FastComtec.get_bitshift (   self)

Get bitshift from Fastcomtec.

Returns
int settings.bitshift: the red out bitshift

◆ get_constraints()

def fastcomtecp7887.FastComtec.get_constraints (   self)

Retrieve the hardware constrains from the Fast counting device.

Returns
dict: dict with keys being the constraint names as string and items are the definition for the constaints.

The keys of the returned dictionary are the str name for the constraints (which are set in this method).

        NO OTHER KEYS SHOULD BE INVENTED!

If you are not sure about the meaning, look in other hardware files to get an impression. If still additional constraints are needed, then they have to be added to all files containing this interface.

The items of the keys are again dictionaries which have the generic dictionary form: {'min':

, 'max':

, 'step':

, 'unit': '

'}

Only the key 'hardware_binwidth_list' differs, since they contain the list of possible binwidths.

If the constraints cannot be set in the fast counting hardware then write just zero to each key of the generic dicts. Note that there is a difference between float input (0.0) and integer input (0), because some logic modules might rely on that distinction.

ALL THE PRESENT KEYS OF THE CONSTRAINTS DICT MUST BE ASSIGNED!

◆ get_current_runtime()

def fastcomtecp7887.FastComtec.get_current_runtime (   self)

Returns the current runtime.

Returns
float runtime: in s

◆ get_current_sweeps()

def fastcomtecp7887.FastComtec.get_current_sweeps (   self)

Returns the current runtime.

Returns
int sweeps: in sweeps

◆ get_delay_start()

def fastcomtecp7887.FastComtec.get_delay_start (   self)

Returns the current record delay length.

Returns
float delay_s: current record delay length in seconds

◆ get_length()

def fastcomtecp7887.FastComtec.get_length (   self)

Get the length of the current measurement.

Returns
int: length of the current measurement

◆ is_gated()

def fastcomtecp7887.FastComtec.is_gated (   self)

Check the gated counting possibility.

Returns
bool: Boolean value indicates if the fast counter is a gated counter (TRUE) or not (FALSE).

◆ pause_measure()

def fastcomtecp7887.FastComtec.pause_measure (   self)

Make a pause in the measurement, which can be continued.

◆ set_binwidth()

def fastcomtecp7887.FastComtec.set_binwidth (   self,
  binwidth 
)

Set defined binwidth in Card.

Parameters
floatbinwidth: the current binwidth in seconds
Returns
float: Red out bitshift converted to binwidth

The binwidth is converted into to an appropiate bitshift defined as 2**bitshift*minimal_binwidth.

◆ set_bitshift()

def fastcomtecp7887.FastComtec.set_bitshift (   self,
  bitshift 
)

Sets the bitshift properly for this card.

Parameters
intbitshift:
Returns
int: asks the actual bitshift and returns the red out value

◆ set_delay_start()

def fastcomtecp7887.FastComtec.set_delay_start (   self,
  delay_s 
)

Sets the record delay length.

Parameters
intdelay_s: Record delay after receiving a start trigger
Returns
int mode: specified save mode

◆ set_length()

def fastcomtecp7887.FastComtec.set_length (   self,
  length_bins,
  preset = None,
  cycles = None,
  sequences = None 
)

Sets the length of the length of the actual measurement.

Parameters
intlength_bins: Length of the measurement in bins
Returns
float: Red out length of measurement

◆ start_measure()

def fastcomtecp7887.FastComtec.start_measure (   self)

Start the measurement.

◆ stop_measure()

def fastcomtecp7887.FastComtec.stop_measure (   self)

Stop the measurement.


The documentation for this class was generated from the following file: