diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index 857a0dc46..cbab15398 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -90,6 +90,12 @@ FormCommSetGPS.cs + + Form + + + FormSerialMonitor.cs + Form @@ -126,6 +132,24 @@ FormSerialPass.cs + + Form + + + FormEthernet.cs + + + Form + + + FormYes.cs + + + Form + + + FormYesNo.cs + FormLoop.cs @@ -163,14 +187,19 @@ FormCommPicker.cs + Designer FormCommSaver.cs + Designer FormCommSetGPS.cs Designer + + FormSerialMonitor.cs + FormGPSData.cs Designer @@ -199,6 +228,18 @@ FormSerialPass.cs + + FormEthernet.cs + + + FormYes.cs + + + FormYesNo.cs + + + FormTimedMessage.cs + FormUDP.cs @@ -280,6 +321,10 @@ + + + + diff --git a/SourceCode/AgIO/Source/App.config b/SourceCode/AgIO/Source/App.config index c31e3cb58..ac8b81985 100644 --- a/SourceCode/AgIO/Source/App.config +++ b/SourceCode/AgIO/Source/App.config @@ -152,7 +152,7 @@ True - False + True False @@ -181,6 +181,21 @@ 5 + + 127 + + + 255 + + + 255 + + + 255 + + + + diff --git a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs index 9b14e5ef5..89f2c3f76 100644 --- a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs @@ -5,15 +5,31 @@ namespace AgIO { - public partial class FormLoop { - public void TimedMessageBox(int timeout, string s1, string s2) + public void TimedMessageBox(int timeout, string title, string message) { - var form = new FormTimedMessage(timeout, s1, s2); + var form = new FormTimedMessage(timeout, title, message); form.Show(); } + public void YesMessageBox(string s1) + { + var form = new FormYes(s1); + form.ShowDialog(this); + } + + private void toolStripSerialMonitor_Click(object sender, EventArgs e) + { + ShowSerialMonitor(); + } + + public void ShowSerialMonitor() + { + var form = new FormSerialMonitor(this); + form.Show(this); + } + private void SettingsCommunicationGPS() { isGPSCommOpen = true; @@ -25,6 +41,14 @@ private void SettingsCommunicationGPS() isGPSCommOpen = false; } + private void SettingsEthernet() + { + using (FormEthernet form = new FormEthernet(this)) + { + form.ShowDialog(this); + } + } + private void SettingsNTRIP() { if (isRadio_RequiredOn) @@ -82,14 +106,9 @@ private void SettingsRadio() private void SettingsUDP() { - using (var form = new FormUDP(this)) + FormUDP formEth = new FormUDP(this); { - if (form.ShowDialog(this) == DialogResult.OK) - { - //Clicked Save - Application.Restart(); - Environment.Exit(0); - } + formEth.Show(this); } } @@ -152,16 +171,6 @@ private void btnStartStopNtrip_Click(object sender, EventArgs e) } } - private void loadToolStrip_Click(object sender, EventArgs e) - { - - } - - private void saveToolStrip_Click(object sender, EventArgs e) - { - - } - public void KeypadToNUD(NumericUpDown sender, Form owner) { sender.BackColor = System.Drawing.Color.Red; @@ -192,7 +201,6 @@ public void KeyboardToText(TextBox sender, Form owner) private ToolStripDropDownButton toolStripDropDownButton1; private ToolStripMenuItem toolStripMenuItem1; private ToolStripMenuItem toolStripMenuItem2; - private ToolStripMenuItem toolStripMenuItem4; private ToolStripMenuItem deviceManagerToolStripMenuItem; } } diff --git a/SourceCode/AgIO/Source/Forms/FormEthernet.cs b/SourceCode/AgIO/Source/Forms/FormEthernet.cs new file mode 100644 index 000000000..a56238f89 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.cs @@ -0,0 +1,116 @@ +using System; +using System.ComponentModel; +using System.Diagnostics; +using System.Drawing; +using System.Linq; +using System.Net; +using System.Net.NetworkInformation; +using System.Net.Sockets; +using System.Windows.Forms; + +namespace AgIO +{ + public partial class FormEthernet : Form + { + //class variables + private readonly FormLoop mf = null; + + public FormEthernet(Form callingForm) + { + //get copy of the calling main form + mf = callingForm as FormLoop; + InitializeComponent(); + + nudFirstIP.Controls[0].Enabled = false; + nudSecndIP.Controls[0].Enabled = false; + nudThirdIP.Controls[0].Enabled = false; + } + + private void FormUDp_Load(object sender, EventArgs e) + { + + cboxIsUDPOn.Checked = Properties.Settings.Default.setUDP_isOn; + cboxPlugin.Checked = Properties.Settings.Default.setUDP_isUsePluginApp; + cboxIsSendNMEAToUDP.Checked = Properties.Settings.Default.setUDP_isSendNMEAToUDP; + + //nudSub1.Value = Properties.Settings.Default.etIP_SubnetOne; + //nudSub2.Value = Properties.Settings.Default.etIP_SubnetTwo; + //nudSub3.Value = Properties.Settings.Default.etIP_SubnetThree; + + nudFirstIP.Value = Properties.Settings.Default.eth_loopOne; + nudSecndIP.Value = Properties.Settings.Default.eth_loopTwo; + nudThirdIP.Value = Properties.Settings.Default.eth_loopThree; + nudFourthIP.Value= Properties.Settings.Default.eth_loopFour; + + if (!cboxIsUDPOn.Checked) cboxIsUDPOn.BackColor = System.Drawing.Color.Salmon; + } + + private void nudFirstIP_Click(object sender, EventArgs e) + { + mf.KeypadToNUD((NumericUpDown)sender, this); + } + + private void btnSerialCancel_Click(object sender, EventArgs e) + { + //Properties.Settings.Default.etIP_SubnetOne = (byte)nudSub1.Value; + //Properties.Settings.Default.etIP_SubnetTwo = (byte)nudSub2.Value; + //Properties.Settings.Default.etIP_SubnetThree = (byte)nudSub3.Value; + + Properties.Settings.Default.eth_loopOne = (byte)nudFirstIP.Value; + Properties.Settings.Default.eth_loopTwo = (byte)nudSecndIP.Value; + Properties.Settings.Default.eth_loopThree = (byte)nudThirdIP.Value; + Properties.Settings.Default.eth_loopFour = (byte)nudFourthIP.Value; + + Properties.Settings.Default.setUDP_isOn = cboxIsUDPOn.Checked; + Properties.Settings.Default.setUDP_isUsePluginApp = cboxPlugin.Checked; + Properties.Settings.Default.setUDP_isSendNMEAToUDP = cboxIsSendNMEAToUDP.Checked; + + Properties.Settings.Default.Save(); + + mf.YesMessageBox("AgIO will Restart to Enable UDP Networking Features"); + + Application.Restart(); + Environment.Exit(0); + Close(); + + } + + private void btnHelp_Click(object sender, EventArgs e) + { + System.Diagnostics.Process.Start(gStr.gsEthernetHelp); + } + + + ////get the ipv4 address only + //public void GetIP4AddressList() + //{ + // tboxNets.Text = ""; + // foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + // { + // if (IPA.AddressFamily == AddressFamily.InterNetwork) + // { + // tboxNets.Text += IPA.ToString() + "\r\n"; + // } + // } + //} + + //public void IsValidNetworkFound() + //{ + // foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + // { + // if (IPA.AddressFamily == AddressFamily.InterNetwork) + // { + // byte[] data = IPA.GetAddressBytes(); + // // Split string by ".", check that array length is 3 + // if (data[0] == 192 && data[1] == 168 && data[2] == 1) + // { + // if (data[3] < 255 && data[3] > 1) + // { + // break; + // } + // } + // } + // } + //} + } +} diff --git a/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs b/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs new file mode 100644 index 000000000..2355f9538 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs @@ -0,0 +1,352 @@ +namespace AgIO +{ + partial class FormEthernet + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.btnSerialCancel = new System.Windows.Forms.Button(); + this.label13 = new System.Windows.Forms.Label(); + this.cboxIsSendNMEAToUDP = new System.Windows.Forms.CheckBox(); + this.groupBox3 = new System.Windows.Forms.GroupBox(); + this.cboxPlugin = new System.Windows.Forms.CheckBox(); + this.groupBox5 = new System.Windows.Forms.GroupBox(); + this.cboxIsUDPOn = new System.Windows.Forms.CheckBox(); + this.nudThirdIP = new System.Windows.Forms.NumericUpDown(); + this.nudSecndIP = new System.Windows.Forms.NumericUpDown(); + this.nudFirstIP = new System.Windows.Forms.NumericUpDown(); + this.label2 = new System.Windows.Forms.Label(); + this.label3 = new System.Windows.Forms.Label(); + this.nudFourthIP = new System.Windows.Forms.NumericUpDown(); + this.label1 = new System.Windows.Forms.Label(); + this.btnHelp = new System.Windows.Forms.Button(); + this.groupBox3.SuspendLayout(); + this.groupBox5.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudFourthIP)).BeginInit(); + this.SuspendLayout(); + // + // btnSerialCancel + // + this.btnSerialCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnSerialCancel.FlatAppearance.BorderSize = 0; + this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.OK64; + this.btnSerialCancel.Location = new System.Drawing.Point(668, 141); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(92, 79); + this.btnSerialCancel.TabIndex = 71; + this.btnSerialCancel.UseVisualStyleBackColor = true; + this.btnSerialCancel.Click += new System.EventHandler(this.btnSerialCancel_Click); + // + // label13 + // + this.label13.AutoSize = true; + this.label13.BackColor = System.Drawing.Color.White; + this.label13.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label13.Location = new System.Drawing.Point(2, 23); + this.label13.Name = "label13"; + this.label13.Size = new System.Drawing.Size(161, 46); + this.label13.TabIndex = 518; + this.label13.Text = "Loopback Address\r\n(Don\'t Change)"; + this.label13.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // cboxIsSendNMEAToUDP + // + this.cboxIsSendNMEAToUDP.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsSendNMEAToUDP.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; + this.cboxIsSendNMEAToUDP.Checked = true; + this.cboxIsSendNMEAToUDP.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxIsSendNMEAToUDP.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; + this.cboxIsSendNMEAToUDP.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsSendNMEAToUDP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsSendNMEAToUDP.Location = new System.Drawing.Point(33, 28); + this.cboxIsSendNMEAToUDP.Name = "cboxIsSendNMEAToUDP"; + this.cboxIsSendNMEAToUDP.Size = new System.Drawing.Size(126, 35); + this.cboxIsSendNMEAToUDP.TabIndex = 92; + this.cboxIsSendNMEAToUDP.Text = "NMEA"; + this.cboxIsSendNMEAToUDP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsSendNMEAToUDP.UseVisualStyleBackColor = true; + // + // groupBox3 + // + this.groupBox3.Controls.Add(this.cboxIsSendNMEAToUDP); + this.groupBox3.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.groupBox3.Location = new System.Drawing.Point(22, 136); + this.groupBox3.Name = "groupBox3"; + this.groupBox3.Size = new System.Drawing.Size(171, 80); + this.groupBox3.TabIndex = 94; + this.groupBox3.TabStop = false; + this.groupBox3.Text = "NMEA to Network"; + // + // cboxPlugin + // + this.cboxPlugin.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxPlugin.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.cboxPlugin.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; + this.cboxPlugin.Checked = true; + this.cboxPlugin.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxPlugin.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; + this.cboxPlugin.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxPlugin.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxPlugin.Location = new System.Drawing.Point(33, 30); + this.cboxPlugin.Name = "cboxPlugin"; + this.cboxPlugin.Size = new System.Drawing.Size(126, 35); + this.cboxPlugin.TabIndex = 92; + this.cboxPlugin.Text = "Rate App"; + this.cboxPlugin.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxPlugin.UseVisualStyleBackColor = true; + // + // groupBox5 + // + this.groupBox5.Controls.Add(this.cboxPlugin); + this.groupBox5.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.groupBox5.Location = new System.Drawing.Point(216, 136); + this.groupBox5.Name = "groupBox5"; + this.groupBox5.Size = new System.Drawing.Size(171, 80); + this.groupBox5.TabIndex = 95; + this.groupBox5.TabStop = false; + this.groupBox5.Text = "Application Plugin"; + // + // cboxIsUDPOn + // + this.cboxIsUDPOn.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsUDPOn.BackColor = System.Drawing.Color.LightSalmon; + this.cboxIsUDPOn.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; + this.cboxIsUDPOn.Checked = true; + this.cboxIsUDPOn.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxIsUDPOn.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; + this.cboxIsUDPOn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsUDPOn.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsUDPOn.Location = new System.Drawing.Point(433, 155); + this.cboxIsUDPOn.Name = "cboxIsUDPOn"; + this.cboxIsUDPOn.Size = new System.Drawing.Size(159, 50); + this.cboxIsUDPOn.TabIndex = 92; + this.cboxIsUDPOn.Text = "UDP On"; + this.cboxIsUDPOn.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsUDPOn.UseVisualStyleBackColor = false; + // + // nudThirdIP + // + this.nudThirdIP.BackColor = System.Drawing.Color.AliceBlue; + this.nudThirdIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.nudThirdIP.Location = new System.Drawing.Point(426, 27); + this.nudThirdIP.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudThirdIP.Name = "nudThirdIP"; + this.nudThirdIP.Size = new System.Drawing.Size(102, 40); + this.nudThirdIP.TabIndex = 527; + this.nudThirdIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudThirdIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; + this.nudThirdIP.Value = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudThirdIP.Click += new System.EventHandler(this.nudFirstIP_Click); + // + // nudSecndIP + // + this.nudSecndIP.BackColor = System.Drawing.Color.AliceBlue; + this.nudSecndIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.nudSecndIP.Location = new System.Drawing.Point(300, 27); + this.nudSecndIP.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudSecndIP.Name = "nudSecndIP"; + this.nudSecndIP.Size = new System.Drawing.Size(102, 40); + this.nudSecndIP.TabIndex = 526; + this.nudSecndIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudSecndIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; + this.nudSecndIP.Value = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudSecndIP.Click += new System.EventHandler(this.nudFirstIP_Click); + // + // nudFirstIP + // + this.nudFirstIP.BackColor = System.Drawing.Color.AliceBlue; + this.nudFirstIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.nudFirstIP.Location = new System.Drawing.Point(174, 27); + this.nudFirstIP.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudFirstIP.Name = "nudFirstIP"; + this.nudFirstIP.Size = new System.Drawing.Size(102, 40); + this.nudFirstIP.TabIndex = 525; + this.nudFirstIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudFirstIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; + this.nudFirstIP.Value = new decimal(new int[] { + 127, + 0, + 0, + 0}); + this.nudFirstIP.Click += new System.EventHandler(this.nudFirstIP_Click); + // + // label2 + // + this.label2.AutoSize = true; + this.label2.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label2.Location = new System.Drawing.Point(278, 21); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(24, 35); + this.label2.TabIndex = 528; + this.label2.Text = "."; + this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label3 + // + this.label3.AutoSize = true; + this.label3.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label3.Location = new System.Drawing.Point(403, 21); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(24, 35); + this.label3.TabIndex = 529; + this.label3.Text = "."; + this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // nudFourthIP + // + this.nudFourthIP.BackColor = System.Drawing.Color.AliceBlue; + this.nudFourthIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.nudFourthIP.Location = new System.Drawing.Point(552, 27); + this.nudFourthIP.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudFourthIP.Name = "nudFourthIP"; + this.nudFourthIP.Size = new System.Drawing.Size(102, 40); + this.nudFourthIP.TabIndex = 530; + this.nudFourthIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudFourthIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; + this.nudFourthIP.Value = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.nudFourthIP.Click += new System.EventHandler(this.nudFirstIP_Click); + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label1.Location = new System.Drawing.Point(529, 21); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(24, 35); + this.label1.TabIndex = 531; + this.label1.Text = "."; + this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // btnHelp + // + this.btnHelp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnHelp.FlatAppearance.BorderSize = 0; + this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnHelp.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnHelp.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnHelp.Image = global::AgIO.Properties.Resources.Help; + this.btnHelp.Location = new System.Drawing.Point(693, 4); + this.btnHelp.Name = "btnHelp"; + this.btnHelp.Size = new System.Drawing.Size(76, 65); + this.btnHelp.TabIndex = 532; + this.btnHelp.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnHelp.UseVisualStyleBackColor = true; + this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click); + // + // FormEthernet + // + this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.White; + this.ClientSize = new System.Drawing.Size(772, 232); + this.ControlBox = false; + this.Controls.Add(this.btnHelp); + this.Controls.Add(this.nudFourthIP); + this.Controls.Add(this.nudThirdIP); + this.Controls.Add(this.nudSecndIP); + this.Controls.Add(this.nudFirstIP); + this.Controls.Add(this.label2); + this.Controls.Add(this.label3); + this.Controls.Add(this.label13); + this.Controls.Add(this.cboxIsUDPOn); + this.Controls.Add(this.groupBox5); + this.Controls.Add(this.groupBox3); + this.Controls.Add(this.btnSerialCancel); + this.Controls.Add(this.label1); + this.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "FormEthernet"; + this.ShowInTaskbar = false; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "Ethernet Configuration"; + this.Load += new System.EventHandler(this.FormUDp_Load); + this.groupBox3.ResumeLayout(false); + this.groupBox5.ResumeLayout(false); + ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudFourthIP)).EndInit(); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + private System.Windows.Forms.Button btnSerialCancel; + private System.Windows.Forms.Label label13; + private System.Windows.Forms.CheckBox cboxIsSendNMEAToUDP; + private System.Windows.Forms.GroupBox groupBox3; + private System.Windows.Forms.CheckBox cboxPlugin; + private System.Windows.Forms.GroupBox groupBox5; + private System.Windows.Forms.CheckBox cboxIsUDPOn; + private System.Windows.Forms.NumericUpDown nudThirdIP; + private System.Windows.Forms.NumericUpDown nudSecndIP; + private System.Windows.Forms.NumericUpDown nudFirstIP; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.Label label3; + private System.Windows.Forms.NumericUpDown nudFourthIP; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Button btnHelp; + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormEthernet.resx b/SourceCode/AgIO/Source/Forms/FormEthernet.resx new file mode 100644 index 000000000..1af7de150 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index 85f6879e7..01115109c 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -44,6 +44,15 @@ private void InitializeComponent() this.lblFromGPS = new System.Windows.Forms.Label(); this.lblGPS1Comm = new System.Windows.Forms.Label(); this.statusStrip1 = new System.Windows.Forms.StatusStrip(); + this.toolStripDropDownButton1 = new System.Windows.Forms.ToolStripDropDownButton(); + this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem(); + this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripMenuItem(); + this.toolStripEthernet = new System.Windows.Forms.ToolStripMenuItem(); + this.deviceManagerToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.settingsMenuStrip = new System.Windows.Forms.ToolStripDropDownButton(); + this.saveToolStrip = new System.Windows.Forms.ToolStripMenuItem(); + this.loadToolStrip = new System.Windows.Forms.ToolStripMenuItem(); + this.serialPassThroughToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.lblSteerAngle = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label(); this.lblNTRIP_IP = new System.Windows.Forms.Label(); @@ -66,15 +75,12 @@ private void InitializeComponent() this.label10 = new System.Windows.Forms.Label(); this.lbl9To16 = new System.Windows.Forms.Label(); this.label12 = new System.Windows.Forms.Label(); - this.lblPacketSize = new System.Windows.Forms.Label(); - this.label11 = new System.Windows.Forms.Label(); this.lblStationID = new System.Windows.Forms.Label(); this.label13 = new System.Windows.Forms.Label(); this.lblSkipCounter = new System.Windows.Forms.Label(); this.lblCount = new System.Windows.Forms.Label(); this.label7 = new System.Windows.Forms.Label(); this.lblToGPS = new System.Windows.Forms.Label(); - this.btnGPSData = new System.Windows.Forms.Button(); this.btnResetTimer = new System.Windows.Forms.Button(); this.cboxIsSteerModule = new System.Windows.Forms.CheckBox(); this.cboxIsIMUModule = new System.Windows.Forms.CheckBox(); @@ -86,27 +92,21 @@ private void InitializeComponent() this.btnWindowsShutDown = new System.Windows.Forms.Button(); this.btnSlide = new System.Windows.Forms.Button(); this.pictureBox1 = new System.Windows.Forms.PictureBox(); - this.btnUDP = new System.Windows.Forms.Button(); this.cboxLogNMEA = new System.Windows.Forms.CheckBox(); this.btnExit = new System.Windows.Forms.Button(); this.btnRunAOG = new System.Windows.Forms.Button(); - this.toolStripDropDownButton1 = new System.Windows.Forms.ToolStripDropDownButton(); - this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem(); - this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripMenuItem(); - this.toolStripMenuItem4 = new System.Windows.Forms.ToolStripMenuItem(); - this.deviceManagerToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.settingsMenuStrip = new System.Windows.Forms.ToolStripDropDownButton(); - this.saveToolStrip = new System.Windows.Forms.ToolStripMenuItem(); - this.loadToolStrip = new System.Windows.Forms.ToolStripMenuItem(); - this.serialPassThroughToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.btnRelayTest = new System.Windows.Forms.Button(); + this.btnGPSData = new System.Windows.Forms.Button(); + this.btnUDP = new System.Windows.Forms.Button(); + this.btnHelp = new System.Windows.Forms.Button(); + this.toolStripSerialMonitor = new System.Windows.Forms.ToolStripMenuItem(); this.statusStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); this.SuspendLayout(); // // oneSecondLoopTimer // - this.oneSecondLoopTimer.Interval = 4000; + this.oneSecondLoopTimer.Interval = 1500; this.oneSecondLoopTimer.Tick += new System.EventHandler(this.oneSecondLoopTimer_Tick); // // label6 @@ -166,7 +166,7 @@ private void InitializeComponent() this.lblWatch.BackColor = System.Drawing.Color.Transparent; this.lblWatch.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblWatch.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblWatch.Location = new System.Drawing.Point(3, 116); + this.lblWatch.Location = new System.Drawing.Point(14, 105); this.lblWatch.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblWatch.Name = "lblWatch"; this.lblWatch.Size = new System.Drawing.Size(105, 18); @@ -179,7 +179,7 @@ private void InitializeComponent() this.lblNTRIPBytes.BackColor = System.Drawing.Color.Transparent; this.lblNTRIPBytes.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblNTRIPBytes.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblNTRIPBytes.Location = new System.Drawing.Point(3, 89); + this.lblNTRIPBytes.Location = new System.Drawing.Point(14, 81); this.lblNTRIPBytes.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblNTRIPBytes.Name = "lblNTRIPBytes"; this.lblNTRIPBytes.Size = new System.Drawing.Size(105, 18); @@ -193,7 +193,7 @@ private void InitializeComponent() this.lblMod2Comm.BackColor = System.Drawing.Color.Transparent; this.lblMod2Comm.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblMod2Comm.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblMod2Comm.Location = new System.Drawing.Point(136, 330); + this.lblMod2Comm.Location = new System.Drawing.Point(167, 342); this.lblMod2Comm.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblMod2Comm.Name = "lblMod2Comm"; this.lblMod2Comm.Size = new System.Drawing.Size(64, 25); @@ -205,7 +205,7 @@ private void InitializeComponent() this.lblMod1Comm.BackColor = System.Drawing.Color.Transparent; this.lblMod1Comm.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblMod1Comm.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblMod1Comm.Location = new System.Drawing.Point(136, 170); + this.lblMod1Comm.Location = new System.Drawing.Point(167, 170); this.lblMod1Comm.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblMod1Comm.Name = "lblMod1Comm"; this.lblMod1Comm.Size = new System.Drawing.Size(64, 25); @@ -217,7 +217,7 @@ private void InitializeComponent() this.lblIMUComm.BackColor = System.Drawing.Color.Transparent; this.lblIMUComm.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblIMUComm.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblIMUComm.Location = new System.Drawing.Point(136, 83); + this.lblIMUComm.Location = new System.Drawing.Point(167, 86); this.lblIMUComm.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblIMUComm.Name = "lblIMUComm"; this.lblIMUComm.Size = new System.Drawing.Size(64, 25); @@ -226,23 +226,24 @@ private void InitializeComponent() // // lblFromGPS // + this.lblFromGPS.AutoSize = true; this.lblFromGPS.BackColor = System.Drawing.Color.Transparent; - this.lblFromGPS.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblFromGPS.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblFromGPS.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblFromGPS.Location = new System.Drawing.Point(286, 249); + this.lblFromGPS.Location = new System.Drawing.Point(330, 273); this.lblFromGPS.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblFromGPS.Name = "lblFromGPS"; - this.lblFromGPS.Size = new System.Drawing.Size(45, 25); + this.lblFromGPS.Size = new System.Drawing.Size(26, 18); this.lblFromGPS.TabIndex = 130; this.lblFromGPS.Text = "---"; - this.lblFromGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.lblFromGPS.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; // // lblGPS1Comm // this.lblGPS1Comm.BackColor = System.Drawing.Color.Transparent; this.lblGPS1Comm.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblGPS1Comm.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblGPS1Comm.Location = new System.Drawing.Point(136, 249); + this.lblGPS1Comm.Location = new System.Drawing.Point(167, 257); this.lblGPS1Comm.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblGPS1Comm.Name = "lblGPS1Comm"; this.lblGPS1Comm.Size = new System.Drawing.Size(64, 25); @@ -259,21 +260,118 @@ private void InitializeComponent() this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripDropDownButton1, this.settingsMenuStrip}); - this.statusStrip1.Location = new System.Drawing.Point(101, 394); + this.statusStrip1.Location = new System.Drawing.Point(93, 410); this.statusStrip1.Name = "statusStrip1"; this.statusStrip1.Padding = new System.Windows.Forms.Padding(1, 0, 11, 0); - this.statusStrip1.Size = new System.Drawing.Size(212, 70); + this.statusStrip1.Size = new System.Drawing.Size(230, 70); this.statusStrip1.SizingGrip = false; this.statusStrip1.TabIndex = 149; this.statusStrip1.Text = "statusStrip1"; // + // toolStripDropDownButton1 + // + this.toolStripDropDownButton1.AutoSize = false; + this.toolStripDropDownButton1.BackColor = System.Drawing.Color.Transparent; + this.toolStripDropDownButton1.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; + this.toolStripDropDownButton1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.toolStripMenuItem1, + this.toolStripMenuItem2, + this.toolStripEthernet, + this.toolStripSerialMonitor, + this.deviceManagerToolStripMenuItem}); + this.toolStripDropDownButton1.Image = global::AgIO.Properties.Resources.Settings48; + this.toolStripDropDownButton1.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; + this.toolStripDropDownButton1.ImageTransparentColor = System.Drawing.Color.Magenta; + this.toolStripDropDownButton1.Name = "toolStripDropDownButton1"; + this.toolStripDropDownButton1.ShowDropDownArrow = false; + this.toolStripDropDownButton1.Size = new System.Drawing.Size(110, 68); + // + // toolStripMenuItem1 + // + this.toolStripMenuItem1.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.toolStripMenuItem1.Image = global::AgIO.Properties.Resources.VehFileSave; + this.toolStripMenuItem1.Name = "toolStripMenuItem1"; + this.toolStripMenuItem1.Size = new System.Drawing.Size(311, 70); + this.toolStripMenuItem1.Text = "Save"; + this.toolStripMenuItem1.Click += new System.EventHandler(this.toolStripMenuItem1_Click); + // + // toolStripMenuItem2 + // + this.toolStripMenuItem2.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.toolStripMenuItem2.Image = global::AgIO.Properties.Resources.VehFileLoad; + this.toolStripMenuItem2.Name = "toolStripMenuItem2"; + this.toolStripMenuItem2.Size = new System.Drawing.Size(311, 70); + this.toolStripMenuItem2.Text = "Load"; + this.toolStripMenuItem2.Click += new System.EventHandler(this.toolStripMenuItem2_Click); + // + // toolStripEthernet + // + this.toolStripEthernet.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.toolStripEthernet.Image = global::AgIO.Properties.Resources.ScanNetwork; + this.toolStripEthernet.Name = "toolStripEthernet"; + this.toolStripEthernet.Size = new System.Drawing.Size(311, 70); + this.toolStripEthernet.Text = "Ethernet Settings"; + this.toolStripEthernet.Click += new System.EventHandler(this.toolStripEthernet_Click); + // + // deviceManagerToolStripMenuItem + // + this.deviceManagerToolStripMenuItem.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.deviceManagerToolStripMenuItem.Image = global::AgIO.Properties.Resources.DeviceManager; + this.deviceManagerToolStripMenuItem.Name = "deviceManagerToolStripMenuItem"; + this.deviceManagerToolStripMenuItem.Size = new System.Drawing.Size(311, 70); + this.deviceManagerToolStripMenuItem.Text = "Device Manager"; + this.deviceManagerToolStripMenuItem.Click += new System.EventHandler(this.deviceManagerToolStripMenuItem_Click); + // + // settingsMenuStrip + // + this.settingsMenuStrip.AutoSize = false; + this.settingsMenuStrip.BackColor = System.Drawing.Color.Transparent; + this.settingsMenuStrip.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; + this.settingsMenuStrip.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.saveToolStrip, + this.loadToolStrip, + this.serialPassThroughToolStripMenuItem}); + this.settingsMenuStrip.Image = global::AgIO.Properties.Resources.NtripSettings; + this.settingsMenuStrip.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; + this.settingsMenuStrip.ImageTransparentColor = System.Drawing.Color.Magenta; + this.settingsMenuStrip.Name = "settingsMenuStrip"; + this.settingsMenuStrip.ShowDropDownArrow = false; + this.settingsMenuStrip.Size = new System.Drawing.Size(110, 68); + // + // saveToolStrip + // + this.saveToolStrip.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.saveToolStrip.Image = global::AgIO.Properties.Resources.NTRIP_Client; + this.saveToolStrip.Name = "saveToolStrip"; + this.saveToolStrip.Size = new System.Drawing.Size(285, 70); + this.saveToolStrip.Text = "Client NTRIP"; + this.saveToolStrip.Click += new System.EventHandler(this.btnNTRIP_Click); + // + // loadToolStrip + // + this.loadToolStrip.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.loadToolStrip.Image = global::AgIO.Properties.Resources.RadioSettings; + this.loadToolStrip.Name = "loadToolStrip"; + this.loadToolStrip.Size = new System.Drawing.Size(285, 70); + this.loadToolStrip.Text = "Radio NTRIP"; + this.loadToolStrip.Click += new System.EventHandler(this.btnRadio_Click_1); + // + // serialPassThroughToolStripMenuItem + // + this.serialPassThroughToolStripMenuItem.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.serialPassThroughToolStripMenuItem.Image = global::AgIO.Properties.Resources.NTRIP_Serial; + this.serialPassThroughToolStripMenuItem.Name = "serialPassThroughToolStripMenuItem"; + this.serialPassThroughToolStripMenuItem.Size = new System.Drawing.Size(285, 70); + this.serialPassThroughToolStripMenuItem.Text = "Serial NTRIP"; + this.serialPassThroughToolStripMenuItem.Click += new System.EventHandler(this.serialPassThroughToolStripMenuItem_Click); + // // lblSteerAngle // this.lblSteerAngle.AutoSize = true; this.lblSteerAngle.BackColor = System.Drawing.Color.Transparent; this.lblSteerAngle.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblSteerAngle.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblSteerAngle.Location = new System.Drawing.Point(522, 85); + this.lblSteerAngle.Location = new System.Drawing.Point(549, 85); this.lblSteerAngle.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblSteerAngle.Name = "lblSteerAngle"; this.lblSteerAngle.Size = new System.Drawing.Size(40, 18); @@ -288,7 +386,7 @@ private void InitializeComponent() this.label1.Cursor = System.Windows.Forms.Cursors.Default; this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label1.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.label1.Location = new System.Drawing.Point(15, 377); + this.label1.Location = new System.Drawing.Point(15, 397); this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(77, 15); @@ -301,7 +399,7 @@ private void InitializeComponent() this.lblNTRIP_IP.BackColor = System.Drawing.Color.Transparent; this.lblNTRIP_IP.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblNTRIP_IP.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblNTRIP_IP.Location = new System.Drawing.Point(457, 6); + this.lblNTRIP_IP.Location = new System.Drawing.Point(480, 6); this.lblNTRIP_IP.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblNTRIP_IP.Name = "lblNTRIP_IP"; this.lblNTRIP_IP.Size = new System.Drawing.Size(133, 18); @@ -316,7 +414,7 @@ private void InitializeComponent() this.lblSerialPorts.BackColor = System.Drawing.Color.Transparent; this.lblSerialPorts.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblSerialPorts.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.lblSerialPorts.Location = new System.Drawing.Point(90, 378); + this.lblSerialPorts.Location = new System.Drawing.Point(90, 398); this.lblSerialPorts.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblSerialPorts.Name = "lblSerialPorts"; this.lblSerialPorts.Size = new System.Drawing.Size(45, 14); @@ -329,7 +427,7 @@ private void InitializeComponent() this.lblMount.BackColor = System.Drawing.Color.Transparent; this.lblMount.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblMount.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblMount.Location = new System.Drawing.Point(457, 27); + this.lblMount.Location = new System.Drawing.Point(480, 27); this.lblMount.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblMount.Name = "lblMount"; this.lblMount.Size = new System.Drawing.Size(133, 18); @@ -339,13 +437,14 @@ private void InitializeComponent() // // lblIP // + this.lblIP.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.lblIP.BackColor = System.Drawing.Color.Transparent; - this.lblIP.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblIP.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblIP.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblIP.Location = new System.Drawing.Point(3, 236); + this.lblIP.Location = new System.Drawing.Point(10, 205); this.lblIP.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblIP.Name = "lblIP"; - this.lblIP.Size = new System.Drawing.Size(105, 56); + this.lblIP.Size = new System.Drawing.Size(123, 102); this.lblIP.TabIndex = 464; this.lblIP.Text = "288.288.288.288"; this.lblIP.TextAlign = System.Drawing.ContentAlignment.BottomCenter; @@ -362,10 +461,10 @@ private void InitializeComponent() this.lblMessages.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.lblMessages.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblMessages.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblMessages.Location = new System.Drawing.Point(599, 69); + this.lblMessages.Location = new System.Drawing.Point(643, 69); this.lblMessages.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblMessages.Name = "lblMessages"; - this.lblMessages.Size = new System.Drawing.Size(78, 326); + this.lblMessages.Size = new System.Drawing.Size(78, 315); this.lblMessages.TabIndex = 474; this.lblMessages.Text = "1888 - 18"; this.lblMessages.Click += new System.EventHandler(this.lblMessages_Click); @@ -376,7 +475,7 @@ private void InitializeComponent() this.lblWASCounts.BackColor = System.Drawing.Color.Transparent; this.lblWASCounts.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblWASCounts.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblWASCounts.Location = new System.Drawing.Point(522, 108); + this.lblWASCounts.Location = new System.Drawing.Point(549, 108); this.lblWASCounts.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblWASCounts.Name = "lblWASCounts"; this.lblWASCounts.Size = new System.Drawing.Size(43, 18); @@ -389,7 +488,7 @@ private void InitializeComponent() this.label3.BackColor = System.Drawing.Color.Transparent; this.label3.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label3.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label3.Location = new System.Drawing.Point(469, 84); + this.label3.Location = new System.Drawing.Point(496, 84); this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(56, 19); @@ -402,7 +501,7 @@ private void InitializeComponent() this.label4.BackColor = System.Drawing.Color.Transparent; this.label4.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label4.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label4.Location = new System.Drawing.Point(461, 107); + this.label4.Location = new System.Drawing.Point(488, 107); this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(64, 19); @@ -415,7 +514,7 @@ private void InitializeComponent() this.label2.BackColor = System.Drawing.Color.Transparent; this.label2.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label2.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label2.Location = new System.Drawing.Point(461, 142); + this.label2.Location = new System.Drawing.Point(488, 142); this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(61, 19); @@ -428,7 +527,7 @@ private void InitializeComponent() this.lblSwitchStatus.BackColor = System.Drawing.Color.Transparent; this.lblSwitchStatus.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblSwitchStatus.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblSwitchStatus.Location = new System.Drawing.Point(522, 143); + this.lblSwitchStatus.Location = new System.Drawing.Point(549, 143); this.lblSwitchStatus.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblSwitchStatus.Name = "lblSwitchStatus"; this.lblSwitchStatus.Size = new System.Drawing.Size(18, 18); @@ -441,7 +540,7 @@ private void InitializeComponent() this.lblWorkSwitchStatus.BackColor = System.Drawing.Color.Transparent; this.lblWorkSwitchStatus.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblWorkSwitchStatus.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblWorkSwitchStatus.Location = new System.Drawing.Point(522, 166); + this.lblWorkSwitchStatus.Location = new System.Drawing.Point(549, 166); this.lblWorkSwitchStatus.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblWorkSwitchStatus.Name = "lblWorkSwitchStatus"; this.lblWorkSwitchStatus.Size = new System.Drawing.Size(18, 18); @@ -454,7 +553,7 @@ private void InitializeComponent() this.label9.BackColor = System.Drawing.Color.Transparent; this.label9.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label9.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label9.Location = new System.Drawing.Point(470, 165); + this.label9.Location = new System.Drawing.Point(497, 165); this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label9.Name = "label9"; this.label9.Size = new System.Drawing.Size(52, 19); @@ -469,7 +568,7 @@ private void InitializeComponent() this.btnStartStopNtrip.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnStartStopNtrip.ForeColor = System.Drawing.Color.Black; this.btnStartStopNtrip.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnStartStopNtrip.Location = new System.Drawing.Point(16, 146); + this.btnStartStopNtrip.Location = new System.Drawing.Point(25, 130); this.btnStartStopNtrip.Margin = new System.Windows.Forms.Padding(4); this.btnStartStopNtrip.Name = "btnStartStopNtrip"; this.btnStartStopNtrip.Size = new System.Drawing.Size(80, 27); @@ -484,7 +583,7 @@ private void InitializeComponent() this.lblMessagesFound.BackColor = System.Drawing.Color.Transparent; this.lblMessagesFound.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblMessagesFound.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblMessagesFound.Location = new System.Drawing.Point(651, 47); + this.lblMessagesFound.Location = new System.Drawing.Point(695, 41); this.lblMessagesFound.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblMessagesFound.Name = "lblMessagesFound"; this.lblMessagesFound.Size = new System.Drawing.Size(18, 18); @@ -498,7 +597,7 @@ private void InitializeComponent() this.label5.BackColor = System.Drawing.Color.Transparent; this.label5.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label5.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label5.Location = new System.Drawing.Point(599, 47); + this.label5.Location = new System.Drawing.Point(643, 41); this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(53, 18); @@ -509,12 +608,12 @@ private void InitializeComponent() // this.lbl1To8.AutoSize = true; this.lbl1To8.BackColor = System.Drawing.Color.Transparent; - this.lbl1To8.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lbl1To8.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lbl1To8.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lbl1To8.Location = new System.Drawing.Point(472, 230); + this.lbl1To8.Location = new System.Drawing.Point(486, 228); this.lbl1To8.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lbl1To8.Name = "lbl1To8"; - this.lbl1To8.Size = new System.Drawing.Size(88, 18); + this.lbl1To8.Size = new System.Drawing.Size(106, 23); this.lbl1To8.TabIndex = 500; this.lbl1To8.Text = "00000000"; // @@ -522,12 +621,12 @@ private void InitializeComponent() // this.label10.AutoSize = true; this.label10.BackColor = System.Drawing.Color.Transparent; - this.label10.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label10.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label10.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label10.Location = new System.Drawing.Point(474, 213); + this.label10.Location = new System.Drawing.Point(486, 208); this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label10.Name = "label10"; - this.label10.Size = new System.Drawing.Size(83, 16); + this.label10.Size = new System.Drawing.Size(106, 19); this.label10.TabIndex = 499; this.label10.Text = "8 << 1"; // @@ -535,12 +634,12 @@ private void InitializeComponent() // this.lbl9To16.AutoSize = true; this.lbl9To16.BackColor = System.Drawing.Color.Transparent; - this.lbl9To16.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lbl9To16.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lbl9To16.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lbl9To16.Location = new System.Drawing.Point(472, 273); + this.lbl9To16.Location = new System.Drawing.Point(486, 280); this.lbl9To16.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lbl9To16.Name = "lbl9To16"; - this.lbl9To16.Size = new System.Drawing.Size(88, 18); + this.lbl9To16.Size = new System.Drawing.Size(106, 23); this.lbl9To16.TabIndex = 502; this.lbl9To16.Text = "00000000"; // @@ -548,49 +647,22 @@ private void InitializeComponent() // this.label12.AutoSize = true; this.label12.BackColor = System.Drawing.Color.Transparent; - this.label12.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label12.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label12.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label12.Location = new System.Drawing.Point(474, 256); + this.label12.Location = new System.Drawing.Point(486, 259); this.label12.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label12.Name = "label12"; - this.label12.Size = new System.Drawing.Size(82, 16); + this.label12.Size = new System.Drawing.Size(105, 19); this.label12.TabIndex = 501; this.label12.Text = "16 << 9"; // - // lblPacketSize - // - this.lblPacketSize.AutoSize = true; - this.lblPacketSize.BackColor = System.Drawing.Color.Transparent; - this.lblPacketSize.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblPacketSize.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblPacketSize.Location = new System.Drawing.Point(622, 4); - this.lblPacketSize.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - this.lblPacketSize.Name = "lblPacketSize"; - this.lblPacketSize.Size = new System.Drawing.Size(18, 18); - this.lblPacketSize.TabIndex = 505; - this.lblPacketSize.Text = "0"; - this.lblPacketSize.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - // - // label11 - // - this.label11.AutoSize = true; - this.label11.BackColor = System.Drawing.Color.Transparent; - this.label11.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label11.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label11.Location = new System.Drawing.Point(598, 4); - this.label11.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - this.label11.Name = "label11"; - this.label11.Size = new System.Drawing.Size(20, 18); - this.label11.TabIndex = 506; - this.label11.Text = "L:"; - // // lblStationID // this.lblStationID.AutoSize = true; this.lblStationID.BackColor = System.Drawing.Color.Transparent; this.lblStationID.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblStationID.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblStationID.Location = new System.Drawing.Point(627, 26); + this.lblStationID.Location = new System.Drawing.Point(671, 20); this.lblStationID.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblStationID.Name = "lblStationID"; this.lblStationID.Size = new System.Drawing.Size(18, 18); @@ -604,7 +676,7 @@ private void InitializeComponent() this.label13.BackColor = System.Drawing.Color.Transparent; this.label13.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label13.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label13.Location = new System.Drawing.Point(598, 26); + this.label13.Location = new System.Drawing.Point(642, 20); this.label13.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label13.Name = "label13"; this.label13.Size = new System.Drawing.Size(29, 18); @@ -630,7 +702,7 @@ private void InitializeComponent() this.lblCount.BackColor = System.Drawing.Color.Transparent; this.lblCount.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblCount.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblCount.Location = new System.Drawing.Point(490, 51); + this.lblCount.Location = new System.Drawing.Point(513, 51); this.lblCount.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblCount.Name = "lblCount"; this.lblCount.Size = new System.Drawing.Size(69, 18); @@ -653,35 +725,17 @@ private void InitializeComponent() // // lblToGPS // + this.lblToGPS.AutoSize = true; this.lblToGPS.BackColor = System.Drawing.Color.Transparent; - this.lblToGPS.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblToGPS.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblToGPS.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblToGPS.Location = new System.Drawing.Point(30, 177); + this.lblToGPS.Location = new System.Drawing.Point(330, 246); this.lblToGPS.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblToGPS.Name = "lblToGPS"; - this.lblToGPS.Size = new System.Drawing.Size(45, 25); + this.lblToGPS.Size = new System.Drawing.Size(26, 18); this.lblToGPS.TabIndex = 512; this.lblToGPS.Text = "---"; - this.lblToGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // btnGPSData - // - this.btnGPSData.BackColor = System.Drawing.Color.Transparent; - this.btnGPSData.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnGPSData.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; - this.btnGPSData.FlatAppearance.BorderSize = 0; - this.btnGPSData.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnGPSData.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnGPSData.ForeColor = System.Drawing.Color.Black; - this.btnGPSData.Image = global::AgIO.Properties.Resources.Nmea; - this.btnGPSData.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnGPSData.Location = new System.Drawing.Point(188, 4); - this.btnGPSData.Margin = new System.Windows.Forms.Padding(4); - this.btnGPSData.Name = "btnGPSData"; - this.btnGPSData.Size = new System.Drawing.Size(120, 48); - this.btnGPSData.TabIndex = 513; - this.btnGPSData.UseVisualStyleBackColor = false; - this.btnGPSData.Click += new System.EventHandler(this.btnGPSData_Click); + this.lblToGPS.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; // // btnResetTimer // @@ -695,7 +749,7 @@ private void InitializeComponent() this.btnResetTimer.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnResetTimer.ForeColor = System.Drawing.Color.Black; this.btnResetTimer.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnResetTimer.Location = new System.Drawing.Point(439, 399); + this.btnResetTimer.Location = new System.Drawing.Point(456, 415); this.btnResetTimer.Margin = new System.Windows.Forms.Padding(4); this.btnResetTimer.Name = "btnResetTimer"; this.btnResetTimer.Size = new System.Drawing.Size(63, 58); @@ -714,7 +768,7 @@ private void InitializeComponent() this.cboxIsSteerModule.CheckState = System.Windows.Forms.CheckState.Checked; this.cboxIsSteerModule.FlatAppearance.BorderSize = 0; this.cboxIsSteerModule.FlatStyle = System.Windows.Forms.FlatStyle.Popup; - this.cboxIsSteerModule.Location = new System.Drawing.Point(411, 162); + this.cboxIsSteerModule.Location = new System.Drawing.Point(411, 170); this.cboxIsSteerModule.Name = "cboxIsSteerModule"; this.cboxIsSteerModule.Size = new System.Drawing.Size(26, 27); this.cboxIsSteerModule.TabIndex = 498; @@ -731,7 +785,7 @@ private void InitializeComponent() this.cboxIsIMUModule.CheckState = System.Windows.Forms.CheckState.Checked; this.cboxIsIMUModule.FlatAppearance.BorderSize = 0; this.cboxIsIMUModule.FlatStyle = System.Windows.Forms.FlatStyle.Popup; - this.cboxIsIMUModule.Location = new System.Drawing.Point(411, 75); + this.cboxIsIMUModule.Location = new System.Drawing.Point(411, 88); this.cboxIsIMUModule.Name = "cboxIsIMUModule"; this.cboxIsIMUModule.Size = new System.Drawing.Size(26, 27); this.cboxIsIMUModule.TabIndex = 496; @@ -748,7 +802,7 @@ private void InitializeComponent() this.cboxIsMachineModule.CheckState = System.Windows.Forms.CheckState.Checked; this.cboxIsMachineModule.FlatAppearance.BorderSize = 0; this.cboxIsMachineModule.FlatStyle = System.Windows.Forms.FlatStyle.Popup; - this.cboxIsMachineModule.Location = new System.Drawing.Point(411, 332); + this.cboxIsMachineModule.Location = new System.Drawing.Point(411, 343); this.cboxIsMachineModule.Name = "cboxIsMachineModule"; this.cboxIsMachineModule.Size = new System.Drawing.Size(26, 27); this.cboxIsMachineModule.TabIndex = 495; @@ -767,7 +821,7 @@ private void InitializeComponent() this.btnIMU.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnIMU.ForeColor = System.Drawing.Color.White; this.btnIMU.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnIMU.Location = new System.Drawing.Point(206, 70); + this.btnIMU.Location = new System.Drawing.Point(238, 70); this.btnIMU.Margin = new System.Windows.Forms.Padding(4); this.btnIMU.Name = "btnIMU"; this.btnIMU.Size = new System.Drawing.Size(84, 59); @@ -786,7 +840,7 @@ private void InitializeComponent() this.btnSteer.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnSteer.ForeColor = System.Drawing.Color.White; this.btnSteer.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSteer.Location = new System.Drawing.Point(206, 154); + this.btnSteer.Location = new System.Drawing.Point(238, 155); this.btnSteer.Margin = new System.Windows.Forms.Padding(4); this.btnSteer.Name = "btnSteer"; this.btnSteer.Size = new System.Drawing.Size(84, 59); @@ -805,7 +859,7 @@ private void InitializeComponent() this.btnMachine.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnMachine.ForeColor = System.Drawing.Color.White; this.btnMachine.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnMachine.Location = new System.Drawing.Point(206, 312); + this.btnMachine.Location = new System.Drawing.Point(238, 325); this.btnMachine.Margin = new System.Windows.Forms.Padding(4); this.btnMachine.Name = "btnMachine"; this.btnMachine.Size = new System.Drawing.Size(84, 59); @@ -824,7 +878,7 @@ private void InitializeComponent() this.btnGPS.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnGPS.ForeColor = System.Drawing.Color.White; this.btnGPS.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnGPS.Location = new System.Drawing.Point(206, 233); + this.btnGPS.Location = new System.Drawing.Point(238, 240); this.btnGPS.Margin = new System.Windows.Forms.Padding(4); this.btnGPS.Name = "btnGPS"; this.btnGPS.Size = new System.Drawing.Size(84, 59); @@ -834,6 +888,7 @@ private void InitializeComponent() // // btnWindowsShutDown // + this.btnWindowsShutDown.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnWindowsShutDown.BackColor = System.Drawing.Color.Transparent; this.btnWindowsShutDown.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; this.btnWindowsShutDown.FlatAppearance.BorderSize = 0; @@ -842,7 +897,7 @@ private void InitializeComponent() this.btnWindowsShutDown.ForeColor = System.Drawing.Color.White; this.btnWindowsShutDown.Image = global::AgIO.Properties.Resources.WindowsShutDown; this.btnWindowsShutDown.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnWindowsShutDown.Location = new System.Drawing.Point(614, 399); + this.btnWindowsShutDown.Location = new System.Drawing.Point(665, 415); this.btnWindowsShutDown.Margin = new System.Windows.Forms.Padding(4); this.btnWindowsShutDown.Name = "btnWindowsShutDown"; this.btnWindowsShutDown.Size = new System.Drawing.Size(63, 58); @@ -861,10 +916,10 @@ private void InitializeComponent() this.btnSlide.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnSlide.ForeColor = System.Drawing.Color.White; this.btnSlide.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSlide.Location = new System.Drawing.Point(357, 8); + this.btnSlide.Location = new System.Drawing.Point(357, 6); this.btnSlide.Margin = new System.Windows.Forms.Padding(4); this.btnSlide.Name = "btnSlide"; - this.btnSlide.Size = new System.Drawing.Size(55, 43); + this.btnSlide.Size = new System.Drawing.Size(56, 49); this.btnSlide.TabIndex = 475; this.btnSlide.UseVisualStyleBackColor = false; this.btnSlide.Click += new System.EventHandler(this.btnSlide_Click); @@ -874,34 +929,16 @@ private void InitializeComponent() this.pictureBox1.BackColor = System.Drawing.Color.Black; this.pictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; this.pictureBox1.Image = global::AgIO.Properties.Resources.AgIO_First; - this.pictureBox1.Location = new System.Drawing.Point(550, 357); + this.pictureBox1.Location = new System.Drawing.Point(583, 360); this.pictureBox1.Name = "pictureBox1"; this.pictureBox1.Size = new System.Drawing.Size(42, 35); this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.pictureBox1.TabIndex = 182; this.pictureBox1.TabStop = false; // - // btnUDP - // - this.btnUDP.BackColor = System.Drawing.Color.Gainsboro; - this.btnUDP.BackgroundImage = global::AgIO.Properties.Resources.B_UDP; - this.btnUDP.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnUDP.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; - this.btnUDP.FlatAppearance.BorderSize = 0; - this.btnUDP.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnUDP.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnUDP.ForeColor = System.Drawing.Color.White; - this.btnUDP.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnUDP.Location = new System.Drawing.Point(18, 301); - this.btnUDP.Margin = new System.Windows.Forms.Padding(4); - this.btnUDP.Name = "btnUDP"; - this.btnUDP.Size = new System.Drawing.Size(82, 60); - this.btnUDP.TabIndex = 184; - this.btnUDP.UseVisualStyleBackColor = false; - this.btnUDP.Click += new System.EventHandler(this.btnUDP_Click); - // // cboxLogNMEA // + this.cboxLogNMEA.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.cboxLogNMEA.Appearance = System.Windows.Forms.Appearance.Button; this.cboxLogNMEA.BackColor = System.Drawing.Color.Transparent; this.cboxLogNMEA.BackgroundImage = global::AgIO.Properties.Resources.LogNMEA; @@ -912,7 +949,7 @@ private void InitializeComponent() this.cboxLogNMEA.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.cboxLogNMEA.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.cboxLogNMEA.ForeColor = System.Drawing.SystemColors.ControlText; - this.cboxLogNMEA.Location = new System.Drawing.Point(520, 399); + this.cboxLogNMEA.Location = new System.Drawing.Point(562, 415); this.cboxLogNMEA.Name = "cboxLogNMEA"; this.cboxLogNMEA.RightToLeft = System.Windows.Forms.RightToLeft.Yes; this.cboxLogNMEA.Size = new System.Drawing.Size(63, 58); @@ -932,7 +969,7 @@ private void InitializeComponent() this.btnExit.ForeColor = System.Drawing.Color.White; this.btnExit.Image = global::AgIO.Properties.Resources.SwitchOff; this.btnExit.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnExit.Location = new System.Drawing.Point(3, 399); + this.btnExit.Location = new System.Drawing.Point(3, 415); this.btnExit.Margin = new System.Windows.Forms.Padding(4); this.btnExit.Name = "btnExit"; this.btnExit.Size = new System.Drawing.Size(63, 58); @@ -951,7 +988,7 @@ private void InitializeComponent() this.btnRunAOG.ForeColor = System.Drawing.Color.White; this.btnRunAOG.Image = global::AgIO.Properties.Resources.AgIOBtn; this.btnRunAOG.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnRunAOG.Location = new System.Drawing.Point(338, 399); + this.btnRunAOG.Location = new System.Drawing.Point(338, 415); this.btnRunAOG.Margin = new System.Windows.Forms.Padding(4); this.btnRunAOG.Name = "btnRunAOG"; this.btnRunAOG.Size = new System.Drawing.Size(63, 58); @@ -959,102 +996,6 @@ private void InitializeComponent() this.btnRunAOG.UseVisualStyleBackColor = false; this.btnRunAOG.Click += new System.EventHandler(this.btnRunAOG_Click); // - // toolStripDropDownButton1 - // - this.toolStripDropDownButton1.AutoSize = false; - this.toolStripDropDownButton1.BackColor = System.Drawing.Color.Transparent; - this.toolStripDropDownButton1.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; - this.toolStripDropDownButton1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.toolStripMenuItem1, - this.toolStripMenuItem2, - this.toolStripMenuItem4, - this.deviceManagerToolStripMenuItem}); - this.toolStripDropDownButton1.Image = global::AgIO.Properties.Resources.Settings48; - this.toolStripDropDownButton1.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; - this.toolStripDropDownButton1.ImageTransparentColor = System.Drawing.Color.Magenta; - this.toolStripDropDownButton1.Name = "toolStripDropDownButton1"; - this.toolStripDropDownButton1.ShowDropDownArrow = false; - this.toolStripDropDownButton1.Size = new System.Drawing.Size(96, 68); - // - // toolStripMenuItem1 - // - this.toolStripMenuItem1.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.toolStripMenuItem1.Image = global::AgIO.Properties.Resources.VehFileSave; - this.toolStripMenuItem1.Name = "toolStripMenuItem1"; - this.toolStripMenuItem1.Size = new System.Drawing.Size(296, 70); - this.toolStripMenuItem1.Text = "Save"; - this.toolStripMenuItem1.Click += new System.EventHandler(this.toolStripMenuItem1_Click); - // - // toolStripMenuItem2 - // - this.toolStripMenuItem2.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.toolStripMenuItem2.Image = global::AgIO.Properties.Resources.VehFileLoad; - this.toolStripMenuItem2.Name = "toolStripMenuItem2"; - this.toolStripMenuItem2.Size = new System.Drawing.Size(296, 70); - this.toolStripMenuItem2.Text = "Load"; - this.toolStripMenuItem2.Click += new System.EventHandler(this.toolStripMenuItem2_Click); - // - // toolStripMenuItem4 - // - this.toolStripMenuItem4.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.toolStripMenuItem4.Image = global::AgIO.Properties.Resources.satellite; - this.toolStripMenuItem4.Name = "toolStripMenuItem4"; - this.toolStripMenuItem4.Size = new System.Drawing.Size(296, 70); - this.toolStripMenuItem4.Text = "GPS Data"; - this.toolStripMenuItem4.Click += new System.EventHandler(this.toolStripMenuItem4_Click); - // - // deviceManagerToolStripMenuItem - // - this.deviceManagerToolStripMenuItem.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.deviceManagerToolStripMenuItem.Image = global::AgIO.Properties.Resources.DeviceManager; - this.deviceManagerToolStripMenuItem.Name = "deviceManagerToolStripMenuItem"; - this.deviceManagerToolStripMenuItem.Size = new System.Drawing.Size(296, 70); - this.deviceManagerToolStripMenuItem.Text = "Device Manager"; - this.deviceManagerToolStripMenuItem.Click += new System.EventHandler(this.deviceManagerToolStripMenuItem_Click); - // - // settingsMenuStrip - // - this.settingsMenuStrip.AutoSize = false; - this.settingsMenuStrip.BackColor = System.Drawing.Color.Transparent; - this.settingsMenuStrip.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; - this.settingsMenuStrip.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.saveToolStrip, - this.loadToolStrip, - this.serialPassThroughToolStripMenuItem}); - this.settingsMenuStrip.Image = global::AgIO.Properties.Resources.NtripSettings; - this.settingsMenuStrip.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; - this.settingsMenuStrip.ImageTransparentColor = System.Drawing.Color.Magenta; - this.settingsMenuStrip.Name = "settingsMenuStrip"; - this.settingsMenuStrip.ShowDropDownArrow = false; - this.settingsMenuStrip.Size = new System.Drawing.Size(96, 68); - // - // saveToolStrip - // - this.saveToolStrip.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.saveToolStrip.Image = global::AgIO.Properties.Resources.NTRIP_Client; - this.saveToolStrip.Name = "saveToolStrip"; - this.saveToolStrip.Size = new System.Drawing.Size(285, 70); - this.saveToolStrip.Text = "Client NTRIP"; - this.saveToolStrip.Click += new System.EventHandler(this.btnNTRIP_Click); - // - // loadToolStrip - // - this.loadToolStrip.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.loadToolStrip.Image = global::AgIO.Properties.Resources.RadioSettings; - this.loadToolStrip.Name = "loadToolStrip"; - this.loadToolStrip.Size = new System.Drawing.Size(285, 70); - this.loadToolStrip.Text = "Radio NTRIP"; - this.loadToolStrip.Click += new System.EventHandler(this.btnRadio_Click_1); - // - // serialPassThroughToolStripMenuItem - // - this.serialPassThroughToolStripMenuItem.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.serialPassThroughToolStripMenuItem.Image = global::AgIO.Properties.Resources.NTRIP_Serial; - this.serialPassThroughToolStripMenuItem.Name = "serialPassThroughToolStripMenuItem"; - this.serialPassThroughToolStripMenuItem.Size = new System.Drawing.Size(285, 70); - this.serialPassThroughToolStripMenuItem.Text = "Serial NTRIP"; - this.serialPassThroughToolStripMenuItem.Click += new System.EventHandler(this.serialPassThroughToolStripMenuItem_Click); - // // btnRelayTest // this.btnRelayTest.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); @@ -1067,7 +1008,7 @@ private void InitializeComponent() this.btnRelayTest.Image = global::AgIO.Properties.Resources.TestRelays; this.btnRelayTest.ImageAlign = System.Drawing.ContentAlignment.TopCenter; this.btnRelayTest.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnRelayTest.Location = new System.Drawing.Point(487, 293); + this.btnRelayTest.Location = new System.Drawing.Point(510, 311); this.btnRelayTest.Margin = new System.Windows.Forms.Padding(4); this.btnRelayTest.Name = "btnRelayTest"; this.btnRelayTest.Size = new System.Drawing.Size(61, 73); @@ -1077,21 +1018,83 @@ private void InitializeComponent() this.btnRelayTest.UseVisualStyleBackColor = false; this.btnRelayTest.Click += new System.EventHandler(this.btnRelayTest_Click); // + // btnGPSData + // + this.btnGPSData.BackColor = System.Drawing.Color.Transparent; + this.btnGPSData.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnGPSData.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnGPSData.FlatAppearance.BorderSize = 0; + this.btnGPSData.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnGPSData.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnGPSData.ForeColor = System.Drawing.Color.Black; + this.btnGPSData.Image = global::AgIO.Properties.Resources.Nmea; + this.btnGPSData.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnGPSData.Location = new System.Drawing.Point(129, 6); + this.btnGPSData.Margin = new System.Windows.Forms.Padding(4); + this.btnGPSData.Name = "btnGPSData"; + this.btnGPSData.Size = new System.Drawing.Size(56, 49); + this.btnGPSData.TabIndex = 513; + this.btnGPSData.UseVisualStyleBackColor = false; + this.btnGPSData.Click += new System.EventHandler(this.btnGPSData_Click); + // + // btnUDP + // + this.btnUDP.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.btnUDP.BackColor = System.Drawing.Color.Gainsboro; + this.btnUDP.BackgroundImage = global::AgIO.Properties.Resources.B_UDP; + this.btnUDP.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnUDP.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnUDP.FlatAppearance.BorderSize = 0; + this.btnUDP.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnUDP.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnUDP.ForeColor = System.Drawing.Color.White; + this.btnUDP.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnUDP.Location = new System.Drawing.Point(18, 309); + this.btnUDP.Margin = new System.Windows.Forms.Padding(4); + this.btnUDP.Name = "btnUDP"; + this.btnUDP.Size = new System.Drawing.Size(107, 73); + this.btnUDP.TabIndex = 184; + this.btnUDP.UseVisualStyleBackColor = false; + this.btnUDP.Click += new System.EventHandler(this.btnUDP_Click); + // + // btnHelp + // + this.btnHelp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnHelp.FlatAppearance.BorderSize = 0; + this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnHelp.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnHelp.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnHelp.Image = global::AgIO.Properties.Resources.Help; + this.btnHelp.Location = new System.Drawing.Point(251, 6); + this.btnHelp.Name = "btnHelp"; + this.btnHelp.Size = new System.Drawing.Size(56, 49); + this.btnHelp.TabIndex = 522; + this.btnHelp.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnHelp.UseVisualStyleBackColor = true; + this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click); + // + // toolStripSerialMonitor + // + this.toolStripSerialMonitor.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.toolStripSerialMonitor.Image = global::AgIO.Properties.Resources.NTRIP_Serial; + this.toolStripSerialMonitor.Name = "toolStripSerialMonitor"; + this.toolStripSerialMonitor.Size = new System.Drawing.Size(311, 70); + this.toolStripSerialMonitor.Text = "Serial Monitor"; + this.toolStripSerialMonitor.Click += new System.EventHandler(this.toolStripSerialMonitor_Click); + // // FormLoop // this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 18F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.BackColor = System.Drawing.Color.Gainsboro; this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.ClientSize = new System.Drawing.Size(682, 459); - this.Controls.Add(this.lblToGPS); + this.ClientSize = new System.Drawing.Size(734, 475); + this.Controls.Add(this.btnHelp); this.Controls.Add(this.label7); this.Controls.Add(this.lblSkipCounter); this.Controls.Add(this.lblCount); this.Controls.Add(this.lblStationID); this.Controls.Add(this.label13); - this.Controls.Add(this.lblPacketSize); - this.Controls.Add(this.label11); this.Controls.Add(this.btnResetTimer); this.Controls.Add(this.lbl9To16); this.Controls.Add(this.lbl1To8); @@ -1122,9 +1125,7 @@ private void InitializeComponent() this.Controls.Add(this.label3); this.Controls.Add(this.btnSlide); this.Controls.Add(this.pictureBox1); - this.Controls.Add(this.btnUDP); this.Controls.Add(this.label8); - this.Controls.Add(this.lblIP); this.Controls.Add(this.cboxLogNMEA); this.Controls.Add(this.lblGPS1Comm); this.Controls.Add(this.lblMod2Comm); @@ -1133,7 +1134,6 @@ private void InitializeComponent() this.Controls.Add(this.lblIMUComm); this.Controls.Add(this.lblMessages); this.Controls.Add(this.label5); - this.Controls.Add(this.lblFromGPS); this.Controls.Add(this.btnExit); this.Controls.Add(this.btnRunAOG); this.Controls.Add(this.statusStrip1); @@ -1141,6 +1141,10 @@ private void InitializeComponent() this.Controls.Add(this.lblCurentLon); this.Controls.Add(this.lblCurrentLat); this.Controls.Add(this.btnRelayTest); + this.Controls.Add(this.btnUDP); + this.Controls.Add(this.lblIP); + this.Controls.Add(this.lblToGPS); + this.Controls.Add(this.lblFromGPS); this.Controls.Add(this.btnGPSData); this.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; @@ -1183,10 +1187,6 @@ private void InitializeComponent() private System.Windows.Forms.ToolStripMenuItem loadToolStrip; private System.Windows.Forms.StatusStrip statusStrip1; private System.Windows.Forms.Button btnUDP; - private System.Windows.Forms.Button btnIMU; - private System.Windows.Forms.Button btnGPS; - private System.Windows.Forms.Button btnMachine; - private System.Windows.Forms.Button btnSteer; private System.Windows.Forms.Button btnRunAOG; private System.Windows.Forms.Button btnExit; private System.Windows.Forms.CheckBox cboxLogNMEA; @@ -1217,8 +1217,6 @@ private void InitializeComponent() private System.Windows.Forms.Label lbl9To16; private System.Windows.Forms.Label label12; private System.Windows.Forms.Button btnResetTimer; - private System.Windows.Forms.Label lblPacketSize; - private System.Windows.Forms.Label label11; private System.Windows.Forms.Label lblStationID; private System.Windows.Forms.Label label13; private System.Windows.Forms.ToolStripMenuItem serialPassThroughToolStripMenuItem; @@ -1228,6 +1226,13 @@ private void InitializeComponent() private System.Windows.Forms.Label label7; private System.Windows.Forms.Label lblToGPS; private System.Windows.Forms.Button btnGPSData; + public System.Windows.Forms.Button btnIMU; + public System.Windows.Forms.Button btnGPS; + public System.Windows.Forms.Button btnMachine; + public System.Windows.Forms.Button btnSteer; + private System.Windows.Forms.ToolStripMenuItem toolStripEthernet; + private System.Windows.Forms.Button btnHelp; + private System.Windows.Forms.ToolStripMenuItem toolStripSerialMonitor; } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index 61542f088..d7717239d 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -35,6 +35,8 @@ public partial class FormLoop : Form //Stringbuilder public StringBuilder logNMEASentence = new StringBuilder(); + public StringBuilder logMonitorSentence = new StringBuilder(); + private StringBuilder sbRTCM = new StringBuilder(); public bool isKeyboardOn = true; @@ -58,7 +60,7 @@ public partial class FormLoop : Form //is the fly out displayed public bool isViewAdvanced = false; - public bool isLogNMEA; + public bool isLogNMEA, isLogMonitorOn; //used to hide the window and not update text fields and most counters public bool isAppInFocus = true, isLostFocus; @@ -306,6 +308,8 @@ private void oneSecondLoopTimer_Tick(object sender, EventArgs e) return; } + //to check if new data for subnet + secondsSinceStart = (DateTime.Now - Process.GetCurrentProcess().StartTime).TotalSeconds; //Hello Alarm logic @@ -324,7 +328,7 @@ private void oneSecondLoopTimer_Tick(object sender, EventArgs e) //send a hello to modules SendUDPMessage(helloFromAgIO, epModule); - helloFromAgIO[7] = 0; + //helloFromAgIO[7] = 0; #region Sleep @@ -416,6 +420,17 @@ private void TenSecondLoop() if (focusSkipCounter != 0) { + //update connections + lblIP.Text = ""; + foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + { + if (IPA.AddressFamily == AddressFamily.InterNetwork) + { + _ = IPA.ToString(); + lblIP.Text += IPA.ToString() + "\r\n"; + } + } + if (isViewAdvanced && isNTRIP_RequiredOn) { try @@ -512,7 +527,7 @@ private void btnSlide_Click(object sender, EventArgs e) { if (this.Width < 600) { - this.Width = 700; + this.Width = 750; isViewAdvanced = true; btnSlide.BackgroundImage = Properties.Resources.ArrowGrnLeft; sbRTCM.Clear(); @@ -649,7 +664,7 @@ private void DoTraffic() if (focusSkipCounter != 0) { - lblFromGPS.Text = traffic.cntrGPSOut == 0 ? "--" : (traffic.cntrGPSOut).ToString(); + lblFromGPS.Text = traffic.cntrGPSOut == 0 ? "---" : (traffic.cntrGPSOut).ToString(); //reset all counters traffic.cntrGPSOut = 0; @@ -758,7 +773,6 @@ private void toolStripMenuItem4_Click(object sender, EventArgs e) private void lblIP_Click(object sender, EventArgs e) { lblIP.Text = ""; - foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) { if (IPA.AddressFamily == AddressFamily.InterNetwork) @@ -810,6 +824,16 @@ private void btnGPSData_Click(object sender, EventArgs e) form.Show(this); } + private void toolStripEthernet_Click(object sender, EventArgs e) + { + SettingsEthernet(); + } + + private void btnHelp_Click(object sender, EventArgs e) + { + System.Diagnostics.Process.Start(gStr.gsAgIOHelp); + } + private void lblNTRIPBytes_Click(object sender, EventArgs e) { tripBytes = 0; @@ -829,7 +853,8 @@ private void btnBringUpCommSettings_Click(object sender, EventArgs e) private void btnUDP_Click(object sender, EventArgs e) { - SettingsUDP(); + if (!Settings.Default.setUDP_isOn) SettingsEthernet(); + else SettingsUDP(); } private void btnRunAOG_Click(object sender, EventArgs e) diff --git a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs index 7164d7882..130b29357 100644 --- a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs @@ -80,8 +80,9 @@ private void InitializeComponent() this.comboboxPacketSize = new System.Windows.Forms.ComboBox(); this.labelRtcmPort = new System.Windows.Forms.Label(); this.cboxIsNTRIPOn = new System.Windows.Forms.CheckBox(); - this.btnSerialCancel = new System.Windows.Forms.Button(); this.btnSerialOK = new System.Windows.Forms.Button(); + this.btnSerialCancel = new System.Windows.Forms.Button(); + this.btnHelp = new System.Windows.Forms.Button(); ((System.ComponentModel.ISupportInitialize)(this.nudCasterPort)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSendToUDPPort)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudGGAInterval)).BeginInit(); @@ -96,7 +97,7 @@ private void InitializeComponent() // tboxCasterIP // this.tboxCasterIP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxCasterIP.Location = new System.Drawing.Point(83, 458); + this.tboxCasterIP.Location = new System.Drawing.Point(92, 446); this.tboxCasterIP.Name = "tboxCasterIP"; this.tboxCasterIP.ReadOnly = true; this.tboxCasterIP.Size = new System.Drawing.Size(170, 33); @@ -109,7 +110,7 @@ private void InitializeComponent() // this.nudCasterPort.BackColor = System.Drawing.Color.AliceBlue; this.nudCasterPort.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudCasterPort.Location = new System.Drawing.Point(494, 427); + this.nudCasterPort.Location = new System.Drawing.Point(494, 411); this.nudCasterPort.Maximum = new decimal(new int[] { 65535, 0, @@ -135,7 +136,7 @@ private void InitializeComponent() // this.label5.AutoSize = true; this.label5.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label5.Location = new System.Drawing.Point(41, 461); + this.label5.Location = new System.Drawing.Point(50, 449); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(39, 25); this.label5.TabIndex = 82; @@ -310,11 +311,11 @@ private void InitializeComponent() // this.btnGetIP.BackColor = System.Drawing.SystemColors.MenuBar; this.btnGetIP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnGetIP.Location = new System.Drawing.Point(83, 387); + this.btnGetIP.Location = new System.Drawing.Point(100, 377); this.btnGetIP.Name = "btnGetIP"; this.btnGetIP.Size = new System.Drawing.Size(157, 40); this.btnGetIP.TabIndex = 109; - this.btnGetIP.Text = "Confirm IP"; + this.btnGetIP.Text = "Verify URL"; this.btnGetIP.UseVisualStyleBackColor = false; this.btnGetIP.Click += new System.EventHandler(this.btnGetIP_Click); // @@ -621,7 +622,7 @@ private void InitializeComponent() // this.label6.AutoSize = true; this.label6.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label6.Location = new System.Drawing.Point(489, 470); + this.label6.Location = new System.Drawing.Point(489, 454); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(123, 23); this.label6.TabIndex = 146; @@ -631,7 +632,7 @@ private void InitializeComponent() // this.label7.AutoSize = true; this.label7.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label7.Location = new System.Drawing.Point(494, 395); + this.label7.Location = new System.Drawing.Point(494, 379); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(123, 25); this.label7.TabIndex = 145; @@ -784,21 +785,6 @@ private void InitializeComponent() this.cboxIsNTRIPOn.UseVisualStyleBackColor = false; this.cboxIsNTRIPOn.Click += new System.EventHandler(this.cboxIsNTRIPOn_Click); // - // btnSerialCancel - // - this.btnSerialCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.btnSerialCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSerialCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.btnSerialCancel.FlatAppearance.BorderSize = 0; - this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnSerialCancel.Image = global::AgIO.Properties.Resources.Cancel64; - this.btnSerialCancel.Location = new System.Drawing.Point(529, 581); - this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(105, 64); - this.btnSerialCancel.TabIndex = 95; - this.btnSerialCancel.UseVisualStyleBackColor = true; - // // btnSerialOK // this.btnSerialOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); @@ -817,6 +803,37 @@ private void InitializeComponent() this.btnSerialOK.UseVisualStyleBackColor = true; this.btnSerialOK.Click += new System.EventHandler(this.btnSerialOK_Click); // + // btnSerialCancel + // + this.btnSerialCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnSerialCancel.FlatAppearance.BorderSize = 0; + this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.Cancel64; + this.btnSerialCancel.Location = new System.Drawing.Point(529, 581); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(105, 64); + this.btnSerialCancel.TabIndex = 95; + this.btnSerialCancel.UseVisualStyleBackColor = true; + // + // btnHelp + // + this.btnHelp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnHelp.FlatAppearance.BorderSize = 0; + this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnHelp.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnHelp.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnHelp.Image = global::AgIO.Properties.Resources.Help; + this.btnHelp.Location = new System.Drawing.Point(162, 577); + this.btnHelp.Name = "btnHelp"; + this.btnHelp.Size = new System.Drawing.Size(76, 65); + this.btnHelp.TabIndex = 533; + this.btnHelp.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnHelp.UseVisualStyleBackColor = true; + this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click); + // // FormNtrip // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); @@ -824,6 +841,7 @@ private void InitializeComponent() this.BackColor = System.Drawing.Color.WhiteSmoke; this.ClientSize = new System.Drawing.Size(767, 648); this.ControlBox = false; + this.Controls.Add(this.btnHelp); this.Controls.Add(this.tabControl1); this.Controls.Add(this.cboxIsNTRIPOn); this.Controls.Add(this.btnSerialCancel); @@ -862,7 +880,6 @@ private void InitializeComponent() private System.Windows.Forms.Label label14; private System.Windows.Forms.NumericUpDown nudSendToUDPPort; private System.Windows.Forms.Label label10; - private System.Windows.Forms.Button btnSerialCancel; private System.Windows.Forms.Button btnSerialOK; private System.Windows.Forms.TextBox tboxUserName; private System.Windows.Forms.TextBox tboxUserPassword; @@ -906,5 +923,7 @@ private void InitializeComponent() private System.Windows.Forms.Label labelRtcmPort; private System.Windows.Forms.Label label6; private System.Windows.Forms.Label label7; + private System.Windows.Forms.Button btnSerialCancel; + private System.Windows.Forms.Button btnHelp; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormNtrip.cs b/SourceCode/AgIO/Source/Forms/FormNtrip.cs index fa109f506..e8f0dc398 100644 --- a/SourceCode/AgIO/Source/Forms/FormNtrip.cs +++ b/SourceCode/AgIO/Source/Forms/FormNtrip.cs @@ -54,6 +54,9 @@ public FormNtrip(Form callingForm) private void FormNtrip_Load(object sender, EventArgs e) { + cboxIsNTRIPOn.Checked = Properties.Settings.Default.setNTRIP_isOn; + + if (!cboxIsNTRIPOn.Checked) tabControl1.Enabled = false; string hostName = Dns.GetHostName(); // Retrieve the Name of HOST tboxHostName.Text = hostName; @@ -62,14 +65,13 @@ private void FormNtrip_Load(object sender, EventArgs e) cboxToSerial.Checked = Properties.Settings.Default.setNTRIP_sendToSerial; cboxToUDP.Checked = Properties.Settings.Default.setNTRIP_sendToUDP; + nudSendToUDPPort.Value = Properties.Settings.Default.setNTRIP_sendToUDPPort; tboxEnterURL.Text = Properties.Settings.Default.setNTRIP_casterURL; tboxCasterIP.Text = Properties.Settings.Default.setNTRIP_casterIP; nudCasterPort.Value = Properties.Settings.Default.setNTRIP_casterPort; - nudSendToUDPPort.Value = Properties.Settings.Default.setNTRIP_sendToUDPPort; - cboxIsNTRIPOn.Checked = Properties.Settings.Default.setNTRIP_isOn; tboxUserName.Text = Properties.Settings.Default.setNTRIP_userName; tboxUserPassword.Text = Properties.Settings.Default.setNTRIP_userPassword; @@ -95,7 +97,20 @@ private void FormNtrip_Load(object sender, EventArgs e) private void cboxIsNTRIPOn_Click(object sender, EventArgs e) { - ntripStatusChanged = true; + Properties.Settings.Default.setNTRIP_isOn = cboxIsNTRIPOn.Checked; + + if (cboxIsNTRIPOn.Checked) + { + Properties.Settings.Default.setRadio_isOn = mf.isRadio_RequiredOn = false; + Properties.Settings.Default.setPass_isOn = mf.isSerialPass_RequiredOn = false; + } + + Properties.Settings.Default.Save(); + + mf.YesMessageBox("Restart of AgIO is Required - Restarting"); + + Application.Restart(); + Environment.Exit(0); } //get the ipv4 address only @@ -128,15 +143,17 @@ private void btnGetIP_Click(object sender, EventArgs e) tboxCasterIP.Text = addr.ToString().Trim(); } } + mf.TimedMessageBox(2500, "IP Located", "Verified: " + actualIP); + } else { - mf.TimedMessageBox(2500, "No IP Located", "Can't Find: " + actualIP); + mf.YesMessageBox("Can't Find: " + actualIP); } } catch (Exception) { - mf.TimedMessageBox(1500, "No IP Located", "Can't Find: " + actualIP); + mf.YesMessageBox("Can't Find: " + actualIP); } } @@ -371,6 +388,7 @@ private void tboxEnterURL_Click(object sender, EventArgs e) mf.KeyboardToText((TextBox)sender, this); btnSerialCancel.Focus(); } + btnGetIP.PerformClick(); } private void tboxMount_Click(object sender, EventArgs e) @@ -425,5 +443,10 @@ private void cboxToSerial_Click(object sender, EventArgs e) ntripStatusChanged = true; if (cboxToUDP.Checked) cboxToUDP.Checked = false; } + + private void btnHelp_Click(object sender, EventArgs e) + { + System.Diagnostics.Process.Start(gStr.gsNTRIP_Help); + } } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs new file mode 100644 index 000000000..48a878fc4 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs @@ -0,0 +1,259 @@ +using System; +using System.ComponentModel; +using System.Diagnostics; +using System.Drawing; +using System.IO; +using System.IO.Ports; +using System.Linq; +using System.Net; +using System.Net.NetworkInformation; +using System.Net.Sockets; +using System.Windows.Forms; + +namespace AgIO +{ + public partial class FormSerialMonitor : Form + { + //class variables + private readonly FormLoop mf = null; + + public static string portName = "***"; + public static int baudRate = 115200; + + public string recvSentence = "GPS"; + public SerialPort sp = new SerialPort(portName, baudRate, Parity.None, 8, StopBits.One); + + private bool logOn = false; + + public FormSerialMonitor(Form callingForm) + { + //get copy of the calling main form + mf = callingForm as FormLoop; + InitializeComponent(); + } + + private void FormUDp_Load(object sender, EventArgs e) + { + cboxPort.Items.Clear(); + foreach (string s in System.IO.Ports.SerialPort.GetPortNames()) + { + cboxPort.Items.Add(s); + } + } + + #region IMUSerialPort //-------------------------------------------------------------------- + private void ReceivePort(string sentence) + { + textBoxRcv.AppendText(sentence); + } + + //Send machine info out to machine board + public void SendPort(byte[] items, int numItems) + { + //Tell Arduino to turn section on or off accordingly + //if (sp.IsOpen) + //{ + // try + // { + // sp.Write(items, 0, numItems); + // } + // catch (Exception) + // { + // ClosePort(); + // } + //} + } + + //open the Arduino serial port + public void OpenPort() + { + if (!sp.IsOpen) + { + sp.PortName = portName; + sp.BaudRate = baudRate; + sp.DataReceived += sp_DataReceived; + sp.DtrEnable = true; + sp.RtsEnable = true; + } + + try { sp.Open(); } + catch (Exception e) + { + //WriteErrorLog("Opening Machine Port" + e.ToString()); + + //MessageBox.Show(e.Message + "\n\r" + "\n\r" + "Go to Settings -> COM Ports to Fix", "No Arduino Port Active"); + + + //Properties.Settings.Default.setPort_wasConnected = false; + //Properties.Settings.Default.Save(); + //wasConnectedLastRun = false; + } + + if (sp.IsOpen) + { + //short delay for the use of mega2560, it is working in debugmode with breakpoint + System.Threading.Thread.Sleep(500); // 500 was not enough + + sp.DiscardOutBuffer(); + sp.DiscardInBuffer(); + } + } + + //close the machine port + public void ClosePort() + { + if (sp.IsOpen) + { + sp.DataReceived -= sp_DataReceived; + try + { + sp.Close(); + } + + catch (Exception e) + { + //WriteErrorLog("Closing Machine Serial Port" + e.ToString()); + MessageBox.Show(e.Message, "Connection already terminated??"); + } + + sp.Dispose(); + } + } + + private void sp_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e) + { + if (sp.IsOpen) + { + try + { + string sentence = sp.ReadExisting(); + BeginInvoke((MethodInvoker)(() => ReceivePort(sentence))); + } + catch (Exception) + { + } + } + } + #endregion ---------------------------------------------------------------- + + + private void btnSerialCancel_Click(object sender, EventArgs e) + { + mf.isLogMonitorOn = false; + Close(); + } + + private void btnHelp_Click(object sender, EventArgs e) + { + //System.Diagnostics.Process.Start(gStr.gsEthernetHelp); + } + + private void cboxPort_SelectedIndexChanged(object sender, EventArgs e) + { + sp.PortName = cboxPort.Text; + portName = cboxPort.Text; + } + + private void cboxBaud_SelectedIndexChanged(object sender, EventArgs e) + { + sp.BaudRate = Convert.ToInt32(cboxBaud.Text); + baudRate = Convert.ToInt32(cboxBaud.Text); + } + + private void btnOpenSerial_Click(object sender, EventArgs e) + { + OpenPort(); + if (sp.IsOpen) + { + cboxBaud.Enabled = false; + cboxPort.Enabled = false; + btnCloseSerial.Enabled = true; + btnOpenSerial.Enabled = false; + lblCurrentBaud.Text = sp.BaudRate.ToString(); + lblCurrentPort.Text = sp.PortName; + } + else + { + cboxBaud.Enabled = true; + cboxPort.Enabled = true; + btnCloseSerial.Enabled = false; + btnOpenSerial.Enabled = true; + MessageBox.Show("Unable to connect to Port"); + } + + } + + private void btnRescan_Click(object sender, EventArgs e) + { + cboxPort.Items.Clear(); + + foreach (string s in System.IO.Ports.SerialPort.GetPortNames()) + { + cboxPort.Items.Add(s); + } + } + + private void btnCloseSerial_Click(object sender, EventArgs e) + { + ClosePort(); + if (sp.IsOpen) + { + cboxBaud.Enabled = false; + cboxPort.Enabled = false; + btnCloseSerial.Enabled = true; + btnOpenSerial.Enabled = false; + } + else + { + cboxBaud.Enabled = true; + cboxPort.Enabled = true; + btnCloseSerial.Enabled = false; + btnOpenSerial.Enabled = true; + } + + } + + private void btnLog_Click(object sender, EventArgs e) + { + logOn = !logOn; + if (logOn) + { + btnLog.BackColor = Color.LightGreen; + mf.isLogMonitorOn = true; + timer1.Enabled = true; + } + else + { + btnLog.BackColor = Color.Transparent; + mf.isLogMonitorOn = false; + timer1.Enabled = false; + } + } + + private void timer1_Tick(object sender, EventArgs e) + { + textBoxRcv.AppendText(mf.logMonitorSentence.ToString()); + mf.logMonitorSentence.Clear(); + } + + private void btnFileSave_Click(object sender, EventArgs e) + { + using (StreamWriter writer = new StreamWriter("zAgIO_SerialMon_log.txt", false)) + { + writer.Write(textBoxRcv.Text); + } + + mf.TimedMessageBox(2000, "File Saved", "To zAgIO_SerialMon_Log.Txt"); + } + + private void FormSerialMonitor_FormClosing(object sender, FormClosingEventArgs e) + { + mf.isLogMonitorOn=false; + } + + private void btnClear_Click(object sender, EventArgs e) + { + textBoxRcv.Text = ""; + } + } +} diff --git a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs new file mode 100644 index 000000000..0bdf795ac --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs @@ -0,0 +1,297 @@ +namespace AgIO +{ + partial class FormSerialMonitor + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormSerialMonitor)); + this.btnSerialCancel = new System.Windows.Forms.Button(); + this.cboxPort = new System.Windows.Forms.ComboBox(); + this.cboxBaud = new System.Windows.Forms.ComboBox(); + this.lblCurrentPort = new System.Windows.Forms.Label(); + this.lblCurrentBaud = new System.Windows.Forms.Label(); + this.btnCloseSerial = new System.Windows.Forms.Button(); + this.btnOpenSerial = new System.Windows.Forms.Button(); + this.textBoxRcv = new System.Windows.Forms.TextBox(); + this.btnRescan = new System.Windows.Forms.Button(); + this.btnLog = new System.Windows.Forms.Button(); + this.timer1 = new System.Windows.Forms.Timer(this.components); + this.btnFileSave = new System.Windows.Forms.Button(); + this.btnClear = new System.Windows.Forms.Button(); + this.btnHelp = new System.Windows.Forms.Button(); + this.SuspendLayout(); + // + // btnSerialCancel + // + this.btnSerialCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnSerialCancel.FlatAppearance.BorderSize = 0; + this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.OK64; + this.btnSerialCancel.Location = new System.Drawing.Point(462, 300); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(65, 54); + this.btnSerialCancel.TabIndex = 71; + this.btnSerialCancel.UseVisualStyleBackColor = true; + this.btnSerialCancel.Click += new System.EventHandler(this.btnSerialCancel_Click); + // + // cboxPort + // + this.cboxPort.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.cboxPort.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.cboxPort.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); + this.cboxPort.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.cboxPort.FormattingEnabled = true; + this.cboxPort.Location = new System.Drawing.Point(96, 24); + this.cboxPort.Name = "cboxPort"; + this.cboxPort.Size = new System.Drawing.Size(124, 37); + this.cboxPort.TabIndex = 538; + this.cboxPort.SelectedIndexChanged += new System.EventHandler(this.cboxPort_SelectedIndexChanged); + // + // cboxBaud + // + this.cboxBaud.BackColor = System.Drawing.SystemColors.ControlLightLight; + this.cboxBaud.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.cboxBaud.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); + this.cboxBaud.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.cboxBaud.FormattingEnabled = true; + this.cboxBaud.Items.AddRange(new object[] { + "4800", + "9600", + "19200", + "38400", + "57600", + "115200"}); + this.cboxBaud.Location = new System.Drawing.Point(236, 24); + this.cboxBaud.Name = "cboxBaud"; + this.cboxBaud.Size = new System.Drawing.Size(127, 37); + this.cboxBaud.TabIndex = 537; + this.cboxBaud.SelectedIndexChanged += new System.EventHandler(this.cboxBaud_SelectedIndexChanged); + // + // lblCurrentPort + // + this.lblCurrentPort.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblCurrentPort.Location = new System.Drawing.Point(96, 3); + this.lblCurrentPort.Name = "lblCurrentPort"; + this.lblCurrentPort.Size = new System.Drawing.Size(121, 18); + this.lblCurrentPort.TabIndex = 536; + this.lblCurrentPort.Text = "Port"; + this.lblCurrentPort.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblCurrentBaud + // + this.lblCurrentBaud.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblCurrentBaud.Location = new System.Drawing.Point(236, 3); + this.lblCurrentBaud.Name = "lblCurrentBaud"; + this.lblCurrentBaud.Size = new System.Drawing.Size(124, 18); + this.lblCurrentBaud.TabIndex = 535; + this.lblCurrentBaud.Text = "Baud"; + this.lblCurrentBaud.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // btnCloseSerial + // + this.btnCloseSerial.BackColor = System.Drawing.Color.Transparent; + this.btnCloseSerial.Enabled = false; + this.btnCloseSerial.FlatAppearance.BorderSize = 0; + this.btnCloseSerial.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCloseSerial.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnCloseSerial.Image = ((System.Drawing.Image)(resources.GetObject("btnCloseSerial.Image"))); + this.btnCloseSerial.Location = new System.Drawing.Point(467, 6); + this.btnCloseSerial.Name = "btnCloseSerial"; + this.btnCloseSerial.Size = new System.Drawing.Size(56, 58); + this.btnCloseSerial.TabIndex = 533; + this.btnCloseSerial.UseVisualStyleBackColor = false; + this.btnCloseSerial.Click += new System.EventHandler(this.btnCloseSerial_Click); + // + // btnOpenSerial + // + this.btnOpenSerial.BackColor = System.Drawing.Color.Transparent; + this.btnOpenSerial.FlatAppearance.BorderSize = 0; + this.btnOpenSerial.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnOpenSerial.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnOpenSerial.Image = ((System.Drawing.Image)(resources.GetObject("btnOpenSerial.Image"))); + this.btnOpenSerial.Location = new System.Drawing.Point(380, 6); + this.btnOpenSerial.Name = "btnOpenSerial"; + this.btnOpenSerial.Size = new System.Drawing.Size(58, 58); + this.btnOpenSerial.TabIndex = 534; + this.btnOpenSerial.UseVisualStyleBackColor = false; + this.btnOpenSerial.Click += new System.EventHandler(this.btnOpenSerial_Click); + // + // textBoxRcv + // + this.textBoxRcv.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left) + | System.Windows.Forms.AnchorStyles.Right))); + this.textBoxRcv.BackColor = System.Drawing.SystemColors.Window; + this.textBoxRcv.Font = new System.Drawing.Font("Tahoma", 9.75F); + this.textBoxRcv.Location = new System.Drawing.Point(12, 69); + this.textBoxRcv.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.textBoxRcv.Multiline = true; + this.textBoxRcv.Name = "textBoxRcv"; + this.textBoxRcv.ReadOnly = true; + this.textBoxRcv.ScrollBars = System.Windows.Forms.ScrollBars.Both; + this.textBoxRcv.Size = new System.Drawing.Size(521, 219); + this.textBoxRcv.TabIndex = 539; + // + // btnRescan + // + this.btnRescan.BackColor = System.Drawing.Color.Transparent; + this.btnRescan.FlatAppearance.BorderSize = 0; + this.btnRescan.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnRescan.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnRescan.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnRescan.Image = global::AgIO.Properties.Resources.ScanPorts; + this.btnRescan.Location = new System.Drawing.Point(3, 3); + this.btnRescan.Name = "btnRescan"; + this.btnRescan.Size = new System.Drawing.Size(61, 63); + this.btnRescan.TabIndex = 540; + this.btnRescan.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; + this.btnRescan.UseVisualStyleBackColor = false; + this.btnRescan.Click += new System.EventHandler(this.btnRescan_Click); + // + // btnLog + // + this.btnLog.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnLog.BackColor = System.Drawing.Color.Transparent; + this.btnLog.FlatAppearance.BorderSize = 0; + this.btnLog.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnLog.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnLog.Image = global::AgIO.Properties.Resources.LogNMEA; + this.btnLog.Location = new System.Drawing.Point(363, 300); + this.btnLog.Name = "btnLog"; + this.btnLog.Size = new System.Drawing.Size(65, 54); + this.btnLog.TabIndex = 541; + this.btnLog.UseVisualStyleBackColor = false; + this.btnLog.Click += new System.EventHandler(this.btnLog_Click); + // + // timer1 + // + this.timer1.Interval = 333; + this.timer1.Tick += new System.EventHandler(this.timer1_Tick); + // + // btnFileSave + // + this.btnFileSave.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnFileSave.BackColor = System.Drawing.Color.Transparent; + this.btnFileSave.FlatAppearance.BorderSize = 0; + this.btnFileSave.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnFileSave.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnFileSave.Image = global::AgIO.Properties.Resources.VehFileSave; + this.btnFileSave.Location = new System.Drawing.Point(269, 300); + this.btnFileSave.Name = "btnFileSave"; + this.btnFileSave.Size = new System.Drawing.Size(65, 54); + this.btnFileSave.TabIndex = 542; + this.btnFileSave.UseVisualStyleBackColor = false; + this.btnFileSave.Click += new System.EventHandler(this.btnFileSave_Click); + // + // btnClear + // + this.btnClear.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnClear.BackColor = System.Drawing.Color.Transparent; + this.btnClear.FlatAppearance.BorderSize = 0; + this.btnClear.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnClear.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnClear.Image = global::AgIO.Properties.Resources.Trash; + this.btnClear.Location = new System.Drawing.Point(175, 300); + this.btnClear.Name = "btnClear"; + this.btnClear.Size = new System.Drawing.Size(65, 54); + this.btnClear.TabIndex = 543; + this.btnClear.UseVisualStyleBackColor = false; + this.btnClear.Click += new System.EventHandler(this.btnClear_Click); + // + // btnHelp + // + this.btnHelp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnHelp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnHelp.FlatAppearance.BorderSize = 0; + this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnHelp.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnHelp.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnHelp.Image = global::AgIO.Properties.Resources.Help; + this.btnHelp.Location = new System.Drawing.Point(34, 300); + this.btnHelp.Name = "btnHelp"; + this.btnHelp.Size = new System.Drawing.Size(65, 54); + this.btnHelp.TabIndex = 544; + this.btnHelp.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnHelp.UseVisualStyleBackColor = true; + this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click); + // + // FormSerialMonitor + // + this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.White; + this.ClientSize = new System.Drawing.Size(539, 361); + this.ControlBox = false; + this.Controls.Add(this.btnHelp); + this.Controls.Add(this.btnClear); + this.Controls.Add(this.btnFileSave); + this.Controls.Add(this.btnLog); + this.Controls.Add(this.btnRescan); + this.Controls.Add(this.textBoxRcv); + this.Controls.Add(this.cboxPort); + this.Controls.Add(this.cboxBaud); + this.Controls.Add(this.lblCurrentPort); + this.Controls.Add(this.lblCurrentBaud); + this.Controls.Add(this.btnCloseSerial); + this.Controls.Add(this.btnOpenSerial); + this.Controls.Add(this.btnSerialCancel); + this.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow; + this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "FormSerialMonitor"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "Serial Monitor - Baud: Teensy - 115200 Arduino - 38400"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormSerialMonitor_FormClosing); + this.Load += new System.EventHandler(this.FormUDp_Load); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + private System.Windows.Forms.Button btnSerialCancel; + private System.Windows.Forms.ComboBox cboxPort; + private System.Windows.Forms.ComboBox cboxBaud; + private System.Windows.Forms.Label lblCurrentPort; + private System.Windows.Forms.Label lblCurrentBaud; + private System.Windows.Forms.Button btnCloseSerial; + private System.Windows.Forms.Button btnOpenSerial; + private System.Windows.Forms.TextBox textBoxRcv; + private System.Windows.Forms.Button btnRescan; + private System.Windows.Forms.Button btnLog; + private System.Windows.Forms.Timer timer1; + private System.Windows.Forms.Button btnFileSave; + private System.Windows.Forms.Button btnClear; + private System.Windows.Forms.Button btnHelp; + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.resx b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.resx new file mode 100644 index 000000000..ea9705a46 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.resx @@ -0,0 +1,179 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + + iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m + dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAUOSURBVHhe7Zovbx1HFMX9AQLMS4yLjItMwwwLzUqN + io1KjYpNwg3yASIFFFSqrICAgsqKVFBQyQGRAgJezm8yd3R33t3n3fd212tljnS0s7uzM/feuX9m972j + hoaGhoaGhoaGGfH26MWJeCFei2/Ee3FTkWvcow99T/LjzxNS4Fi8FO9EFLwVr8Qz8TR3K+BavkcfDMEz + PMsYx7nb+oGwIko8iChykW+NQh4HT2AMxmLMdRsiC2yKd1wY4cVz0VY4Ivfo01FU53gH9xl7L4POCgQW + cXHi+Cxf9qtoYTCGPMOzxRhqEyLMwVzr8AYJwupsCaW2hUGk3Bgm98/D1sbeyiWLAgHEWkAzSKTMIewo + rLYZ+GmMwMRZgBKTapOxI+Gn5GWejvks5yxrBE2IG7IifuVvxEjgOXiTp2VePAFZlssJmowYvM2nSytv + 9EboyDMrNBFuVyyu4xJu38cUDjqaR85bIvNExFwqdTqSByLBBvP9+c+b/29fbz5c/RbeH8AU/zpSIpFt + vlDQ4GkTk08536e+F/51+tPG493Zy7DfI7zL4iBP2kzl02mhgW310w5Px4Nc/4/jHzZfHj5m1b8Bg0R9 + B9BCwSrT9F7AJKJffSaKhBnET3fvstrfQBhE/QbyIYuFXHhBKZWTQYOmrWlukwgjQZIb/33xS+fav9e/ + pxX35x6f7z907u9JL1sJi0mgAXmf3+RTs/KWEN6t/7t5lc5JboDrZhwPrve5/p8nP6ZnOEb3Kybv1JFQ + 5Xy67wkaDKumOusm2CIKf3zzNqu22XJzUF+rvcWIUcyYHKM+Aa00sy+YriRqML7SpOyqI6+r0eSFtYvX + wOVRin7R8xiyNlTUL+B5lpFqdU17EmgwXN5qP4NHk3dIfbcVjIAR+lyfhOiBV0X9AtoisScoCftgaLDy + JqYj7hVNvkUUjMLAgIEwlH/GcoaBPiMSpIVpeiOlPQkYPDdphwmwjwhPQtwFCwUSXo2RewNfpovMB8MP + xiR5sp1Ecb9ydfavgZvX3vLP5a+dMQdwPQYw9/crSJvY7wPubkbAa/x4A7keA0AUquMcr/ClMgL3R8S9 + 52wG2CsJ+nJYl7w62dWwjZR/ZgBnS4KjyyCMyplXiqSHh/RhRPkzzlYGR22EjJGro7DPC2xz+0plXSIH + cLaNEFvhZFEde7fCNXcpV2f4ulT27RIfoW2F8dhJt8LpZchNMDgP1GHgwb26VPqQGPmVqH5XmfbHVQ04 + 6HXY87FEB6JS6b2mNtIOzvc6DPLAvsxQGSJBEolfDxSxfYDlAULEK29EYe85GKTuU7FkfLVx/1k+iOBa + fAWycrjTC7wro8AeJS3lCUC1iO472urP90kMaODBH0UNddYfywEfQ5b5KAo0uHnBo5/FCQHK4B6lbCyX + +ywONAGu738YGZQQZ6K5Pgsz/w8jBk3U+SlK7e/npzGgycziJd7UZrcYCToHyy5PbfJS8cjFoAkt4xa3 + oy1GAk/Jer5SmRYHE2cBvCdw7aCfzHrImEVRtVn5p1PegAAiLkgcFjdU25JlpMwYdpKb2oQfc3H9aZU3 + VEKVP0kBnWMI7kXK7SLPdLK6ztf3JykPBBZxSzYkndVBYBEFcF2qBn08ucY9+nSU0zleRp9OzlklEF60 + +ERojDJ6tXgmP2uKM+b6Vr0PCCvyi7IlRBSxFd6KXa7le/ShL8/wLGM8H8UjSIHv78/SDQ0NDQ0NDQ3r + xtHRV12hQda7PTJxAAAAAElFTkSuQmCC + + + + + iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m + dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAATGSURBVHhe7ZqxjtQwEIbvEXgECkSNED3wAAh6KK5E + VFdBQ0EBHRISiBIdDSVQUZ0EHYIGuiuhQbQnKsrl/4zHcryzu/FukgvCv/QrdmKPx+OZsZPdvYaGhoaG + hoaGhhFx7v75s+K++ET8IH4XFwW5xzPa0PZs7P5vQhM4Ix6IX0Um+FZ8IF4RL8RmCdyLz2iDIehDX2Sc + ic3mD5QVmcSJyET246MqRDl4AjKQhcx5GyIqbBPvuDDKizdEW2GPPKNNZ6Kq4x08R/ZWBh0VKCzi4sTx + lXg7X0ULgxrSh77JGCoTIozBWPPwBinC6iwppbKFgTe5Ggb3j2JLYy/lkkmBAmKpoBnEm8wu7ExYZTPw + 6RiBgaMCKSZVJmN7yg/Jgzgc41nOmdYIGhA3ZEXylT8UPYXH4GEclnHxBHSZLidoMGLwbaxOPXljboSO + PqNCA+F2yeK6TuH2qxjCQVfzyHG3yDgQMRe2Ol3JA55ivXn71Z3F0fHR4un7Z+7zHgzxrytbJLqNFwoS + Hg4xsUp9m/098drz64scN1/ccttt4NeoDvqEw1SsDgsJttUPJzxdd3L9iw8vLX79/hWn/hcYxGvbgxYK + tjMN7wUMIuarz0CeMr14/PM4TvsvCAOvXU+eRLXQCy9IW+VgkNBwNI1lEqGniMvDjy/Diuf1HD9OfnSe + b8lctxQWg0ACeZ9fxKpZ2VNiiSQ3gLsT43df3wt1A/dXuf7lx1dDH67e84LBO3UlVKkP9z1BwrBq2Gez + ATYSxUuUro9BvL4YxXIEV6+NQ9uaORcMtyVKGF9pQnbVlddVb/Alvv7yJkygBC7PpAgFrx/hUBrKa+fw + RtSR3eoJ5UEgYbi87f0I9wZfoq2gB4ywyvVJiDk+ffvstnNoi8SZICXsnSFh6U1MV9zLG7xDz/1LYCAO + Qnk/yxkG2lQkSAvT8EZKeRAgPBYp90qAJK++sFDw+lSeDfJtOum8M3JhDBIHW8saAwDcvIz7h+8eubLX + cD4GYOVqgbubEUigntwNnI8B4LokuA54w5YHo9EMUJ0EYXniqwEesIURRkuCW22D5XZWi4rtzzjaNrjV + QYgJ7IJyi+zB0Q5CHIWDRXWtOgqXmb0vVh2RN9COwnjsoEfh8DKUDdA7D9SGASdEtlBP1gaW7yrD/rgq + gdWvw+Wpbh3wFPb9HV6Lx3sdBlFwvs2wM3iKBBK/OfAEzgb2IkSZEKk86a1iyvgq4/6jfBCxT2K2Ha71 + gvwMwOrusLJ9aKs/3icxIMG9P4oabLW9NgNxmo+iQMLNCzZ+FicE2Aa32MpqOd1ncaABcP38h5FeCXEk + muuzMOP/MGLQQJ2folT+f34aAxrMLJ7iTWVOi56iYzCd8lQmLyWPnAwa0DJucjvKoqfwkCzHSzvT5GDg + qEDuCdzb6SezFURmmqjKrPzpTd6AAiIuSBwmN1TZkqU3mRp2kpvKhB9jcf90J28olEp/kgKqYwieeZNb + R/p0srrq8/uTVA4UFnFLDiSd1UFhkQnguuwatMnJPZ7RpjM51fEy2nRyziyB8qLFJ0pjlOrVok/saxNH + 5vxWfRVQVuQXZUuITMRWeCl2uRef0Ya29KEvMv6diXvQBP6/P0s3NDQ0NDQ0NMwbe3t/ADGMPFxvAWeD + AAAAAElFTkSuQmCC + + + + 17, 17 + + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormTimedMessage.Designer.cs b/SourceCode/AgIO/Source/Forms/FormTimedMessage.Designer.cs index 80af7414b..e08361cd4 100644 --- a/SourceCode/AgIO/Source/Forms/FormTimedMessage.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormTimedMessage.Designer.cs @@ -29,20 +29,20 @@ protected override void Dispose(bool disposing) private void InitializeComponent() { this.components = new System.ComponentModel.Container(); - this.lblMessage = new System.Windows.Forms.Label(); + this.lblTitle = new System.Windows.Forms.Label(); this.timer1 = new System.Windows.Forms.Timer(this.components); this.lblMessage2 = new System.Windows.Forms.Label(); this.SuspendLayout(); // // lblMessage // - this.lblMessage.AutoSize = true; - this.lblMessage.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); - this.lblMessage.Location = new System.Drawing.Point(12, 20); - this.lblMessage.Name = "lblMessage"; - this.lblMessage.Size = new System.Drawing.Size(115, 29); - this.lblMessage.TabIndex = 0; - this.lblMessage.Text = "Message"; + this.lblTitle.AutoSize = true; + this.lblTitle.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); + this.lblTitle.Location = new System.Drawing.Point(12, 20); + this.lblTitle.Name = "lblMessage"; + this.lblTitle.Size = new System.Drawing.Size(115, 29); + this.lblTitle.TabIndex = 0; + this.lblTitle.Text = "Message"; // // timer1 // @@ -64,17 +64,19 @@ private void InitializeComponent() // this.AutoScaleDimensions = new System.Drawing.SizeF(10F, 23F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.LightSalmon; this.ClientSize = new System.Drawing.Size(272, 151); this.ControlBox = false; this.Controls.Add(this.lblMessage2); - this.Controls.Add(this.lblMessage); + this.Controls.Add(this.lblTitle); this.Font = new System.Drawing.Font("Tahoma", 14.25F); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; this.Margin = new System.Windows.Forms.Padding(6); this.Name = "FormTimedMessage"; + this.ShowIcon = false; this.ShowInTaskbar = false; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; - this.Text = "Drive Message"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "AgIO Message"; this.TopMost = true; this.ResumeLayout(false); this.PerformLayout(); @@ -83,7 +85,7 @@ private void InitializeComponent() #endregion - private System.Windows.Forms.Label lblMessage; + private System.Windows.Forms.Label lblTitle; private System.Windows.Forms.Timer timer1; private System.Windows.Forms.Label lblMessage2; } diff --git a/SourceCode/AgIO/Source/Forms/FormTimedMessage.cs b/SourceCode/AgIO/Source/Forms/FormTimedMessage.cs index 295ee481b..e1d0b94a6 100644 --- a/SourceCode/AgIO/Source/Forms/FormTimedMessage.cs +++ b/SourceCode/AgIO/Source/Forms/FormTimedMessage.cs @@ -5,16 +5,16 @@ namespace AgIO { public partial class FormTimedMessage : Form { - public FormTimedMessage(int timeInMsec, string str, string str2) + public FormTimedMessage(int timeInMsec, string titleStr, string messageStr) { InitializeComponent(); - lblMessage.Text = str; - lblMessage2.Text = str2; + lblTitle.Text = titleStr; + lblMessage2.Text = messageStr; - timer1.Interval = timeInMsec; + timer1.Interval = timeInMsec; - int messWidth = str2.Length; + int messWidth = messageStr.Length; Width = messWidth * 15 + 120; } diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 9edef25ff..e861a1516 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -29,222 +29,112 @@ protected override void Dispose(bool disposing) private void InitializeComponent() { this.components = new System.ComponentModel.Container(); - this.groupBox4 = new System.Windows.Forms.GroupBox(); - this.label9 = new System.Windows.Forms.Label(); this.label6 = new System.Windows.Forms.Label(); this.lblNetworkHelp = new System.Windows.Forms.Label(); - this.label12 = new System.Windows.Forms.Label(); - this.tboxHostName = new System.Windows.Forms.TextBox(); - this.cboxIsUDPOn = new System.Windows.Forms.CheckBox(); - this.groupBox3 = new System.Windows.Forms.GroupBox(); - this.cboxIsSendNMEAToUDP = new System.Windows.Forms.CheckBox(); - this.groupBox5 = new System.Windows.Forms.GroupBox(); - this.cboxPlugin = new System.Windows.Forms.CheckBox(); this.timer1 = new System.Windows.Forms.Timer(this.components); this.label1 = new System.Windows.Forms.Label(); this.nudFirstIP = new System.Windows.Forms.NumericUpDown(); - this.nudSecondIP = new System.Windows.Forms.NumericUpDown(); + this.nudSecndIP = new System.Windows.Forms.NumericUpDown(); this.nudThirdIP = new System.Windows.Forms.NumericUpDown(); this.label2 = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label(); + this.label8 = new System.Windows.Forms.Label(); + this.label7 = new System.Windows.Forms.Label(); + this.tboxNets = new System.Windows.Forms.TextBox(); this.label4 = new System.Windows.Forms.Label(); + this.lblHostname = new System.Windows.Forms.Label(); + this.lblNoAdapter = new System.Windows.Forms.Label(); + this.cboxUp = new System.Windows.Forms.CheckBox(); this.label5 = new System.Windows.Forms.Label(); - this.groupBox1 = new System.Windows.Forms.GroupBox(); - this.label8 = new System.Windows.Forms.Label(); - this.lblConnectedModules = new System.Windows.Forms.Label(); + this.label9 = new System.Windows.Forms.Label(); + this.lblSubTimer = new System.Windows.Forms.Label(); + this.label11 = new System.Windows.Forms.Label(); + this.label13 = new System.Windows.Forms.Label(); + this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); + this.lblBtnIMU = new System.Windows.Forms.Label(); + this.lblBtnGPS = new System.Windows.Forms.Label(); + this.label18 = new System.Windows.Forms.Label(); + this.lblIMU_IP = new System.Windows.Forms.Label(); + this.lblBtnMachine = new System.Windows.Forms.Label(); + this.label15 = new System.Windows.Forms.Label(); + this.lblGPSIP = new System.Windows.Forms.Label(); + this.lblSteerIP = new System.Windows.Forms.Label(); + this.lblBtnSteer = new System.Windows.Forms.Label(); + this.label16 = new System.Windows.Forms.Label(); + this.lblMachineIP = new System.Windows.Forms.Label(); + this.label17 = new System.Windows.Forms.Label(); + this.lblNewSubnet = new System.Windows.Forms.Label(); + this.btnHelp = new System.Windows.Forms.Button(); + this.btnNetworkCPL = new System.Windows.Forms.Button(); + this.btnAutoSet = new System.Windows.Forms.Button(); this.btnSendSubnet = new System.Windows.Forms.Button(); this.btnSerialCancel = new System.Windows.Forms.Button(); - this.btnSerialOK = new System.Windows.Forms.Button(); - this.label7 = new System.Windows.Forms.Label(); + this.pboxSendSteer = new System.Windows.Forms.PictureBox(); + this.btnSerialMonitor = new System.Windows.Forms.Button(); this.label10 = new System.Windows.Forms.Label(); - this.groupBox4.SuspendLayout(); - this.groupBox3.SuspendLayout(); - this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudSecondIP)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); - this.groupBox1.SuspendLayout(); + this.tableLayoutPanel1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).BeginInit(); this.SuspendLayout(); // - // groupBox4 - // - this.groupBox4.Controls.Add(this.label9); - this.groupBox4.Controls.Add(this.label6); - this.groupBox4.Controls.Add(this.lblNetworkHelp); - this.groupBox4.Controls.Add(this.label12); - this.groupBox4.Controls.Add(this.tboxHostName); - this.groupBox4.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.groupBox4.Location = new System.Drawing.Point(14, 12); - this.groupBox4.Name = "groupBox4"; - this.groupBox4.Size = new System.Drawing.Size(355, 291); - this.groupBox4.TabIndex = 72; - this.groupBox4.TabStop = false; - this.groupBox4.Text = "This Computer"; - // - // label9 - // - this.label9.AutoSize = true; - this.label9.BackColor = System.Drawing.SystemColors.ButtonHighlight; - this.label9.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.label9.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label9.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.label9.Location = new System.Drawing.Point(35, 101); - this.label9.Name = "label9"; - this.label9.Size = new System.Drawing.Size(47, 31); - this.label9.TabIndex = 161; - this.label9.Text = "...."; - this.label9.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // // label6 // this.label6.AutoSize = true; this.label6.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label6.Location = new System.Drawing.Point(63, 207); + this.label6.Location = new System.Drawing.Point(485, 543); this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(220, 23); + this.label6.Size = new System.Drawing.Size(139, 23); this.label6.TabIndex = 144; - this.label6.Text = "Current Network Address"; + this.label6.Text = "Current Subnet"; this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblNetworkHelp // this.lblNetworkHelp.BackColor = System.Drawing.SystemColors.ButtonHighlight; this.lblNetworkHelp.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.lblNetworkHelp.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblNetworkHelp.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.lblNetworkHelp.Location = new System.Drawing.Point(62, 233); + this.lblNetworkHelp.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblNetworkHelp.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.lblNetworkHelp.Location = new System.Drawing.Point(408, 493); this.lblNetworkHelp.Name = "lblNetworkHelp"; - this.lblNetworkHelp.Size = new System.Drawing.Size(221, 46); + this.lblNetworkHelp.Size = new System.Drawing.Size(279, 46); this.lblNetworkHelp.TabIndex = 143; - this.lblNetworkHelp.Text = "192.168.1.x"; + this.lblNetworkHelp.Text = "192 . 168 . 123 . x"; this.lblNetworkHelp.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // label12 - // - this.label12.AutoSize = true; - this.label12.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label12.Location = new System.Drawing.Point(31, 78); - this.label12.Name = "label12"; - this.label12.Size = new System.Drawing.Size(182, 23); - this.label12.TabIndex = 142; - this.label12.Text = "Connected Networks"; - this.label12.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // tboxHostName - // - this.tboxHostName.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxHostName.Location = new System.Drawing.Point(27, 33); - this.tboxHostName.Name = "tboxHostName"; - this.tboxHostName.ReadOnly = true; - this.tboxHostName.Size = new System.Drawing.Size(221, 30); - this.tboxHostName.TabIndex = 86; - this.tboxHostName.Text = "HostName"; - // - // cboxIsUDPOn - // - this.cboxIsUDPOn.Appearance = System.Windows.Forms.Appearance.Button; - this.cboxIsUDPOn.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; - this.cboxIsUDPOn.Checked = true; - this.cboxIsUDPOn.CheckState = System.Windows.Forms.CheckState.Checked; - this.cboxIsUDPOn.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; - this.cboxIsUDPOn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.cboxIsUDPOn.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.cboxIsUDPOn.Location = new System.Drawing.Point(66, 31); - this.cboxIsUDPOn.Name = "cboxIsUDPOn"; - this.cboxIsUDPOn.Size = new System.Drawing.Size(145, 50); - this.cboxIsUDPOn.TabIndex = 92; - this.cboxIsUDPOn.Text = "UDP On"; - this.cboxIsUDPOn.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.cboxIsUDPOn.UseVisualStyleBackColor = true; - // - // groupBox3 - // - this.groupBox3.Controls.Add(this.cboxIsSendNMEAToUDP); - this.groupBox3.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.groupBox3.Location = new System.Drawing.Point(638, 24); - this.groupBox3.Name = "groupBox3"; - this.groupBox3.Size = new System.Drawing.Size(227, 100); - this.groupBox3.TabIndex = 94; - this.groupBox3.TabStop = false; - this.groupBox3.Text = "Send NMEA to Network"; - // - // cboxIsSendNMEAToUDP - // - this.cboxIsSendNMEAToUDP.Appearance = System.Windows.Forms.Appearance.Button; - this.cboxIsSendNMEAToUDP.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; - this.cboxIsSendNMEAToUDP.Checked = true; - this.cboxIsSendNMEAToUDP.CheckState = System.Windows.Forms.CheckState.Checked; - this.cboxIsSendNMEAToUDP.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; - this.cboxIsSendNMEAToUDP.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.cboxIsSendNMEAToUDP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.cboxIsSendNMEAToUDP.Location = new System.Drawing.Point(85, 37); - this.cboxIsSendNMEAToUDP.Name = "cboxIsSendNMEAToUDP"; - this.cboxIsSendNMEAToUDP.Size = new System.Drawing.Size(126, 35); - this.cboxIsSendNMEAToUDP.TabIndex = 92; - this.cboxIsSendNMEAToUDP.Text = "NMEA"; - this.cboxIsSendNMEAToUDP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.cboxIsSendNMEAToUDP.UseVisualStyleBackColor = true; - // - // groupBox5 - // - this.groupBox5.Controls.Add(this.cboxPlugin); - this.groupBox5.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.groupBox5.Location = new System.Drawing.Point(638, 134); - this.groupBox5.Name = "groupBox5"; - this.groupBox5.Size = new System.Drawing.Size(227, 100); - this.groupBox5.TabIndex = 95; - this.groupBox5.TabStop = false; - this.groupBox5.Text = "Application Plugin"; - // - // cboxPlugin - // - this.cboxPlugin.Appearance = System.Windows.Forms.Appearance.Button; - this.cboxPlugin.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.cboxPlugin.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; - this.cboxPlugin.Checked = true; - this.cboxPlugin.CheckState = System.Windows.Forms.CheckState.Checked; - this.cboxPlugin.FlatAppearance.CheckedBackColor = System.Drawing.Color.PaleGreen; - this.cboxPlugin.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.cboxPlugin.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.cboxPlugin.Location = new System.Drawing.Point(85, 38); - this.cboxPlugin.Name = "cboxPlugin"; - this.cboxPlugin.Size = new System.Drawing.Size(126, 35); - this.cboxPlugin.TabIndex = 92; - this.cboxPlugin.Text = "Rate App"; - this.cboxPlugin.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.cboxPlugin.UseVisualStyleBackColor = true; - // // timer1 // this.timer1.Enabled = true; - this.timer1.Interval = 1200; + this.timer1.Interval = 500; this.timer1.Tick += new System.EventHandler(this.timer1_Tick); // // label1 // this.label1.AutoSize = true; this.label1.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label1.Location = new System.Drawing.Point(55, 306); + this.label1.Location = new System.Drawing.Point(434, 422); this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(212, 23); + this.label1.Size = new System.Drawing.Size(236, 23); this.label1.TabIndex = 147; - this.label1.Text = "Change Subnet Address"; + this.label1.Text = "Enter New Subnet Address"; this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // nudFirstIP // this.nudFirstIP.BackColor = System.Drawing.Color.AliceBlue; this.nudFirstIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudFirstIP.Location = new System.Drawing.Point(14, 335); + this.nudFirstIP.Location = new System.Drawing.Point(372, 378); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, 0, 0}); this.nudFirstIP.Name = "nudFirstIP"; - this.nudFirstIP.Size = new System.Drawing.Size(90, 40); + this.nudFirstIP.Size = new System.Drawing.Size(102, 40); this.nudFirstIP.TabIndex = 148; this.nudFirstIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudFirstIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; this.nudFirstIP.Value = new decimal(new int[] { 192, 0, @@ -252,53 +142,55 @@ private void InitializeComponent() 0}); this.nudFirstIP.Click += new System.EventHandler(this.nudFirstIP_Click); // - // nudSecondIP + // nudSecndIP // - this.nudSecondIP.BackColor = System.Drawing.Color.AliceBlue; - this.nudSecondIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudSecondIP.Location = new System.Drawing.Point(123, 335); - this.nudSecondIP.Maximum = new decimal(new int[] { + this.nudSecndIP.BackColor = System.Drawing.Color.AliceBlue; + this.nudSecndIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.nudSecndIP.Location = new System.Drawing.Point(489, 378); + this.nudSecndIP.Maximum = new decimal(new int[] { 255, 0, 0, 0}); - this.nudSecondIP.Name = "nudSecondIP"; - this.nudSecondIP.Size = new System.Drawing.Size(90, 40); - this.nudSecondIP.TabIndex = 149; - this.nudSecondIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; - this.nudSecondIP.Value = new decimal(new int[] { + this.nudSecndIP.Name = "nudSecndIP"; + this.nudSecndIP.Size = new System.Drawing.Size(102, 40); + this.nudSecndIP.TabIndex = 149; + this.nudSecndIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudSecndIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; + this.nudSecndIP.Value = new decimal(new int[] { 168, 0, 0, 0}); - this.nudSecondIP.Click += new System.EventHandler(this.nudSecondIP_Click); + this.nudSecndIP.Click += new System.EventHandler(this.nudFirstIP_Click); // // nudThirdIP // this.nudThirdIP.BackColor = System.Drawing.Color.AliceBlue; this.nudThirdIP.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudThirdIP.Location = new System.Drawing.Point(231, 335); + this.nudThirdIP.Location = new System.Drawing.Point(606, 378); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, 0, 0}); this.nudThirdIP.Name = "nudThirdIP"; - this.nudThirdIP.Size = new System.Drawing.Size(90, 40); + this.nudThirdIP.Size = new System.Drawing.Size(102, 40); this.nudThirdIP.TabIndex = 150; this.nudThirdIP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.nudThirdIP.UpDownAlign = System.Windows.Forms.LeftRightAlignment.Left; this.nudThirdIP.Value = new decimal(new int[] { 5, 0, 0, 0}); - this.nudThirdIP.Click += new System.EventHandler(this.nudThirdIP_Click); + this.nudThirdIP.Click += new System.EventHandler(this.nudFirstIP_Click); // // label2 // this.label2.AutoSize = true; this.label2.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label2.Location = new System.Drawing.Point(102, 330); + this.label2.Location = new System.Drawing.Point(472, 372); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(24, 35); this.label2.TabIndex = 152; @@ -309,84 +201,407 @@ private void InitializeComponent() // this.label3.AutoSize = true; this.label3.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label3.Location = new System.Drawing.Point(211, 330); + this.label3.Location = new System.Drawing.Point(589, 372); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(24, 35); this.label3.TabIndex = 153; this.label3.Text = "."; this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // + // label8 + // + this.label8.AutoSize = true; + this.label8.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label8.Location = new System.Drawing.Point(783, 421); + this.label8.Name = "label8"; + this.label8.Size = new System.Drawing.Size(37, 23); + this.label8.TabIndex = 157; + this.label8.Text = "Set"; + this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // label7 + // + this.label7.AutoSize = true; + this.label7.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label7.Location = new System.Drawing.Point(337, 20); + this.label7.Name = "label7"; + this.label7.Size = new System.Drawing.Size(118, 23); + this.label7.TabIndex = 161; + this.label7.Text = "Module Scan"; + this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // tboxNets + // + this.tboxNets.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.tboxNets.Location = new System.Drawing.Point(16, 45); + this.tboxNets.Multiline = true; + this.tboxNets.Name = "tboxNets"; + this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; + this.tboxNets.Size = new System.Drawing.Size(261, 468); + this.tboxNets.TabIndex = 162; + // // label4 // this.label4.AutoSize = true; - this.label4.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label4.Location = new System.Drawing.Point(320, 330); + this.label4.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label4.Location = new System.Drawing.Point(14, 13); this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(24, 35); - this.label4.TabIndex = 154; - this.label4.Text = "."; + this.label4.Size = new System.Drawing.Size(101, 23); + this.label4.TabIndex = 163; + this.label4.Text = "Hostname:"; this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // + // lblHostname + // + this.lblHostname.AutoSize = true; + this.lblHostname.BackColor = System.Drawing.Color.White; + this.lblHostname.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblHostname.Location = new System.Drawing.Point(112, 13); + this.lblHostname.Name = "lblHostname"; + this.lblHostname.Size = new System.Drawing.Size(94, 23); + this.lblHostname.TabIndex = 165; + this.lblHostname.Text = "Hostname"; + this.lblHostname.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblNoAdapter + // + this.lblNoAdapter.AutoSize = true; + this.lblNoAdapter.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblNoAdapter.ForeColor = System.Drawing.Color.Red; + this.lblNoAdapter.Location = new System.Drawing.Point(398, 462); + this.lblNoAdapter.Name = "lblNoAdapter"; + this.lblNoAdapter.Size = new System.Drawing.Size(298, 25); + this.lblNoAdapter.TabIndex = 166; + this.lblNoAdapter.Text = "No Adapter For This Subnet"; + this.lblNoAdapter.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // cboxUp + // + this.cboxUp.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxUp.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; + this.cboxUp.Checked = true; + this.cboxUp.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxUp.FlatAppearance.CheckedBackColor = System.Drawing.Color.Transparent; + this.cboxUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxUp.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxUp.Location = new System.Drawing.Point(78, 520); + this.cboxUp.Name = "cboxUp"; + this.cboxUp.Size = new System.Drawing.Size(171, 50); + this.cboxUp.TabIndex = 168; + this.cboxUp.Text = "Up"; + this.cboxUp.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxUp.UseVisualStyleBackColor = true; + this.cboxUp.Click += new System.EventHandler(this.cboxUp_Click); + // // label5 // this.label5.AutoSize = true; - this.label5.BackColor = System.Drawing.SystemColors.Control; - this.label5.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label5.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.label5.Location = new System.Drawing.Point(338, 338); + this.label5.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label5.Location = new System.Drawing.Point(583, 313); this.label5.Name = "label5"; - this.label5.Size = new System.Drawing.Size(35, 35); - this.label5.TabIndex = 155; - this.label5.Text = "X"; + this.label5.Size = new System.Drawing.Size(56, 23); + this.label5.TabIndex = 512; + this.label5.Text = "Fill In"; this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // groupBox1 - // - this.groupBox1.Controls.Add(this.cboxIsUDPOn); - this.groupBox1.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.groupBox1.Location = new System.Drawing.Point(638, 275); - this.groupBox1.Name = "groupBox1"; - this.groupBox1.Size = new System.Drawing.Size(227, 100); - this.groupBox1.TabIndex = 96; - this.groupBox1.TabStop = false; - this.groupBox1.Text = "UDP Network"; - // - // label8 - // - this.label8.AutoSize = true; - this.label8.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label8.Location = new System.Drawing.Point(26, 418); - this.label8.Name = "label8"; - this.label8.Size = new System.Drawing.Size(119, 23); - this.label8.TabIndex = 157; - this.label8.Text = "Send Subnet"; - this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // lblConnectedModules + // label9 // - this.lblConnectedModules.AutoSize = true; - this.lblConnectedModules.BackColor = System.Drawing.SystemColors.ButtonHighlight; - this.lblConnectedModules.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.lblConnectedModules.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblConnectedModules.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.lblConnectedModules.Location = new System.Drawing.Point(405, 72); - this.lblConnectedModules.Name = "lblConnectedModules"; - this.lblConnectedModules.Size = new System.Drawing.Size(197, 27); - this.lblConnectedModules.TabIndex = 160; - this.lblConnectedModules.Text = "Scan For Modules"; - this.lblConnectedModules.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.label9.AutoSize = true; + this.label9.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label9.Location = new System.Drawing.Point(18, 534); + this.label9.Name = "label9"; + this.label9.Size = new System.Drawing.Size(51, 23); + this.label9.TabIndex = 513; + this.label9.Text = "Filter"; + this.label9.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // lblSubTimer + // + this.lblSubTimer.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblSubTimer.Location = new System.Drawing.Point(362, 314); + this.lblSubTimer.Name = "lblSubTimer"; + this.lblSubTimer.Size = new System.Drawing.Size(100, 23); + this.lblSubTimer.TabIndex = 514; + this.lblSubTimer.Text = "Scanning"; + this.lblSubTimer.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label11 + // + this.label11.AutoSize = true; + this.label11.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label11.Location = new System.Drawing.Point(502, 20); + this.label11.Name = "label11"; + this.label11.Size = new System.Drawing.Size(99, 23); + this.label11.TabIndex = 516; + this.label11.Text = "IP Address"; + this.label11.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label13 + // + this.label13.AutoSize = true; + this.label13.BackColor = System.Drawing.Color.White; + this.label13.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label13.Location = new System.Drawing.Point(362, 249); + this.label13.Name = "label13"; + this.label13.Size = new System.Drawing.Size(70, 23); + this.label13.TabIndex = 518; + this.label13.Text = "Subnet"; + this.label13.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // tableLayoutPanel1 + // + this.tableLayoutPanel1.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single; + this.tableLayoutPanel1.ColumnCount = 3; + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 95F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 26F)); + this.tableLayoutPanel1.Controls.Add(this.lblBtnIMU, 2, 0); + this.tableLayoutPanel1.Controls.Add(this.lblBtnGPS, 2, 2); + this.tableLayoutPanel1.Controls.Add(this.label18, 0, 0); + this.tableLayoutPanel1.Controls.Add(this.lblIMU_IP, 1, 0); + this.tableLayoutPanel1.Controls.Add(this.lblBtnMachine, 2, 3); + this.tableLayoutPanel1.Controls.Add(this.label15, 0, 1); + this.tableLayoutPanel1.Controls.Add(this.lblGPSIP, 1, 2); + this.tableLayoutPanel1.Controls.Add(this.lblSteerIP, 1, 1); + this.tableLayoutPanel1.Controls.Add(this.lblBtnSteer, 2, 1); + this.tableLayoutPanel1.Controls.Add(this.label16, 0, 3); + this.tableLayoutPanel1.Controls.Add(this.lblMachineIP, 1, 3); + this.tableLayoutPanel1.Controls.Add(this.label17, 0, 2); + this.tableLayoutPanel1.Location = new System.Drawing.Point(341, 45); + this.tableLayoutPanel1.Name = "tableLayoutPanel1"; + this.tableLayoutPanel1.RowCount = 4; + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); + this.tableLayoutPanel1.Size = new System.Drawing.Size(341, 177); + this.tableLayoutPanel1.TabIndex = 519; + // + // lblBtnIMU + // + this.lblBtnIMU.AutoSize = true; + this.lblBtnIMU.BackColor = System.Drawing.Color.White; + this.lblBtnIMU.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblBtnIMU.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblBtnIMU.Location = new System.Drawing.Point(317, 1); + this.lblBtnIMU.Name = "lblBtnIMU"; + this.lblBtnIMU.Size = new System.Drawing.Size(20, 43); + this.lblBtnIMU.TabIndex = 533; + this.lblBtnIMU.Text = "-"; + this.lblBtnIMU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblBtnGPS + // + this.lblBtnGPS.AutoSize = true; + this.lblBtnGPS.BackColor = System.Drawing.Color.White; + this.lblBtnGPS.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblBtnGPS.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblBtnGPS.Location = new System.Drawing.Point(317, 89); + this.lblBtnGPS.Name = "lblBtnGPS"; + this.lblBtnGPS.Size = new System.Drawing.Size(20, 43); + this.lblBtnGPS.TabIndex = 532; + this.lblBtnGPS.Text = "-"; + this.lblBtnGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label18 + // + this.label18.AutoSize = true; + this.label18.BackColor = System.Drawing.Color.White; + this.label18.Dock = System.Windows.Forms.DockStyle.Fill; + this.label18.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label18.Location = new System.Drawing.Point(4, 1); + this.label18.Name = "label18"; + this.label18.Size = new System.Drawing.Size(89, 43); + this.label18.TabIndex = 524; + this.label18.Text = "IMU"; + this.label18.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblIMU_IP + // + this.lblIMU_IP.AutoSize = true; + this.lblIMU_IP.BackColor = System.Drawing.Color.White; + this.lblIMU_IP.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblIMU_IP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblIMU_IP.Location = new System.Drawing.Point(100, 1); + this.lblIMU_IP.Name = "lblIMU_IP"; + this.lblIMU_IP.Size = new System.Drawing.Size(210, 43); + this.lblIMU_IP.TabIndex = 526; + this.lblIMU_IP.Text = ".."; + this.lblIMU_IP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblBtnMachine + // + this.lblBtnMachine.AutoSize = true; + this.lblBtnMachine.BackColor = System.Drawing.Color.White; + this.lblBtnMachine.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblBtnMachine.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblBtnMachine.Location = new System.Drawing.Point(317, 133); + this.lblBtnMachine.Name = "lblBtnMachine"; + this.lblBtnMachine.Size = new System.Drawing.Size(20, 43); + this.lblBtnMachine.TabIndex = 531; + this.lblBtnMachine.Text = "-"; + this.lblBtnMachine.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label15 + // + this.label15.AutoSize = true; + this.label15.BackColor = System.Drawing.Color.White; + this.label15.Dock = System.Windows.Forms.DockStyle.Fill; + this.label15.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label15.Location = new System.Drawing.Point(4, 45); + this.label15.Name = "label15"; + this.label15.Size = new System.Drawing.Size(89, 43); + this.label15.TabIndex = 521; + this.label15.Text = "Steer"; + this.label15.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblGPSIP + // + this.lblGPSIP.AutoSize = true; + this.lblGPSIP.BackColor = System.Drawing.Color.White; + this.lblGPSIP.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblGPSIP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblGPSIP.Location = new System.Drawing.Point(100, 89); + this.lblGPSIP.Name = "lblGPSIP"; + this.lblGPSIP.Size = new System.Drawing.Size(210, 43); + this.lblGPSIP.TabIndex = 530; + this.lblGPSIP.Text = ".."; + this.lblGPSIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblSteerIP + // + this.lblSteerIP.AutoSize = true; + this.lblSteerIP.BackColor = System.Drawing.Color.White; + this.lblSteerIP.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblSteerIP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblSteerIP.Location = new System.Drawing.Point(100, 45); + this.lblSteerIP.Name = "lblSteerIP"; + this.lblSteerIP.Size = new System.Drawing.Size(210, 43); + this.lblSteerIP.TabIndex = 526; + this.lblSteerIP.Text = ".."; + this.lblSteerIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblBtnSteer + // + this.lblBtnSteer.AutoSize = true; + this.lblBtnSteer.BackColor = System.Drawing.Color.White; + this.lblBtnSteer.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblBtnSteer.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblBtnSteer.Location = new System.Drawing.Point(317, 45); + this.lblBtnSteer.Name = "lblBtnSteer"; + this.lblBtnSteer.Size = new System.Drawing.Size(20, 43); + this.lblBtnSteer.TabIndex = 521; + this.lblBtnSteer.Text = "-"; + this.lblBtnSteer.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label16 + // + this.label16.AutoSize = true; + this.label16.BackColor = System.Drawing.Color.White; + this.label16.Dock = System.Windows.Forms.DockStyle.Fill; + this.label16.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label16.Location = new System.Drawing.Point(4, 133); + this.label16.Name = "label16"; + this.label16.Size = new System.Drawing.Size(89, 43); + this.label16.TabIndex = 522; + this.label16.Text = "Machine"; + this.label16.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblMachineIP + // + this.lblMachineIP.AutoSize = true; + this.lblMachineIP.BackColor = System.Drawing.Color.White; + this.lblMachineIP.Dock = System.Windows.Forms.DockStyle.Fill; + this.lblMachineIP.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblMachineIP.Location = new System.Drawing.Point(100, 133); + this.lblMachineIP.Name = "lblMachineIP"; + this.lblMachineIP.Size = new System.Drawing.Size(210, 43); + this.lblMachineIP.TabIndex = 528; + this.lblMachineIP.Text = ".."; + this.lblMachineIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label17 + // + this.label17.AutoSize = true; + this.label17.BackColor = System.Drawing.Color.White; + this.label17.Dock = System.Windows.Forms.DockStyle.Fill; + this.label17.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label17.Location = new System.Drawing.Point(4, 89); + this.label17.Name = "label17"; + this.label17.Size = new System.Drawing.Size(89, 43); + this.label17.TabIndex = 523; + this.label17.Text = "GPS"; + this.label17.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblNewSubnet + // + this.lblNewSubnet.BackColor = System.Drawing.SystemColors.ButtonHighlight; + this.lblNewSubnet.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.lblNewSubnet.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblNewSubnet.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.lblNewSubnet.Location = new System.Drawing.Point(438, 235); + this.lblNewSubnet.Name = "lblNewSubnet"; + this.lblNewSubnet.Size = new System.Drawing.Size(221, 46); + this.lblNewSubnet.TabIndex = 520; + this.lblNewSubnet.Text = "192 . 168 . 123"; + this.lblNewSubnet.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // btnHelp + // + this.btnHelp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnHelp.FlatAppearance.BorderSize = 0; + this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnHelp.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnHelp.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnHelp.Image = global::AgIO.Properties.Resources.Help; + this.btnHelp.Location = new System.Drawing.Point(759, 12); + this.btnHelp.Name = "btnHelp"; + this.btnHelp.Size = new System.Drawing.Size(76, 65); + this.btnHelp.TabIndex = 521; + this.btnHelp.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnHelp.UseVisualStyleBackColor = true; + this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click); + // + // btnNetworkCPL + // + this.btnNetworkCPL.BackgroundImage = global::AgIO.Properties.Resources.DeviceManager; + this.btnNetworkCPL.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnNetworkCPL.FlatAppearance.BorderSize = 0; + this.btnNetworkCPL.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnNetworkCPL.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnNetworkCPL.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnNetworkCPL.Location = new System.Drawing.Point(303, 511); + this.btnNetworkCPL.Name = "btnNetworkCPL"; + this.btnNetworkCPL.Size = new System.Drawing.Size(76, 65); + this.btnNetworkCPL.TabIndex = 521; + this.btnNetworkCPL.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnNetworkCPL.UseVisualStyleBackColor = true; + this.btnNetworkCPL.Click += new System.EventHandler(this.btnNetworkCPL_Click); + // + // btnAutoSet + // + this.btnAutoSet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnAutoSet.Enabled = false; + this.btnAutoSet.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnAutoSet.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnAutoSet.Image = global::AgIO.Properties.Resources.DnArrow64; + this.btnAutoSet.Location = new System.Drawing.Point(517, 296); + this.btnAutoSet.Name = "btnAutoSet"; + this.btnAutoSet.Size = new System.Drawing.Size(60, 58); + this.btnAutoSet.TabIndex = 511; + this.btnAutoSet.UseVisualStyleBackColor = true; + this.btnAutoSet.Click += new System.EventHandler(this.btnAutoSet_Click); // // btnSendSubnet // this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSendSubnet.FlatAppearance.BorderSize = 0; this.btnSendSubnet.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSendSubnet.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnSendSubnet.ForeColor = System.Drawing.SystemColors.ControlText; - this.btnSendSubnet.Image = global::AgIO.Properties.Resources.ToolAcceptChange; - this.btnSendSubnet.Location = new System.Drawing.Point(145, 398); + this.btnSendSubnet.Image = global::AgIO.Properties.Resources.SubnetSend; + this.btnSendSubnet.Location = new System.Drawing.Point(755, 339); this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(98, 64); + this.btnSendSubnet.Size = new System.Drawing.Size(92, 79); this.btnSendSubnet.TabIndex = 151; this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; this.btnSendSubnet.UseVisualStyleBackColor = true; @@ -400,77 +615,88 @@ private void InitializeComponent() this.btnSerialCancel.FlatAppearance.BorderSize = 0; this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnSerialCancel.Image = global::AgIO.Properties.Resources.Cancel64; - this.btnSerialCancel.Location = new System.Drawing.Point(643, 395); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.back_button; + this.btnSerialCancel.Location = new System.Drawing.Point(757, 493); this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); + this.btnSerialCancel.Size = new System.Drawing.Size(92, 79); this.btnSerialCancel.TabIndex = 71; this.btnSerialCancel.UseVisualStyleBackColor = true; - // - // btnSerialOK - // - this.btnSerialOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.btnSerialOK.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSerialOK.FlatAppearance.BorderSize = 0; - this.btnSerialOK.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnSerialOK.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnSerialOK.ForeColor = System.Drawing.SystemColors.ControlText; - this.btnSerialOK.Image = global::AgIO.Properties.Resources.OK64; - this.btnSerialOK.Location = new System.Drawing.Point(779, 395); - this.btnSerialOK.Name = "btnSerialOK"; - this.btnSerialOK.Size = new System.Drawing.Size(88, 64); - this.btnSerialOK.TabIndex = 70; - this.btnSerialOK.TextAlign = System.Drawing.ContentAlignment.TopLeft; - this.btnSerialOK.UseVisualStyleBackColor = true; - this.btnSerialOK.Click += new System.EventHandler(this.btnSerialOK_Click); - // - // label7 - // - this.label7.AutoSize = true; - this.label7.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label7.Location = new System.Drawing.Point(440, 45); - this.label7.Name = "label7"; - this.label7.Size = new System.Drawing.Size(126, 23); - this.label7.TabIndex = 161; - this.label7.Text = "Network Scan"; - this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.btnSerialCancel.Click += new System.EventHandler(this.btnSerialCancel_Click); + // + // pboxSendSteer + // + this.pboxSendSteer.BackgroundImage = global::AgIO.Properties.Resources.ConSt_Mandatory; + this.pboxSendSteer.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.pboxSendSteer.Location = new System.Drawing.Point(782, 299); + this.pboxSendSteer.Name = "pboxSendSteer"; + this.pboxSendSteer.Size = new System.Drawing.Size(38, 39); + this.pboxSendSteer.TabIndex = 510; + this.pboxSendSteer.TabStop = false; + this.pboxSendSteer.Visible = false; + // + // btnSerialMonitor + // + this.btnSerialMonitor.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialMonitor.FlatAppearance.BorderSize = 0; + this.btnSerialMonitor.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialMonitor.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialMonitor.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnSerialMonitor.Image = global::AgIO.Properties.Resources.NTRIP_Serial; + this.btnSerialMonitor.Location = new System.Drawing.Point(761, 110); + this.btnSerialMonitor.Name = "btnSerialMonitor"; + this.btnSerialMonitor.Size = new System.Drawing.Size(76, 65); + this.btnSerialMonitor.TabIndex = 522; + this.btnSerialMonitor.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnSerialMonitor.UseVisualStyleBackColor = true; + this.btnSerialMonitor.Click += new System.EventHandler(this.btnSerialMonitor_Click); // // label10 // this.label10.AutoSize = true; - this.label10.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label10.Location = new System.Drawing.Point(244, 418); + this.label10.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label10.Location = new System.Drawing.Point(769, 173); this.label10.Name = "label10"; - this.label10.Size = new System.Drawing.Size(98, 23); - this.label10.TabIndex = 164; - this.label10.Text = "To Module"; + this.label10.Size = new System.Drawing.Size(66, 18); + this.label10.TabIndex = 523; + this.label10.Text = "Monitor"; this.label10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // FormUDP // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(880, 470); + this.ClientSize = new System.Drawing.Size(861, 584); this.ControlBox = false; - this.Controls.Add(this.label10); + this.Controls.Add(this.btnSerialMonitor); + this.Controls.Add(this.btnHelp); + this.Controls.Add(this.btnNetworkCPL); + this.Controls.Add(this.lblNewSubnet); + this.Controls.Add(this.tableLayoutPanel1); + this.Controls.Add(this.label13); + this.Controls.Add(this.label11); + this.Controls.Add(this.label9); + this.Controls.Add(this.btnAutoSet); + this.Controls.Add(this.cboxUp); + this.Controls.Add(this.lblNoAdapter); + this.Controls.Add(this.lblHostname); + this.Controls.Add(this.label4); + this.Controls.Add(this.tboxNets); + this.Controls.Add(this.label6); + this.Controls.Add(this.lblNetworkHelp); this.Controls.Add(this.label7); - this.Controls.Add(this.lblConnectedModules); - this.Controls.Add(this.groupBox1); - this.Controls.Add(this.label5); this.Controls.Add(this.btnSendSubnet); this.Controls.Add(this.nudThirdIP); - this.Controls.Add(this.groupBox5); - this.Controls.Add(this.nudSecondIP); - this.Controls.Add(this.groupBox3); + this.Controls.Add(this.nudSecndIP); this.Controls.Add(this.nudFirstIP); this.Controls.Add(this.label1); - this.Controls.Add(this.groupBox4); this.Controls.Add(this.btnSerialCancel); - this.Controls.Add(this.btnSerialOK); this.Controls.Add(this.label2); this.Controls.Add(this.label3); - this.Controls.Add(this.label4); this.Controls.Add(this.label8); + this.Controls.Add(this.label5); + this.Controls.Add(this.lblSubTimer); + this.Controls.Add(this.pboxSendSteer); + this.Controls.Add(this.label10); this.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5); @@ -481,48 +707,60 @@ private void InitializeComponent() this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Ethernet Configuration"; this.Load += new System.EventHandler(this.FormUDp_Load); - this.groupBox4.ResumeLayout(false); - this.groupBox4.PerformLayout(); - this.groupBox3.ResumeLayout(false); - this.groupBox5.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudSecondIP)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).EndInit(); - this.groupBox1.ResumeLayout(false); + this.tableLayoutPanel1.ResumeLayout(false); + this.tableLayoutPanel1.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); } #endregion - - private System.Windows.Forms.GroupBox groupBox4; private System.Windows.Forms.Button btnSerialCancel; - private System.Windows.Forms.Button btnSerialOK; - private System.Windows.Forms.TextBox tboxHostName; - private System.Windows.Forms.CheckBox cboxIsUDPOn; - private System.Windows.Forms.GroupBox groupBox3; - private System.Windows.Forms.CheckBox cboxIsSendNMEAToUDP; - private System.Windows.Forms.Label label12; - private System.Windows.Forms.GroupBox groupBox5; - private System.Windows.Forms.CheckBox cboxPlugin; private System.Windows.Forms.Label lblNetworkHelp; private System.Windows.Forms.Timer timer1; private System.Windows.Forms.Label label1; private System.Windows.Forms.NumericUpDown nudFirstIP; - private System.Windows.Forms.NumericUpDown nudSecondIP; + private System.Windows.Forms.NumericUpDown nudSecndIP; private System.Windows.Forms.NumericUpDown nudThirdIP; - private System.Windows.Forms.Button btnSendSubnet; private System.Windows.Forms.Label label2; private System.Windows.Forms.Label label3; - private System.Windows.Forms.Label label4; - private System.Windows.Forms.Label label5; - private System.Windows.Forms.GroupBox groupBox1; private System.Windows.Forms.Label label6; private System.Windows.Forms.Label label8; - public System.Windows.Forms.Label lblConnectedModules; private System.Windows.Forms.Label label7; - public System.Windows.Forms.Label label9; + private System.Windows.Forms.TextBox tboxNets; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.Label lblHostname; + private System.Windows.Forms.Label lblNoAdapter; + private System.Windows.Forms.CheckBox cboxUp; + private System.Windows.Forms.Button btnAutoSet; + private System.Windows.Forms.PictureBox pboxSendSteer; + private System.Windows.Forms.Button btnSendSubnet; + private System.Windows.Forms.Label label5; + private System.Windows.Forms.Label label9; + private System.Windows.Forms.Label lblSubTimer; + private System.Windows.Forms.Label label11; + private System.Windows.Forms.Label label13; + private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; + private System.Windows.Forms.Label label18; + private System.Windows.Forms.Label label17; + private System.Windows.Forms.Label label16; + private System.Windows.Forms.Label label15; + private System.Windows.Forms.Label lblSteerIP; + private System.Windows.Forms.Label lblGPSIP; + private System.Windows.Forms.Label lblMachineIP; + private System.Windows.Forms.Label lblIMU_IP; + private System.Windows.Forms.Label lblNewSubnet; + private System.Windows.Forms.Label lblBtnIMU; + private System.Windows.Forms.Label lblBtnGPS; + private System.Windows.Forms.Label lblBtnMachine; + private System.Windows.Forms.Label lblBtnSteer; + private System.Windows.Forms.Button btnNetworkCPL; + private System.Windows.Forms.Button btnHelp; + private System.Windows.Forms.Button btnSerialMonitor; private System.Windows.Forms.Label label10; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 57dca49a6..f66dd12b6 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -1,6 +1,10 @@ using System; using System.ComponentModel; +using System.Diagnostics; +using System.Drawing; +using System.Linq; using System.Net; +using System.Net.NetworkInformation; using System.Net.Sockets; using System.Windows.Forms; @@ -13,8 +17,8 @@ public partial class FormUDP : Form //used to send communication check pgn= C8 or 200 private byte[] sendIPToModules = { 0x80, 0x81, 0x7F, 201, 5, 201, 201, 192, 168, 5, 0x47 }; - private byte[] ipToSend = { 192,168,5 }; - + private byte[] ipCurrent = { 192, 168, 5 }; + private byte[] ipNew = { 192, 168, 5 }; public FormUDP(Form callingForm) { @@ -23,177 +27,345 @@ public FormUDP(Form callingForm) InitializeComponent(); nudFirstIP.Controls[0].Enabled = false; - nudSecondIP.Controls[0].Enabled = false; + nudSecndIP.Controls[0].Enabled = false; nudThirdIP.Controls[0].Enabled = false; } - private void btnSerialOK_Click(object sender, EventArgs e) - { - Properties.Settings.Default.setUDP_isOn = cboxIsUDPOn.Checked; - Properties.Settings.Default.setUDP_isUsePluginApp = cboxPlugin.Checked; - Properties.Settings.Default.setUDP_isSendNMEAToUDP = cboxIsSendNMEAToUDP.Checked; - - Properties.Settings.Default.Save(); - Application.Restart(); - Environment.Exit(0); - Close(); - } - private void FormUDp_Load(object sender, EventArgs e) { - string hostName = Dns.GetHostName(); // Retrieve the Name of HOST - tboxHostName.Text = hostName; + mf.ipAutoSet[0] = 99; + mf.ipAutoSet[1] = 99; + mf.ipAutoSet[2] = 99; - cboxIsUDPOn.Checked = Properties.Settings.Default.setUDP_isOn; - cboxPlugin.Checked = Properties.Settings.Default.setUDP_isUsePluginApp; - cboxIsSendNMEAToUDP.Checked = Properties.Settings.Default.setUDP_isSendNMEAToUDP; + lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST lblNetworkHelp.Text = - Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + - Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + + Properties.Settings.Default.etIP_SubnetOne.ToString() + " . " + + Properties.Settings.Default.etIP_SubnetTwo.ToString() + " . " + Properties.Settings.Default.etIP_SubnetThree.ToString(); - nudFirstIP.Value = ipToSend[0] = Properties.Settings.Default.etIP_SubnetOne; - nudSecondIP.Value = ipToSend[1] = Properties.Settings.Default.etIP_SubnetTwo; - nudThirdIP.Value = ipToSend[2] = Properties.Settings.Default.etIP_SubnetThree; - - if (!cboxIsUDPOn.Checked) - { - nudFirstIP.Enabled = false; - nudSecondIP.Enabled = false; - nudThirdIP.Enabled = false; - btnSendSubnet.Enabled = false; - } + nudFirstIP.Value = ipNew[0] = ipCurrent[0] = Properties.Settings.Default.etIP_SubnetOne; + nudSecndIP.Value = ipNew[1] = ipCurrent[1] = Properties.Settings.Default.etIP_SubnetTwo; + nudThirdIP.Value = ipNew[2] = ipCurrent[2] = Properties.Settings.Default.etIP_SubnetThree; ScanNetwork(); } - //get the ipv4 address only - public void GetIP4AddressList() + int tickCounter = 0; + + private void timer1_Tick(object sender, EventArgs e) { - label9.Text = ""; + if(!mf.scanReply.isNewData) + { + mf.ipAutoSet[0] = 99; + mf.ipAutoSet[1] = 99; + mf.ipAutoSet[2] = 99; + btnAutoSet.Enabled = false; + } + else + { + btnAutoSet.Enabled = true; + } - foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + if (mf.scanReply.isNewSteer) { - if (IPA.AddressFamily == AddressFamily.InterNetwork) - { - label9.Text += IPA.ToString() + "\r\n"; - } + lblSteerIP.Text = mf.scanReply.steerIP; + mf.scanReply.isNewSteer = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; + } + + if (mf.scanReply.isNewMachine) + { + lblMachineIP.Text = mf.scanReply.machineIP; + mf.scanReply.isNewMachine = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; + } + + if (mf.scanReply.isNewIMU) + { + lblIMU_IP.Text = mf.scanReply.IMU_IP; + mf.scanReply.isNewIMU = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; + } + + if (mf.scanReply.isNewGPS) + { + lblGPSIP.Text = mf.scanReply.GPS_IP; + mf.scanReply.isNewGPS = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; + } + + if (tickCounter == 4) + { + lblBtnSteer.BackColor = mf.btnSteer.BackColor; + lblBtnMachine.BackColor = mf.btnMachine.BackColor; + lblBtnGPS.BackColor = mf.btnGPS.BackColor; + lblBtnIMU.BackColor = mf.btnIMU.BackColor; + } + + if (tickCounter > 5) + { + ScanNetwork(); + tickCounter = 0; + lblSubTimer.Text = "Scanning"; + } + else + { + lblSubTimer.Text = "-"; } + tickCounter++; } - public void IsValidNetworkFound() + private void ScanNetwork() { - foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + tboxNets.Text = ""; + + lblSteerIP.Text = lblMachineIP.Text = lblGPSIP.Text = lblIMU_IP.Text = lblNewSubnet.Text = ""; + mf.scanReply.isNewData = false; + + bool isSubnetMatchCard = false; + + byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; + + //Send out 255x4 to each installed network interface + foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) { - if (IPA.AddressFamily == AddressFamily.InterNetwork) + if (nic.Supports(NetworkInterfaceComponent.IPv4) ) { - byte[] data = IPA.GetAddressBytes(); - // Split string by ".", check that array length is 3 - if (data[0] == 192 && data[1] == 168 && data[2] == 1) + foreach (var info in nic.GetIPProperties().UnicastAddresses) { - if (data[3] < 255 && data[3] > 1) + // Only InterNetwork and not loopback which have a subnetmask + if (info.Address.AddressFamily == AddressFamily.InterNetwork && !IPAddress.IsLoopback(info.Address)) { - break; + Socket scanSocket; + try + { + //create list of interface properties + if ((cboxUp.Checked && nic.OperationalStatus == OperationalStatus.Up) || !cboxUp.Checked) + { + var properties = nic.GetIPStatistics(); + tboxNets.Text += + info.Address + " - " + nic.OperationalStatus + "\r\n"; + + tboxNets.Text += nic.Name.ToString() + "\r\n"; + tboxNets.Text += "Sent: " + (properties.NonUnicastPacketsSent + + properties.UnicastPacketsSent).ToString() + + " Recd: " + (properties.NonUnicastPacketsReceived + + properties.UnicastPacketsReceived).ToString() + "\r\n\r\n"; + } + + if ( nic.OperationalStatus == OperationalStatus.Up + && info.IPv4Mask != null) + { + byte[] data = info.Address.GetAddressBytes(); + if (data[0] == ipCurrent[0] && data[1] == ipCurrent[1] && data[2] == ipCurrent[2]) + { + isSubnetMatchCard = true; + } + + //send scan reply out each network interface + scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.DontRoute, true); + + try + { + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + scanSocket.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); + } + catch (Exception ex) + { + Console.Write("Bind Error = "); + Console.WriteLine(ex.ToString()); + } + + scanSocket.Dispose(); + } + } + catch (Exception ex) + { + Console.Write("nic Loop = "); + Console.WriteLine(ex.ToString()); + } } } } } - } - private void timer1_Tick(object sender, EventArgs e) - { - GetIP4AddressList(); - //IsValidNetworkFound(); - if (cboxIsUDPOn.Checked) + if (isSubnetMatchCard) { - cboxIsSendNMEAToUDP.Enabled = true; - cboxPlugin.Enabled = true; + lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; + lblNoAdapter.Visible = false; } else { - cboxIsSendNMEAToUDP.Enabled = false; - cboxPlugin.Enabled = false; - cboxIsSendNMEAToUDP.Checked = false; - cboxPlugin.Checked = false; - } - - if (counter == 0) - { - ScanNetwork(); - counter++; + lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; + lblNoAdapter.Visible = true; } - else - { - lblConnectedModules.Text = mf.scanReturn; - counter = 0; - } } private void btnSendSubnet_Click(object sender, EventArgs e) { - DialogResult result3 = MessageBox.Show( - "Change Modules and AgIO Subnet To: \r\n\r\n" + - ipToSend[0].ToString() + "." + - ipToSend[1].ToString() + "." + - ipToSend[2].ToString() + " ?", - "Are you sure ?", - MessageBoxButtons.YesNo, - MessageBoxIcon.Question, - MessageBoxDefaultButton.Button2); - - if (result3 == DialogResult.Yes) { + sendIPToModules[7] = ipNew[0]; + sendIPToModules[8] = ipNew[1]; + sendIPToModules[9] = ipNew[2]; - sendIPToModules[7] = ipToSend[0]; - sendIPToModules[8] = ipToSend[1]; - sendIPToModules[9] = ipToSend[2]; + //loop thru all interfaces + foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) + { + if (nic.Supports(NetworkInterfaceComponent.IPv4) && nic.OperationalStatus == OperationalStatus.Up) + { + foreach (var info in nic.GetIPProperties().UnicastAddresses) + { + // Only InterNetwork and not loopback which have a subnetmask + if (info.Address.AddressFamily == AddressFamily.InterNetwork && + !IPAddress.IsLoopback(info.Address) && + info.IPv4Mask != null) + { + Socket scanSocket; + try + { + if (nic.OperationalStatus == OperationalStatus.Up + && info.IPv4Mask != null) + { + scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.DontRoute, true); - mf.SendUDPMessage(sendIPToModules, mf.epModuleSet); + try + { + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + scanSocket.SendTo(sendIPToModules, 0, sendIPToModules.Length, SocketFlags.None, mf.epModuleSet); + } + catch (Exception ex) + { + Console.Write("Bind Error = "); + Console.WriteLine(ex.ToString()); + } + + scanSocket.Dispose(); + } + } + catch (Exception ex) + { + Console.Write("nic Loop = "); + Console.WriteLine(ex.ToString()); + } + } + } + } + } + + Properties.Settings.Default.etIP_SubnetOne = ipCurrent[0] = ipNew[0]; + Properties.Settings.Default.etIP_SubnetTwo = ipCurrent[1] = ipNew[1]; + Properties.Settings.Default.etIP_SubnetThree = ipCurrent[2] = ipNew[2]; - Properties.Settings.Default.etIP_SubnetOne = ipToSend[0]; - Properties.Settings.Default.etIP_SubnetTwo = ipToSend[1]; - Properties.Settings.Default.etIP_SubnetThree = ipToSend[2]; Properties.Settings.Default.Save(); + mf.epModule = new IPEndPoint(IPAddress.Parse( + Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + + Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + + Properties.Settings.Default.etIP_SubnetThree.ToString() + ".255"), 8888); + lblNetworkHelp.Text = - ipToSend[0].ToString() + "." + - ipToSend[1].ToString() + "." + - ipToSend[2].ToString(); - - counter = 0; + Properties.Settings.Default.etIP_SubnetOne.ToString() + " . " + + Properties.Settings.Default.etIP_SubnetTwo.ToString() + " . " + + Properties.Settings.Default.etIP_SubnetThree.ToString(); } + + pboxSendSteer.Visible = false; + btnSerialCancel.Image = Properties.Resources.back_button; + } + + private void btnAutoSet_Click(object sender, EventArgs e) + { + nudFirstIP.Value = mf.scanReply.subnet[0]; + nudSecndIP.Value = mf.scanReply.subnet[1]; + nudThirdIP.Value = mf.scanReply.subnet[2]; + ipNew[0] = mf.scanReply.subnet[0]; + ipNew[1] = mf.scanReply.subnet[1]; + ipNew[2] = mf.scanReply.subnet[2]; + btnSerialCancel.Image = Properties.Resources.Cancel64; + pboxSendSteer.Visible = true; } - int counter = 0; private void nudFirstIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[0] = (byte)nudFirstIP.Value; + ipNew[0] = (byte)nudFirstIP.Value; + ipNew[1] = (byte)nudSecndIP.Value; + ipNew[2] = (byte)nudThirdIP.Value; + btnSendSubnet.Enabled = true; + pboxSendSteer.Visible = true; + btnSerialCancel.Image = Properties.Resources.Cancel64; } - private void nudSecondIP_Click(object sender, EventArgs e) + private void cboxUp_Click(object sender, EventArgs e) { - mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[1] = (byte)nudSecondIP.Value; + if(cboxUp.Checked) + { + cboxUp.Text = "Up"; + } + else + { + cboxUp.Text = "Up + Down"; + } } - private void nudThirdIP_Click(object sender, EventArgs e) + private void btnNetworkCPL_Click(object sender, EventArgs e) { - mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[2] = (byte)nudThirdIP.Value; + Process.Start("ncpa.cpl"); } - private void ScanNetwork() + private void btnHelp_Click(object sender, EventArgs e) { - mf.scanReturn = ""; - byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; - mf.SendUDPMessage(scanModules, mf.epModuleSet); + System.Diagnostics.Process.Start(gStr.gsSerialMonHelp); + } - private void btnRescan_Click(object sender, EventArgs e) + private void btnSerialCancel_Click(object sender, EventArgs e) { - ScanNetwork(); + Close(); } + + private void btnSerialMonitor_Click(object sender, EventArgs e) + { + mf.ShowSerialMonitor(); + } + + ////get the ipv4 address only + //public void GetIP4AddressList() + //{ + // tboxNets.Text = ""; + // foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + // { + // if (IPA.AddressFamily == AddressFamily.InterNetwork) + // { + // tboxNets.Text += IPA.ToString() + "\r\n"; + // } + // } + //} + + //public void IsValidNetworkFound() + //{ + // foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) + // { + // if (IPA.AddressFamily == AddressFamily.InterNetwork) + // { + // byte[] data = IPA.GetAddressBytes(); + // // Split string by ".", check that array length is 3 + // if (data[0] == 192 && data[1] == 168 && data[2] == 1) + // { + // if (data[3] < 255 && data[3] > 1) + // { + // break; + // } + // } + // } + // } + //} } -} \ No newline at end of file +} diff --git a/SourceCode/AgIO/Source/Forms/FormYes.cs b/SourceCode/AgIO/Source/Forms/FormYes.cs new file mode 100644 index 000000000..e80f0817e --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYes.cs @@ -0,0 +1,18 @@ +using System; +using System.Windows.Forms; + +namespace AgIO +{ + public partial class FormYes : Form + { + public FormYes(string messageStr) + { + InitializeComponent(); + + lblMessage2.Text = messageStr; + + int messWidth = messageStr.Length; + Width = messWidth * 15 + 180; + } + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormYes.designer.cs b/SourceCode/AgIO/Source/Forms/FormYes.designer.cs new file mode 100644 index 000000000..f7c3d223d --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYes.designer.cs @@ -0,0 +1,89 @@ +namespace AgIO +{ + partial class FormYes + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.lblMessage2 = new System.Windows.Forms.Label(); + this.btnSerialOK = new System.Windows.Forms.Button(); + this.SuspendLayout(); + // + // lblMessage2 + // + this.lblMessage2.AutoSize = true; + this.lblMessage2.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); + this.lblMessage2.Location = new System.Drawing.Point(46, 71); + this.lblMessage2.Name = "lblMessage2"; + this.lblMessage2.Size = new System.Drawing.Size(137, 29); + this.lblMessage2.TabIndex = 1; + this.lblMessage2.Text = "Message 2"; + // + // btnSerialOK + // + this.btnSerialOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialOK.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialOK.DialogResult = System.Windows.Forms.DialogResult.OK; + this.btnSerialOK.FlatAppearance.BorderSize = 0; + this.btnSerialOK.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialOK.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialOK.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnSerialOK.Image = global::AgIO.Properties.Resources.OK64; + this.btnSerialOK.Location = new System.Drawing.Point(136, 161); + this.btnSerialOK.Name = "btnSerialOK"; + this.btnSerialOK.Size = new System.Drawing.Size(105, 64); + this.btnSerialOK.TabIndex = 96; + this.btnSerialOK.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnSerialOK.UseVisualStyleBackColor = true; + // + // FormYes + // + this.AutoScaleDimensions = new System.Drawing.SizeF(10F, 23F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(200)))), ((int)(((byte)(200))))); + this.ClientSize = new System.Drawing.Size(245, 229); + this.ControlBox = false; + this.Controls.Add(this.btnSerialOK); + this.Controls.Add(this.lblMessage2); + this.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; + this.Margin = new System.Windows.Forms.Padding(6); + this.Name = "FormYes"; + this.ShowIcon = false; + this.ShowInTaskbar = false; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "AgIO Message"; + this.TopMost = true; + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + private System.Windows.Forms.Label lblMessage2; + private System.Windows.Forms.Button btnSerialOK; + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormYes.resx b/SourceCode/AgIO/Source/Forms/FormYes.resx new file mode 100644 index 000000000..1af7de150 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYes.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormYesNo.cs b/SourceCode/AgIO/Source/Forms/FormYesNo.cs new file mode 100644 index 000000000..5affc0e9d --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYesNo.cs @@ -0,0 +1,26 @@ +using System; +using System.Windows.Forms; + +namespace AgIO +{ + public partial class FormYesNo : Form + { + public FormYesNo(string messageStr) + { + InitializeComponent(); + + lblMessage2.Text = messageStr; + + int messWidth = messageStr.Length; + Width = messWidth * 15 + 180; + } + + private void timer1_Tick(object sender, EventArgs e) + { + timer1.Enabled = false; + timer1.Dispose(); + Dispose(); + Close(); + } + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormYesNo.designer.cs b/SourceCode/AgIO/Source/Forms/FormYesNo.designer.cs new file mode 100644 index 000000000..25badf2a7 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYesNo.designer.cs @@ -0,0 +1,116 @@ +namespace AgIO +{ + partial class FormYesNo + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + this.timer1 = new System.Windows.Forms.Timer(this.components); + this.lblMessage2 = new System.Windows.Forms.Label(); + this.btnSerialCancel = new System.Windows.Forms.Button(); + this.btnSerialOK = new System.Windows.Forms.Button(); + this.SuspendLayout(); + // + // timer1 + // + this.timer1.Enabled = true; + this.timer1.Interval = 3000; + this.timer1.Tick += new System.EventHandler(this.timer1_Tick); + // + // lblMessage2 + // + this.lblMessage2.AutoSize = true; + this.lblMessage2.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold); + this.lblMessage2.Location = new System.Drawing.Point(46, 71); + this.lblMessage2.Name = "lblMessage2"; + this.lblMessage2.Size = new System.Drawing.Size(137, 29); + this.lblMessage2.TabIndex = 1; + this.lblMessage2.Text = "Message 2"; + // + // btnSerialCancel + // + this.btnSerialCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnSerialCancel.FlatAppearance.BorderSize = 0; + this.btnSerialCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialCancel.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.Cancel64; + this.btnSerialCancel.Location = new System.Drawing.Point(8, 161); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(105, 64); + this.btnSerialCancel.TabIndex = 97; + this.btnSerialCancel.UseVisualStyleBackColor = true; + // + // btnSerialOK + // + this.btnSerialOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSerialOK.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSerialOK.DialogResult = System.Windows.Forms.DialogResult.OK; + this.btnSerialOK.FlatAppearance.BorderSize = 0; + this.btnSerialOK.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSerialOK.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnSerialOK.ForeColor = System.Drawing.SystemColors.ControlText; + this.btnSerialOK.Image = global::AgIO.Properties.Resources.OK64; + this.btnSerialOK.Location = new System.Drawing.Point(136, 161); + this.btnSerialOK.Name = "btnSerialOK"; + this.btnSerialOK.Size = new System.Drawing.Size(105, 64); + this.btnSerialOK.TabIndex = 96; + this.btnSerialOK.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnSerialOK.UseVisualStyleBackColor = true; + // + // FormYesNo + // + this.AutoScaleDimensions = new System.Drawing.SizeF(10F, 23F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(200)))), ((int)(((byte)(200))))); + this.ClientSize = new System.Drawing.Size(253, 237); + this.ControlBox = false; + this.Controls.Add(this.btnSerialCancel); + this.Controls.Add(this.btnSerialOK); + this.Controls.Add(this.lblMessage2); + this.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; + this.Margin = new System.Windows.Forms.Padding(6); + this.Name = "FormYesNo"; + this.ShowIcon = false; + this.ShowInTaskbar = false; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "AgIO Message"; + this.TopMost = true; + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + private System.Windows.Forms.Timer timer1; + private System.Windows.Forms.Label lblMessage2; + private System.Windows.Forms.Button btnSerialCancel; + private System.Windows.Forms.Button btnSerialOK; + } +} \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormYesNo.resx b/SourceCode/AgIO/Source/Forms/FormYesNo.resx new file mode 100644 index 000000000..1f666f268 --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormYesNo.resx @@ -0,0 +1,123 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17, 17 + + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormtimedMessage.resx b/SourceCode/AgIO/Source/Forms/FormtimedMessage.resx index 1af7de150..1f666f268 100644 --- a/SourceCode/AgIO/Source/Forms/FormtimedMessage.resx +++ b/SourceCode/AgIO/Source/Forms/FormtimedMessage.resx @@ -117,4 +117,7 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 17, 17 + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs index e692c8dc4..f9ac70b8b 100644 --- a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs @@ -115,7 +115,7 @@ public void ParseNMEA(ref string buffer) { if (isLogNMEA) { - logNMEASentence.Append("\r\n" + + logNMEASentence.Append("\r\n" + DateTime.UtcNow.ToString(" ->> mm:ss.fff ", CultureInfo.InvariantCulture) + "\r\n" + rawBuffer + "\r\n"); } @@ -123,6 +123,12 @@ public void ParseNMEA(ref string buffer) return; } + if (isLogMonitorOn) + { + logMonitorSentence.Append(DateTime.UtcNow.ToString("mm:ss.fff ", CultureInfo.InvariantCulture)+rawBuffer); + } + + //now we have a complete sentence or more somewhere in the portData while (true) { diff --git a/SourceCode/AgIO/Source/Forms/NTRIPComm.Designer.cs b/SourceCode/AgIO/Source/Forms/NTRIPComm.Designer.cs index d1b011430..534402c2d 100644 --- a/SourceCode/AgIO/Source/Forms/NTRIPComm.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/NTRIPComm.Designer.cs @@ -431,7 +431,7 @@ public void OnAddMessage(byte[] data) if (isViewAdvanced && isNTRIP_RequiredOn ) { int mess = 0; - lblPacketSize.Text = data.Length.ToString(); + //lblPacketSize.Text = data.Length.ToString(); try { @@ -522,7 +522,7 @@ private void ntripMeterTimer_Tick(object sender, EventArgs e) if (focusSkipCounter != 0) { - lblToGPS.Text = traffic.cntrGPSInBytes == 0 ? "--" : (traffic.cntrGPSInBytes).ToString(); + lblToGPS.Text = traffic.cntrGPSInBytes == 0 ? "---" : (traffic.cntrGPSInBytes).ToString(); traffic.cntrGPSInBytes = 0; } } diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 9fee39524..97e823089 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -16,6 +16,21 @@ public class CTraffic public uint helloFromMachine = 99, helloFromAutoSteer = 99, helloFromIMU = 99; } + public class CScanReply + { + public string steerIP = ""; + public string machineIP = ""; + public string GPS_IP = ""; + public string IMU_IP = ""; + public string subnetStr = ""; + + public byte[] subnet = { 0, 0, 0 }; + + public bool isNewSteer, isNewMachine, isNewGPS, isNewIMU; + + public bool isNewData = false; + } + public partial class FormLoop { // loopback Socket @@ -23,14 +38,25 @@ public partial class FormLoop private EndPoint endPointLoopBack = new IPEndPoint(IPAddress.Loopback, 0); // UDP Socket - private Socket UDPSocket; + public Socket UDPSocket; private EndPoint endPointUDP = new IPEndPoint(IPAddress.Any, 0); public bool isUDPNetworkConnected; //2 endpoints for local and 2 udp - private IPEndPoint epAgOpen = new IPEndPoint(IPAddress.Parse("127.255.255.255"), 15555); - private IPEndPoint epAgVR = new IPEndPoint(IPAddress.Parse("127.255.255.255"), 16666); + + private IPEndPoint epAgOpen = new IPEndPoint(IPAddress.Parse( + Properties.Settings.Default.eth_loopOne.ToString() + "." + + Properties.Settings.Default.eth_loopTwo.ToString() + "." + + Properties.Settings.Default.eth_loopThree.ToString() + "." + + Properties.Settings.Default.eth_loopFour.ToString()), 15555); + + private IPEndPoint epAgVR = new IPEndPoint(IPAddress.Parse( + Properties.Settings.Default.eth_loopOne.ToString() + "." + + Properties.Settings.Default.eth_loopTwo.ToString() + "." + + Properties.Settings.Default.eth_loopThree.ToString() + "." + + Properties.Settings.Default.eth_loopFour.ToString()), 16666); + public IPEndPoint epModule = new IPEndPoint(IPAddress.Parse( Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + @@ -38,9 +64,11 @@ public partial class FormLoop private IPEndPoint epNtrip; public IPEndPoint epModuleSet = new IPEndPoint(IPAddress.Parse("255.255.255.255"), 8888); + public byte[] ipAutoSet = { 192, 168, 5 }; //class for counting bytes public CTraffic traffic = new CTraffic(); + public CScanReply scanReply = new CScanReply(); //scan results placed here public string scanReturn = "Scanning..."; @@ -56,8 +84,8 @@ public partial class FormLoop public void LoadUDPNetwork() { helloFromAgIO[5] = 56; - lblIP.Text = ""; + lblIP.Text = ""; try //udp network { foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) @@ -65,7 +93,7 @@ public void LoadUDPNetwork() if (IPA.AddressFamily == AddressFamily.InterNetwork) { string data = IPA.ToString(); - lblIP.Text += IPA.ToString() + "\r\n"; + lblIP.Text += IPA.ToString().Trim() + "\r\n"; } } @@ -317,7 +345,8 @@ private void ReceiveFromUDP(byte[] data) //module data also sent to VR if (isPluginUsed) SendToLoopBackMessageVR(data); - else if (data[3] == 126) + //check for Scan and Hello + if (data[3] == 126 && data.Length == 11) { traffic.helloFromAutoSteer = 0; if (isViewAdvanced) @@ -331,7 +360,7 @@ private void ReceiveFromUDP(byte[] data) } } - else if (data[3] == 123) + else if (data[3] == 123 && data.Length == 11) { traffic.helloFromMachine = 0; @@ -342,36 +371,66 @@ private void ReceiveFromUDP(byte[] data) } } - else if (data[3] == 121) + else if (data[3] == 121 && data.Length == 11) traffic.helloFromIMU = 0; //scan Reply - else if (data[3] == 203) // + else if (data[3] == 203 && data.Length == 13) // { - if (data[2] == 123) + if (data[2] == 126) //steer module { - scanReturn += "Machine Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; + scanReply.steerIP = data[5].ToString() + "." + data[6].ToString() + "." + data[7].ToString() + "." + data[8].ToString(); + + scanReply.subnet[0] = data[09]; + scanReply.subnet[1] = data[10]; + scanReply.subnet[2] = data[11]; + + scanReply.subnetStr = data[9].ToString() + "." + data[10].ToString() + "." + data[11].ToString(); + + scanReply.isNewData = true; + scanReply.isNewSteer = true; } - else if (data[2] == 120) + // + else if (data[2] == 123) //machine module { - scanReturn += "Panda Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; - } + scanReply.machineIP = data[5].ToString() + "." + data[6].ToString() + "." + data[7].ToString() + "." + data[8].ToString(); + + scanReply.subnet[0] = data[09]; + scanReply.subnet[1] = data[10]; + scanReply.subnet[2] = data[11]; + + scanReply.subnetStr = data[9].ToString() + "." + data[10].ToString() + "." + data[11].ToString(); - else if (data[2] == 126) + scanReply.isNewData = true; + scanReply.isNewMachine = true; + + } + else if (data[2] == 121) //IMU Module { - scanReturn += "Steer Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; + scanReply.IMU_IP = data[5].ToString() + "." + data[6].ToString() + "." + data[7].ToString() + "." + data[8].ToString(); + + scanReply.subnet[0] = data[09]; + scanReply.subnet[1] = data[10]; + scanReply.subnet[2] = data[11]; + + scanReply.subnetStr = data[9].ToString() + "." + data[10].ToString() + "." + data[11].ToString(); + + scanReply.isNewData = true; + scanReply.isNewIMU = true; } - else if (data[2] == 121) + + else if (data[2] == 120) //GPS module { - scanReturn += "IMU Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; + scanReply.GPS_IP = data[5].ToString() + "." + data[6].ToString() + "." + data[7].ToString() + "." + data[8].ToString(); + + scanReply.subnet[0] = data[09]; + scanReply.subnet[1] = data[10]; + scanReply.subnet[2] = data[11]; + + scanReply.subnetStr = data[9].ToString() + "." + data[10].ToString() + "." + data[11].ToString(); + + scanReply.isNewData = true; + scanReply.isNewGPS = true; } } diff --git a/SourceCode/AgIO/Source/Properties/AssemblyInfo.cs b/SourceCode/AgIO/Source/Properties/AssemblyInfo.cs index 44ef59e4d..0a5c9b840 100644 --- a/SourceCode/AgIO/Source/Properties/AssemblyInfo.cs +++ b/SourceCode/AgIO/Source/Properties/AssemblyInfo.cs @@ -32,6 +32,6 @@ // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("5.7.0")] -[assembly: AssemblyFileVersion("5.7.0")] +[assembly: AssemblyVersion("5.7.1")] +[assembly: AssemblyFileVersion("5.7.1")] [assembly: NeutralResourcesLanguage("en-CA")] diff --git a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs index 3bfdc2330..0a1fd31e0 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs +++ b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs @@ -180,6 +180,16 @@ internal static System.Drawing.Bitmap B_UDP { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap back_button { + get { + object obj = ResourceManager.GetObject("back_button", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -250,6 +260,16 @@ internal static System.Drawing.Bitmap ConS_ImplementAntenna { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap ConSt_Mandatory { + get { + object obj = ResourceManager.GetObject("ConSt_Mandatory", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -280,6 +300,16 @@ internal static System.Drawing.Bitmap Edit { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap Help { + get { + object obj = ResourceManager.GetObject("Help", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -440,6 +470,16 @@ internal static System.Drawing.Bitmap Sort { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap SubnetSend { + get { + object obj = ResourceManager.GetObject("SubnetSend", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// diff --git a/SourceCode/AgIO/Source/Properties/Resources.resx b/SourceCode/AgIO/Source/Properties/Resources.resx index 04b83f17f..ff33f1002 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.resx +++ b/SourceCode/AgIO/Source/Properties/Resources.resx @@ -142,12 +142,15 @@ ..\btnImages\TestRelays.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ScanNetwork.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ConS_ImplementAntenna.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\NTRIP_Serial.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ConSt_Mandatory.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\USB_Connect.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -157,8 +160,8 @@ ..\btnImages\InOut.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\B_GPS.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ScanNetwork.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnimages\trash.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -175,11 +178,14 @@ ..\btnImages\ToolAcceptChange.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\back-button.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Edit.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ConS_ImplementAntenna.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\B_GPS.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Check_Error.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -238,14 +244,17 @@ ..\btnImages\LogNMEA.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SwitchOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Settings48.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\ArrowGrnRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SwitchOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Nmea.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Com_IMUModule.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -256,13 +265,16 @@ ..\btnImages\ArrowRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SubnetSend.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\NtripSettings.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\B_IMU.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Nmea.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Help.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Properties/Settings.Designer.cs b/SourceCode/AgIO/Source/Properties/Settings.Designer.cs index de3d4c05a..a866be522 100644 --- a/SourceCode/AgIO/Source/Properties/Settings.Designer.cs +++ b/SourceCode/AgIO/Source/Properties/Settings.Designer.cs @@ -600,7 +600,7 @@ public bool setNTRIP_sendToSerial { [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Configuration.DefaultSettingValueAttribute("False")] + [global::System.Configuration.DefaultSettingValueAttribute("True")] public bool setNTRIP_sendToUDP { get { return ((bool)(this["setNTRIP_sendToUDP"])); @@ -717,5 +717,65 @@ public byte etIP_SubnetThree { this["etIP_SubnetThree"] = value; } } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("127")] + public byte eth_loopOne { + get { + return ((byte)(this["eth_loopOne"])); + } + set { + this["eth_loopOne"] = value; + } + } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("255")] + public byte eth_loopTwo { + get { + return ((byte)(this["eth_loopTwo"])); + } + set { + this["eth_loopTwo"] = value; + } + } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("255")] + public byte eth_loopThree { + get { + return ((byte)(this["eth_loopThree"])); + } + set { + this["eth_loopThree"] = value; + } + } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("255")] + public byte eth_loopFour { + get { + return ((byte)(this["eth_loopFour"])); + } + set { + this["eth_loopFour"] = value; + } + } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("")] + public string Setting { + get { + return ((string)(this["Setting"])); + } + set { + this["Setting"] = value; + } + } } } diff --git a/SourceCode/AgIO/Source/Properties/Settings.settings b/SourceCode/AgIO/Source/Properties/Settings.settings index 3953dda7f..043dfc3ba 100644 --- a/SourceCode/AgIO/Source/Properties/Settings.settings +++ b/SourceCode/AgIO/Source/Properties/Settings.settings @@ -147,7 +147,7 @@ True - False + True False @@ -176,5 +176,20 @@ 5 + + 127 + + + 255 + + + 255 + + + 255 + + + + \ No newline at end of file diff --git a/SourceCode/AgIO/Source/btnImages/B_GPS.png b/SourceCode/AgIO/Source/btnImages/B_GPS.png index eee542965..e00146188 100644 Binary files a/SourceCode/AgIO/Source/btnImages/B_GPS.png and b/SourceCode/AgIO/Source/btnImages/B_GPS.png differ diff --git a/SourceCode/AgIO/Source/btnImages/B_UDP.png b/SourceCode/AgIO/Source/btnImages/B_UDP.png index 3d0e23fbd..a22c8c458 100644 Binary files a/SourceCode/AgIO/Source/btnImages/B_UDP.png and b/SourceCode/AgIO/Source/btnImages/B_UDP.png differ diff --git a/SourceCode/AgIO/Source/btnImages/ConSt_Mandatory.png b/SourceCode/AgIO/Source/btnImages/ConSt_Mandatory.png new file mode 100644 index 000000000..ec8af16fe Binary files /dev/null and b/SourceCode/AgIO/Source/btnImages/ConSt_Mandatory.png differ diff --git a/SourceCode/AgIO/Source/btnImages/Help.png b/SourceCode/AgIO/Source/btnImages/Help.png new file mode 100644 index 000000000..901ac04e8 Binary files /dev/null and b/SourceCode/AgIO/Source/btnImages/Help.png differ diff --git a/SourceCode/AgIO/Source/btnImages/SubnetSend.png b/SourceCode/AgIO/Source/btnImages/SubnetSend.png new file mode 100644 index 000000000..eb7a0843c Binary files /dev/null and b/SourceCode/AgIO/Source/btnImages/SubnetSend.png differ diff --git a/SourceCode/AgIO/Source/btnImages/back-button.png b/SourceCode/AgIO/Source/btnImages/back-button.png new file mode 100644 index 000000000..333159704 Binary files /dev/null and b/SourceCode/AgIO/Source/btnImages/back-button.png differ diff --git a/SourceCode/AgIO/Source/gStr.Designer.cs b/SourceCode/AgIO/Source/gStr.Designer.cs index 4fc97823c..0b647fd59 100644 --- a/SourceCode/AgIO/Source/gStr.Designer.cs +++ b/SourceCode/AgIO/Source/gStr.Designer.cs @@ -60,6 +60,15 @@ internal gStr() { } } + /// + /// Looks up a localized string similar to https://github.com/farmerbriantee/AgOpenGPS/wiki/03.-AgIO-Orientation. + /// + internal static string gsAgIOHelp { + get { + return ResourceManager.GetString("gsAgIOHelp", resourceCulture); + } + } + /// /// Looks up a localized string similar to Authourizing. /// @@ -69,6 +78,15 @@ internal static string gsAuthourizing { } } + /// + /// Looks up a localized string similar to https://github.com/farmerbriantee/AgOpenGPS/wiki/05.-Ethernet-Setup. + /// + internal static string gsEthernetHelp { + get { + return ResourceManager.GetString("gsEthernetHelp", resourceCulture); + } + } + /// /// Looks up a localized string similar to Listening. /// @@ -87,6 +105,15 @@ internal static string gsNTRIP { } } + /// + /// Looks up a localized string similar to https://github.com/farmerbriantee/AgOpenGPS/wiki/04.-RTK-Setup. + /// + internal static string gsNTRIP_Help { + get { + return ResourceManager.GetString("gsNTRIP_Help", resourceCulture); + } + } + /// /// Looks up a localized string similar to Save And Return. /// @@ -105,6 +132,15 @@ internal static string gsSaveComms { } } + /// + /// Looks up a localized string similar to https://github.com/farmerbriantee/AgOpenGPS/wiki/06.-Serial-Monitor. + /// + internal static string gsSerialMonHelp { + get { + return ResourceManager.GetString("gsSerialMonHelp", resourceCulture); + } + } + /// /// Looks up a localized string similar to Waiting. /// diff --git a/SourceCode/AgIO/Source/gStr.resx b/SourceCode/AgIO/Source/gStr.resx index 69989cb65..6b6af74ac 100644 --- a/SourceCode/AgIO/Source/gStr.resx +++ b/SourceCode/AgIO/Source/gStr.resx @@ -117,21 +117,33 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + https://github.com/farmerbriantee/AgOpenGPS/wiki/03.-AgIO-Orientation + Authourizing + + https://github.com/farmerbriantee/AgOpenGPS/wiki/05.-Ethernet-Setup + Listening NTRIP + + https://github.com/farmerbriantee/AgOpenGPS/wiki/04.-RTK-Setup + Save And Return Save Comms + + https://github.com/farmerbriantee/AgOpenGPS/wiki/06.-Serial-Monitor + Waiting diff --git a/SourceCode/GPS/Forms/Controls.Designer.cs b/SourceCode/GPS/Forms/Controls.Designer.cs index 98c216065..b67b23a3b 100644 --- a/SourceCode/GPS/Forms/Controls.Designer.cs +++ b/SourceCode/GPS/Forms/Controls.Designer.cs @@ -810,11 +810,18 @@ private void colorsToolStripMenuItem_Click(object sender, EventArgs e) } private void colorsSectionToolStripMenuItem_Click(object sender, EventArgs e) { - using (var form = new FormSectionColor(this)) + if (tool.isSectionsNotZones) { - form.ShowDialog(this); + using (var form = new FormSectionColor(this)) + { + form.ShowDialog(this); + } + SettingsIO.ExportAll(vehiclesDirectory + vehicleFileName + ".XML"); + } + else + { + TimedMessageBox(2000, "Cannot use with zones", "Only for Sections"); } - SettingsIO.ExportAll(vehiclesDirectory + vehicleFileName + ".XML"); } //Languages diff --git a/SourceCode/GPS/Forms/Sections.Designer.cs b/SourceCode/GPS/Forms/Sections.Designer.cs index 494363b19..dbbe049cc 100644 --- a/SourceCode/GPS/Forms/Sections.Designer.cs +++ b/SourceCode/GPS/Forms/Sections.Designer.cs @@ -666,7 +666,6 @@ public void SectionCalcMulti() private void BuildMachineByte() { - if (tool.isSectionsNotZones) { p_254.pgn[p_254.sc1to8] = 0; @@ -684,7 +683,7 @@ private void BuildMachineByte() for (int j = 8; j < 16; j++) { if (section[j].isSectionOn) - number |= 1 << j; + number |= 1 << (j-8); } p_254.pgn[p_254.sc9to16] = unchecked((byte)number); diff --git a/SourceCode/GPS/Forms/Settings/ConfigTool.Designer.cs b/SourceCode/GPS/Forms/Settings/ConfigTool.Designer.cs index 79cfbda25..78925d826 100644 --- a/SourceCode/GPS/Forms/Settings/ConfigTool.Designer.cs +++ b/SourceCode/GPS/Forms/Settings/ConfigTool.Designer.cs @@ -463,8 +463,6 @@ private void tabTSections_Leave(object sender, EventArgs e) Properties.Settings.Default.setVehicle_toolWidth = mf.tool.width; - Properties.Settings.Default.Save(); - SendRelaySettingsToMachineModule(); } else @@ -549,10 +547,15 @@ private void tabTSections_Leave(object sender, EventArgs e) String str = ""; str = String.Join(",",mf.tool.zoneRanges); Properties.Settings.Default.setTool_zones = str; - Properties.Settings.Default.Save(); mf.LineUpAllZoneButtons(); } + + //no multi color zones + if (mf.tool.isSectionsNotZones) + Properties.Settings.Default.setColor_isMultiColorSections = mf.tool.isMultiColoredSections = false; + + Properties.Settings.Default.Save(); } private void nudZone1To_Click(object sender, EventArgs e) diff --git a/SourceCode/GPS/Forms/Settings/FormSteerWiz.Designer.cs b/SourceCode/GPS/Forms/Settings/FormSteerWiz.Designer.cs index 54f9457bc..74daaef63 100644 --- a/SourceCode/GPS/Forms/Settings/FormSteerWiz.Designer.cs +++ b/SourceCode/GPS/Forms/Settings/FormSteerWiz.Designer.cs @@ -168,12 +168,12 @@ private void InitializeComponent() this.label93 = new System.Windows.Forms.Label(); this.button14 = new System.Windows.Forms.Button(); this.tabAntennaOffset = new System.Windows.Forms.TabPage(); - this.label103 = new System.Windows.Forms.Label(); this.button11 = new System.Windows.Forms.Button(); this.label102 = new System.Windows.Forms.Label(); this.nudAntennaOffset = new System.Windows.Forms.NumericUpDown(); this.label104 = new System.Windows.Forms.Label(); this.button12 = new System.Windows.Forms.Button(); + this.label103 = new System.Windows.Forms.Label(); this.tabButtonSwitch = new System.Windows.Forms.TabPage(); this.button15 = new System.Windows.Forms.Button(); this.label53 = new System.Windows.Forms.Label(); @@ -198,6 +198,7 @@ private void InitializeComponent() this.btnOkNext_Danfoss = new System.Windows.Forms.Button(); this.cboxDanfoss = new System.Windows.Forms.CheckBox(); this.tabRollInv = new System.Windows.Forms.TabPage(); + this.label115 = new System.Windows.Forms.Label(); this.lblRoll = new System.Windows.Forms.Label(); this.pictureBox9 = new System.Windows.Forms.PictureBox(); this.cboxDataInvertRoll = new System.Windows.Forms.CheckBox(); @@ -320,6 +321,7 @@ private void InitializeComponent() this.btnPrev_PGain = new System.Windows.Forms.Button(); this.btnNext_PGain = new System.Windows.Forms.Button(); this.tabEnd = new System.Windows.Forms.TabPage(); + this.label116 = new System.Windows.Forms.Label(); this.btnRestartWizard = new System.Windows.Forms.Button(); this.label69 = new System.Windows.Forms.Label(); this.btnPrev_End = new System.Windows.Forms.Button(); @@ -336,8 +338,6 @@ private void InitializeComponent() this.label67 = new System.Windows.Forms.Label(); this.lblBarWasOffset = new System.Windows.Forms.Label(); this.btnCloseAll = new System.Windows.Forms.Button(); - this.label115 = new System.Windows.Forms.Label(); - this.label116 = new System.Windows.Forms.Label(); this.tabControl1.SuspendLayout(); this.tabSteer.SuspendLayout(); this.tabStan.SuspendLayout(); @@ -2121,6 +2121,11 @@ private void InitializeComponent() 0, 0, 0}); + this.nudAntennaPivot.Minimum = new decimal(new int[] { + 999, + 0, + 0, + -2147483648}); this.nudAntennaPivot.Name = "nudAntennaPivot"; this.nudAntennaPivot.ReadOnly = true; this.nudAntennaPivot.Size = new System.Drawing.Size(165, 65); @@ -2309,20 +2314,6 @@ private void InitializeComponent() this.tabAntennaOffset.TabIndex = 40; this.tabAntennaOffset.Text = "AntOff"; // - // label103 - // - this.label103.BackColor = System.Drawing.Color.Linen; - this.label103.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; - this.label103.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label103.ForeColor = System.Drawing.Color.Black; - this.label103.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.label103.Location = new System.Drawing.Point(171, 1); - this.label103.Name = "label103"; - this.label103.Size = new System.Drawing.Size(313, 187); - this.label103.TabIndex = 538; - this.label103.Text = "Set Antenna Offset"; - this.label103.TextAlign = System.Drawing.ContentAlignment.TopCenter; - // // button11 // this.button11.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); @@ -2365,6 +2356,11 @@ private void InitializeComponent() 0, 0, 0}); + this.nudAntennaOffset.Minimum = new decimal(new int[] { + 999, + 0, + 0, + -2147483648}); this.nudAntennaOffset.Name = "nudAntennaOffset"; this.nudAntennaOffset.ReadOnly = true; this.nudAntennaOffset.Size = new System.Drawing.Size(165, 65); @@ -2409,6 +2405,20 @@ private void InitializeComponent() this.button12.UseVisualStyleBackColor = false; this.button12.Click += new System.EventHandler(this.btnOkNext_Click); // + // label103 + // + this.label103.BackColor = System.Drawing.Color.Linen; + this.label103.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.label103.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label103.ForeColor = System.Drawing.Color.Black; + this.label103.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.label103.Location = new System.Drawing.Point(171, 1); + this.label103.Name = "label103"; + this.label103.Size = new System.Drawing.Size(313, 187); + this.label103.TabIndex = 538; + this.label103.Text = "Set Antenna Offset"; + this.label103.TextAlign = System.Drawing.ContentAlignment.TopCenter; + // // tabButtonSwitch // this.tabButtonSwitch.BackColor = System.Drawing.Color.White; @@ -2783,6 +2793,19 @@ private void InitializeComponent() this.tabRollInv.TabIndex = 42; this.tabRollInv.Text = "RollInv"; // + // label115 + // + this.label115.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.label115.BackColor = System.Drawing.Color.Transparent; + this.label115.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label115.ForeColor = System.Drawing.Color.Black; + this.label115.Location = new System.Drawing.Point(139, 105); + this.label115.Name = "label115"; + this.label115.Size = new System.Drawing.Size(268, 56); + this.label115.TabIndex = 552; + this.label115.Text = "If not Select Invert Roll"; + this.label115.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // // lblRoll // this.lblRoll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); @@ -4658,6 +4681,19 @@ private void InitializeComponent() this.tabEnd.TabIndex = 32; this.tabEnd.Text = "End"; // + // label116 + // + this.label116.BackColor = System.Drawing.Color.Transparent; + this.label116.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label116.ForeColor = System.Drawing.Color.Black; + this.label116.Location = new System.Drawing.Point(50, 114); + this.label116.Name = "label116"; + this.label116.Size = new System.Drawing.Size(530, 152); + this.label116.TabIndex = 538; + this.label116.Text = "Now go drive an AB Line and fine tune settings based on your speed and soil condi" + + "tions.\r\n\r\nRemember: CPD, Min PWM, and Look Ahead are critical settings. "; + this.label116.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // // btnRestartWizard // this.btnRestartWizard.BackColor = System.Drawing.Color.LightBlue; @@ -4875,32 +4911,6 @@ private void InitializeComponent() this.btnCloseAll.UseVisualStyleBackColor = false; this.btnCloseAll.Click += new System.EventHandler(this.btnExit_Click); // - // label115 - // - this.label115.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.label115.BackColor = System.Drawing.Color.Transparent; - this.label115.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label115.ForeColor = System.Drawing.Color.Black; - this.label115.Location = new System.Drawing.Point(139, 105); - this.label115.Name = "label115"; - this.label115.Size = new System.Drawing.Size(268, 56); - this.label115.TabIndex = 552; - this.label115.Text = "If not Select Invert Roll"; - this.label115.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // label116 - // - this.label116.BackColor = System.Drawing.Color.Transparent; - this.label116.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label116.ForeColor = System.Drawing.Color.Black; - this.label116.Location = new System.Drawing.Point(50, 114); - this.label116.Name = "label116"; - this.label116.Size = new System.Drawing.Size(530, 152); - this.label116.TabIndex = 538; - this.label116.Text = "Now go drive an AB Line and fine tune settings based on your speed and soil condi" + - "tions.\r\n\r\nRemember: CPD, Min PWM, and Look Ahead are critical settings. "; - this.label116.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // // FormSteerWiz // this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F); diff --git a/SourceCode/GPS/Forms/Settings/FormSteerWiz.resx b/SourceCode/GPS/Forms/Settings/FormSteerWiz.resx index 4eee3b4ef..614471cba 100644 --- a/SourceCode/GPS/Forms/Settings/FormSteerWiz.resx +++ b/SourceCode/GPS/Forms/Settings/FormSteerWiz.resx @@ -128,7 +128,7 @@ AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAADu - IQAAAk1TRnQBSQFMAgEBBAEAAXABAwFwAQMBQgEAASwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo + IQAAAk1TRnQBSQFMAgEBBAEAAXgBAwF4AQMBQgEAASwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo AwABCAEBAgABWAMAAQEBAAEIBQABwAFaGAABgAIAAYADAAKAAQABgAMAAYABAAGAAQACgAIAA8ABAAHA AdwBwAEAAfABygGmAQABMwUAATMBAAEzAQABMwEAAjMCAAMWAQADHAEAAyIBAAMpAQADVQEAA00BAANC AQADOQEAAYABfAH/AQACUAH/AQABkwEAAdYBAAH/AewBzAEAAcYB1gHvAQAB1gLnAQABkAGpAa0CAAH/ diff --git a/SourceCode/GPS/Forms/UDPComm.Designer.cs b/SourceCode/GPS/Forms/UDPComm.Designer.cs index 4e141499a..cc39fab82 100644 --- a/SourceCode/GPS/Forms/UDPComm.Designer.cs +++ b/SourceCode/GPS/Forms/UDPComm.Designer.cs @@ -453,13 +453,13 @@ protected override bool ProcessCmdKey(ref Message msg, Keys keyData) if ((char)keyData == hotkeys[4]) //auto section on off { - btnSectionMasterAuto.PerformClick(); + btnSectionMasterManual.PerformClick(); return true; // indicate that you handled this keystroke } if ((char)keyData == hotkeys[5]) //auto section on off { - btnSectionMasterManual.PerformClick(); + btnSectionMasterAuto.PerformClick(); return true; // indicate that you handled this keystroke } diff --git a/SourceCode/GPS/Properties/AssemblyInfo.cs b/SourceCode/GPS/Properties/AssemblyInfo.cs index 84c1ab7af..0d640cedc 100644 --- a/SourceCode/GPS/Properties/AssemblyInfo.cs +++ b/SourceCode/GPS/Properties/AssemblyInfo.cs @@ -31,5 +31,5 @@ // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("5.7.0")] -[assembly: AssemblyFileVersion("5.7.0")] \ No newline at end of file +[assembly: AssemblyVersion("5.7.1")] +[assembly: AssemblyFileVersion("5.7.1")] \ No newline at end of file diff --git a/SourceCode/GPS/Properties/Settings.Designer.cs b/SourceCode/GPS/Properties/Settings.Designer.cs index d7117dfc6..8b0314ac7 100644 --- a/SourceCode/GPS/Properties/Settings.Designer.cs +++ b/SourceCode/GPS/Properties/Settings.Designer.cs @@ -25,7 +25,7 @@ public static Settings Default { [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Configuration.DefaultSettingValueAttribute("-63")] + [global::System.Configuration.DefaultSettingValueAttribute("-62")] public double setDisplay_camPitch { get { return ((double)(this["setDisplay_camPitch"])); diff --git a/SourceCode/GPS/Properties/Settings.settings b/SourceCode/GPS/Properties/Settings.settings index c97035c28..89226a7e7 100644 --- a/SourceCode/GPS/Properties/Settings.settings +++ b/SourceCode/GPS/Properties/Settings.settings @@ -3,7 +3,7 @@ - -63 + -62 30, 30 diff --git a/SourceCode/GPS/app.config b/SourceCode/GPS/app.config index 5e3457c36..11d10c6d8 100644 --- a/SourceCode/GPS/app.config +++ b/SourceCode/GPS/app.config @@ -2,28 +2,13 @@ -
- - - 1 - - - 1 - - - 0 - - - 2 - - - -63 + -62 30, 30