From 3b48e213af8acbd3d4464a0c07d3be9f77dfb1e8 Mon Sep 17 00:00:00 2001 From: X11MA Date: Sun, 14 May 2017 14:02:06 +0200 Subject: [PATCH] Script execution --- script/Sridhar/field_sweepID2.py | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/script/Sridhar/field_sweepID2.py b/script/Sridhar/field_sweepID2.py index 0c73f5e..1c9f177 100644 --- a/script/Sridhar/field_sweepID2.py +++ b/script/Sridhar/field_sweepID2.py @@ -47,7 +47,8 @@ for r in RANGES: set_preference(Preference.ENABLED_PLOTS, ['field', 'tey_norm']) set_preference(Preference.PLOT_TYPES, {'tey_norm':1}) -scan = ManualScan(['field', 'Energy'], ['TEY', 'I0', 'polarization', 'temperature', 'RingCurrent', 'tey_norm'] , [min(setpoints), min(ENERGIES)], [max(setpoints), max(ENERGIES)], [len(setpoints)-1, len(ENERGIES)-1]) +#scan = ManualScan(['field', 'Energy'], ['TEY', 'I0', 'polarization', 'temperature', 'RingCurrent', 'tey_norm'] , [min(setpoints), min(ENERGIES)], [max(setpoints), max(ENERGIES)], [len(setpoints)-1, len(ENERGIES)-1]) +scan = ManualScan(['field', 'Energy'], ['I0', 'TEY', 'TFY', 'polarization', 'temperature', 'RingCurrent', 'tey_norm','tfy_norm'] , [min(setpoints), min(ENERGIES)], [max(setpoints), max(ENERGIES)], [len(setpoints)-1, len(ENERGIES)-1]) scan.start() # Main loop @@ -73,21 +74,22 @@ for B in setpoints: detector1 = keithley_1a.read() #Keithley1 detector2 = keithley_2a.read() #Keithley2 - #detector3 = keithley_3a.read() #Keithley3 - detector4 = caget(OTF_MODE1) #polarization in ID1 - #detector5 = caget("X11MA-ID1:ALPHA-READ") # polAngle in ID1 + detector3 = keithley_3a.read() #Keithley3 + detector4 = caget(OTF_MODE2) #polarization in ID2 + #detector5 = caget("X11MA-ID2:ALPHA-READ") # polAngle in ID2 detector6 = caget('X11MA-ES3-LSCI:TEMP_RBV') #temperature.get() detector7 = caget("ARIDI-PCT:CURRENT") #detector8 = signal_field_analog_x.read() # fieldAnalogX.get() - tey_norm = detector1/detector2 - #trans_norm = detector3/detector2 + tey_norm = detector2/detector1 + tfy_norm = detector3/detector1 #converting polarization strings to integer numbers: C+ -> 1 and C- -> 2 if detector4 == 'CIRC +': detector4 = 1 elif detector4 == 'CIRC -': detector4 = 2 else: detector4 = 0 - scan.append ([B, E], [readback1, readback2], [detector1, detector2, detector4, detector6, detector7, tey_norm]) + #scan.append ([B, E], [readback1, readback2], [detector1, detector2, detector4, detector6, detector7, tey_norm]) + scan.append ([B, E], [readback1, readback2], [detector1, detector2, detector3, detector4, detector6, detector7, tey_norm, tfy_norm]) scan.end() caput("X11MA-ES1-10ADC:AVG",1) \ No newline at end of file