Script execution
This commit is contained in:
@@ -4,8 +4,8 @@
|
||||
|
||||
|
||||
tc1 = caget('X06DA-OP-MO:TC1') # theta1 thermo couple 1
|
||||
energy = # Mono energy
|
||||
dtz = caget(X06DA-ES-DET:TRZ1') # detector Z- position
|
||||
energy = get_energy() # Mono energy
|
||||
dtz = caget('X06DA-ES-DET:TRZ1') # detector Z- position
|
||||
|
||||
if current.read() < 200:
|
||||
raise Exception ('Ring current too low')
|
||||
@@ -19,7 +19,7 @@ if caget('X06DA-FE-PH1:OPEN_EPS','i') == 0: # FrontEnd shutter state
|
||||
if caget('X06DA-OP-ST1:OPEN_EPS','i') == 0: # ExpHutch shutter state
|
||||
raise Exception ('ExpHutchShutter closed ')
|
||||
|
||||
if caget('X06DA-OP-MO:E-GET'),'d') > 17.5: #Mono energy
|
||||
if caget(('X06DA-OP-MO:E-GET'),'d') > 17.5: #Mono energy
|
||||
raise Exception ('Sorry, no feedback above 17.5 keV for now')
|
||||
|
||||
tc = 40 # 2015.09.20 quick fix by MT JW
|
||||
@@ -48,16 +48,16 @@ by = bpm1.read()
|
||||
print "EBOX-POSV before rock: " + str(by)
|
||||
# if beam is not off, do nothing
|
||||
if abs(by) > ymax:
|
||||
run("rock", {"rock_axis":th1})
|
||||
rock(th1)
|
||||
|
||||
# result of ROCK
|
||||
time.sleep(2.0)
|
||||
by = bpm1.read()
|
||||
print, "EBOX-POSV after rock: " + str(by)
|
||||
print "EBOX-POSV after rock: " + str(by)
|
||||
|
||||
# feedback
|
||||
while abs(by) >= ymax :
|
||||
by = bpm1.read()
|
||||
by = bpm1.read()
|
||||
print "current EBOX-POSV: " + str(by)
|
||||
cur = caget('X06DA-ES-BPM1:SUM','d')
|
||||
if cur > tc:
|
||||
@@ -74,4 +74,4 @@ while abs(by) >= ymax :
|
||||
time.sleep(0.25)
|
||||
|
||||
|
||||
print "TRY3 net movement: " + str(y3i-try3.read()) //print how much TRY3 moved
|
||||
print "TRY3 net movement: " + str(y3i-try3.read()) #print how much TRY3 moved
|
||||
|
||||
Reference in New Issue
Block a user