20140508-181001
This commit is contained in:
parent
f853278bd7
commit
f28c2349e4
Binary file not shown.
@ -19,8 +19,8 @@
|
||||
<setting name="Com_Port" serializeAs="String">
|
||||
<value>COM7</value>
|
||||
</setting>
|
||||
<setting name="Setting" serializeAs="String">
|
||||
<value />
|
||||
<setting name="Chart_Items" serializeAs="String">
|
||||
<value>1000</value>
|
||||
</setting>
|
||||
</Laminator_GUI.Properties.Settings>
|
||||
</userSettings>
|
||||
|
@ -38,7 +38,7 @@ namespace Laminator_GUI
|
||||
InitializeComponent();
|
||||
this.createButtons();
|
||||
this.settings = new Settings();
|
||||
this.chart.ChartAreas[0].AxisX.Maximum = 500;
|
||||
this.chart.ChartAreas[0].AxisX.Maximum = this.settings.Chart_Items;
|
||||
this.serialPort = new SerialPort(this.settings.Com_Port, 9600, Parity.None, 8, StopBits.One);
|
||||
this.serialPort.Open();
|
||||
this.serialPort.Write("m" + this.settings.Default_Motor.PadLeft(2, '0') + "\n");
|
||||
@ -93,7 +93,7 @@ namespace Laminator_GUI
|
||||
this.hist.Enqueue(temp);
|
||||
this.hmotor.Enqueue(this.motorBool);
|
||||
this.hheat.Enqueue(this.heaterBool);
|
||||
if (this.hist.Count > 500)
|
||||
if (this.hist.Count > this.settings.Chart_Items)
|
||||
{
|
||||
this.hist.Dequeue();
|
||||
this.hmotor.Dequeue();
|
||||
|
@ -61,13 +61,13 @@ namespace Laminator_GUI.Properties {
|
||||
|
||||
[global::System.Configuration.UserScopedSettingAttribute()]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Configuration.DefaultSettingValueAttribute("")]
|
||||
public string Setting {
|
||||
[global::System.Configuration.DefaultSettingValueAttribute("1000")]
|
||||
public int Chart_Items {
|
||||
get {
|
||||
return ((string)(this["Setting"]));
|
||||
return ((int)(this["Chart_Items"]));
|
||||
}
|
||||
set {
|
||||
this["Setting"] = value;
|
||||
this["Chart_Items"] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2,14 +2,17 @@
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="Laminator_GUI.Properties" GeneratedClassName="Settings">
|
||||
<Profiles />
|
||||
<Settings>
|
||||
<Setting Name="Com_Port" Type="System.String" Scope="User">
|
||||
<Value Profile="(Default)">COM8</Value>
|
||||
</Setting>
|
||||
<Setting Name="Default_Temp" Type="System.String" Scope="User">
|
||||
<Value Profile="(Default)">32</Value>
|
||||
</Setting>
|
||||
<Setting Name="Default_Motor" Type="System.String" Scope="User">
|
||||
<Value Profile="(Default)">10</Value>
|
||||
</Setting>
|
||||
<Setting Name="Com_Port" Type="System.String" Scope="User">
|
||||
<Value Profile="(Default)">COM7</Value>
|
||||
</Setting>
|
||||
<Setting Name="Chart_Items" Type="System.Int32" Scope="User">
|
||||
<Value Profile="(Default)">1000</Value>
|
||||
</Setting>
|
||||
</Settings>
|
||||
</SettingsFile>
|
Binary file not shown.
@ -19,8 +19,8 @@
|
||||
<setting name="Com_Port" serializeAs="String">
|
||||
<value>COM7</value>
|
||||
</setting>
|
||||
<setting name="Setting" serializeAs="String">
|
||||
<value />
|
||||
<setting name="Chart_Items" serializeAs="String">
|
||||
<value>1000</value>
|
||||
</setting>
|
||||
</Laminator_GUI.Properties.Settings>
|
||||
</userSettings>
|
||||
|
Binary file not shown.
@ -19,8 +19,8 @@
|
||||
<setting name="Com_Port" serializeAs="String">
|
||||
<value>COM7</value>
|
||||
</setting>
|
||||
<setting name="Setting" serializeAs="String">
|
||||
<value />
|
||||
<setting name="Chart_Items" serializeAs="String">
|
||||
<value>1000</value>
|
||||
</setting>
|
||||
</Laminator_GUI.Properties.Settings>
|
||||
</userSettings>
|
||||
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user