Startup
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
startphi=-60
|
||||
endphi=120 # for DACs the middle is 57
|
||||
time_step=4
|
||||
time_step=1
|
||||
step=0.5 # in degrees
|
||||
#fname='testing'
|
||||
fname='MRc_01' # remember the run number
|
||||
|
||||
|
||||
|
||||
startphi, endphi, time_step, step = float(startphi), float(endphi), float(time_step), float(step)
|
||||
#TODO: Should not move to startphi?
|
||||
scr.setSpeed (5.0)
|
||||
scr.move(startphi)
|
||||
|
||||
filt=caget("X04SA-ES2-FI:TRANSM",'d') *1000000000 #TODO:Check if wtiting 1000000000.00000000000000 or 1.0E9 is equivalent
|
||||
caput("X04SA-ES2-PIL:cam1:FilterTransm",filt)
|
||||
@@ -14,7 +18,7 @@ caput("X04SA-ES2-PIL:cam1:FilterTransm",filt)
|
||||
exp_time = time_step -0.003 # calculates Exposure time
|
||||
phitot = endphi - startphi # calculates total omega span
|
||||
images = int(phitot/step) # calculates number of images #TODO: floor or ceil?
|
||||
velo = float(step)/time_step
|
||||
velo = step/time_step
|
||||
if velo > 5.0:
|
||||
raise Exception("Too fast velocity calculated for the motor, please change")
|
||||
|
||||
@@ -49,8 +53,9 @@ sleep (1.0)
|
||||
scr.moveAsync(endphi)
|
||||
det.start()
|
||||
|
||||
#scr.waitReady(tottime * 1000) #TODO: Should sleep or wait end of move?
|
||||
sleep(tottime)
|
||||
#scr.waitInPosition(endphi, int(tottime * 1000)) #TODO: Should sleep or wait end of move? or waiting Pilatus to finish: det.waitReady(int(tottime * 1000))
|
||||
scr.waitReady(int(tottime * 1000))
|
||||
#sleep(tottime)
|
||||
|
||||
|
||||
### BACKWARD ###
|
||||
|
||||
Reference in New Issue
Block a user