Closedown
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
#BucketSize=ch.psi.pshell.epics.ChannelDouble||Read||true
|
||||
FillingPattern=ch.psi.pshell.epics.ChannelDoubleArray|ACORF-FILL:UnsortComp|Read||true
|
||||
MCPArray1=ch.psi.pshell.epics.ChannelIntegerArray|X11MA-ES4:PHC-CTRWF1|Read||true
|
||||
SamplingTime=ch.psi.pshell.epics.ChannelDouble|X11MA-ES4:SAMPLE-TIME|Read||true
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
DelayScan.java=enabled
|
||||
EnergyScan.java=enabled
|
||||
Test.java=disabled
|
||||
|
||||
544
plugins/DelayScan.form
Normal file
544
plugins/DelayScan.form
Normal file
@@ -0,0 +1,544 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
|
||||
<Form version="1.5" maxVersion="1.9" type="org.netbeans.modules.form.forminfo.JPanelFormInfo">
|
||||
<NonVisualComponents>
|
||||
<Component class="javax.swing.ButtonGroup" name="buttonGroupPlot">
|
||||
</Component>
|
||||
<Component class="javax.swing.ButtonGroup" name="buttonGroup1">
|
||||
<AuxValues>
|
||||
<AuxValue name="JavaCodeGenerator_SerializeTo" type="java.lang.String" value="EnergyScan_buttonGroup1"/>
|
||||
</AuxValues>
|
||||
</Component>
|
||||
</NonVisualComponents>
|
||||
<AuxValues>
|
||||
<AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="0"/>
|
||||
<AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="false"/>
|
||||
<AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
|
||||
<AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
|
||||
<AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
|
||||
<AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
|
||||
<AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
|
||||
<AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
|
||||
<AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
|
||||
</AuxValues>
|
||||
|
||||
<Layout>
|
||||
<DimensionLayout dim="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="jPanel3" max="32767" attributes="0"/>
|
||||
<Component id="panelParameters" max="32767" attributes="0"/>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
<DimensionLayout dim="1">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Component id="panelParameters" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace pref="111" max="32767" attributes="0"/>
|
||||
<Component id="jPanel3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
</Layout>
|
||||
<SubComponents>
|
||||
<Container class="javax.swing.JPanel" name="panelParameters">
|
||||
<Properties>
|
||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
||||
<Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
|
||||
<TitledBorder title="Parameters"/>
|
||||
</Border>
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
<Layout>
|
||||
<DimensionLayout dim="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<Component id="jLabel16" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="jTextField1" min="-2" pref="161" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Group type="102" attributes="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<Component id="jLabel17" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace min="-2" pref="6" max="-2" attributes="0"/>
|
||||
<Component id="spinnerOffset1" min="-2" pref="76" max="-2" attributes="0"/>
|
||||
<EmptySpace min="-2" pref="22" max="-2" attributes="0"/>
|
||||
<Component id="jLabel13" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="spinnerOffset2" linkSize="5" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="jLabel1" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel3" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel8" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="spinnerSize" min="-2" pref="80" max="-2" attributes="0"/>
|
||||
<Component id="spinnerEnd" alignment="0" min="-2" pref="80" max="-2" attributes="0"/>
|
||||
<Component id="spinnerStart" alignment="1" min="-2" pref="80" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
<Component id="jLabel11" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<EmptySpace pref="6" max="-2" attributes="0"/>
|
||||
<EmptySpace min="56" pref="56" max="-2" attributes="0"/>
|
||||
<Component id="comboRunType" min="-2" pref="105" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="1" attributes="0">
|
||||
<Component id="jLabel4" linkSize="4" alignment="1" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel2" linkSize="4" alignment="1" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel18" alignment="1" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel5" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||
<Component id="spinnerRounds" linkSize="5" alignment="1" max="32767" attributes="0"/>
|
||||
<Component id="spinnerAcqTime" alignment="1" max="32767" attributes="0"/>
|
||||
<Component id="spinnerFineDelay" alignment="1" max="32767" attributes="0"/>
|
||||
<Component id="spinnerDelay" alignment="1" max="32767" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</Group>
|
||||
<EmptySpace max="32767" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
<DimensionLayout dim="1">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerStart" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel2" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerDelay" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel3" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerEnd" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel4" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerFineDelay" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel8" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerSize" alignment="3" max="32767" attributes="0"/>
|
||||
<Component id="jLabel18" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerAcqTime" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" pref="30" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel16" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jTextField1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel17" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerOffset1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel13" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerOffset2" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" pref="15" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel11" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="comboRunType" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="spinnerRounds" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel5" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
</Layout>
|
||||
<SubComponents>
|
||||
<Component class="javax.swing.JLabel" name="jLabel1">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Delay start (ns):"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerStart">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="680.0" maximum="9999.0" minimum="0.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel2">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="LPP delay at t=0"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerDelay">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="750.0" maximum="9999.0" minimum="0.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel3">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Delay end (ns):"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerEnd">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="2.0" maximum="60.0" minimum="0.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel4">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="LPP fine delay at t=0"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerFineDelay">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="10.0" maximum="600.0" minimum="0.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel8">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Step size (ns):"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerSize">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0.0" maximum="20.0" minimum="-20.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel13">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Offset2:"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerOffset2">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0.0" maximum="20.0" minimum="-20.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JTextField" name="jTextField1">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="800, 780"/>
|
||||
</Properties>
|
||||
<Events>
|
||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jTextField1ActionPerformed"/>
|
||||
</Events>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel16">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Energies:"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel17">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Offset1:"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel11">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Run Type:"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JComboBox" name="comboRunType">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.ComboBoxModel" editor="org.netbeans.modules.form.editors2.ComboBoxModelEditor">
|
||||
<StringArray count="6">
|
||||
<StringItem index="0" value="+/-"/>
|
||||
<StringItem index="1" value="+"/>
|
||||
<StringItem index="2" value="-"/>
|
||||
<StringItem index="3" value="LH/LV"/>
|
||||
<StringItem index="4" value="LH"/>
|
||||
<StringItem index="5" value="LV"/>
|
||||
</StringArray>
|
||||
</Property>
|
||||
</Properties>
|
||||
<AuxValues>
|
||||
<AuxValue name="JavaCodeGenerator_SerializeTo" type="java.lang.String" value="EnergyScan_comboRunType"/>
|
||||
</AuxValues>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerRounds">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="1" maximum="10" minimum="1" numberType="java.lang.Integer" stepSize="1" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel5">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Rounds:"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerOffset1">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0.0" maximum="20.0" minimum="-20.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="spinnerAcqTime">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0.0" maximum="20.0" minimum="-20.0" numberType="java.lang.Double" stepSize="1.0" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel18">
|
||||
<Properties>
|
||||
<Property name="horizontalAlignment" type="int" value="11"/>
|
||||
<Property name="text" type="java.lang.String" value="Acquisition time (s):"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
</SubComponents>
|
||||
</Container>
|
||||
<Container class="javax.swing.JPanel" name="jPanel3">
|
||||
<Properties>
|
||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
||||
<Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
|
||||
<TitledBorder title="Scan Control"/>
|
||||
</Border>
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
<Layout>
|
||||
<DimensionLayout dim="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="103" alignment="0" groupAlignment="0" max="-2" attributes="0">
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="jRadioButton1" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jRadioButton2" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" pref="80" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="jCheckBox3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox2" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Component id="jLabel6" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace max="32767" attributes="0"/>
|
||||
<Component id="jLabel7" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Component id="jRadioButton3" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace min="-2" pref="48" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox4" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
<EmptySpace min="-2" pref="31" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Component id="jLabel9" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel14" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||
<Component id="jSpinner1" max="32767" attributes="0"/>
|
||||
<Component id="jSpinner2" max="32767" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="2" attributes="0">
|
||||
<Component id="buttonExecute" alignment="2" min="-2" pref="100" max="-2" attributes="0"/>
|
||||
<Component id="buttonAbort" alignment="2" min="-2" pref="100" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox1" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Component id="jLabel15" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
<DimensionLayout dim="1">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" alignment="1" attributes="0">
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jLabel6" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel7" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel15" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" attributes="0">
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="buttonExecute" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jRadioButton1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox2" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" pref="16" max="-2" attributes="0"/>
|
||||
<Component id="buttonAbort" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Group type="102" attributes="0">
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jSpinner1" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel9" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jSpinner2" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jLabel14" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</Group>
|
||||
</Group>
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<EmptySpace min="-2" pref="60" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jRadioButton2" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox3" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="3" attributes="0">
|
||||
<Component id="jRadioButton3" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
<Component id="jCheckBox4" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</Group>
|
||||
<EmptySpace pref="13" max="32767" attributes="0"/>
|
||||
</Group>
|
||||
</Group>
|
||||
</DimensionLayout>
|
||||
</Layout>
|
||||
<SubComponents>
|
||||
<Component class="javax.swing.JButton" name="buttonExecute">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Start"/>
|
||||
</Properties>
|
||||
<Events>
|
||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonExecuteActionPerformed"/>
|
||||
</Events>
|
||||
</Component>
|
||||
<Component class="javax.swing.JButton" name="buttonAbort">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Abort"/>
|
||||
<Property name="enabled" type="boolean" value="false"/>
|
||||
</Properties>
|
||||
<Events>
|
||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="buttonAbortActionPerformed"/>
|
||||
</Events>
|
||||
</Component>
|
||||
<Component class="javax.swing.JCheckBox" name="jCheckBox1">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="set offsets"/>
|
||||
</Properties>
|
||||
<Events>
|
||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jCheckBox1ActionPerformed"/>
|
||||
</Events>
|
||||
</Component>
|
||||
<Component class="javax.swing.JRadioButton" name="jRadioButton2">
|
||||
<Properties>
|
||||
<Property name="buttonGroup" type="javax.swing.ButtonGroup" editor="org.netbeans.modules.form.RADComponent$ButtonGroupPropertyEditor">
|
||||
<ComponentRef name="buttonGroup1"/>
|
||||
</Property>
|
||||
<Property name="text" type="java.lang.String" value="ID2"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JRadioButton" name="jRadioButton1">
|
||||
<Properties>
|
||||
<Property name="buttonGroup" type="javax.swing.ButtonGroup" editor="org.netbeans.modules.form.RADComponent$ButtonGroupPropertyEditor">
|
||||
<ComponentRef name="buttonGroup1"/>
|
||||
</Property>
|
||||
<Property name="text" type="java.lang.String" value="ID1"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JRadioButton" name="jRadioButton3">
|
||||
<Properties>
|
||||
<Property name="buttonGroup" type="javax.swing.ButtonGroup" editor="org.netbeans.modules.form.RADComponent$ButtonGroupPropertyEditor">
|
||||
<ComponentRef name="buttonGroup1"/>
|
||||
</Property>
|
||||
<Property name="selected" type="boolean" value="true"/>
|
||||
<Property name="text" type="java.lang.String" value="ID1+ID2"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JCheckBox" name="jCheckBox2">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="MCP signal"/>
|
||||
</Properties>
|
||||
<Events>
|
||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jCheckBox2ActionPerformed"/>
|
||||
</Events>
|
||||
</Component>
|
||||
<Component class="javax.swing.JCheckBox" name="jCheckBox3">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="MCP I_0"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel6">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="ID mode"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel7">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Save MCP data"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="jSpinner1">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0" maximum="1000" minimum="0" numberType="java.lang.Integer" stepSize="1" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JSpinner" name="jSpinner2">
|
||||
<Properties>
|
||||
<Property name="model" type="javax.swing.SpinnerModel" editor="org.netbeans.modules.form.editors2.SpinnerModelEditor">
|
||||
<SpinnerModel initial="0" maximum="1000" minimum="0" numberType="java.lang.Integer" stepSize="1" type="number"/>
|
||||
</Property>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel9">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="start"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel14">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="end"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JLabel" name="jLabel15">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Camshaft position"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
<Component class="javax.swing.JCheckBox" name="jCheckBox4">
|
||||
<Properties>
|
||||
<Property name="text" type="java.lang.String" value="Save array data"/>
|
||||
</Properties>
|
||||
</Component>
|
||||
</SubComponents>
|
||||
</Container>
|
||||
</SubComponents>
|
||||
</Form>
|
||||
550
plugins/DelayScan.java
Normal file
550
plugins/DelayScan.java
Normal file
@@ -0,0 +1,550 @@
|
||||
/*
|
||||
* Copyright (c) 2014 Paul Scherrer Institute. All rights reserved.
|
||||
*/
|
||||
|
||||
import java.awt.Component;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
import java.util.HashMap;
|
||||
import java.util.logging.Level;
|
||||
import javax.swing.JLabel;
|
||||
import ch.psi.utils.State;
|
||||
import ch.psi.utils.swing.Editor.EditorDialog;
|
||||
import ch.psi.pshell.plot.LinePlotBase;
|
||||
import ch.psi.pshell.plot.LinePlotSeries;
|
||||
import ch.psi.pshell.plot.Plot;
|
||||
import ch.psi.pshell.ui.Panel;
|
||||
import ch.psi.utils.swing.DsvEditor;
|
||||
import java.awt.event.WindowAdapter;
|
||||
import java.awt.event.WindowEvent;
|
||||
import java.io.File;
|
||||
import java.nio.file.Files;
|
||||
import javax.swing.DefaultComboBoxModel;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public class DelayScan extends Panel {
|
||||
|
||||
public DelayScan() {
|
||||
initComponents();
|
||||
}
|
||||
|
||||
double energyCache = 0;
|
||||
boolean restart;
|
||||
|
||||
@Override
|
||||
public void onStateChange(State state, State former) {
|
||||
setEnabled(state == State.Ready);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onExecutedFile(String fileName, Object result) {
|
||||
}
|
||||
|
||||
boolean otf;
|
||||
|
||||
void stopScan() {
|
||||
try {
|
||||
getLogger().info("Stopping scan");
|
||||
evalAsync("caput('START', 'STOP')");
|
||||
} catch (Exception ex) {
|
||||
getLogger().log(Level.WARNING, null, ex);
|
||||
}
|
||||
}
|
||||
|
||||
Path getConfigFile() {
|
||||
return Paths.get(getController().getSetup().getConfigPath(), "energy_scan.properties");
|
||||
}
|
||||
|
||||
LinePlotBase scanPlot;
|
||||
LinePlotSeries scanSeries;
|
||||
|
||||
@Override
|
||||
public void setEnabled(boolean value) {
|
||||
super.setEnabled(value);
|
||||
buttonExecute.setEnabled(value);
|
||||
//buttonPlot.setEnabled(value);
|
||||
checkParameterControls();
|
||||
}
|
||||
|
||||
void checkParameterControls() {
|
||||
boolean enabled;
|
||||
enabled = isEnabled();
|
||||
for (Component c : panelParameters.getComponents()) {
|
||||
if (!(c instanceof JLabel)) {
|
||||
c.setEnabled(enabled);
|
||||
}
|
||||
}
|
||||
|
||||
//spinnerAlpha.setEnabled(enabled && comboMode.getSelectedItem().equals("LINEAR"));
|
||||
}
|
||||
|
||||
double last = 0;
|
||||
|
||||
void run() throws Exception {
|
||||
HashMap args = new HashMap();
|
||||
args.put("START",(Double) spinnerStart.getValue());
|
||||
args.put("DELAY", (Double) spinnerDelay.getValue());
|
||||
args.put("END", (Double) spinnerEnd.getValue());
|
||||
args.put("FINEDELAY", (Double) spinnerFineDelay.getValue());
|
||||
args.put("SIZE", (Double) spinnerSize.getValue());
|
||||
args.put("OFFSET1", (Double) spinnerOffset1.getValue());
|
||||
args.put("OFFSET2", (Double) spinnerOffset2.getValue());
|
||||
args.put("ACQTIME", (Double) spinnerAcqTime.getValue());
|
||||
args.put("ENERGIES", jTextField1.getText());
|
||||
args.put("RUNTYPE", comboRunType.getSelectedItem().toString());
|
||||
args.put("ROUNDS", (Integer) spinnerRounds.getValue());
|
||||
args.put("SET_OFFSETS", jCheckBox1.isSelected() ? 1 : 2);
|
||||
args.put("ID1", jRadioButton1.isSelected() ? 1 : 2);
|
||||
args.put("ID2", jRadioButton2.isSelected() ? 1 : 2);
|
||||
args.put("MCP_1", jCheckBox2.isSelected() ? 1 : 2);
|
||||
args.put("MCP_2", jCheckBox3.isSelected() ? 1 : 2);
|
||||
args.put("Cam_start", jSpinner1.getValue());
|
||||
args.put("Cam_end", jSpinner2.getValue());
|
||||
args.put("Save_array_data", jCheckBox4.isSelected() ? 1 : 2);
|
||||
|
||||
buttonAbort.setEnabled(true);
|
||||
|
||||
runAsync("DelayScan", args).handle((ok, ex) -> {
|
||||
try {
|
||||
buttonAbort.setEnabled(false);
|
||||
if (ex != null) {
|
||||
throw ex;
|
||||
} else {
|
||||
}
|
||||
} catch (Throwable t) {
|
||||
getLogger().log(Level.WARNING, null, ex);
|
||||
//showException((Exception)ex);
|
||||
}
|
||||
return ok;
|
||||
});
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
|
||||
private void initComponents() {
|
||||
|
||||
buttonGroupPlot = new javax.swing.ButtonGroup();
|
||||
buttonGroup1 = new javax.swing.ButtonGroup();
|
||||
panelParameters = new javax.swing.JPanel();
|
||||
jLabel1 = new javax.swing.JLabel();
|
||||
spinnerStart = new javax.swing.JSpinner();
|
||||
jLabel2 = new javax.swing.JLabel();
|
||||
spinnerDelay = new javax.swing.JSpinner();
|
||||
jLabel3 = new javax.swing.JLabel();
|
||||
spinnerEnd = new javax.swing.JSpinner();
|
||||
jLabel4 = new javax.swing.JLabel();
|
||||
spinnerFineDelay = new javax.swing.JSpinner();
|
||||
jLabel8 = new javax.swing.JLabel();
|
||||
spinnerSize = new javax.swing.JSpinner();
|
||||
jLabel13 = new javax.swing.JLabel();
|
||||
spinnerOffset2 = new javax.swing.JSpinner();
|
||||
jTextField1 = new javax.swing.JTextField();
|
||||
jLabel16 = new javax.swing.JLabel();
|
||||
jLabel17 = new javax.swing.JLabel();
|
||||
jLabel11 = new javax.swing.JLabel();
|
||||
comboRunType = new javax.swing.JComboBox();
|
||||
spinnerRounds = new javax.swing.JSpinner();
|
||||
jLabel5 = new javax.swing.JLabel();
|
||||
spinnerOffset1 = new javax.swing.JSpinner();
|
||||
spinnerAcqTime = new javax.swing.JSpinner();
|
||||
jLabel18 = new javax.swing.JLabel();
|
||||
jPanel3 = new javax.swing.JPanel();
|
||||
buttonExecute = new javax.swing.JButton();
|
||||
buttonAbort = new javax.swing.JButton();
|
||||
jCheckBox1 = new javax.swing.JCheckBox();
|
||||
jRadioButton2 = new javax.swing.JRadioButton();
|
||||
jRadioButton1 = new javax.swing.JRadioButton();
|
||||
jRadioButton3 = new javax.swing.JRadioButton();
|
||||
jCheckBox2 = new javax.swing.JCheckBox();
|
||||
jCheckBox3 = new javax.swing.JCheckBox();
|
||||
jLabel6 = new javax.swing.JLabel();
|
||||
jLabel7 = new javax.swing.JLabel();
|
||||
jSpinner1 = new javax.swing.JSpinner();
|
||||
jSpinner2 = new javax.swing.JSpinner();
|
||||
jLabel9 = new javax.swing.JLabel();
|
||||
jLabel14 = new javax.swing.JLabel();
|
||||
jLabel15 = new javax.swing.JLabel();
|
||||
jCheckBox4 = new javax.swing.JCheckBox();
|
||||
|
||||
panelParameters.setBorder(javax.swing.BorderFactory.createTitledBorder("Parameters"));
|
||||
|
||||
jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel1.setText("Delay start (ns):");
|
||||
|
||||
spinnerStart.setModel(new javax.swing.SpinnerNumberModel(680.0d, 0.0d, 9999.0d, 1.0d));
|
||||
|
||||
jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel2.setText("LPP delay at t=0");
|
||||
|
||||
spinnerDelay.setModel(new javax.swing.SpinnerNumberModel(750.0d, 0.0d, 9999.0d, 1.0d));
|
||||
|
||||
jLabel3.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel3.setText("Delay end (ns):");
|
||||
|
||||
spinnerEnd.setModel(new javax.swing.SpinnerNumberModel(2.0d, 0.0d, 60.0d, 1.0d));
|
||||
|
||||
jLabel4.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel4.setText("LPP fine delay at t=0");
|
||||
|
||||
spinnerFineDelay.setModel(new javax.swing.SpinnerNumberModel(10.0d, 0.0d, 600.0d, 1.0d));
|
||||
|
||||
jLabel8.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel8.setText("Step size (ns):");
|
||||
|
||||
spinnerSize.setModel(new javax.swing.SpinnerNumberModel(0.0d, -20.0d, 20.0d, 1.0d));
|
||||
|
||||
jLabel13.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel13.setText("Offset2:");
|
||||
|
||||
spinnerOffset2.setModel(new javax.swing.SpinnerNumberModel(0.0d, -20.0d, 20.0d, 1.0d));
|
||||
|
||||
jTextField1.setText("800, 780");
|
||||
jTextField1.addActionListener(new java.awt.event.ActionListener() {
|
||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||
jTextField1ActionPerformed(evt);
|
||||
}
|
||||
});
|
||||
|
||||
jLabel16.setText("Energies:");
|
||||
|
||||
jLabel17.setText("Offset1:");
|
||||
|
||||
jLabel11.setText("Run Type:");
|
||||
|
||||
comboRunType.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "+/-", "+", "-", "LH/LV", "LH", "LV" }));
|
||||
|
||||
spinnerRounds.setModel(new javax.swing.SpinnerNumberModel(1, 1, 10, 1));
|
||||
|
||||
jLabel5.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel5.setText("Rounds:");
|
||||
|
||||
spinnerOffset1.setModel(new javax.swing.SpinnerNumberModel(0.0d, -20.0d, 20.0d, 1.0d));
|
||||
|
||||
spinnerAcqTime.setModel(new javax.swing.SpinnerNumberModel(0.0d, -20.0d, 20.0d, 1.0d));
|
||||
|
||||
jLabel18.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
|
||||
jLabel18.setText("Acquisition time (s):");
|
||||
|
||||
javax.swing.GroupLayout panelParametersLayout = new javax.swing.GroupLayout(panelParameters);
|
||||
panelParameters.setLayout(panelParametersLayout);
|
||||
panelParametersLayout.setHorizontalGroup(
|
||||
panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addContainerGap()
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addComponent(jLabel16)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 161, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addComponent(jLabel17)
|
||||
.addGap(6, 6, 6)
|
||||
.addComponent(spinnerOffset1, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addGap(22, 22, 22)
|
||||
.addComponent(jLabel13)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addComponent(spinnerOffset2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(jLabel1)
|
||||
.addComponent(jLabel3)
|
||||
.addComponent(jLabel8))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(spinnerSize, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(spinnerEnd, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(spinnerStart, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
||||
.addComponent(jLabel11)
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 6, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addGap(56, 56, 56)
|
||||
.addComponent(comboRunType, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
|
||||
.addComponent(jLabel4)
|
||||
.addComponent(jLabel2)
|
||||
.addComponent(jLabel18)
|
||||
.addComponent(jLabel5))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||
.addComponent(spinnerRounds, javax.swing.GroupLayout.Alignment.TRAILING)
|
||||
.addComponent(spinnerAcqTime, javax.swing.GroupLayout.Alignment.TRAILING)
|
||||
.addComponent(spinnerFineDelay, javax.swing.GroupLayout.Alignment.TRAILING)
|
||||
.addComponent(spinnerDelay, javax.swing.GroupLayout.Alignment.TRAILING))))
|
||||
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
|
||||
);
|
||||
|
||||
panelParametersLayout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {jLabel2, jLabel4});
|
||||
|
||||
panelParametersLayout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {spinnerOffset2, spinnerRounds});
|
||||
|
||||
panelParametersLayout.setVerticalGroup(
|
||||
panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(panelParametersLayout.createSequentialGroup()
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel1)
|
||||
.addComponent(spinnerStart, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel2)
|
||||
.addComponent(spinnerDelay, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel3)
|
||||
.addComponent(spinnerEnd, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel4)
|
||||
.addComponent(spinnerFineDelay, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel8)
|
||||
.addComponent(spinnerSize)
|
||||
.addComponent(jLabel18)
|
||||
.addComponent(spinnerAcqTime, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGap(30, 30, 30)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel16)
|
||||
.addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGap(18, 18, 18)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel17)
|
||||
.addComponent(spinnerOffset1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel13)
|
||||
.addComponent(spinnerOffset2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGap(15, 15, 15)
|
||||
.addGroup(panelParametersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel11)
|
||||
.addComponent(comboRunType, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(spinnerRounds, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel5)))
|
||||
);
|
||||
|
||||
jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder("Scan Control"));
|
||||
|
||||
buttonExecute.setText("Start");
|
||||
buttonExecute.addActionListener(new java.awt.event.ActionListener() {
|
||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||
buttonExecuteActionPerformed(evt);
|
||||
}
|
||||
});
|
||||
|
||||
buttonAbort.setText("Abort");
|
||||
buttonAbort.setEnabled(false);
|
||||
buttonAbort.addActionListener(new java.awt.event.ActionListener() {
|
||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||
buttonAbortActionPerformed(evt);
|
||||
}
|
||||
});
|
||||
|
||||
jCheckBox1.setText("set offsets");
|
||||
jCheckBox1.addActionListener(new java.awt.event.ActionListener() {
|
||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||
jCheckBox1ActionPerformed(evt);
|
||||
}
|
||||
});
|
||||
|
||||
buttonGroup1.add(jRadioButton2);
|
||||
jRadioButton2.setText("ID2");
|
||||
|
||||
buttonGroup1.add(jRadioButton1);
|
||||
jRadioButton1.setText("ID1");
|
||||
|
||||
buttonGroup1.add(jRadioButton3);
|
||||
jRadioButton3.setSelected(true);
|
||||
jRadioButton3.setText("ID1+ID2");
|
||||
|
||||
jCheckBox2.setText("MCP signal");
|
||||
jCheckBox2.addActionListener(new java.awt.event.ActionListener() {
|
||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||
jCheckBox2ActionPerformed(evt);
|
||||
}
|
||||
});
|
||||
|
||||
jCheckBox3.setText("MCP I_0");
|
||||
|
||||
jLabel6.setText("ID mode");
|
||||
|
||||
jLabel7.setText("Save MCP data");
|
||||
|
||||
jSpinner1.setModel(new javax.swing.SpinnerNumberModel(0, 0, 1000, 1));
|
||||
|
||||
jSpinner2.setModel(new javax.swing.SpinnerNumberModel(0, 0, 1000, 1));
|
||||
|
||||
jLabel9.setText("start");
|
||||
|
||||
jLabel14.setText("end");
|
||||
|
||||
jLabel15.setText("Camshaft position");
|
||||
|
||||
jCheckBox4.setText("Save array data");
|
||||
|
||||
javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
|
||||
jPanel3.setLayout(jPanel3Layout);
|
||||
jPanel3Layout.setHorizontalGroup(
|
||||
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addContainerGap()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(jRadioButton1)
|
||||
.addComponent(jRadioButton2))
|
||||
.addGap(80, 80, 80)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(jCheckBox3)
|
||||
.addComponent(jCheckBox2)))
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addComponent(jLabel6)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||
.addComponent(jLabel7)))
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addComponent(jRadioButton3)
|
||||
.addGap(48, 48, 48)
|
||||
.addComponent(jCheckBox4)))
|
||||
.addGap(31, 31, 31)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(jLabel9)
|
||||
.addComponent(jLabel14))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||
.addComponent(jSpinner1)
|
||||
.addComponent(jSpinner2))
|
||||
.addGap(18, 18, 18)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER)
|
||||
.addComponent(buttonExecute, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(buttonAbort, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
.addGap(18, 18, 18)
|
||||
.addComponent(jCheckBox1))
|
||||
.addComponent(jLabel15))
|
||||
.addContainerGap())
|
||||
);
|
||||
jPanel3Layout.setVerticalGroup(
|
||||
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel3Layout.createSequentialGroup()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addContainerGap()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jLabel6)
|
||||
.addComponent(jLabel7)
|
||||
.addComponent(jLabel15))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(buttonExecute)
|
||||
.addComponent(jCheckBox1)
|
||||
.addComponent(jRadioButton1)
|
||||
.addComponent(jCheckBox2))
|
||||
.addGap(16, 16, 16)
|
||||
.addComponent(buttonAbort))
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jSpinner1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel9))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jSpinner2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addComponent(jLabel14)))))
|
||||
.addGroup(jPanel3Layout.createSequentialGroup()
|
||||
.addGap(60, 60, 60)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jRadioButton2)
|
||||
.addComponent(jCheckBox3))
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||
.addComponent(jRadioButton3)
|
||||
.addComponent(jCheckBox4))))
|
||||
.addContainerGap(13, Short.MAX_VALUE))
|
||||
);
|
||||
|
||||
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
|
||||
this.setLayout(layout);
|
||||
layout.setHorizontalGroup(
|
||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addComponent(jPanel3, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||
.addComponent(panelParameters, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||
);
|
||||
layout.setVerticalGroup(
|
||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||
.addGroup(layout.createSequentialGroup()
|
||||
.addComponent(panelParameters, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 111, Short.MAX_VALUE)
|
||||
.addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||
);
|
||||
}// </editor-fold>//GEN-END:initComponents
|
||||
|
||||
private void buttonExecuteActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonExecuteActionPerformed
|
||||
try {
|
||||
run();
|
||||
} catch (Exception ex) {
|
||||
showException(ex);
|
||||
}
|
||||
}//GEN-LAST:event_buttonExecuteActionPerformed
|
||||
|
||||
private void buttonAbortActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonAbortActionPerformed
|
||||
abort();
|
||||
}//GEN-LAST:event_buttonAbortActionPerformed
|
||||
|
||||
private void jCheckBox1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jCheckBox1ActionPerformed
|
||||
// TODO add your handling code here:
|
||||
}//GEN-LAST:event_jCheckBox1ActionPerformed
|
||||
|
||||
private void jCheckBox2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jCheckBox2ActionPerformed
|
||||
// TODO add your handling code here:
|
||||
}//GEN-LAST:event_jCheckBox2ActionPerformed
|
||||
|
||||
private void jTextField1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jTextField1ActionPerformed
|
||||
// TODO add your handling code here:
|
||||
}//GEN-LAST:event_jTextField1ActionPerformed
|
||||
|
||||
EditorDialog dlgConfig;
|
||||
// Variables declaration - do not modify//GEN-BEGIN:variables
|
||||
private javax.swing.JButton buttonAbort;
|
||||
private javax.swing.JButton buttonExecute;
|
||||
private javax.swing.ButtonGroup buttonGroup1;
|
||||
private javax.swing.ButtonGroup buttonGroupPlot;
|
||||
private javax.swing.JComboBox comboRunType;
|
||||
private javax.swing.JCheckBox jCheckBox1;
|
||||
private javax.swing.JCheckBox jCheckBox2;
|
||||
private javax.swing.JCheckBox jCheckBox3;
|
||||
private javax.swing.JCheckBox jCheckBox4;
|
||||
private javax.swing.JLabel jLabel1;
|
||||
private javax.swing.JLabel jLabel11;
|
||||
private javax.swing.JLabel jLabel13;
|
||||
private javax.swing.JLabel jLabel14;
|
||||
private javax.swing.JLabel jLabel15;
|
||||
private javax.swing.JLabel jLabel16;
|
||||
private javax.swing.JLabel jLabel17;
|
||||
private javax.swing.JLabel jLabel18;
|
||||
private javax.swing.JLabel jLabel2;
|
||||
private javax.swing.JLabel jLabel3;
|
||||
private javax.swing.JLabel jLabel4;
|
||||
private javax.swing.JLabel jLabel5;
|
||||
private javax.swing.JLabel jLabel6;
|
||||
private javax.swing.JLabel jLabel7;
|
||||
private javax.swing.JLabel jLabel8;
|
||||
private javax.swing.JLabel jLabel9;
|
||||
private javax.swing.JPanel jPanel3;
|
||||
private javax.swing.JRadioButton jRadioButton1;
|
||||
private javax.swing.JRadioButton jRadioButton2;
|
||||
private javax.swing.JRadioButton jRadioButton3;
|
||||
private javax.swing.JSpinner jSpinner1;
|
||||
private javax.swing.JSpinner jSpinner2;
|
||||
private javax.swing.JTextField jTextField1;
|
||||
private javax.swing.JPanel panelParameters;
|
||||
private javax.swing.JSpinner spinnerAcqTime;
|
||||
private javax.swing.JSpinner spinnerDelay;
|
||||
private javax.swing.JSpinner spinnerEnd;
|
||||
private javax.swing.JSpinner spinnerFineDelay;
|
||||
private javax.swing.JSpinner spinnerOffset1;
|
||||
private javax.swing.JSpinner spinnerOffset2;
|
||||
private javax.swing.JSpinner spinnerRounds;
|
||||
private javax.swing.JSpinner spinnerSize;
|
||||
private javax.swing.JSpinner spinnerStart;
|
||||
// End of variables declaration//GEN-END:variables
|
||||
}
|
||||
@@ -28,8 +28,10 @@ VG12_SET = "X11MA-EPS-VG12:SET"
|
||||
VG12_GET = "X11MA-OP-VG12:OPEN"
|
||||
VG13_SET = "X11MA-EPS-VG13:SET"
|
||||
VG13_GET = "X11MA-OP-VG13:OPEN"
|
||||
|
||||
|
||||
LPP_DELAY = "X11MA-ES2-4CHT:SET2-DELAY"
|
||||
LPP_FINE_DELAY = "X11MA-ES2-4CHT:SET2-FINE"
|
||||
TIME_DELAY_SET = "X11MA-ES2:Theta-New.A"
|
||||
TIME_DELAY_START = "X11MA-ES2:SCAN-START"
|
||||
|
||||
|
||||
FST = time.strftime("%y%m%d")
|
||||
|
||||
Reference in New Issue
Block a user