Startup
This commit is contained in:
39
script/develop/ManipulatorFlyScan.py
Normal file
39
script/develop/ManipulatorFlyScan.py
Normal file
@@ -0,0 +1,39 @@
|
||||
"""
|
||||
2D Manipulator scan
|
||||
|
||||
set manipulator scan parameters below.
|
||||
set analyser parameters separately!
|
||||
move manipulator to center position before start!
|
||||
|
||||
"""
|
||||
|
||||
import math
|
||||
|
||||
# actual number of positions will be +1!
|
||||
RANGE = (111.0, 117.5)
|
||||
STEP = (0.5)
|
||||
ENDSCAN = False
|
||||
|
||||
MOTORS = (ManipulatorZ)
|
||||
SENSORS = (Counts, SampleCurrent, RefCurrent, MachineCurrent, EnergyDistribution, AngleDistribution)
|
||||
|
||||
adjust_sensors()
|
||||
set_adc_averaging()
|
||||
#set_preference(Preference.PLOT_TYPES, {'Scienta spectrum':1})
|
||||
|
||||
# time per scienta acquisition in seconds
|
||||
time1 = time.time()
|
||||
trig_scienta()
|
||||
time2 = time.time()
|
||||
scienta_time = (time2 - time1) + 1.0
|
||||
print "scienta_time: ", scienta_time
|
||||
|
||||
# time for one scan step in seconds
|
||||
NSTEPS = int((RANGE[1] - RANGE[0]) / STEP) + 1
|
||||
scan_time = scienta_time * NSTEPS
|
||||
print "scan_time: ", scan_time
|
||||
|
||||
#try:
|
||||
cscan(MOTORS, SENSORS, RANGE[0], RANGE[1], NSTEPS - 1, time=scan_time, before_read=before_readout, after_read = after_readout)
|
||||
#except ContinuousScanFollowingErrorException:
|
||||
print time.time(), " cscan: exception"
|
||||
Reference in New Issue
Block a user