def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    trigger.switch_auto('axial',  False) #axial needs to be inverted, so that high TTL corresponds to light ON
    trigger.switch_auto('110DP',  True) #high TTL corresponds to light OFF
    trigger.switch_auto('866DP',  True) #high TTL corresponds to light OFF
    trigger.switch_manual('crystallization',  False) #high TTL corresponds to light OFF
    #make sure r&s synthesizers are on, and are of correct frequency
    #heating
    dpass.select('axial')
    dpass.frequency(axfreq)
    dpass.output(True)
    #readout / cooling
    dpass.select('110DP')
    dpass.output(True)
    rs110DP.select_device(dpass.device_id())
    #make sure the list is in range:
    freqRange = dpass.frequency_range()
    powerRange = dpass.amplitude_range()
    print freqRange, powerRange
    for freq,power in rs110List:
        if not (freqRange[0] <= freq <= freqRange[1]):
            raise Exception('frequency list parameters out of range')
        if not (powerRange[0] <= power <= powerRange[1]):
            raise Exception('power list parameters out of range')
    #create list and enter the list mode
    rs110DP.new_list(rs110List)
    rs110DP.activate_list_mode(True)
    rs110DP.reset_list() ####need to reset because activate list mode after programming ends up at some random step
    #repump
    dpass.select('repump')
    dpass.output(True)
    globalDict['resolution']=trfpga.get_resolution()
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure manual override for the 397 local heating beam is off
    trigger.switch('axial', False)
    #make sure r&s synthesizers are on, and
    for name in ['axial', 'radial']:
        dpass.select(name)
        dpass.output(True)
    #create directory for file saving
    dirappend = time.strftime("%Y%b%d_%H%M_%S", time.localtime())
    basedir = registry.getDataDirectory(reg)
    directory = basedir + '\\' + rawSaveDir + '\\' + experimentName + '\\' + dirappend
    os.mkdir(directory)
    os.chdir(directory)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
    dp.set_inputs('timeResolvedBinning', [('timelength', recordTime),
                                          ('resolution', resolution),
                                          ('bintime', binTime)])
    #where to save into datavault
    dv.cd(['', 'Experiments', experimentName, dirappend], True)
    #make sure we are running in the calibrated mode
    dpass.select('radial')
    dpass.amplitude_offset(radOffset)
Exemple #3
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    trigger.switch_auto('axial',  False) #axial needs to be inverted, so that high TTL corresponds to light on
    trigger.switch_auto('global',  False)
    #make sure r&s synthesizers are on, and 
    for name in ['axial']:
        dpass.select(name)
        dpass.output(True)
    globalDict['resolution']=trfpga.get_resolution()
Exemple #4
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure manual override for the 397 local heating beam is off
    for name in ['global','radial','axial','866DP']:
        trigger.switch_auto(name,  False)
    #make sure r&s synthesizers are on
    for name in ['axial','radial']:
        dpass.select(name)
        dpass.output(True)
    globalDict['resolution']=trfpga.get_resolution()
Exemple #5
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure r&s synthesizers are on and go into auto mode
    for name in ['repump']:
        dpass.select(name)
        dpass.output(True)
    for name in ['866DP']:
        trigger.switch_auto(name)
    dp866.activate_list_mode(True)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure r&s synthesizers are on and go into auto mode
    for name in ['repump']:
        dpass.select(name)
        dpass.output(True)
    for name in ['866DP']:
        trigger.switch_auto(name)
    dp866.activate_list_mode(True)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure r&s synthesizers are on and go into auto mode
    for name in ['axial','radial']:
        dpass.select(name)
        dpass.output(True)
    for name in ['axial','radial','global']:
        trigger.switch_auto(name,False)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
    dp.set_inputs('timeResolvedBinning',[('timelength',recordTime),('resolution',resolution),('bintime',binTime)])
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure r&s synthesizers are on and go into auto mode
    for name in ['axial', 'radial']:
        dpass.select(name)
        dpass.output(True)
    for name in ['axial', 'radial', 'global']:
        trigger.switch_auto(name, False)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
    dp.set_inputs('timeResolvedBinning', [('timelength', recordTime),
                                          ('resolution', resolution),
                                          ('bintime', binTime)])
