Script execution

This commit is contained in:
sfop
2017-01-20 10:28:39 +01:00
parent 6cfef52de9
commit dad78512e9

View File

@@ -2,9 +2,12 @@ import ch.psi.pshell.epics.ControlledVariable as ControlledVariable
if get_exec_pars().source == CommandSource.ui:
station = "SINSB04"
bpm_ch = "SINBC01-DBPM140"
else:
station = args[0]
bpm_ch = args[1]
print(station)
print(bpm_ch)
start = caget(station + "-RSYS:SET-SCAN-START")
stop = caget(station + "-RSYS:SET-SCAN-STOP")
step = caget(station + "-RSYS:SET-SCAN-STEP")
@@ -13,6 +16,8 @@ nb = caget(station + "-RSYS:SET-NUM-AVERAGE")
bpm_ch = caget(station + "-RSYS:DBPM")
disp = caget(bpm_ch + ":DISPERSION")
energy0 = caget(bpm_ch + ":ENERGY")
print(disp)
print(energy0)
phase = ControlledVariable("Phase", station + "-RSYS:SET-VSUM-PHASE-SIM", station + "-RSYS:GET-VSUM-PHASE-SIM")
phase.config.minValue =-45.0