Closedown

This commit is contained in:
sfop
2017-07-04 12:10:13 +02:00
parent bf21bea963
commit 59218f3ccf
2 changed files with 10 additions and 6 deletions

View File

@@ -32,6 +32,8 @@ public class SchottkyScan extends Panel {
initComponents();
setPersistedComponents(SwingUtils.getComponentsByType(panelPars, JSpinner.class));
buttonSet.setEnabled(false);
plot.setStyle(LinePlotJFree.Style.ErrorY);
}
//Overridable callbacks

View File

@@ -1,7 +1,7 @@
import ch.psi.pshell.epics.Positioner as Positioner
import ch.psi.pshell.epics.ChannelDouble as ChannelDouble
dry_run = False
dry_run = True
if get_exec_pars().source == CommandSource.ui:
start = -30.0
@@ -19,10 +19,12 @@ else:
plt = args[5]
if plt is not None:
plt.setStyle(plt.Style.ErrorY)
plt.clear()
#plt.setStyle(plt.Style.ErrorY) #Must be set by Plugin otherwise first scan is not shown
plt.addSeries(LinePlotErrorSeries("Values"))
plt.getAxis(plt.AxisId.X).setLabel("Gun Beam Phase (deg)")
plt.getAxis(plt.AxisId.Y).setLabel("SINEG01-DICT215:B1_CHARGE")
plt.getAxis(plt.AxisId.Y).setLabel("SINEG01-DICT215:B1_CHARGE")
if dry_run:
bph = Positioner("Beam phase", "SINEG01-RSYS:SET-BEAM-PHASE-SIM", "SINEG01-RSYS:SET-BEAM-PHASE-SIM")
@@ -52,9 +54,9 @@ rph.monitored=True
rph0 = rph.read()
#Record callback: uptate of output plot
def after_sample(record, scan):
if plt is not None:
plt.getSeries(0).appendData(record.positions[0], record.values[1].mean, record.values[1].stdev)
def after_sample(record, scan):
if plt is not None:
plt.getSeries(0).appendData(record.positions[0], record.values[1].mean, record.values[1].stdev)
try:
rph_averager = create_averager(rph, nb, 0.1) # Set polling time to -1 for BS data to get all messages