Exemple #9
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    if heatWithRadial:
    #make sure all beams are auto controlled. axial needs to be inverted to provide cooling in between sequences
        for name in ['global','radial','866DP']:
            trigger.switch_auto(name,  False)
        trigger.switch_auto('axial',  True)
    elif heatArbitrary:
        for name in ['global','radial','axial','866DP']:
            trigger.switch_auto(name,  False)
        if not heatArbitraryRadOn:
            trigger.switch_manual('radial', False)
    #make sure r&s synthesizers are on, and 
    for name in ['axial','radial']:
        dpass.select(name)
        dpass.output(True)
    globalDict['resolution']=trfpga.get_resolution()
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure r&s synthesizers are on and go into auto mode
    for name in ['axial','radial']:
        dpass.select(name)
        dpass.output(True)
        trigger.switch_auto(name,False)
    trigger.switch_auto('global',False)
    #create directory for file saving
    dirappend = time.strftime("%Y%b%d_%H%M_%S",time.localtime())
    basedir = registry.getDataDirectory(reg)
    directory = basedir + '\\' + rawSaveDir + '\\' + experimentName  + '\\' + dirappend
    os.makedirs(directory)
    os.chdir(directory)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
    dp.set_inputs('timeResolvedBinning',[('timelength',recordTime),('resolution',resolution),('bintime',binTime)])
    dv.cd(['','Experiments', experimentName, dirappend], True )
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure manual override for the 397 local heating beam is off
    trigger.switch('axial',False)
    #make sure r&s synthesizers are on, and 
    for name in ['radial']:
        dpass.select(name)
        dpass.output(True)
    #create directory for file saving
    dirappend = time.strftime("%Y%b%d_%H%M_%S",time.localtime())
    basedir = registry.getDataDirectory(reg)
    directory = basedir + '\\' + rawSaveDir + '\\' + experimentName  + '\\' + dirappend
    os.mkdir(directory)
    os.chdir(directory)
    #set up dataprocessing inputs
    resolution = trfpga.get_resolution()
    dp.set_inputs('timeResolvedBinning',[('timelength',recordTime),('resolution',resolution),('bintime',binTime)])
    #where to save into datavault
    dv.cd(['','Experiments', experimentName, dirappend], True )
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    trigger.switch_auto(
        'axial', False
    )  #axial needs to be inverted, so that high TTL corresponds to light ON
    trigger.switch_auto('110DP', True)  #high TTL corresponds to light OFF
    trigger.switch_auto('866DP', True)  #high TTL corresponds to light OFF
    trigger.switch_manual('crystallization',
                          False)  #high TTL corresponds to light OFF
    #make sure r&s synthesizers are on, and are of correct frequency
    #heating
    dpass.select('axial')
    dpass.frequency(axfreq)
    dpass.output(True)
    #readout / cooling
    dpass.select('110DP')
    dpass.output(True)
    rs110DP.select_device(dpass.device_id())
    #make sure the list is in range:
    freqRange = dpass.frequency_range()
    powerRange = dpass.amplitude_range()
    print freqRange, powerRange
    for freq, power in rs110List:
        if not (freqRange[0] <= freq <= freqRange[1]):
            raise Exception('frequency list parameters out of range')
        if not (powerRange[0] <= power <= powerRange[1]):
            raise Exception('power list parameters out of range')
    #create list and enter the list mode
    rs110DP.new_list(rs110List)
    rs110DP.activate_list_mode(True)
    rs110DP.reset_list(
    )  ####need to reset because activate list mode after programming ends up at some random step
    #repump
    dpass.select('repump')
    dpass.output(True)
    globalDict['resolution'] = trfpga.get_resolution()
Exemple #13
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
Exemple #14
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure manual overrides are off
    trigger.switch_auto('radial',  False)
    trigger.switch_auto('866DP',  True)
Exemple #15
0
from scriptLibrary import paulsbox 
import numpy as np

lattice = labrad.connect('192.168.169.254', password = '******')

centerFreq = 18298446#15.00*10**6
ptsAround = 4
recordTime = 0.5 #seconds
iterations = 500
average = 5
#program pulse sequence for triggering time resolved
pboxDict = {
            'sequence':'TimeResolvedTrigger.py',
            'nothing':1,
            }
paulsbox.program(cxn.paul_box, pboxDict)
trfpga = cxn.timeresolvedfpga
trigger = cxn.trigger
trfpga.set_time_length(recordTime)
timeResolution = float(trfpga.get_resolution())
freqRes = 1.0 / recordTime
dv = lattice.data_vault


freqs = centerFreq + np.arange(-ptsAround,ptsAround + 1) * freqRes

def getFFTpwr(timetags):
    mat = np.exp(-1.j*2.0*np.pi*np.outer(freqs, timetags))
    fft = mat.sum(axis=1)
    pwr = np.abs(fft)**2.0
    pwr = pwr / timetags.size
Exemple #16
0
def initialize():
    trfpga.set_time_length(recordTime)
    paulsbox.program(pbox, pboxDict)
    #make sure manual overrides are off
    trigger.switch_auto('radial', False)
    trigger.switch_auto('866DP', True)
Exemple #17
0
import labrad
cxn = labrad.connect()
from scriptLibrary import paulsbox
import numpy as np

centerFreq = 14998866  #15.00*10**6
ptsAround = 4
recordTime = 0.5  #seconds
iterations = 50
average = 3
#program pulse sequence for triggering time resolved
pboxDict = {
    'sequence': 'TimeResolvedTrigger.py',
    'nothing': 1,
}
paulsbox.program(cxn.paul_box, pboxDict)
trfpga = cxn.timeresolvedfpga
trigger = cxn.trigger
trfpga.set_time_length(recordTime)
timeResolution = float(trfpga.get_resolution())
freqRes = 1.0 / recordTime
dv = cxn.data_vault

freqs = centerFreq + np.arange(-ptsAround, ptsAround + 1) * freqRes


def getFFTpwr(timetags):
    mat = np.exp(-1.j * 2.0 * np.pi * np.outer(freqs, timetags))
    fft = mat.sum(axis=1)
    pwr = np.abs(fft)**2.0
    pwr = pwr / timetags.size