for d in ddgs:
        d.setDelay('A', 'T0', delay)

setdelay(decelSeq.off+offset + 0.01/decelSeq.fvel*pb.s)
pb.build()
print decelSeq.off+offset
# After this point, files are created and the script is saved.
raw_input('Final Check! Enter when done.')


# Parameters to Vary
vinit = [800,805,810,815,820]
#distances = [.186 + i*.001 for i in range(-12,13,3)]  #dave's original scan
distances = [.185 + i*.001 for i in range(-1,4,1)]  # denser and more focusing scan
# Define output files, together with the tag that labels them.
o = output.output({0:'optimizing2_denser_scan_strong_focusing'})    

# Saves a copy of the script to the Data folder
yeutil.saveScript()

# Initialize Plot Window to monitor results
plt.ion()
plt.show()
cmap = matplotlib.cm.get_cmap('jet')
# Loop through speeds and measure peak heights
for (i,v) in enumerate(vinit):
    plt.subplot(131+i)
    plt.xlabel('Time from decelerator turn-off (us)')
    if not i:
        plt.ylabel('Signal (arb)')
    plt.title('Optimizing Valve Distance for v=%d' %(v))
Ejemplo n.º 2
0
        d.setDelay('A', 'T0', delay)

setdelay(decelSeq.off+offset + 0.008/decelSeq.fvel*pb.s)
pb.build()
print decelSeq.off+offset
# After this point, files are created and the script is saved.
raw_input('Final Check! Enter when done.')


# Bunching Stages
numbers = yeutil.frange(0,320,32)

# Define output files, together with the tag that labels them.
files = {(n,'SF'):'SF Mode l=%d' %(333-n) for n in numbers}
files.update({(n,'S=1'):'S=1 Mode l=%d' %(333-n) for n in numbers})
o = output.output(files)    
f = yeutil.yeopen('Decel-offtimes')

# Saves a copy of the script to the Data folder
yeutil.saveScript()

# Loop through speeds and measure peak heights
for n in numbers:
    for mode in ['S=1','SF']:
        print mode
        print n
        decelSeq = decelProg(n,mode)
                
        # Modify laser fire window based on final speed
        full = 8e-3/decelSeq.fvel
        delay = yeutil.frange(-full/4,full/4,full/20)
Ejemplo n.º 3
0
    for d in ddgs:
        d.setDelay('A', 'T0', delay)

setdelay(decelSeq.off+offset + 0.01/decelSeq.fvel*pb.s)
pb.build()
print decelSeq.off+offset
# After this point, files are created and the script is saved.
raw_input('Final Check! Enter when done.')


# Parameters to Vary
vinit = [810,815,820]
distances = [.195 + i*.001 for i in range(-12,13,3)]

# Define output files, together with the tag that labels them.
o = output.output({0:'optimizing'})    

# Saves a copy of the script to the Data folder
yeutil.saveScript()

# Initialize Plot Window to monitor results
plt.ion()
plt.show()
cmap = matplotlib.cm.get_cmap('jet')
# Loop through speeds and measure peak heights
for (i,v) in enumerate(vinit):
    plt.subplot(131+i)
    plt.xlabel('Time from decelerator turn-off (us)')
    if not i:
        plt.ylabel('Signal (arb)')
    plt.title('Optimizing Valve Distance for v=%d' %(v))