From c8cee269347a2ce5a728833102bf41a8ce62163d Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Tue, 24 Jan 2023 17:31:58 -0700 Subject: [PATCH 01/17] Network Loop for broadcast --- .../AgIO/Source/Forms/FormUDP.Designer.cs | 56 +++++++ SourceCode/AgIO/Source/Forms/FormUDP.cs | 147 ++++++++++++++---- 2 files changed, 171 insertions(+), 32 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 9edef25ff..0952c87a2 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -57,6 +57,10 @@ private void InitializeComponent() this.btnSerialOK = new System.Windows.Forms.Button(); this.label7 = new System.Windows.Forms.Label(); this.label10 = new System.Windows.Forms.Label(); + this.lblSent = new System.Windows.Forms.Label(); + this.lblRecd = new System.Windows.Forms.Label(); + this.label11 = new System.Windows.Forms.Label(); + this.label13 = new System.Windows.Forms.Label(); this.groupBox4.SuspendLayout(); this.groupBox3.SuspendLayout(); this.groupBox5.SuspendLayout(); @@ -446,12 +450,60 @@ private void InitializeComponent() this.label10.Text = "To Module"; this.label10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // + // lblSent + // + this.lblSent.AutoSize = true; + this.lblSent.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblSent.Location = new System.Drawing.Point(467, 400); + this.lblSent.Name = "lblSent"; + this.lblSent.Size = new System.Drawing.Size(48, 23); + this.lblSent.TabIndex = 165; + this.lblSent.Text = "Sent"; + this.lblSent.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblRecd + // + this.lblRecd.AutoSize = true; + this.lblRecd.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblRecd.Location = new System.Drawing.Point(467, 436); + this.lblRecd.Name = "lblRecd"; + this.lblRecd.Size = new System.Drawing.Size(52, 23); + this.lblRecd.TabIndex = 166; + this.lblRecd.Text = "Recd"; + this.lblRecd.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(403, 400); + this.label11.Name = "label11"; + this.label11.Size = new System.Drawing.Size(48, 23); + this.label11.TabIndex = 167; + this.label11.Text = "Sent"; + this.label11.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label13 + // + this.label13.AutoSize = true; + 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(403, 436); + this.label13.Name = "label13"; + this.label13.Size = new System.Drawing.Size(56, 23); + this.label13.TabIndex = 168; + this.label13.Text = "Rec\'d"; + this.label13.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.ControlBox = false; + this.Controls.Add(this.label13); + this.Controls.Add(this.label11); + this.Controls.Add(this.lblRecd); + this.Controls.Add(this.lblSent); this.Controls.Add(this.label10); this.Controls.Add(this.label7); this.Controls.Add(this.lblConnectedModules); @@ -524,5 +576,9 @@ private void InitializeComponent() private System.Windows.Forms.Label label7; public System.Windows.Forms.Label label9; private System.Windows.Forms.Label label10; + private System.Windows.Forms.Label lblSent; + private System.Windows.Forms.Label lblRecd; + private System.Windows.Forms.Label label11; + private System.Windows.Forms.Label label13; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 57dca49a6..3ccece2fa 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -1,6 +1,8 @@ using System; using System.ComponentModel; +using System.Linq; using System.Net; +using System.Net.NetworkInformation; using System.Net.Sockets; using System.Windows.Forms; @@ -66,18 +68,22 @@ private void FormUDp_Load(object sender, EventArgs e) } ScanNetwork(); + GetIP4AddressList(); + if (cnt > 1) mf.TimedMessageBox(3000, "More then 1 network", "Connect only the module Network"); } + int cnt = 0; //get the ipv4 address only public void GetIP4AddressList() { label9.Text = ""; - + cnt = 0; foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) { if (IPA.AddressFamily == AddressFamily.InterNetwork) { label9.Text += IPA.ToString() + "\r\n"; + cnt++; } } } @@ -127,41 +133,92 @@ private void timer1_Tick(object sender, EventArgs e) { lblConnectedModules.Text = mf.scanReturn; counter = 0; - } + } + + var ipStats = from nic in NetworkInterface.GetAllNetworkInterfaces() + where nic.NetworkInterfaceType != NetworkInterfaceType.Loopback + && nic.OperationalStatus == OperationalStatus.Up + select nic.GetIPStatistics(); + + var ipStat = ipStats.First(); + + lblRecd.Text = (ipStat.BytesReceived).ToString(); + lblSent.Text = (ipStat.BytesSent).ToString(); + + //NetworkInterface[] adapters = NetworkInterface.GetAllNetworkInterfaces(); + //foreach (NetworkInterface adapter in adapters) + //{ + // if (adapter.NetworkInterfaceType == NetworkInterfaceType.Loopback) continue; + // var properties = adapter.GetIPStatistics(); + // lblIP.Text += adapter.NetworkInterfaceType.ToString() + "\r\n"; + //} } 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) { + 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); - sendIPToModules[7] = ipToSend[0]; - sendIPToModules[8] = ipToSend[1]; - sendIPToModules[9] = ipToSend[2]; + if (result3 == DialogResult.Yes) + { - mf.SendUDPMessage(sendIPToModules, mf.epModuleSet); + sendIPToModules[7] = ipToSend[0]; + sendIPToModules[8] = ipToSend[1]; + sendIPToModules[9] = ipToSend[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.SendUDPMessage(sendIPToModules, mf.epModuleSet); - lblNetworkHelp.Text = - ipToSend[0].ToString() + "." + - ipToSend[1].ToString() + "." + - ipToSend[2].ToString(); - - counter = 0; + 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) + { + + var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + + try + { + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + + scanSocket.SendTo(sendIPToModules, 0, sendIPToModules.Length, SocketFlags.None, mf.epModuleSet); + } + finally + { + scanSocket.Dispose(); + } + } + } + } + } + + 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(); + + lblNetworkHelp.Text = + ipToSend[0].ToString() + "." + + ipToSend[1].ToString() + "." + + ipToSend[2].ToString(); + + counter = 0; + } } } @@ -188,12 +245,38 @@ private void ScanNetwork() { mf.scanReturn = ""; byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; - mf.SendUDPMessage(scanModules, mf.epModuleSet); - } + //mf.SendUDPMessage(scanModules, mf.epModuleSet); - private void btnRescan_Click(object sender, EventArgs e) - { - ScanNetwork(); + 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) + { + + var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + + try + { + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + + scanSocket.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); + } + finally + { + scanSocket.Dispose(); + } + } + } + } + } } } } \ No newline at end of file From c9148271b8aa90661c48992bc792f02cd5361330 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 25 Jan 2023 07:36:30 -0700 Subject: [PATCH 02/17] NetworkAdapter Scan --- .../AgIO/Source/Forms/FormLoop.Designer.cs | 222 +++++------ .../AgIO/Source/Forms/FormUDP.Designer.cs | 350 ++++++------------ SourceCode/AgIO/Source/Forms/FormUDP.cs | 222 +++++------ SourceCode/AgIO/Source/Forms/UDP.designer.cs | 2 +- 4 files changed, 328 insertions(+), 468 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index 85f6879e7..fb8dfb61c 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.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.lblSteerAngle = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label(); this.lblNTRIP_IP = new System.Windows.Forms.Label(); @@ -90,15 +99,6 @@ private void InitializeComponent() 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.statusStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); @@ -106,7 +106,7 @@ private void InitializeComponent() // // oneSecondLoopTimer // - this.oneSecondLoopTimer.Interval = 4000; + this.oneSecondLoopTimer.Interval = 1500; this.oneSecondLoopTimer.Tick += new System.EventHandler(this.oneSecondLoopTimer_Tick); // // label6 @@ -267,6 +267,102 @@ private void InitializeComponent() 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.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); + // // lblSteerAngle // this.lblSteerAngle.AutoSize = true; @@ -340,12 +436,12 @@ private void InitializeComponent() // lblIP // 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", 11.25F, 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.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(148, 56); this.lblIP.TabIndex = 464; this.lblIP.Text = "288.288.288.288"; this.lblIP.TextAlign = System.Drawing.ContentAlignment.BottomCenter; @@ -892,10 +988,10 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(24, 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.Size = new System.Drawing.Size(102, 60); this.btnUDP.TabIndex = 184; this.btnUDP.UseVisualStyleBackColor = false; this.btnUDP.Click += new System.EventHandler(this.btnUDP_Click); @@ -959,102 +1055,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))); @@ -1122,7 +1122,6 @@ 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); @@ -1142,6 +1141,7 @@ private void InitializeComponent() this.Controls.Add(this.lblCurrentLat); this.Controls.Add(this.btnRelayTest); this.Controls.Add(this.btnGPSData); + this.Controls.Add(this.btnUDP); 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; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 0952c87a2..6ff4ce066 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -29,12 +29,10 @@ 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.label6 = new System.Windows.Forms.Label(); + this.lblNetworkHelp = new System.Windows.Forms.Label(); this.cboxIsUDPOn = new System.Windows.Forms.CheckBox(); this.groupBox3 = new System.Windows.Forms.GroupBox(); this.cboxIsSendNMEAToUDP = new System.Windows.Forms.CheckBox(); @@ -47,103 +45,65 @@ private void InitializeComponent() this.nudThirdIP = new System.Windows.Forms.NumericUpDown(); this.label2 = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label(); - this.label4 = new System.Windows.Forms.Label(); - 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.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.label10 = new System.Windows.Forms.Label(); - this.lblSent = new System.Windows.Forms.Label(); - this.lblRecd = new System.Windows.Forms.Label(); - this.label11 = new System.Windows.Forms.Label(); - this.label13 = new System.Windows.Forms.Label(); - this.groupBox4.SuspendLayout(); + this.tboxNets = new System.Windows.Forms.TextBox(); + this.label4 = new System.Windows.Forms.Label(); + this.tboxModules = new System.Windows.Forms.TextBox(); this.groupBox3.SuspendLayout(); this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecondIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); - this.groupBox1.SuspendLayout(); 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; + // 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(9, 53); + this.label12.Name = "label12"; + this.label12.Size = new System.Drawing.Size(159, 23); + this.label12.TabIndex = 142; + this.label12.Text = "Network Adapters"; + 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(165, 6); + this.tboxHostName.Name = "tboxHostName"; + this.tboxHostName.ReadOnly = true; + this.tboxHostName.Size = new System.Drawing.Size(211, 30); + this.tboxHostName.TabIndex = 86; + this.tboxHostName.Text = "HostName"; // // 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(427, 408); this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(220, 23); + this.label6.Size = new System.Drawing.Size(187, 23); this.label6.TabIndex = 144; - this.label6.Text = "Current Network Address"; + this.label6.Text = "Current AgIO 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.Font = new System.Drawing.Font("Tahoma", 18F, 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.Location = new System.Drawing.Point(415, 431); this.lblNetworkHelp.Name = "lblNetworkHelp"; - this.lblNetworkHelp.Size = new System.Drawing.Size(221, 46); + this.lblNetworkHelp.Size = new System.Drawing.Size(221, 33); this.lblNetworkHelp.TabIndex = 143; this.lblNetworkHelp.Text = "192.168.1.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; @@ -153,24 +113,25 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(426, 620); 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; + this.cboxIsUDPOn.Click += new System.EventHandler(this.cboxPlugin_Click); // // 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.Location = new System.Drawing.Point(12, 600); this.groupBox3.Name = "groupBox3"; - this.groupBox3.Size = new System.Drawing.Size(227, 100); + this.groupBox3.Size = new System.Drawing.Size(171, 80); this.groupBox3.TabIndex = 94; this.groupBox3.TabStop = false; - this.groupBox3.Text = "Send NMEA to Network"; + this.groupBox3.Text = "NMEA to Network"; // // cboxIsSendNMEAToUDP // @@ -181,21 +142,22 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(30, 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; + this.cboxIsSendNMEAToUDP.Click += new System.EventHandler(this.cboxPlugin_Click); // // 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.Location = new System.Drawing.Point(189, 600); this.groupBox5.Name = "groupBox5"; - this.groupBox5.Size = new System.Drawing.Size(227, 100); + this.groupBox5.Size = new System.Drawing.Size(171, 80); this.groupBox5.TabIndex = 95; this.groupBox5.TabStop = false; this.groupBox5.Text = "Application Plugin"; @@ -210,36 +172,37 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(14, 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; + this.cboxPlugin.Click += new System.EventHandler(this.cboxPlugin_Click); // // timer1 // this.timer1.Enabled = true; - this.timer1.Interval = 1200; + this.timer1.Interval = 2000; 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(456, 488); this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(212, 23); + this.label1.Size = new System.Drawing.Size(185, 23); this.label1.TabIndex = 147; - this.label1.Text = "Change Subnet Address"; + this.label1.Text = "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(415, 517); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, @@ -260,7 +223,7 @@ private void InitializeComponent() // 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.Location = new System.Drawing.Point(524, 517); this.nudSecondIP.Maximum = new decimal(new int[] { 255, 0, @@ -281,7 +244,7 @@ private void InitializeComponent() // 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(632, 517); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, @@ -302,7 +265,7 @@ private void InitializeComponent() // 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(503, 512); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(24, 35); this.label2.TabIndex = 152; @@ -313,84 +276,36 @@ 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(612, 512); 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; // - // 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.Name = "label4"; - this.label4.Size = new System.Drawing.Size(24, 35); - this.label4.TabIndex = 154; - this.label4.Text = "."; - this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // 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.Name = "label5"; - this.label5.Size = new System.Drawing.Size(35, 35); - this.label5.TabIndex = 155; - this.label5.Text = "X"; - 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.Location = new System.Drawing.Point(649, 394); this.label8.Name = "label8"; - this.label8.Size = new System.Drawing.Size(119, 23); + this.label8.Size = new System.Drawing.Size(75, 23); this.label8.TabIndex = 157; - this.label8.Text = "Send Subnet"; + this.label8.Text = "Confirm"; this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // - // lblConnectedModules - // - 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; - // // btnSendSubnet // this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSendSubnet.Enabled = false; 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.OK64; + this.btnSendSubnet.Location = new System.Drawing.Point(642, 420); this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(98, 64); + this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); this.btnSendSubnet.TabIndex = 151; this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; this.btnSendSubnet.UseVisualStyleBackColor = true; @@ -405,110 +320,69 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(656, 616); this.btnSerialCancel.Name = "btnSerialCancel"; this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); 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.Location = new System.Drawing.Point(512, 26); this.label7.Name = "label7"; - this.label7.Size = new System.Drawing.Size(126, 23); + this.label7.Size = new System.Drawing.Size(118, 23); this.label7.TabIndex = 161; - this.label7.Text = "Network Scan"; + this.label7.Text = "Module Scan"; this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // 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.Name = "label10"; - this.label10.Size = new System.Drawing.Size(98, 23); - this.label10.TabIndex = 164; - this.label10.Text = "To Module"; - this.label10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // lblSent - // - this.lblSent.AutoSize = true; - this.lblSent.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblSent.Location = new System.Drawing.Point(467, 400); - this.lblSent.Name = "lblSent"; - this.lblSent.Size = new System.Drawing.Size(48, 23); - this.lblSent.TabIndex = 165; - this.lblSent.Text = "Sent"; - this.lblSent.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // lblRecd - // - this.lblRecd.AutoSize = true; - this.lblRecd.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblRecd.Location = new System.Drawing.Point(467, 436); - this.lblRecd.Name = "lblRecd"; - this.lblRecd.Size = new System.Drawing.Size(52, 23); - this.lblRecd.TabIndex = 166; - this.lblRecd.Text = "Recd"; - this.lblRecd.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(403, 400); - this.label11.Name = "label11"; - this.label11.Size = new System.Drawing.Size(48, 23); - this.label11.TabIndex = 167; - this.label11.Text = "Sent"; - this.label11.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // label13 - // - this.label13.AutoSize = true; - 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(403, 436); - this.label13.Name = "label13"; - this.label13.Size = new System.Drawing.Size(56, 23); - this.label13.TabIndex = 168; - this.label13.Text = "Rec\'d"; - this.label13.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(12, 82); + this.tboxNets.Multiline = true; + this.tboxNets.Name = "tboxNets"; + this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Both; + this.tboxNets.Size = new System.Drawing.Size(364, 475); + this.tboxNets.TabIndex = 162; + // + // label4 + // + this.label4.AutoSize = true; + 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(12, 9); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(154, 23); + this.label4.TabIndex = 163; + this.label4.Text = "Computer Name:"; + this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // tboxModules + // + this.tboxModules.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.tboxModules.Location = new System.Drawing.Point(419, 53); + this.tboxModules.Multiline = true; + this.tboxModules.Name = "tboxModules"; + this.tboxModules.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; + this.tboxModules.Size = new System.Drawing.Size(303, 320); + this.tboxModules.TabIndex = 164; // // 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(756, 691); this.ControlBox = false; - this.Controls.Add(this.label13); - this.Controls.Add(this.label11); - this.Controls.Add(this.lblRecd); - this.Controls.Add(this.lblSent); - this.Controls.Add(this.label10); + this.Controls.Add(this.cboxIsUDPOn); + this.Controls.Add(this.tboxModules); + this.Controls.Add(this.label4); + this.Controls.Add(this.tboxNets); + this.Controls.Add(this.label12); + this.Controls.Add(this.label6); + this.Controls.Add(this.tboxHostName); + 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); @@ -516,12 +390,9 @@ private void InitializeComponent() this.Controls.Add(this.groupBox3); 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.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; @@ -533,24 +404,18 @@ 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.nudThirdIP)).EndInit(); - this.groupBox1.ResumeLayout(false); 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; @@ -567,18 +432,11 @@ private void InitializeComponent() 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.Label label10; - private System.Windows.Forms.Label lblSent; - private System.Windows.Forms.Label lblRecd; - private System.Windows.Forms.Label label11; - private System.Windows.Forms.Label label13; + private System.Windows.Forms.TextBox tboxNets; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.TextBox tboxModules; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 3ccece2fa..e35ef8d56 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -31,14 +31,6 @@ public FormUDP(Form callingForm) 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) @@ -67,49 +59,15 @@ private void FormUDp_Load(object sender, EventArgs e) btnSendSubnet.Enabled = false; } - ScanNetwork(); - GetIP4AddressList(); - if (cnt > 1) mf.TimedMessageBox(3000, "More then 1 network", "Connect only the module Network"); - } - - int cnt = 0; - //get the ipv4 address only - public void GetIP4AddressList() - { - label9.Text = ""; - cnt = 0; - foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) - { - if (IPA.AddressFamily == AddressFamily.InterNetwork) - { - label9.Text += IPA.ToString() + "\r\n"; - cnt++; - } - } - } + if (!cboxIsUDPOn.Checked) cboxIsUDPOn.BackColor = System.Drawing.Color.Salmon; - 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; - } - } - } - } + ScanNetwork(); + //GetIP4AddressList(); } private void timer1_Tick(object sender, EventArgs e) { - GetIP4AddressList(); + //GetIP4AddressList(); //IsValidNetworkFound(); if (cboxIsUDPOn.Checked) { @@ -124,34 +82,60 @@ private void timer1_Tick(object sender, EventArgs e) cboxPlugin.Checked = false; } - if (counter == 0) - { - ScanNetwork(); - counter++; - } - else + ScanNetwork(); + + tboxModules.Text = mf.scanReturn; + } + + private void ScanNetwork() + { + mf.scanReturn = ""; + tboxNets.Text = ""; + + byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; + //mf.SendUDPMessage(scanModules, mf.epModuleSet); + + foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) { - lblConnectedModules.Text = mf.scanReturn; - counter = 0; - } - var ipStats = from nic in NetworkInterface.GetAllNetworkInterfaces() - where nic.NetworkInterfaceType != NetworkInterfaceType.Loopback - && nic.OperationalStatus == OperationalStatus.Up - select nic.GetIPStatistics(); - var ipStat = ipStats.First(); + if (nic.Supports(NetworkInterfaceComponent.IPv4) ) + { + 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)) + { + var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + try + { + tboxNets.Text += + info.Address + " Status - " + nic.OperationalStatus + "\r\n"; + + tboxNets.Text += nic.NetworkInterfaceType.ToString() + "\r\n"; + + var properties = nic.GetIPStatistics(); + tboxNets.Text += "Sent: " + properties.BytesSent.ToString() + + " Recd: " + properties.BytesReceived.ToString() + "\r\n\r\n"; - lblRecd.Text = (ipStat.BytesReceived).ToString(); - lblSent.Text = (ipStat.BytesSent).ToString(); + if ( nic.OperationalStatus == OperationalStatus.Up + && info.IPv4Mask != null) + { + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); - //NetworkInterface[] adapters = NetworkInterface.GetAllNetworkInterfaces(); - //foreach (NetworkInterface adapter in adapters) - //{ - // if (adapter.NetworkInterfaceType == NetworkInterfaceType.Loopback) continue; - // var properties = adapter.GetIPStatistics(); - // lblIP.Text += adapter.NetworkInterfaceType.ToString() + "\r\n"; - //} + scanSocket.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); + } + } + finally + { + scanSocket.Dispose(); + } + } + } + } + } } private void btnSendSubnet_Click(object sender, EventArgs e) @@ -210,73 +194,91 @@ private void btnSendSubnet_Click(object sender, EventArgs e) 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(); - lblNetworkHelp.Text = - ipToSend[0].ToString() + "." + - ipToSend[1].ToString() + "." + - ipToSend[2].ToString(); + //lblNetworkHelp.Text = + // ipToSend[0].ToString() + "." + + // ipToSend[1].ToString() + "." + + // ipToSend[2].ToString(); + + //counter = 0; - counter = 0; + 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(); } } } - int counter = 0; private void nudFirstIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[0] = (byte)nudFirstIP.Value; + btnSendSubnet.Enabled = true; } private void nudSecondIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[1] = (byte)nudSecondIP.Value; + btnSendSubnet.Enabled = true; } private void nudThirdIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[2] = (byte)nudThirdIP.Value; + btnSendSubnet.Enabled = true; } - private void ScanNetwork() - { - mf.scanReturn = ""; - byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; - //mf.SendUDPMessage(scanModules, mf.epModuleSet); - 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) - { - - var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + private void cboxPlugin_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; - try - { - scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); - scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); - scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + Properties.Settings.Default.Save(); + Application.Restart(); + Environment.Exit(0); + Close(); - scanSocket.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); - } - finally - { - scanSocket.Dispose(); - } - } - } - } - } } + + ////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/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 9fee39524..4dfd5e0c4 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -65,7 +65,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"; } } From 1998845125a86a135ca2555fc479765e68f3b288 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 25 Jan 2023 09:47:50 -0700 Subject: [PATCH 03/17] Shortcut keys, multicolor section no zones --- .../AgIO/Source/Forms/FormUDP.Designer.cs | 67 ++++++++++-------- SourceCode/AgIO/Source/Forms/FormUDP.cs | 26 ++++--- SourceCode/AgIO/Source/btnImages/B_UDP.png | Bin 7677 -> 8191 bytes SourceCode/GPS/Forms/Controls.Designer.cs | 13 +++- .../GPS/Forms/Settings/ConfigTool.Designer.cs | 9 ++- SourceCode/GPS/Forms/UDPComm.Designer.cs | 4 +- 6 files changed, 71 insertions(+), 48 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 6ff4ce066..730ec6bf0 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -30,7 +30,6 @@ private void InitializeComponent() { this.components = new System.ComponentModel.Container(); this.label12 = new System.Windows.Forms.Label(); - this.tboxHostName = new System.Windows.Forms.TextBox(); this.label6 = new System.Windows.Forms.Label(); this.lblNetworkHelp = new System.Windows.Forms.Label(); this.cboxIsUDPOn = new System.Windows.Forms.CheckBox(); @@ -52,6 +51,7 @@ private void InitializeComponent() this.tboxNets = new System.Windows.Forms.TextBox(); this.label4 = new System.Windows.Forms.Label(); this.tboxModules = new System.Windows.Forms.TextBox(); + this.lblHostname = new System.Windows.Forms.Label(); this.groupBox3.SuspendLayout(); this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); @@ -70,21 +70,11 @@ private void InitializeComponent() this.label12.Text = "Network Adapters"; 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(165, 6); - this.tboxHostName.Name = "tboxHostName"; - this.tboxHostName.ReadOnly = true; - this.tboxHostName.Size = new System.Drawing.Size(211, 30); - this.tboxHostName.TabIndex = 86; - this.tboxHostName.Text = "HostName"; - // // 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(427, 408); + this.label6.Location = new System.Drawing.Point(383, 408); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(187, 23); this.label6.TabIndex = 144; @@ -97,7 +87,7 @@ private void InitializeComponent() this.lblNetworkHelp.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; this.lblNetworkHelp.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblNetworkHelp.ForeColor = System.Drawing.SystemColors.ControlDarkDark; - this.lblNetworkHelp.Location = new System.Drawing.Point(415, 431); + this.lblNetworkHelp.Location = new System.Drawing.Point(371, 431); this.lblNetworkHelp.Name = "lblNetworkHelp"; this.lblNetworkHelp.Size = new System.Drawing.Size(221, 33); this.lblNetworkHelp.TabIndex = 143; @@ -113,7 +103,7 @@ private void InitializeComponent() 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(426, 620); + this.cboxIsUDPOn.Location = new System.Drawing.Point(384, 620); this.cboxIsUDPOn.Name = "cboxIsUDPOn"; this.cboxIsUDPOn.Size = new System.Drawing.Size(145, 50); this.cboxIsUDPOn.TabIndex = 92; @@ -191,7 +181,7 @@ private void InitializeComponent() // 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(456, 488); + this.label1.Location = new System.Drawing.Point(412, 488); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(185, 23); this.label1.TabIndex = 147; @@ -202,7 +192,7 @@ private void InitializeComponent() // 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(415, 517); + this.nudFirstIP.Location = new System.Drawing.Point(371, 517); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, @@ -223,7 +213,7 @@ private void InitializeComponent() // 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(524, 517); + this.nudSecondIP.Location = new System.Drawing.Point(480, 517); this.nudSecondIP.Maximum = new decimal(new int[] { 255, 0, @@ -244,7 +234,7 @@ private void InitializeComponent() // 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(632, 517); + this.nudThirdIP.Location = new System.Drawing.Point(588, 517); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, @@ -265,7 +255,7 @@ private void InitializeComponent() // 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(503, 512); + this.label2.Location = new System.Drawing.Point(459, 512); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(24, 35); this.label2.TabIndex = 152; @@ -276,7 +266,7 @@ 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(612, 512); + this.label3.Location = new System.Drawing.Point(568, 512); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(24, 35); this.label3.TabIndex = 153; @@ -287,7 +277,7 @@ private void InitializeComponent() // 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(649, 394); + this.label8.Location = new System.Drawing.Point(605, 394); this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(75, 23); this.label8.TabIndex = 157; @@ -303,7 +293,7 @@ private void InitializeComponent() 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.OK64; - this.btnSendSubnet.Location = new System.Drawing.Point(642, 420); + this.btnSendSubnet.Location = new System.Drawing.Point(598, 420); this.btnSendSubnet.Name = "btnSendSubnet"; this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); this.btnSendSubnet.TabIndex = 151; @@ -320,7 +310,7 @@ private void InitializeComponent() 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(656, 616); + this.btnSerialCancel.Location = new System.Drawing.Point(588, 616); this.btnSerialCancel.Name = "btnSerialCancel"; this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); this.btnSerialCancel.TabIndex = 71; @@ -330,7 +320,7 @@ private void InitializeComponent() // 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(512, 26); + this.label7.Location = new System.Drawing.Point(460, 26); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(118, 23); this.label7.TabIndex = 161; @@ -344,7 +334,7 @@ private void InitializeComponent() this.tboxNets.Multiline = true; this.tboxNets.Name = "tboxNets"; this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Both; - this.tboxNets.Size = new System.Drawing.Size(364, 475); + this.tboxNets.Size = new System.Drawing.Size(324, 475); this.tboxNets.TabIndex = 162; // // label4 @@ -360,27 +350,42 @@ private void InitializeComponent() // // tboxModules // - this.tboxModules.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxModules.Location = new System.Drawing.Point(419, 53); + this.tboxModules.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.tboxModules.Location = new System.Drawing.Point(387, 52); this.tboxModules.Multiline = true; this.tboxModules.Name = "tboxModules"; this.tboxModules.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; - this.tboxModules.Size = new System.Drawing.Size(303, 320); + this.tboxModules.Size = new System.Drawing.Size(258, 320); this.tboxModules.TabIndex = 164; + this.tboxModules.Text = "192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nStee" + + "r Module\r\n\r\n192.168.1.126\r\nSteer Module"; + this.tboxModules.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + // + // 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(162, 9); + this.lblHostname.Name = "lblHostname"; + this.lblHostname.Size = new System.Drawing.Size(118, 23); + this.lblHostname.TabIndex = 165; + this.lblHostname.Text = "Module Scan"; + this.lblHostname.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(756, 691); + this.ClientSize = new System.Drawing.Size(688, 691); this.ControlBox = false; + this.Controls.Add(this.lblHostname); this.Controls.Add(this.cboxIsUDPOn); this.Controls.Add(this.tboxModules); this.Controls.Add(this.label4); this.Controls.Add(this.tboxNets); this.Controls.Add(this.label12); this.Controls.Add(this.label6); - this.Controls.Add(this.tboxHostName); this.Controls.Add(this.lblNetworkHelp); this.Controls.Add(this.label7); this.Controls.Add(this.btnSendSubnet); @@ -416,7 +421,6 @@ private void InitializeComponent() #endregion private System.Windows.Forms.Button btnSerialCancel; - private System.Windows.Forms.TextBox tboxHostName; private System.Windows.Forms.CheckBox cboxIsUDPOn; private System.Windows.Forms.GroupBox groupBox3; private System.Windows.Forms.CheckBox cboxIsSendNMEAToUDP; @@ -438,5 +442,6 @@ private void InitializeComponent() private System.Windows.Forms.TextBox tboxNets; private System.Windows.Forms.Label label4; private System.Windows.Forms.TextBox tboxModules; + private System.Windows.Forms.Label lblHostname; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index e35ef8d56..5470566f7 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -35,8 +35,8 @@ private void btnSerialOK_Click(object sender, EventArgs e) private void FormUDp_Load(object sender, EventArgs e) { - string hostName = Dns.GetHostName(); // Retrieve the Name of HOST - tboxHostName.Text = hostName; + lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST + tboxModules.Text = "Scanning"; cboxIsUDPOn.Checked = Properties.Settings.Default.setUDP_isOn; cboxPlugin.Checked = Properties.Settings.Default.setUDP_isUsePluginApp; @@ -106,31 +106,32 @@ private void ScanNetwork() // Only InterNetwork and not loopback which have a subnetmask if (info.Address.AddressFamily == AddressFamily.InterNetwork && !IPAddress.IsLoopback(info.Address)) { - var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); + Socket scanSocket; try { + var properties = nic.GetIPStatistics(); tboxNets.Text += info.Address + " Status - " + nic.OperationalStatus + "\r\n"; - tboxNets.Text += nic.NetworkInterfaceType.ToString() + "\r\n"; - - var properties = nic.GetIPStatistics(); - tboxNets.Text += "Sent: " + properties.BytesSent.ToString() - + " Recd: " + properties.BytesReceived.ToString() + "\r\n\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) { + 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); scanSocket.Bind(new IPEndPoint(info.Address, 9999)); scanSocket.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); + scanSocket.Dispose(); } } finally { - scanSocket.Dispose(); } } } @@ -211,6 +212,13 @@ private void btnSendSubnet_Click(object sender, EventArgs e) Environment.Exit(0); Close(); } + else + { + btnSendSubnet.Enabled = false; + 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; + } } } diff --git a/SourceCode/AgIO/Source/btnImages/B_UDP.png b/SourceCode/AgIO/Source/btnImages/B_UDP.png index 3d0e23fbd165bb2007a2f66b4cb8f43ad3d44de2..c93ff08970f543706bdb49324ebefd221285c137 100644 GIT binary patch delta 8188 zcmV!FR;=~QZvw8U0Krk4D5luqH zM7_*N8cpx@&fMPH`@a9qC1W88%}B_sEN$4FbMHO%+x!3aw}1b02DxAt?1Eje3wFW& zE8G1WH_GczT&2NMt-rSsVIGiKh z-CeT=r>v}0yX%UwJ7O8)O_~k&c(&8JM`DxlViJflF?2 zR$tWH(tpyK!fxj*03QnAzx&u@&Z_F_PbU+}ZvpK4M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*qoM6N<$g30+18UO$Q 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/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/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 } From b1a1fb57af4c84aadb17e2718478975f49a689d8 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 25 Jan 2023 15:16:20 -0700 Subject: [PATCH 04/17] VPN and disconnect AgIO Fiuxes --- .../AgIO/Source/Forms/Controls.Designer.cs | 13 ++++---- SourceCode/AgIO/Source/Forms/FormLoop.cs | 2 +- .../AgIO/Source/Forms/FormUDP.Designer.cs | 6 ++-- SourceCode/AgIO/Source/Forms/FormUDP.cs | 30 +++++++++++-------- 4 files changed, 28 insertions(+), 23 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs index 9b14e5ef5..7ba8945a6 100644 --- a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs @@ -84,12 +84,13 @@ private void SettingsUDP() { using (var form = new FormUDP(this)) { - if (form.ShowDialog(this) == DialogResult.OK) - { - //Clicked Save - Application.Restart(); - Environment.Exit(0); - } + form.ShowDialog(this); + //if (form.ShowDialog(this) == DialogResult.OK) + //{ + // //Clicked Save + // Application.Restart(); + // Environment.Exit(0); + //} } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index 61542f088..b0ffb08ce 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -324,7 +324,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 diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 730ec6bf0..f229ef77b 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -287,7 +287,6 @@ private void InitializeComponent() // btnSendSubnet // this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSendSubnet.Enabled = false; 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))); @@ -309,12 +308,13 @@ 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(588, 616); + this.btnSerialCancel.Image = global::AgIO.Properties.Resources.OK64; + this.btnSerialCancel.Location = new System.Drawing.Point(594, 616); this.btnSerialCancel.Name = "btnSerialCancel"; this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); this.btnSerialCancel.TabIndex = 71; this.btnSerialCancel.UseVisualStyleBackColor = true; + this.btnSerialCancel.Click += new System.EventHandler(this.cboxPlugin_Click); // // label7 // diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 5470566f7..0e89e7c0b 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -29,10 +29,6 @@ public FormUDP(Form callingForm) nudThirdIP.Controls[0].Enabled = false; } - private void btnSerialOK_Click(object sender, EventArgs e) - { - } - private void FormUDp_Load(object sender, EventArgs e) { lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST @@ -83,22 +79,19 @@ private void timer1_Tick(object sender, EventArgs e) } ScanNetwork(); - - tboxModules.Text = mf.scanReturn; } private void ScanNetwork() { - mf.scanReturn = ""; tboxNets.Text = ""; + tboxModules.Text = mf.scanReturn; + mf.scanReturn = ""; byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; //mf.SendUDPMessage(scanModules, mf.epModuleSet); foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) { - - if (nic.Supports(NetworkInterfaceComponent.IPv4) ) { foreach (var info in nic.GetIPProperties().UnicastAddresses) @@ -123,15 +116,26 @@ private void ScanNetwork() 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); - scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + //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.SendTo(scanModules, 0, scanModules.Length, SocketFlags.None, mf.epModuleSet); scanSocket.Dispose(); } } - finally + catch (Exception ex) { + Console.Write("nic Loop = "); + Console.WriteLine(ex.ToString()); } } } From 043414653a3603c4b5d49a89d3ba038ae2bb527c Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 25 Jan 2023 17:33:26 -0700 Subject: [PATCH 05/17] UDP Setup --- .../AgIO/Source/Forms/FormUDP.Designer.cs | 66 ++++++++----------- SourceCode/AgIO/Source/Forms/FormUDP.cs | 64 +++++++++++++----- 2 files changed, 73 insertions(+), 57 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index f229ef77b..57da4065e 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -29,7 +29,6 @@ protected override void Dispose(bool disposing) private void InitializeComponent() { this.components = new System.ComponentModel.Container(); - this.label12 = new System.Windows.Forms.Label(); this.label6 = new System.Windows.Forms.Label(); this.lblNetworkHelp = new System.Windows.Forms.Label(); this.cboxIsUDPOn = new System.Windows.Forms.CheckBox(); @@ -59,22 +58,11 @@ private void InitializeComponent() ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); this.SuspendLayout(); // - // 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(9, 53); - this.label12.Name = "label12"; - this.label12.Size = new System.Drawing.Size(159, 23); - this.label12.TabIndex = 142; - this.label12.Text = "Network Adapters"; - this.label12.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(383, 408); + this.label6.Location = new System.Drawing.Point(451, 400); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(187, 23); this.label6.TabIndex = 144; @@ -85,13 +73,13 @@ private void InitializeComponent() // this.lblNetworkHelp.BackColor = System.Drawing.SystemColors.ButtonHighlight; this.lblNetworkHelp.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.lblNetworkHelp.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + 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.ControlDarkDark; - this.lblNetworkHelp.Location = new System.Drawing.Point(371, 431); + this.lblNetworkHelp.Location = new System.Drawing.Point(420, 423); this.lblNetworkHelp.Name = "lblNetworkHelp"; - this.lblNetworkHelp.Size = new System.Drawing.Size(221, 33); + 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; // // cboxIsUDPOn @@ -181,7 +169,7 @@ private void InitializeComponent() // 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(412, 488); + this.label1.Location = new System.Drawing.Point(448, 488); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(185, 23); this.label1.TabIndex = 147; @@ -192,7 +180,7 @@ private void InitializeComponent() // 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(371, 517); + this.nudFirstIP.Location = new System.Drawing.Point(407, 517); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, @@ -213,7 +201,7 @@ private void InitializeComponent() // 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(480, 517); + this.nudSecondIP.Location = new System.Drawing.Point(516, 517); this.nudSecondIP.Maximum = new decimal(new int[] { 255, 0, @@ -234,7 +222,7 @@ private void InitializeComponent() // 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(588, 517); + this.nudThirdIP.Location = new System.Drawing.Point(624, 517); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, @@ -255,7 +243,7 @@ private void InitializeComponent() // 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(459, 512); + this.label2.Location = new System.Drawing.Point(495, 512); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(24, 35); this.label2.TabIndex = 152; @@ -266,7 +254,7 @@ 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(568, 512); + this.label3.Location = new System.Drawing.Point(604, 512); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(24, 35); this.label3.TabIndex = 153; @@ -277,11 +265,11 @@ private void InitializeComponent() // 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(605, 394); + this.label8.Location = new System.Drawing.Point(747, 467); this.label8.Name = "label8"; - this.label8.Size = new System.Drawing.Size(75, 23); + this.label8.Size = new System.Drawing.Size(37, 23); this.label8.TabIndex = 157; - this.label8.Text = "Confirm"; + this.label8.Text = "Set"; this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // btnSendSubnet @@ -292,7 +280,7 @@ private void InitializeComponent() 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.OK64; - this.btnSendSubnet.Location = new System.Drawing.Point(598, 420); + this.btnSendSubnet.Location = new System.Drawing.Point(726, 493); this.btnSendSubnet.Name = "btnSendSubnet"; this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); this.btnSendSubnet.TabIndex = 151; @@ -309,7 +297,7 @@ private void InitializeComponent() 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(594, 616); + this.btnSerialCancel.Location = new System.Drawing.Point(730, 616); this.btnSerialCancel.Name = "btnSerialCancel"; this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); this.btnSerialCancel.TabIndex = 71; @@ -320,7 +308,7 @@ private void InitializeComponent() // 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(460, 26); + this.label7.Location = new System.Drawing.Point(501, 19); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(118, 23); this.label7.TabIndex = 161; @@ -329,19 +317,19 @@ private void InitializeComponent() // // 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(12, 82); + this.tboxNets.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.tboxNets.Location = new System.Drawing.Point(27, 45); this.tboxNets.Multiline = true; this.tboxNets.Name = "tboxNets"; - this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Both; - this.tboxNets.Size = new System.Drawing.Size(324, 475); + this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; + this.tboxNets.Size = new System.Drawing.Size(355, 536); this.tboxNets.TabIndex = 162; // // label4 // this.label4.AutoSize = true; 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(12, 9); + this.label4.Location = new System.Drawing.Point(29, 9); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(154, 23); this.label4.TabIndex = 163; @@ -351,11 +339,11 @@ private void InitializeComponent() // tboxModules // this.tboxModules.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxModules.Location = new System.Drawing.Point(387, 52); + this.tboxModules.Location = new System.Drawing.Point(420, 45); this.tboxModules.Multiline = true; this.tboxModules.Name = "tboxModules"; this.tboxModules.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; - this.tboxModules.Size = new System.Drawing.Size(258, 320); + this.tboxModules.Size = new System.Drawing.Size(279, 320); this.tboxModules.TabIndex = 164; this.tboxModules.Text = "192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nStee" + "r Module\r\n\r\n192.168.1.126\r\nSteer Module"; @@ -366,7 +354,7 @@ private void InitializeComponent() 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(162, 9); + this.lblHostname.Location = new System.Drawing.Point(179, 9); this.lblHostname.Name = "lblHostname"; this.lblHostname.Size = new System.Drawing.Size(118, 23); this.lblHostname.TabIndex = 165; @@ -377,14 +365,13 @@ private void InitializeComponent() // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(688, 691); + this.ClientSize = new System.Drawing.Size(824, 691); this.ControlBox = false; this.Controls.Add(this.lblHostname); this.Controls.Add(this.cboxIsUDPOn); this.Controls.Add(this.tboxModules); this.Controls.Add(this.label4); this.Controls.Add(this.tboxNets); - this.Controls.Add(this.label12); this.Controls.Add(this.label6); this.Controls.Add(this.lblNetworkHelp); this.Controls.Add(this.label7); @@ -424,7 +411,6 @@ private void InitializeComponent() 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; diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 0e89e7c0b..95258d900 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -39,8 +39,8 @@ private void FormUDp_Load(object sender, EventArgs e) cboxIsSendNMEAToUDP.Checked = Properties.Settings.Default.setUDP_isSendNMEAToUDP; 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; @@ -87,6 +87,8 @@ private void ScanNetwork() tboxModules.Text = mf.scanReturn; mf.scanReturn = ""; + bool isSubnetMatchCard = false; + byte[] scanModules = { 0x80, 0x81, 0x7F, 202, 3, 202, 202, 5, 0x47 }; //mf.SendUDPMessage(scanModules, mf.epModuleSet); @@ -104,7 +106,7 @@ private void ScanNetwork() { var properties = nic.GetIPStatistics(); tboxNets.Text += - info.Address + " Status - " + nic.OperationalStatus + "\r\n"; + info.Address + " - " + nic.OperationalStatus + "\r\n"; tboxNets.Text += nic.Name.ToString() + "\r\n"; tboxNets.Text += "Sent: " + (properties.NonUnicastPacketsSent + properties.UnicastPacketsSent).ToString() @@ -113,10 +115,16 @@ private void ScanNetwork() if ( nic.OperationalStatus == OperationalStatus.Up && info.IPv4Mask != null) { + byte[] data = info.Address.GetAddressBytes(); + if (data[0] == ipToSend[0] && data[1] == ipToSend[1] && data[2] == ipToSend[2]) + { + isSubnetMatchCard = true; + } + 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); + scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.DontRoute, true); try { @@ -141,6 +149,15 @@ private void ScanNetwork() } } } + + if (isSubnetMatchCard) + { + lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; + } + else + { + lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; + } } private void btnSendSubnet_Click(object sender, EventArgs e) @@ -158,13 +175,11 @@ private void btnSendSubnet_Click(object sender, EventArgs e) if (result3 == DialogResult.Yes) { - sendIPToModules[7] = ipToSend[0]; sendIPToModules[8] = ipToSend[1]; sendIPToModules[9] = ipToSend[2]; - //mf.SendUDPMessage(sendIPToModules, mf.epModuleSet); - + //loop thru all interfaces foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) { if (nic.Supports(NetworkInterfaceComponent.IPv4) && nic.OperationalStatus == OperationalStatus.Up) @@ -176,20 +191,35 @@ private void btnSendSubnet_Click(object sender, EventArgs e) !IPAddress.IsLoopback(info.Address) && info.IPv4Mask != null) { - - var scanSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); - + Socket scanSocket; try { - scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Broadcast, true); - scanSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, true); - scanSocket.Bind(new IPEndPoint(info.Address, 9999)); - - scanSocket.SendTo(sendIPToModules, 0, sendIPToModules.Length, SocketFlags.None, mf.epModuleSet); + 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); + + 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(); + } } - finally + catch (Exception ex) { - scanSocket.Dispose(); + Console.Write("nic Loop = "); + Console.WriteLine(ex.ToString()); } } } From 6175f1715cb81f82a95dd00a51a0d862e05ab9c6 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 25 Jan 2023 21:47:28 -0700 Subject: [PATCH 06/17] Subnet Gfx --- SourceCode/AgIO/Source/AgIO.csproj | 1 + .../AgIO/Source/Forms/FormLoop.Designer.cs | 59 ++++++++---- SourceCode/AgIO/Source/Forms/FormLoop.cs | 5 +- .../AgIO/Source/Forms/FormUDP.Designer.cs | 87 ++++++++++-------- SourceCode/AgIO/Source/Forms/FormUDP.cs | 12 ++- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 4 +- .../Source/Properties/Resources.Designer.cs | 10 ++ .../AgIO/Source/Properties/Resources.resx | 61 ++++++------ .../AgIO/Source/btnImages/SubnetSend.png | Bin 0 -> 1852 bytes 9 files changed, 148 insertions(+), 91 deletions(-) create mode 100644 SourceCode/AgIO/Source/btnImages/SubnetSend.png diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index 857a0dc46..b29933b83 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -280,6 +280,7 @@ + diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index fb8dfb61c..a163a7a81 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -100,6 +100,7 @@ private void InitializeComponent() this.btnExit = new System.Windows.Forms.Button(); this.btnRunAOG = new System.Windows.Forms.Button(); this.btnRelayTest = new System.Windows.Forms.Button(); + this.lblSubnet = new System.Windows.Forms.Label(); this.statusStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); this.SuspendLayout(); @@ -166,7 +167,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 +180,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); @@ -259,7 +260,7 @@ 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(101, 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); @@ -384,7 +385,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); @@ -412,7 +413,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); @@ -435,13 +436,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", 11.25F, System.Drawing.FontStyle.Bold, 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(8, 184); this.lblIP.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblIP.Name = "lblIP"; - this.lblIP.Size = new System.Drawing.Size(148, 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; @@ -565,7 +567,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); @@ -752,7 +754,7 @@ private void InitializeComponent() 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.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblToGPS.Location = new System.Drawing.Point(30, 177); + this.lblToGPS.Location = new System.Drawing.Point(41, 161); 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); @@ -791,7 +793,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(439, 415); this.btnResetTimer.Margin = new System.Windows.Forms.Padding(4); this.btnResetTimer.Name = "btnResetTimer"; this.btnResetTimer.Size = new System.Drawing.Size(63, 58); @@ -938,7 +940,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(614, 415); this.btnWindowsShutDown.Margin = new System.Windows.Forms.Padding(4); this.btnWindowsShutDown.Name = "btnWindowsShutDown"; this.btnWindowsShutDown.Size = new System.Drawing.Size(63, 58); @@ -979,6 +981,7 @@ private void InitializeComponent() // // 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; @@ -988,10 +991,10 @@ private void InitializeComponent() 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(24, 301); + this.btnUDP.Location = new System.Drawing.Point(12, 287); this.btnUDP.Margin = new System.Windows.Forms.Padding(4); this.btnUDP.Name = "btnUDP"; - this.btnUDP.Size = new System.Drawing.Size(102, 60); + this.btnUDP.Size = new System.Drawing.Size(102, 70); this.btnUDP.TabIndex = 184; this.btnUDP.UseVisualStyleBackColor = false; this.btnUDP.Click += new System.EventHandler(this.btnUDP_Click); @@ -1008,7 +1011,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(529, 415); this.cboxLogNMEA.Name = "cboxLogNMEA"; this.cboxLogNMEA.RightToLeft = System.Windows.Forms.RightToLeft.Yes; this.cboxLogNMEA.Size = new System.Drawing.Size(63, 58); @@ -1028,7 +1031,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); @@ -1047,7 +1050,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); @@ -1067,7 +1070,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(487, 309); this.btnRelayTest.Margin = new System.Windows.Forms.Padding(4); this.btnRelayTest.Name = "btnRelayTest"; this.btnRelayTest.Size = new System.Drawing.Size(61, 73); @@ -1077,13 +1080,28 @@ private void InitializeComponent() this.btnRelayTest.UseVisualStyleBackColor = false; this.btnRelayTest.Click += new System.EventHandler(this.btnRelayTest_Click); // + // lblSubnet + // + this.lblSubnet.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.lblSubnet.BackColor = System.Drawing.Color.Transparent; + this.lblSubnet.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblSubnet.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.lblSubnet.Location = new System.Drawing.Point(8, 367); + this.lblSubnet.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); + this.lblSubnet.Name = "lblSubnet"; + this.lblSubnet.Size = new System.Drawing.Size(123, 15); + this.lblSubnet.TabIndex = 514; + this.lblSubnet.Text = "288.288.288.288"; + this.lblSubnet.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + // // 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.ClientSize = new System.Drawing.Size(682, 475); + this.Controls.Add(this.lblSubnet); this.Controls.Add(this.lblToGPS); this.Controls.Add(this.label7); this.Controls.Add(this.lblSkipCounter); @@ -1123,7 +1141,6 @@ private void InitializeComponent() this.Controls.Add(this.btnSlide); this.Controls.Add(this.pictureBox1); 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); @@ -1142,6 +1159,7 @@ private void InitializeComponent() this.Controls.Add(this.btnRelayTest); this.Controls.Add(this.btnGPSData); this.Controls.Add(this.btnUDP); + this.Controls.Add(this.lblIP); 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; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; @@ -1228,6 +1246,7 @@ private void InitializeComponent() private System.Windows.Forms.Label label7; private System.Windows.Forms.Label lblToGPS; private System.Windows.Forms.Button btnGPSData; + private System.Windows.Forms.Label lblSubnet; } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index b0ffb08ce..64dd1716b 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -757,8 +757,11 @@ private void toolStripMenuItem4_Click(object sender, EventArgs e) private void lblIP_Click(object sender, EventArgs e) { - lblIP.Text = ""; + lblSubnet.Text = "Sub: " +Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + + Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + + Properties.Settings.Default.etIP_SubnetThree.ToString(); + lblIP.Text = ""; foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) { if (IPA.AddressFamily == AddressFamily.InterNetwork) diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 57da4065e..88d00a70d 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -44,13 +44,14 @@ private void InitializeComponent() this.label2 = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label(); this.label8 = new System.Windows.Forms.Label(); - this.btnSendSubnet = new System.Windows.Forms.Button(); - this.btnSerialCancel = new System.Windows.Forms.Button(); this.label7 = new System.Windows.Forms.Label(); this.tboxNets = new System.Windows.Forms.TextBox(); this.label4 = new System.Windows.Forms.Label(); this.tboxModules = new System.Windows.Forms.TextBox(); this.lblHostname = new System.Windows.Forms.Label(); + this.lblNoAdapter = new System.Windows.Forms.Label(); + this.btnSendSubnet = new System.Windows.Forms.Button(); + this.btnSerialCancel = new System.Windows.Forms.Button(); this.groupBox3.SuspendLayout(); this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); @@ -265,45 +266,13 @@ private void InitializeComponent() // 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(747, 467); + this.label8.Location = new System.Drawing.Point(742, 475); 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; // - // 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.OK64; - this.btnSendSubnet.Location = new System.Drawing.Point(726, 493); - this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); - this.btnSendSubnet.TabIndex = 151; - this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; - this.btnSendSubnet.UseVisualStyleBackColor = true; - this.btnSendSubnet.Click += new System.EventHandler(this.btnSendSubnet_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.OK64; - this.btnSerialCancel.Location = new System.Drawing.Point(730, 616); - this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); - this.btnSerialCancel.TabIndex = 71; - this.btnSerialCancel.UseVisualStyleBackColor = true; - this.btnSerialCancel.Click += new System.EventHandler(this.cboxPlugin_Click); - // // label7 // this.label7.AutoSize = true; @@ -361,12 +330,57 @@ private void InitializeComponent() this.lblHostname.Text = "Module Scan"; 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(406, 570); + this.lblNoAdapter.Name = "lblNoAdapter"; + this.lblNoAdapter.Size = new System.Drawing.Size(314, 25); + this.lblNoAdapter.TabIndex = 166; + this.lblNoAdapter.Text = "No Adapter With This Subnet"; + this.lblNoAdapter.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // btnSendSubnet + // + this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSendSubnet.Enabled = false; + 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.SubnetSend; + this.btnSendSubnet.Location = new System.Drawing.Point(730, 502); + this.btnSendSubnet.Name = "btnSendSubnet"; + this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); + this.btnSendSubnet.TabIndex = 151; + this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnSendSubnet.UseVisualStyleBackColor = true; + this.btnSendSubnet.Click += new System.EventHandler(this.btnSendSubnet_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.OK64; + this.btnSerialCancel.Location = new System.Drawing.Point(730, 616); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); + this.btnSerialCancel.TabIndex = 71; + this.btnSerialCancel.UseVisualStyleBackColor = true; + this.btnSerialCancel.Click += new System.EventHandler(this.cboxPlugin_Click); + // // FormUDP // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(824, 691); - this.ControlBox = false; + this.Controls.Add(this.lblNoAdapter); this.Controls.Add(this.lblHostname); this.Controls.Add(this.cboxIsUDPOn); this.Controls.Add(this.tboxModules); @@ -429,5 +443,6 @@ private void InitializeComponent() private System.Windows.Forms.Label label4; private System.Windows.Forms.TextBox tboxModules; private System.Windows.Forms.Label lblHostname; + private System.Windows.Forms.Label lblNoAdapter; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 95258d900..752976658 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -152,11 +152,13 @@ private void ScanNetwork() if (isSubnetMatchCard) { - lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; + //lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; + lblNoAdapter.Visible = false; } else { - lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; + //lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; + lblNoAdapter.Visible = true; } } @@ -167,7 +169,7 @@ private void btnSendSubnet_Click(object sender, EventArgs e) "Change Modules and AgIO Subnet To: \r\n\r\n" + ipToSend[0].ToString() + "." + ipToSend[1].ToString() + "." + - ipToSend[2].ToString() + " ?", + ipToSend[2].ToString() + " ?", "Are you sure ?", MessageBoxButtons.YesNo, MessageBoxIcon.Question, @@ -248,7 +250,6 @@ private void btnSendSubnet_Click(object sender, EventArgs e) } else { - btnSendSubnet.Enabled = false; 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; @@ -261,6 +262,7 @@ private void nudFirstIP_Click(object sender, EventArgs e) mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[0] = (byte)nudFirstIP.Value; btnSendSubnet.Enabled = true; + //btnSerialCancel.Enabled = false; } private void nudSecondIP_Click(object sender, EventArgs e) @@ -268,6 +270,7 @@ private void nudSecondIP_Click(object sender, EventArgs e) mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[1] = (byte)nudSecondIP.Value; btnSendSubnet.Enabled = true; + //btnSerialCancel.Enabled = false; } private void nudThirdIP_Click(object sender, EventArgs e) @@ -275,6 +278,7 @@ private void nudThirdIP_Click(object sender, EventArgs e) mf.KeypadToNUD((NumericUpDown)sender, this); ipToSend[2] = (byte)nudThirdIP.Value; btnSendSubnet.Enabled = true; + //btnSerialCancel.Enabled = false; } diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 4dfd5e0c4..d743c3938 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -56,8 +56,10 @@ public partial class FormLoop public void LoadUDPNetwork() { helloFromAgIO[5] = 56; + lblSubnet.Text = "Sub: " + Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + + Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + + Properties.Settings.Default.etIP_SubnetThree.ToString(); lblIP.Text = ""; - try //udp network { foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) diff --git a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs index 3bfdc2330..db6cbb5d6 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs +++ b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs @@ -440,6 +440,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..13c0792f8 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.resx +++ b/SourceCode/AgIO/Source/Properties/Resources.resx @@ -124,9 +124,6 @@ ..\btnImages\Com_Module2.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\VehFileLoad.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\AgIO_First.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -142,8 +139,11 @@ ..\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\B_Machine.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 @@ -157,8 +157,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 @@ -178,15 +178,21 @@ ..\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\Cancel64.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 + + ..\btnImages\Nmea.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\B_UDP.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\DnArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -199,9 +205,6 @@ ..\btnImages\NtripToUDP.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\NTRIP_Client.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -214,11 +217,8 @@ ..\btnImages\ArrowGrnLeft.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\OK64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\Com_AutosteerModule.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\satellite.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -226,11 +226,11 @@ ..\btnImages\B_Autosteer.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\B_Machine.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Cancel64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Com_AutosteerModule.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\USB_Disconnect.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -238,8 +238,11 @@ ..\btnImages\LogNMEA.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\B_IMU.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\ArrowGrnRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -256,13 +259,13 @@ ..\btnImages\ArrowRight.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\VehFileLoad.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\OK64.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\SubnetSend.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/btnImages/SubnetSend.png b/SourceCode/AgIO/Source/btnImages/SubnetSend.png new file mode 100644 index 0000000000000000000000000000000000000000..b4a1ab2d529299c219b282dca92901e501d586eb GIT binary patch literal 1852 zcmV-C2gCS@P)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D2GL1GK~#8N?VEdS z6h$1zXRq%UP)e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iyJOQ=;COSUci^pRl;i|;$zJS;r06ZtV+uh>sCUBF; zl?dy@pxBI`Z{EseRg^-pCv^zf{&%V#2L0WEBKCi9UTA9vFU05QFX}?7m5uTK#enC# z1mgMf Date: Thu, 26 Jan 2023 23:17:39 -0700 Subject: [PATCH 07/17] AutoSet Subnet --- SourceCode/AgIO/Source/AgIO.csproj | 2 + .../AgIO/Source/Forms/FormLoop.Designer.cs | 97 +++---- SourceCode/AgIO/Source/Forms/FormLoop.cs | 9 +- .../AgIO/Source/Forms/FormUDP.Designer.cs | 229 ++++++++++++----- SourceCode/AgIO/Source/Forms/FormUDP.cs | 237 +++++++++++------- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 21 +- .../Source/Properties/Resources.Designer.cs | 20 ++ .../AgIO/Source/Properties/Resources.resx | 6 + SourceCode/AgIO/Source/btnImages/B_UDP.png | Bin 8191 -> 8286 bytes .../AgIO/Source/btnImages/ConSt_Mandatory.png | Bin 0 -> 1947 bytes .../AgIO/Source/btnImages/SubnetSend.png | Bin 1852 -> 2830 bytes .../AgIO/Source/btnImages/back-button.png | Bin 0 -> 1119 bytes 12 files changed, 392 insertions(+), 229 deletions(-) create mode 100644 SourceCode/AgIO/Source/btnImages/ConSt_Mandatory.png create mode 100644 SourceCode/AgIO/Source/btnImages/back-button.png diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index b29933b83..8523a9a4d 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -280,6 +280,8 @@ + + diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index a163a7a81..81d47bfc1 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -83,7 +83,6 @@ private void InitializeComponent() 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(); @@ -95,12 +94,12 @@ 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.btnRelayTest = new System.Windows.Forms.Button(); - this.lblSubnet = new System.Windows.Forms.Label(); + this.btnGPSData = new System.Windows.Forms.Button(); + this.btnUDP = new System.Windows.Forms.Button(); this.statusStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); this.SuspendLayout(); @@ -440,7 +439,7 @@ private void InitializeComponent() this.lblIP.BackColor = System.Drawing.Color.Transparent; 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(8, 184); + this.lblIP.Location = new System.Drawing.Point(10, 193); this.lblIP.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.lblIP.Name = "lblIP"; this.lblIP.Size = new System.Drawing.Size(123, 102); @@ -762,25 +761,6 @@ private void InitializeComponent() 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); - // // btnResetTimer // this.btnResetTimer.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); @@ -979,26 +959,6 @@ private void InitializeComponent() this.pictureBox1.TabIndex = 182; this.pictureBox1.TabStop = false; // - // 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(12, 287); - this.btnUDP.Margin = new System.Windows.Forms.Padding(4); - this.btnUDP.Name = "btnUDP"; - this.btnUDP.Size = new System.Drawing.Size(102, 70); - this.btnUDP.TabIndex = 184; - this.btnUDP.UseVisualStyleBackColor = false; - this.btnUDP.Click += new System.EventHandler(this.btnUDP_Click); - // // cboxLogNMEA // this.cboxLogNMEA.Appearance = System.Windows.Forms.Appearance.Button; @@ -1080,19 +1040,44 @@ private void InitializeComponent() this.btnRelayTest.UseVisualStyleBackColor = false; this.btnRelayTest.Click += new System.EventHandler(this.btnRelayTest_Click); // - // lblSubnet + // 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); + // + // btnUDP // - this.lblSubnet.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.lblSubnet.BackColor = System.Drawing.Color.Transparent; - this.lblSubnet.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblSubnet.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblSubnet.Location = new System.Drawing.Point(8, 367); - this.lblSubnet.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); - this.lblSubnet.Name = "lblSubnet"; - this.lblSubnet.Size = new System.Drawing.Size(123, 15); - this.lblSubnet.TabIndex = 514; - this.lblSubnet.Text = "288.288.288.288"; - this.lblSubnet.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + 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); // // FormLoop // @@ -1101,7 +1086,6 @@ private void InitializeComponent() this.BackColor = System.Drawing.Color.Gainsboro; this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.ClientSize = new System.Drawing.Size(682, 475); - this.Controls.Add(this.lblSubnet); this.Controls.Add(this.lblToGPS); this.Controls.Add(this.label7); this.Controls.Add(this.lblSkipCounter); @@ -1246,7 +1230,6 @@ private void InitializeComponent() private System.Windows.Forms.Label label7; private System.Windows.Forms.Label lblToGPS; private System.Windows.Forms.Button btnGPSData; - private System.Windows.Forms.Label lblSubnet; } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index 64dd1716b..b6d5d8850 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -64,6 +64,8 @@ public partial class FormLoop : Form public bool isAppInFocus = true, isLostFocus; public int focusSkipCounter = 310; + public int subnetTimer = 11; + //The base directory where Drive will be stored and fields and vehicles branch from public string baseDirectory; @@ -306,6 +308,9 @@ private void oneSecondLoopTimer_Tick(object sender, EventArgs e) return; } + //to check if new data for subnet + subnetTimer++; + secondsSinceStart = (DateTime.Now - Process.GetCurrentProcess().StartTime).TotalSeconds; //Hello Alarm logic @@ -757,10 +762,6 @@ private void toolStripMenuItem4_Click(object sender, EventArgs e) private void lblIP_Click(object sender, EventArgs e) { - lblSubnet.Text = "Sub: " +Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + - Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + - Properties.Settings.Default.etIP_SubnetThree.ToString(); - lblIP.Text = ""; foreach (IPAddress IPA in Dns.GetHostAddresses(Dns.GetHostName())) { diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 88d00a70d..b3ad924b1 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -39,7 +39,7 @@ private void InitializeComponent() 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(); @@ -50,24 +50,31 @@ private void InitializeComponent() this.tboxModules = new System.Windows.Forms.TextBox(); this.lblHostname = new System.Windows.Forms.Label(); this.lblNoAdapter = new System.Windows.Forms.Label(); - this.btnSendSubnet = new System.Windows.Forms.Button(); + this.cboxUp = new System.Windows.Forms.CheckBox(); this.btnSerialCancel = new System.Windows.Forms.Button(); + this.btnAutoSet = new System.Windows.Forms.Button(); + this.pboxSendSteer = new System.Windows.Forms.PictureBox(); + this.btnSendSubnet = new System.Windows.Forms.Button(); + this.label5 = new System.Windows.Forms.Label(); + this.label9 = new System.Windows.Forms.Label(); + this.lblSubTimer = new System.Windows.Forms.Label(); 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(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).BeginInit(); this.SuspendLayout(); // // 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(451, 400); + this.label6.Location = new System.Drawing.Point(474, 468); this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(187, 23); + this.label6.Size = new System.Drawing.Size(139, 23); this.label6.TabIndex = 144; - this.label6.Text = "Current AgIO Subnet"; + this.label6.Text = "Current Subnet"; this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblNetworkHelp @@ -75,8 +82,8 @@ private void InitializeComponent() this.lblNetworkHelp.BackColor = System.Drawing.SystemColors.ButtonHighlight; this.lblNetworkHelp.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; 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.ControlDarkDark; - this.lblNetworkHelp.Location = new System.Drawing.Point(420, 423); + this.lblNetworkHelp.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; + this.lblNetworkHelp.Location = new System.Drawing.Point(403, 493); this.lblNetworkHelp.Name = "lblNetworkHelp"; this.lblNetworkHelp.Size = new System.Drawing.Size(279, 46); this.lblNetworkHelp.TabIndex = 143; @@ -92,9 +99,9 @@ private void InitializeComponent() 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(384, 620); + this.cboxIsUDPOn.Location = new System.Drawing.Point(735, 199); this.cboxIsUDPOn.Name = "cboxIsUDPOn"; - this.cboxIsUDPOn.Size = new System.Drawing.Size(145, 50); + this.cboxIsUDPOn.Size = new System.Drawing.Size(171, 50); this.cboxIsUDPOn.TabIndex = 92; this.cboxIsUDPOn.Text = "UDP On"; this.cboxIsUDPOn.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -105,7 +112,7 @@ private void InitializeComponent() // 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(12, 600); + this.groupBox3.Location = new System.Drawing.Point(735, 12); this.groupBox3.Name = "groupBox3"; this.groupBox3.Size = new System.Drawing.Size(171, 80); this.groupBox3.TabIndex = 94; @@ -121,7 +128,7 @@ private void InitializeComponent() 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(30, 28); + 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; @@ -134,7 +141,7 @@ private void InitializeComponent() // 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(189, 600); + this.groupBox5.Location = new System.Drawing.Point(735, 98); this.groupBox5.Name = "groupBox5"; this.groupBox5.Size = new System.Drawing.Size(171, 80); this.groupBox5.TabIndex = 95; @@ -151,7 +158,7 @@ private void InitializeComponent() 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(14, 30); + 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; @@ -170,7 +177,7 @@ private void InitializeComponent() // 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(448, 488); + this.label1.Location = new System.Drawing.Point(455, 370); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(185, 23); this.label1.TabIndex = 147; @@ -181,16 +188,17 @@ private void InitializeComponent() // 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(407, 517); + this.nudFirstIP.Location = new System.Drawing.Point(378, 399); 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, @@ -198,41 +206,43 @@ 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(516, 517); - 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(495, 399); + 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.nudSecondIP_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(624, 517); + this.nudThirdIP.Location = new System.Drawing.Point(612, 399); 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, @@ -244,7 +254,7 @@ private void InitializeComponent() // 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(495, 512); + this.label2.Location = new System.Drawing.Point(478, 393); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(24, 35); this.label2.TabIndex = 152; @@ -255,7 +265,7 @@ 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(604, 512); + this.label3.Location = new System.Drawing.Point(595, 393); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(24, 35); this.label3.TabIndex = 153; @@ -266,7 +276,7 @@ private void InitializeComponent() // 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(742, 475); + this.label8.Location = new System.Drawing.Point(762, 474); this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(37, 23); this.label8.TabIndex = 157; @@ -277,7 +287,7 @@ private void InitializeComponent() // 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(501, 19); + this.label7.Location = new System.Drawing.Point(409, 19); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(118, 23); this.label7.TabIndex = 161; @@ -291,7 +301,7 @@ private void InitializeComponent() this.tboxNets.Multiline = true; this.tboxNets.Name = "tboxNets"; this.tboxNets.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; - this.tboxNets.Size = new System.Drawing.Size(355, 536); + this.tboxNets.Size = new System.Drawing.Size(330, 478); this.tboxNets.TabIndex = 162; // // label4 @@ -308,14 +318,14 @@ private void InitializeComponent() // tboxModules // this.tboxModules.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxModules.Location = new System.Drawing.Point(420, 45); + this.tboxModules.Location = new System.Drawing.Point(403, 45); this.tboxModules.Multiline = true; this.tboxModules.Name = "tboxModules"; this.tboxModules.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; - this.tboxModules.Size = new System.Drawing.Size(279, 320); + this.tboxModules.Size = new System.Drawing.Size(268, 287); this.tboxModules.TabIndex = 164; - this.tboxModules.Text = "192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nStee" + - "r Module\r\n\r\n192.168.1.126\r\nSteer Module"; + this.tboxModules.Text = "192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nMachine Module\r\n\r\n192.168.1.126\r\nSt" + + "eer Module"; this.tboxModules.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; // // lblHostname @@ -335,51 +345,130 @@ private void InitializeComponent() 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(406, 570); + this.lblNoAdapter.Location = new System.Drawing.Point(419, 546); this.lblNoAdapter.Name = "lblNoAdapter"; - this.lblNoAdapter.Size = new System.Drawing.Size(314, 25); + this.lblNoAdapter.Size = new System.Drawing.Size(249, 25); this.lblNoAdapter.TabIndex = 166; - this.lblNoAdapter.Text = "No Adapter With This Subnet"; + this.lblNoAdapter.Text = "No Adapter For 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.PaleGreen; + 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(99, 544); + 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); + // + // 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.back_button; + this.btnSerialCancel.Location = new System.Drawing.Point(801, 530); + this.btnSerialCancel.Name = "btnSerialCancel"; + this.btnSerialCancel.Size = new System.Drawing.Size(91, 77); + this.btnSerialCancel.TabIndex = 71; + this.btnSerialCancel.UseVisualStyleBackColor = true; + // + // btnAutoSet + // + this.btnAutoSet.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnAutoSet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnAutoSet.Enabled = false; + this.btnAutoSet.FlatAppearance.BorderSize = 0; + 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.Edit; + this.btnAutoSet.Location = new System.Drawing.Point(752, 277); + 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); + // + // 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(822, 426); + 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; + // // btnSendSubnet // this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSendSubnet.Enabled = false; 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.SubnetSend; - this.btnSendSubnet.Location = new System.Drawing.Point(730, 502); + this.btnSendSubnet.Location = new System.Drawing.Point(741, 407); this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(82, 64); + this.btnSendSubnet.Size = new System.Drawing.Size(78, 64); this.btnSendSubnet.TabIndex = 151; this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; this.btnSendSubnet.UseVisualStyleBackColor = true; this.btnSendSubnet.Click += new System.EventHandler(this.btnSendSubnet_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.OK64; - this.btnSerialCancel.Location = new System.Drawing.Point(730, 616); - this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(88, 64); - this.btnSerialCancel.TabIndex = 71; - this.btnSerialCancel.UseVisualStyleBackColor = true; - this.btnSerialCancel.Click += new System.EventHandler(this.cboxPlugin_Click); + // label5 + // + this.label5.AutoSize = true; + 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(742, 338); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(81, 23); + this.label5.TabIndex = 512; + this.label5.Text = "Auto Set"; + this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // label9 + // + 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(42, 558); + 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", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblSubTimer.Location = new System.Drawing.Point(585, 20); + this.lblSubTimer.Name = "lblSubTimer"; + this.lblSubTimer.Size = new System.Drawing.Size(83, 23); + this.lblSubTimer.TabIndex = 514; + this.lblSubTimer.Text = "12"; + this.lblSubTimer.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(824, 691); + this.ClientSize = new System.Drawing.Size(918, 615); + this.ControlBox = false; + 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.cboxIsUDPOn); @@ -392,7 +481,7 @@ private void InitializeComponent() this.Controls.Add(this.btnSendSubnet); this.Controls.Add(this.nudThirdIP); this.Controls.Add(this.groupBox5); - this.Controls.Add(this.nudSecondIP); + this.Controls.Add(this.nudSecndIP); this.Controls.Add(this.groupBox3); this.Controls.Add(this.nudFirstIP); this.Controls.Add(this.label1); @@ -400,6 +489,9 @@ private void InitializeComponent() this.Controls.Add(this.label2); this.Controls.Add(this.label3); this.Controls.Add(this.label8); + this.Controls.Add(this.pboxSendSteer); + this.Controls.Add(this.label5); + this.Controls.Add(this.lblSubTimer); 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); @@ -413,8 +505,9 @@ private void InitializeComponent() 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(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); @@ -431,9 +524,8 @@ private void InitializeComponent() 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 label6; @@ -444,5 +536,12 @@ private void InitializeComponent() private System.Windows.Forms.TextBox tboxModules; 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; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 752976658..26e52837c 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -15,8 +15,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) { @@ -25,12 +25,18 @@ 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 FormUDp_Load(object sender, EventArgs e) { + mf.ipAutoSet[0] = 99; + mf.ipAutoSet[1] = 99; + mf.ipAutoSet[2] = 99; + + mf.subnetTimer = 11; + lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST tboxModules.Text = "Scanning"; @@ -43,14 +49,14 @@ private void FormUDp_Load(object sender, EventArgs e) 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; + 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; if (!cboxIsUDPOn.Checked) { nudFirstIP.Enabled = false; - nudSecondIP.Enabled = false; + nudSecndIP.Enabled = false; nudThirdIP.Enabled = false; btnSendSubnet.Enabled = false; } @@ -63,8 +69,21 @@ private void FormUDp_Load(object sender, EventArgs e) private void timer1_Tick(object sender, EventArgs e) { - //GetIP4AddressList(); - //IsValidNetworkFound(); + mf.subnetTimer++; + lblSubTimer.Text = mf.subnetTimer.ToString(); + + if (mf.subnetTimer > 10) + { + mf.ipAutoSet[0] = 99; + mf.ipAutoSet[1] = 99; + mf.ipAutoSet[2] = 99; + btnAutoSet.Enabled = false; + } + else + { + btnAutoSet.Enabled = true; + } + if (cboxIsUDPOn.Checked) { cboxIsSendNMEAToUDP.Enabled = true; @@ -104,19 +123,24 @@ private void ScanNetwork() Socket scanSocket; try { - 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 ((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] == ipToSend[0] && data[1] == ipToSend[1] && data[2] == ipToSend[2]) + if (data[0] == ipCurrent[0] && data[1] == ipCurrent[1] && data[2] == ipCurrent[2]) { isSubnetMatchCard = true; } @@ -152,12 +176,12 @@ private void ScanNetwork() if (isSubnetMatchCard) { - //lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; + lblNetworkHelp.BackColor = System.Drawing.Color.LightGreen; lblNoAdapter.Visible = false; } else { - //lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; + lblNetworkHelp.BackColor = System.Drawing.Color.Salmon; lblNoAdapter.Visible = true; } } @@ -165,123 +189,131 @@ private void ScanNetwork() 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] = ipToSend[0]; - sendIPToModules[8] = ipToSend[1]; - sendIPToModules[9] = ipToSend[2]; + sendIPToModules[7] = ipNew[0]; + sendIPToModules[8] = ipNew[1]; + sendIPToModules[9] = ipNew[2]; - //loop thru all interfaces - foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) + //loop thru all interfaces + foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) + { + if (nic.Supports(NetworkInterfaceComponent.IPv4) && nic.OperationalStatus == OperationalStatus.Up) { - if (nic.Supports(NetworkInterfaceComponent.IPv4) && nic.OperationalStatus == OperationalStatus.Up) + foreach (var info in nic.GetIPProperties().UnicastAddresses) { - 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) { - // 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 { - Socket scanSocket; - try + if (nic.OperationalStatus == OperationalStatus.Up + && info.IPv4Mask != null) { - 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); + + try { - 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(sendIPToModules, 0, sendIPToModules.Length, SocketFlags.None, mf.epModuleSet); - } - catch (Exception ex) - { - Console.Write("Bind Error = "); - Console.WriteLine(ex.ToString()); - } - - scanSocket.Dispose(); + scanSocket.Bind(new IPEndPoint(info.Address, 9999)); + scanSocket.SendTo(sendIPToModules, 0, sendIPToModules.Length, SocketFlags.None, mf.epModuleSet); } - } - catch (Exception ex) - { - Console.Write("nic Loop = "); - Console.WriteLine(ex.ToString()); + 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 = ipToSend[0]; - Properties.Settings.Default.etIP_SubnetTwo = ipToSend[1]; - Properties.Settings.Default.etIP_SubnetThree = ipToSend[2]; + 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]; - //lblNetworkHelp.Text = - // ipToSend[0].ToString() + "." + - // ipToSend[1].ToString() + "." + - // ipToSend[2].ToString(); + Properties.Settings.Default.setUDP_isOn = cboxIsUDPOn.Checked; + Properties.Settings.Default.setUDP_isUsePluginApp = cboxPlugin.Checked; + Properties.Settings.Default.setUDP_isSendNMEAToUDP = cboxIsSendNMEAToUDP.Checked; - //counter = 0; + Properties.Settings.Default.Save(); - Properties.Settings.Default.setUDP_isOn = cboxIsUDPOn.Checked; - Properties.Settings.Default.setUDP_isUsePluginApp = cboxPlugin.Checked; - Properties.Settings.Default.setUDP_isSendNMEAToUDP = cboxIsSendNMEAToUDP.Checked; + 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); - Properties.Settings.Default.Save(); - Application.Restart(); - Environment.Exit(0); - Close(); - } - else - { - 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; - } + lblNetworkHelp.Text = + 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) + { + if (mf.ipAutoSet[0] == 99 && mf.ipAutoSet[1] == 99 && mf.ipAutoSet[2] == 99) + { + mf.TimedMessageBox(2000, "No Reply From Module", "No New Subnet From Module"); + } + else + { + nudFirstIP.Value = mf.ipAutoSet[0]; + nudSecndIP.Value = mf.ipAutoSet[1]; + nudThirdIP.Value = mf.ipAutoSet[2]; + ipNew[0] = mf.ipAutoSet[0]; + ipNew[1] = mf.ipAutoSet[1]; + ipNew[2] = mf.ipAutoSet[2]; + btnSerialCancel.Image = Properties.Resources.Cancel64; + pboxSendSteer.Visible = true; + } + + //btnSendSubnet.PerformClick(); } private void nudFirstIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[0] = (byte)nudFirstIP.Value; + ipNew[0] = (byte)nudFirstIP.Value; btnSendSubnet.Enabled = true; - //btnSerialCancel.Enabled = false; + pboxSendSteer.Visible = true; + btnSerialCancel.Image = Properties.Resources.Cancel64; } private void nudSecondIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[1] = (byte)nudSecondIP.Value; + ipNew[1] = (byte)nudSecndIP.Value; btnSendSubnet.Enabled = true; - //btnSerialCancel.Enabled = false; + pboxSendSteer.Visible = true; + btnSerialCancel.Image = Properties.Resources.Cancel64; } private void nudThirdIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); - ipToSend[2] = (byte)nudThirdIP.Value; + ipNew[2] = (byte)nudThirdIP.Value; btnSendSubnet.Enabled = true; - //btnSerialCancel.Enabled = false; + pboxSendSteer.Visible = true; + btnSerialCancel.Image = Properties.Resources.Cancel64; } - private void cboxPlugin_Click(object sender, EventArgs e) { Properties.Settings.Default.setUDP_isOn = cboxIsUDPOn.Checked; @@ -292,7 +324,18 @@ private void cboxPlugin_Click(object sender, EventArgs e) Application.Restart(); Environment.Exit(0); Close(); + } + private void cboxUp_Click(object sender, EventArgs e) + { + if(cboxUp.Checked) + { + cboxUp.Text = "Up"; + } + else + { + cboxUp.Text = "Up + Down"; + } } ////get the ipv4 address only diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index d743c3938..c3915e587 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -23,7 +23,7 @@ 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; @@ -38,6 +38,7 @@ 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(); @@ -56,9 +57,7 @@ public partial class FormLoop public void LoadUDPNetwork() { helloFromAgIO[5] = 56; - lblSubnet.Text = "Sub: " + Properties.Settings.Default.etIP_SubnetOne.ToString() + "." + - Properties.Settings.Default.etIP_SubnetTwo.ToString() + "." + - Properties.Settings.Default.etIP_SubnetThree.ToString(); + lblIP.Text = ""; try //udp network { @@ -350,11 +349,13 @@ private void ReceiveFromUDP(byte[] data) //scan Reply else if (data[3] == 203) // { + subnetTimer = 0; if (data[2] == 123) { scanReturn += "Machine Module \r\n"; scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; + + data[7].ToString() + "." + data[8].ToString() + + "\r\n\r\n"; } else if (data[2] == 120) { @@ -367,7 +368,15 @@ private void ReceiveFromUDP(byte[] data) { scanReturn += "Steer Module \r\n"; scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; + + data[7].ToString() + "." + data[8].ToString() + "\r\nSubnet " + + data[9].ToString() + "." + + data[10].ToString() + "." + + data[11].ToString() + + "\r\n\r\n"; + + ipAutoSet[0] = data[09]; + ipAutoSet[1] = data[10]; + ipAutoSet[2] = data[11]; } else if (data[2] == 121) { diff --git a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs index db6cbb5d6..81ec89f0e 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. /// diff --git a/SourceCode/AgIO/Source/Properties/Resources.resx b/SourceCode/AgIO/Source/Properties/Resources.resx index 13c0792f8..9c7ec2735 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.resx +++ b/SourceCode/AgIO/Source/Properties/Resources.resx @@ -268,4 +268,10 @@ ..\btnImages\SubnetSend.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\ConSt_Mandatory.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/btnImages/B_UDP.png b/SourceCode/AgIO/Source/btnImages/B_UDP.png index c93ff08970f543706bdb49324ebefd221285c137..a22c8c4585e55f6a63950782b2cd0c3adeeaf3bf 100644 GIT binary patch literal 8286 zcmZ`f>XmGdUu0eylYk?vu?(P(dyOrYZQi?mdXj|MhyuSbUW>#ju z_UFvmvpXB3sji5HNsb8s0I-ymShwzl17 zTo;M^tNLd+f==Y`Tk;Lkt9^__ci`}F;@+yz{f|wjF-9hA^+J%xkh=?4uOKe4oOE96 z1KywYjMjBCyNwg|^V8mQAyG&jx+aBDV4?V(B|PVGBjo(P@VfB&^}SIeipl?DqI{=? zSQPt9irg!6J>qq$c|qcPr#0rU)rPf#P9g=9FBfQ%N^{fG)1SPo?&=yOSzHRKsMXA^ zz3g9W>bv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2_$qJ^;wG3QR74kLpHjub&E}$)vc}#IY6_>$W<;+I0!qQObYD7B zz|RqkMY>Fj4*SCj(x=auFUG5M?T&Y)kbvPPo z{umsDj%RTw$rm|peb$U5Xb&=KM5}rj6@8)2Cwpo3$j;BvY9eM{^cDV)KwPR$pd$Kp{*Vv?)>1b&)e$P{W$+=G66gm(dn=$lzAK^Q`AM!trwj%yn#EK=KWNmM z`qdbig-vAK%*InyZlSAHepq10U-#!`7YE4Tp9WC&K94s2WHXL&l!c! z+xB!^@FF@MXe|DEUru(do;*VEw03l!y>2>Dpqzs6CADyxKK!VG zD1W|9TI;l1!GW^q%p^J!UcSRBuop~QcRIgRCs;3rgooI!Y^8=L(W#Y@v(KGP+KcwC zq4&jGH-3{-*3V!4X19z6umJ{zUZNa$&iTmO@j!NQb)#f_-Vvstzm)!*kM{HX@CRbe za29i}s|8m!Zf*^zitg235bdbIG}cNn`EUa^(oArGzaz6T1#Fb96pJ({2@bTVL>0h1 z(oA1x%-DeGfPi=xj5ixcrdA9wvB=FW8AETdASdgsDQfJunJ?$2y2QS(|s( zLF%65TesK_*7b5V+;4>To{uVqRe)ytPEchv3XiPh|AzW_WT!KG*|WNlCm*jzyXb%_ zI7&MyJO&avfS}70pYYLs&>%<|b@9Y4Ck0se3HTwtfDZ1?d?|h!c;~TbhS)g2IPkWX zw*}B?zSvey6r literal 0 HcmV?d00001 diff --git a/SourceCode/AgIO/Source/btnImages/SubnetSend.png b/SourceCode/AgIO/Source/btnImages/SubnetSend.png index b4a1ab2d529299c219b282dca92901e501d586eb..eb7a0843c278453c375af1d891d581b619f0ecdc 100644 GIT binary patch delta 2820 zcmV+f3;XoE4vrQfiBL{Q4GJ0x0000DNk~Le0000;0000;2nGNE09Ea?N0A{Yf5HF& z4#EKyC`y0;01Bf?L_t(|UhUgitRz(#2k;q27!(lqaRbJES6mRq4Z&R@`e595e9-u4 zG|~8EV$>HCpVW+rabE@{5Zre`QQQSwa0A>%Wf@0tX70>f|G%=%&AB~&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K2HnTL9_5?B_gFWdZmZMQZ3rR8IhX;F+UqJ!|%vY6-yQt}QN+<7+0) zGu04)XPuu&h5odu;}LEP5IN4XK0mgY*LkLF0rEd0Z+m~x(scK`;X_T(d_%3dB92G6 la~SHNen)%6h!I8bynnZ>wuoS}ktqNG002ovPDHLkV1jXw^aTI_ literal 0 HcmV?d00001 From c7981ccc6489c79bf293385b19e03ba495c1230e Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Fri, 27 Jan 2023 12:50:50 -0700 Subject: [PATCH 08/17] Section 8 to 16 Fix --- SourceCode/AgIO/Source/AgIO.csproj | 23 +++ SourceCode/AgIO/Source/App.config | 2 +- .../AgIO/Source/Forms/Controls.Designer.cs | 11 +- .../AgIO/Source/Forms/FormLoop.Designer.cs | 161 +++++++----------- SourceCode/AgIO/Source/Forms/FormLoop.cs | 4 +- .../AgIO/Source/Forms/FormNtrip.Designer.cs | 48 +++--- SourceCode/AgIO/Source/Forms/FormNtrip.cs | 28 ++- .../Source/Forms/FormTimedMessage.Designer.cs | 26 +-- .../AgIO/Source/Forms/FormTimedMessage.cs | 10 +- SourceCode/AgIO/Source/Forms/FormUDP.cs | 1 - SourceCode/AgIO/Source/Forms/FormYes.cs | 18 ++ .../AgIO/Source/Forms/FormYes.designer.cs | 89 ++++++++++ SourceCode/AgIO/Source/Forms/FormYes.resx | 120 +++++++++++++ SourceCode/AgIO/Source/Forms/FormYesNo.cs | 26 +++ .../AgIO/Source/Forms/FormYesNo.designer.cs | 116 +++++++++++++ SourceCode/AgIO/Source/Forms/FormYesNo.resx | 123 +++++++++++++ .../AgIO/Source/Forms/FormtimedMessage.resx | 3 + .../AgIO/Source/Forms/NTRIPComm.Designer.cs | 4 +- .../Source/Properties/Settings.Designer.cs | 2 +- .../AgIO/Source/Properties/Settings.settings | 2 +- SourceCode/AgIO/Source/btnImages/B_GPS.png | Bin 3732 -> 3922 bytes SourceCode/GPS/Forms/Sections.Designer.cs | 3 +- 22 files changed, 666 insertions(+), 154 deletions(-) create mode 100644 SourceCode/AgIO/Source/Forms/FormYes.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormYes.designer.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormYes.resx create mode 100644 SourceCode/AgIO/Source/Forms/FormYesNo.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormYesNo.designer.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormYesNo.resx diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index 8523a9a4d..40949c9c8 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -126,6 +126,18 @@ FormSerialPass.cs + + Form + + + FormYes.cs + + + Form + + + FormYesNo.cs + FormLoop.cs @@ -163,9 +175,11 @@ FormCommPicker.cs + Designer FormCommSaver.cs + Designer FormCommSetGPS.cs @@ -199,6 +213,15 @@ FormSerialPass.cs + + FormYes.cs + + + FormYesNo.cs + + + FormTimedMessage.cs + FormUDP.cs diff --git a/SourceCode/AgIO/Source/App.config b/SourceCode/AgIO/Source/App.config index c31e3cb58..2e4ece3e9 100644 --- a/SourceCode/AgIO/Source/App.config +++ b/SourceCode/AgIO/Source/App.config @@ -152,7 +152,7 @@ True - False + True False diff --git a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs index 7ba8945a6..7510a1197 100644 --- a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs @@ -5,15 +5,20 @@ 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 SettingsCommunicationGPS() { isGPSCommOpen = true; diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index 81d47bfc1..bd8beb6a2 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -75,8 +75,6 @@ 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(); @@ -193,7 +191,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(181, 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 +203,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(181, 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 +215,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(181, 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 +224,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.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblFromGPS.Location = new System.Drawing.Point(286, 249); + this.lblFromGPS.Location = new System.Drawing.Point(344, 245); 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(23, 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(181, 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,10 +258,10 @@ private void InitializeComponent() this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripDropDownButton1, this.settingsMenuStrip}); - this.statusStrip1.Location = new System.Drawing.Point(101, 410); + 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"; @@ -282,7 +281,7 @@ private void InitializeComponent() this.toolStripDropDownButton1.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolStripDropDownButton1.Name = "toolStripDropDownButton1"; this.toolStripDropDownButton1.ShowDropDownArrow = false; - this.toolStripDropDownButton1.Size = new System.Drawing.Size(96, 68); + this.toolStripDropDownButton1.Size = new System.Drawing.Size(110, 68); // // toolStripMenuItem1 // @@ -334,7 +333,7 @@ private void InitializeComponent() this.settingsMenuStrip.ImageTransparentColor = System.Drawing.Color.Magenta; this.settingsMenuStrip.Name = "settingsMenuStrip"; this.settingsMenuStrip.ShowDropDownArrow = false; - this.settingsMenuStrip.Size = new System.Drawing.Size(96, 68); + this.settingsMenuStrip.Size = new System.Drawing.Size(110, 68); // // saveToolStrip // @@ -369,7 +368,7 @@ private void InitializeComponent() 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); @@ -397,7 +396,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); @@ -425,7 +424,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); @@ -439,7 +438,7 @@ private void InitializeComponent() this.lblIP.BackColor = System.Drawing.Color.Transparent; 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(10, 193); + 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(123, 102); @@ -459,10 +458,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); @@ -473,7 +472,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); @@ -486,7 +485,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); @@ -499,7 +498,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); @@ -512,7 +511,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); @@ -525,7 +524,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); @@ -538,7 +537,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); @@ -551,7 +550,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); @@ -581,7 +580,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); @@ -595,7 +594,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); @@ -606,12 +605,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"; // @@ -619,12 +618,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"; // @@ -632,12 +631,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"; // @@ -645,49 +644,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); @@ -701,7 +673,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); @@ -727,7 +699,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); @@ -750,16 +722,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.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; - this.lblToGPS.Location = new System.Drawing.Point(41, 161); + this.lblToGPS.Location = new System.Drawing.Point(344, 273); 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(23, 18); this.lblToGPS.TabIndex = 512; this.lblToGPS.Text = "---"; - this.lblToGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.lblToGPS.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; // // btnResetTimer // @@ -773,7 +746,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, 415); + 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); @@ -792,7 +765,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; @@ -809,7 +782,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; @@ -826,7 +799,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; @@ -845,7 +818,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(252, 70); this.btnIMU.Margin = new System.Windows.Forms.Padding(4); this.btnIMU.Name = "btnIMU"; this.btnIMU.Size = new System.Drawing.Size(84, 59); @@ -864,7 +837,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(252, 155); this.btnSteer.Margin = new System.Windows.Forms.Padding(4); this.btnSteer.Name = "btnSteer"; this.btnSteer.Size = new System.Drawing.Size(84, 59); @@ -883,7 +856,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(252, 325); this.btnMachine.Margin = new System.Windows.Forms.Padding(4); this.btnMachine.Name = "btnMachine"; this.btnMachine.Size = new System.Drawing.Size(84, 59); @@ -902,7 +875,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(252, 240); this.btnGPS.Margin = new System.Windows.Forms.Padding(4); this.btnGPS.Name = "btnGPS"; this.btnGPS.Size = new System.Drawing.Size(84, 59); @@ -912,6 +885,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; @@ -920,7 +894,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, 415); + 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); @@ -939,7 +913,7 @@ 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, 16); this.btnSlide.Margin = new System.Windows.Forms.Padding(4); this.btnSlide.Name = "btnSlide"; this.btnSlide.Size = new System.Drawing.Size(55, 43); @@ -952,7 +926,7 @@ 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; @@ -961,6 +935,7 @@ private void InitializeComponent() // // 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; @@ -971,7 +946,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(529, 415); + 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); @@ -1030,7 +1005,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, 309); + 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); @@ -1051,10 +1026,10 @@ private void InitializeComponent() 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.Location = new System.Drawing.Point(133, 11); this.btnGPSData.Margin = new System.Windows.Forms.Padding(4); this.btnGPSData.Name = "btnGPSData"; - this.btnGPSData.Size = new System.Drawing.Size(120, 48); + this.btnGPSData.Size = new System.Drawing.Size(75, 48); this.btnGPSData.TabIndex = 513; this.btnGPSData.UseVisualStyleBackColor = false; this.btnGPSData.Click += new System.EventHandler(this.btnGPSData_Click); @@ -1085,15 +1060,12 @@ private void InitializeComponent() 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, 475); - this.Controls.Add(this.lblToGPS); + this.ClientSize = new System.Drawing.Size(734, 475); 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); @@ -1133,7 +1105,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); @@ -1144,6 +1115,8 @@ private void InitializeComponent() this.Controls.Add(this.btnGPSData); this.Controls.Add(this.btnUDP); this.Controls.Add(this.lblIP); + this.Controls.Add(this.lblToGPS); + this.Controls.Add(this.lblFromGPS); 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; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; @@ -1219,8 +1192,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; diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index b6d5d8850..4ae98c1c7 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -517,7 +517,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(); @@ -654,7 +654,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; diff --git a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs index 7164d7882..9b160c88c 100644 --- a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs @@ -80,8 +80,8 @@ 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(); ((System.ComponentModel.ISupportInitialize)(this.nudCasterPort)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSendToUDPPort)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudGGAInterval)).BeginInit(); @@ -96,7 +96,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 +109,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 +135,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 +310,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 +621,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 +631,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 +784,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 +802,21 @@ 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; + // // FormNtrip // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); @@ -862,7 +862,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 +905,6 @@ 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; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormNtrip.cs b/SourceCode/AgIO/Source/Forms/FormNtrip.cs index fa109f506..4ea83d57d 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) 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.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 26e52837c..24839ad93 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -263,7 +263,6 @@ private void btnSendSubnet_Click(object sender, EventArgs e) pboxSendSteer.Visible = false; btnSerialCancel.Image = Properties.Resources.back_button; - } private void btnAutoSet_Click(object sender, EventArgs e) 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/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/Properties/Settings.Designer.cs b/SourceCode/AgIO/Source/Properties/Settings.Designer.cs index de3d4c05a..9ff83cb36 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"])); diff --git a/SourceCode/AgIO/Source/Properties/Settings.settings b/SourceCode/AgIO/Source/Properties/Settings.settings index 3953dda7f..304d52289 100644 --- a/SourceCode/AgIO/Source/Properties/Settings.settings +++ b/SourceCode/AgIO/Source/Properties/Settings.settings @@ -147,7 +147,7 @@ True - False + True False diff --git a/SourceCode/AgIO/Source/btnImages/B_GPS.png b/SourceCode/AgIO/Source/btnImages/B_GPS.png index eee542965c3ce361dbef58cb7d0544854fad02bd..e0014618884c5c0bdbc2e6b75e482bfc2b434a36 100644 GIT binary patch delta 3886 zcmV+}57F?H9nv0Nkl=&bh~C(H3pd7H!cM zZPBW0p7OGut@0U5<>eJ`3r_rs6)Vhh&pj8o>86_-$KzdrKw!0YwR=3C z4lS2!*(yY}9)GsPmn|Atc4{3Q)IGxMoP9~Gdo&yIC^xt#OJrml8gRTfi)P(q8 zFz7jU{CI17TiaGe^vxo7EhOtuv(TvZ1}y`^OrA&Fm$F)>w4Bs(RD7RN^dFd*n0WuS z*IxVAV~;(?eu%e@xT0FaobBLepGA_X)Yg1H|2N1H(tkougcV`0TBdtqIUy+r98)X! z<0l_~a-%Gw$H1XJfflsj(mF4;dGls-;>3y2;NZ|I$8jDN3I7!@&J;bhHU0KvI-P#| z*s){xzxwK{SKW8teMnf{IH77kJ~%iSiN#{yl9X)rdc8jtHfi^QN0@w&RS@hR9UXo1 z!?_NiT$jp^F;VW(1wr%A#vsu{v_~VaHZOy`}Ld**<{Mq}!13$Yr z6bfyVUT+YB{=~x%KYT>{(gI1_I^d#KCLFFH9JV)$^f_@?Svkzg zM6&VweQk#h9s04Neq$z+2`b9UN9)G)n4Wkz+<$PV-{-qC5{a~HUrY!Ke&K>VK)ArM z9|-T20r_(_^lnbJY15`aDw%vpMfEQwHQuvl&zh5`PMWc?F_TF?2$Z7b1x-+JqD?5jlWKn6hHMvW!XG8agvurkJ3UaV?#XaVd zok*DOo*r}L$Pu$|-@cMs<;1~*2Y)5aKYy%?P7A{V<)^Frx@v)T?PU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5 z)PO7K@ykNJr-db!nbpuqf-k-F(tiPn{_|3)w3ZWO@%S3P{J8n%n{S-FeEIUNSqGh27K8#+~6!B`oYH6Pf9{=*oFCQ>WQ+j*=9^c;HE>fw9o3Fk0 z>!!!o2o!(8QKTg**$oC#Za$y)YNoL+XlUV|eBv=3aXg$zB-&%KXm218*ncuSG`ykY zluSkzhMP(U>&LM;LQfk)&l#I>xSGT4IA8Ugiu*?mWN;DHB3EE~vjsBLw6R#1@{D>mS#zUoRJ( zGL2;Cdj0x!0VB!feicw$7Y3L?E4TvBKjAmcH>T5R&RFs!PMS5LuwldcZOF%!I26wl z;+_Q<;B-$<&%OA}C4(!DMhZ2WTXKJ46^k5xd)@aKXgP^sFmN@O%YX4@373_qutU}z zjncVN1RV<0@_97ZEpw?j7t5{z`9^ESe%;ql!kdP10&$sdj64VKo3^Y1MP3WGgIqMV zV!}5K7?NvgC@=-* zwj$rhE~G>CLZb*zQR&?w2o!}_5ef}*b%0z~6N!XpC?<|)LAHu&&O+og1iuN6VHC^% zi!g=jdA?e>L@%d@^F1u@Npb~(I$l?guX}7;1j^&NaFxHP?tcU~g8b#kdXNiO`F{qu zn3cxixz*lZT?Zu|ONJDBxC$%uZoUYwUjD&l+B6)G^ZdGr-v}PBKr#6|iu_C==#BJB zk^-?6sPb0QqZKJMMdive#&)$FP%T*HJ|0&~KfZJxPw+YD&0MNY@22O|)0zG;^ 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); From 7c38a0d4fd57108eb02155eba6001ecccb8ef712 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Fri, 27 Jan 2023 13:35:10 -0700 Subject: [PATCH 09/17] Machine Module Auto IP --- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 32 +++++++++++++++----- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index c3915e587..08c484d3c 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -354,16 +354,16 @@ private void ReceiveFromUDP(byte[] data) { scanReturn += "Machine Module \r\n"; scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + + data[7].ToString() + "." + data[8].ToString() + "\r\nSubnet " + + data[9].ToString() + "." + + data[10].ToString() + "." + + data[11].ToString() + "\r\n\r\n"; - } - else if (data[2] == 120) - { - scanReturn += "Panda Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; - } + ipAutoSet[0] = data[09]; + ipAutoSet[1] = data[10]; + ipAutoSet[2] = data[11]; + } else if (data[2] == 126) { scanReturn += "Steer Module \r\n"; @@ -384,6 +384,22 @@ private void ReceiveFromUDP(byte[] data) scanReturn += data[5].ToString() + "." + data[6].ToString() + "." + data[7].ToString() + "." + data[8].ToString() + "\r\n\r\n"; } + + else if (data[2] == 120) + { + scanReturn += "Panda Module \r\n"; + scanReturn += data[5].ToString() + "." + data[6].ToString() + "." + + data[7].ToString() + "." + data[8].ToString() + "\r\nSubnet " + + data[9].ToString() + "." + + data[10].ToString() + "." + + data[11].ToString() + + "\r\n\r\n"; + + ipAutoSet[0] = data[09]; + ipAutoSet[1] = data[10]; + ipAutoSet[2] = data[11]; + } + } } // end of pgns From c151c8fa5084094c3ed0de67eb4937f78b71a3dd Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Sat, 28 Jan 2023 09:14:26 -0700 Subject: [PATCH 10/17] Remove strange settings from config --- SourceCode/GPS/Properties/Settings.Designer.cs | 2 +- SourceCode/GPS/Properties/Settings.settings | 2 +- SourceCode/GPS/app.config | 17 +---------------- 3 files changed, 3 insertions(+), 18 deletions(-) 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 From 5383584c8d114e68b961ca2ad5c319f8062e28d7 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Sat, 28 Jan 2023 09:45:26 -0700 Subject: [PATCH 11/17] Negative antenna in wizard bug --- .../Forms/Settings/FormSteerWiz.Designer.cs | 96 ++++++++++--------- .../GPS/Forms/Settings/FormSteerWiz.resx | 2 +- 2 files changed, 54 insertions(+), 44 deletions(-) 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/ From 198ace61b13d231f023e7234f9e69154e06237c2 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Sat, 28 Jan 2023 13:18:53 -0700 Subject: [PATCH 12/17] Update FormUDP.cs --- SourceCode/AgIO/Source/Forms/FormUDP.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 24839ad93..f19acd329 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -72,7 +72,7 @@ private void timer1_Tick(object sender, EventArgs e) mf.subnetTimer++; lblSubTimer.Text = mf.subnetTimer.ToString(); - if (mf.subnetTimer > 10) + if (mf.subnetTimer > 6) { mf.ipAutoSet[0] = 99; mf.ipAutoSet[1] = 99; From 251729bcc0230658ee924dad03a1e9135c24c0bd Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Sun, 29 Jan 2023 22:34:56 -0700 Subject: [PATCH 13/17] Changes to UDP Settings --- .../AgIO/Source/Forms/FormLoop.Designer.cs | 8 +- SourceCode/AgIO/Source/Forms/FormLoop.cs | 3 - .../AgIO/Source/Forms/FormUDP.Designer.cs | 400 +++++++++++++++--- SourceCode/AgIO/Source/Forms/FormUDP.cs | 117 ++--- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 104 +++-- 5 files changed, 462 insertions(+), 170 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index bd8beb6a2..40e73b90f 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -1158,10 +1158,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; @@ -1201,6 +1197,10 @@ 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; } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index 4ae98c1c7..1e7e4811b 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -64,8 +64,6 @@ public partial class FormLoop : Form public bool isAppInFocus = true, isLostFocus; public int focusSkipCounter = 310; - public int subnetTimer = 11; - //The base directory where Drive will be stored and fields and vehicles branch from public string baseDirectory; @@ -309,7 +307,6 @@ private void oneSecondLoopTimer_Tick(object sender, EventArgs e) } //to check if new data for subnet - subnetTimer++; secondsSinceStart = (DateTime.Now - Process.GetCurrentProcess().StartTime).TotalSeconds; diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index b3ad924b1..28f6f7a01 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -47,7 +47,6 @@ private void InitializeComponent() this.label7 = new System.Windows.Forms.Label(); this.tboxNets = new System.Windows.Forms.TextBox(); this.label4 = new System.Windows.Forms.Label(); - this.tboxModules = new System.Windows.Forms.TextBox(); this.lblHostname = new System.Windows.Forms.Label(); this.lblNoAdapter = new System.Windows.Forms.Label(); this.cboxUp = new System.Windows.Forms.CheckBox(); @@ -58,19 +57,37 @@ private void InitializeComponent() this.label5 = 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.lblGPSIP = new System.Windows.Forms.Label(); + this.lblMachineIP = new System.Windows.Forms.Label(); + this.lblSteerIP = new System.Windows.Forms.Label(); + this.lblIMU_IP = new System.Windows.Forms.Label(); + this.label16 = new System.Windows.Forms.Label(); + this.label15 = new System.Windows.Forms.Label(); + this.label17 = new System.Windows.Forms.Label(); + this.label18 = new System.Windows.Forms.Label(); + this.lblNewSubnet = new System.Windows.Forms.Label(); + this.lblBtnSteer = new System.Windows.Forms.Label(); + this.lblBtnMachine = new System.Windows.Forms.Label(); + this.lblBtnGPS = new System.Windows.Forms.Label(); + this.lblBtnIMU = new System.Windows.Forms.Label(); + this.btnNetworkCPL = new System.Windows.Forms.Button(); this.groupBox3.SuspendLayout(); this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).BeginInit(); + this.tableLayoutPanel1.SuspendLayout(); this.SuspendLayout(); // // 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(474, 468); + this.label6.Location = new System.Drawing.Point(485, 543); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(139, 23); this.label6.TabIndex = 144; @@ -83,7 +100,7 @@ private void InitializeComponent() this.lblNetworkHelp.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; 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(403, 493); + this.lblNetworkHelp.Location = new System.Drawing.Point(408, 493); this.lblNetworkHelp.Name = "lblNetworkHelp"; this.lblNetworkHelp.Size = new System.Drawing.Size(279, 46); this.lblNetworkHelp.TabIndex = 143; @@ -99,9 +116,9 @@ private void InitializeComponent() 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(735, 199); + this.cboxIsUDPOn.Location = new System.Drawing.Point(734, 226); this.cboxIsUDPOn.Name = "cboxIsUDPOn"; - this.cboxIsUDPOn.Size = new System.Drawing.Size(171, 50); + 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; @@ -112,7 +129,7 @@ private void InitializeComponent() // 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(735, 12); + this.groupBox3.Location = new System.Drawing.Point(734, 12); this.groupBox3.Name = "groupBox3"; this.groupBox3.Size = new System.Drawing.Size(171, 80); this.groupBox3.TabIndex = 94; @@ -141,7 +158,7 @@ private void InitializeComponent() // 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(735, 98); + this.groupBox5.Location = new System.Drawing.Point(734, 106); this.groupBox5.Name = "groupBox5"; this.groupBox5.Size = new System.Drawing.Size(171, 80); this.groupBox5.TabIndex = 95; @@ -170,25 +187,25 @@ private void InitializeComponent() // timer1 // this.timer1.Enabled = true; - this.timer1.Interval = 2000; + 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(455, 370); + this.label1.Location = new System.Drawing.Point(434, 422); this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(185, 23); + this.label1.Size = new System.Drawing.Size(236, 23); this.label1.TabIndex = 147; - this.label1.Text = "New 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(378, 399); + this.nudFirstIP.Location = new System.Drawing.Point(372, 378); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, @@ -210,7 +227,7 @@ private void InitializeComponent() // 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(495, 399); + this.nudSecndIP.Location = new System.Drawing.Point(489, 378); this.nudSecndIP.Maximum = new decimal(new int[] { 255, 0, @@ -226,13 +243,13 @@ private void InitializeComponent() 0, 0, 0}); - this.nudSecndIP.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(612, 399); + this.nudThirdIP.Location = new System.Drawing.Point(606, 378); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, @@ -248,13 +265,13 @@ private void InitializeComponent() 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(478, 393); + 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; @@ -265,7 +282,7 @@ 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(595, 393); + 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; @@ -276,7 +293,7 @@ private void InitializeComponent() // 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(762, 474); + this.label8.Location = new System.Drawing.Point(757, 443); this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(37, 23); this.label8.TabIndex = 157; @@ -287,7 +304,7 @@ private void InitializeComponent() // 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(409, 19); + 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; @@ -296,48 +313,35 @@ private void InitializeComponent() // // tboxNets // - this.tboxNets.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxNets.Location = new System.Drawing.Point(27, 45); + 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(330, 478); + 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", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label4.Location = new System.Drawing.Point(29, 9); + this.label4.Location = new System.Drawing.Point(14, 13); this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(154, 23); + this.label4.Size = new System.Drawing.Size(101, 23); this.label4.TabIndex = 163; - this.label4.Text = "Computer Name:"; + this.label4.Text = "Hostname:"; this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // tboxModules - // - this.tboxModules.Font = new System.Drawing.Font("Tahoma", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxModules.Location = new System.Drawing.Point(403, 45); - this.tboxModules.Multiline = true; - this.tboxModules.Name = "tboxModules"; - this.tboxModules.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; - this.tboxModules.Size = new System.Drawing.Size(268, 287); - this.tboxModules.TabIndex = 164; - this.tboxModules.Text = "192.168.1.126\r\nSteer Module\r\n\r\n192.168.1.126\r\nMachine Module\r\n\r\n192.168.1.126\r\nSt" + - "eer Module"; - this.tboxModules.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; - // // 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(179, 9); + this.lblHostname.Location = new System.Drawing.Point(112, 13); this.lblHostname.Name = "lblHostname"; - this.lblHostname.Size = new System.Drawing.Size(118, 23); + this.lblHostname.Size = new System.Drawing.Size(94, 23); this.lblHostname.TabIndex = 165; - this.lblHostname.Text = "Module Scan"; + this.lblHostname.Text = "Hostname"; this.lblHostname.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblNoAdapter @@ -345,11 +349,11 @@ private void InitializeComponent() 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(419, 546); + this.lblNoAdapter.Location = new System.Drawing.Point(398, 462); this.lblNoAdapter.Name = "lblNoAdapter"; - this.lblNoAdapter.Size = new System.Drawing.Size(249, 25); + this.lblNoAdapter.Size = new System.Drawing.Size(298, 25); this.lblNoAdapter.TabIndex = 166; - this.lblNoAdapter.Text = "No Adapter For Subnet"; + this.lblNoAdapter.Text = "No Adapter For This Subnet"; this.lblNoAdapter.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // cboxUp @@ -358,10 +362,10 @@ private void InitializeComponent() 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.PaleGreen; + 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(99, 544); + 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; @@ -379,22 +383,20 @@ private void InitializeComponent() 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.back_button; - this.btnSerialCancel.Location = new System.Drawing.Point(801, 530); + this.btnSerialCancel.Location = new System.Drawing.Point(816, 493); this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(91, 77); + this.btnSerialCancel.Size = new System.Drawing.Size(92, 79); this.btnSerialCancel.TabIndex = 71; this.btnSerialCancel.UseVisualStyleBackColor = true; // // btnAutoSet // - this.btnAutoSet.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); this.btnAutoSet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnAutoSet.Enabled = false; - this.btnAutoSet.FlatAppearance.BorderSize = 0; 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.Edit; - this.btnAutoSet.Location = new System.Drawing.Point(752, 277); + 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; @@ -405,7 +407,7 @@ private void InitializeComponent() // this.pboxSendSteer.BackgroundImage = global::AgIO.Properties.Resources.ConSt_Mandatory; this.pboxSendSteer.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.pboxSendSteer.Location = new System.Drawing.Point(822, 426); + this.pboxSendSteer.Location = new System.Drawing.Point(756, 321); this.pboxSendSteer.Name = "pboxSendSteer"; this.pboxSendSteer.Size = new System.Drawing.Size(38, 39); this.pboxSendSteer.TabIndex = 510; @@ -415,14 +417,13 @@ private void InitializeComponent() // 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.SubnetSend; - this.btnSendSubnet.Location = new System.Drawing.Point(741, 407); + this.btnSendSubnet.Location = new System.Drawing.Point(729, 361); this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(78, 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; @@ -432,18 +433,18 @@ private void InitializeComponent() // this.label5.AutoSize = true; 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(742, 338); + this.label5.Location = new System.Drawing.Point(583, 313); this.label5.Name = "label5"; - this.label5.Size = new System.Drawing.Size(81, 23); + this.label5.Size = new System.Drawing.Size(56, 23); this.label5.TabIndex = 512; - this.label5.Text = "Auto Set"; - this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + this.label5.Text = "Fill In"; + this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // label9 // 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(42, 558); + 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; @@ -452,27 +453,268 @@ private void InitializeComponent() // // lblSubTimer // - this.lblSubTimer.Font = new System.Drawing.Font("Tahoma", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblSubTimer.Location = new System.Drawing.Point(585, 20); + 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(83, 23); + this.lblSubTimer.Size = new System.Drawing.Size(100, 23); this.lblSubTimer.TabIndex = 514; - this.lblSubTimer.Text = "12"; + 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, 20F)); + 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; + // + // 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(216, 43); + this.lblGPSIP.TabIndex = 530; + this.lblGPSIP.Text = "k"; + this.lblGPSIP.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(216, 43); + this.lblMachineIP.TabIndex = 528; + this.lblMachineIP.Text = "k"; + this.lblMachineIP.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(216, 43); + this.lblSteerIP.TabIndex = 526; + this.lblSteerIP.Text = "255.255.255.255"; + this.lblSteerIP.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(216, 43); + this.lblIMU_IP.TabIndex = 526; + this.lblIMU_IP.Text = "k"; + this.lblIMU_IP.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; + // + // 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; + // + // 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; + // + // 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; + // + // 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; + // + // 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(323, 45); + this.lblBtnSteer.Name = "lblBtnSteer"; + this.lblBtnSteer.Size = new System.Drawing.Size(14, 43); + this.lblBtnSteer.TabIndex = 521; + this.lblBtnSteer.Text = "-"; + this.lblBtnSteer.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(323, 133); + this.lblBtnMachine.Name = "lblBtnMachine"; + this.lblBtnMachine.Size = new System.Drawing.Size(14, 43); + this.lblBtnMachine.TabIndex = 531; + this.lblBtnMachine.Text = "-"; + this.lblBtnMachine.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(323, 89); + this.lblBtnGPS.Name = "lblBtnGPS"; + this.lblBtnGPS.Size = new System.Drawing.Size(14, 43); + this.lblBtnGPS.TabIndex = 532; + this.lblBtnGPS.Text = "-"; + this.lblBtnGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // 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(323, 1); + this.lblBtnIMU.Name = "lblBtnIMU"; + this.lblBtnIMU.Size = new System.Drawing.Size(14, 43); + this.lblBtnIMU.TabIndex = 533; + this.lblBtnIMU.Text = "-"; + this.lblBtnIMU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // 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); + // // FormUDP // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(918, 615); + this.ClientSize = new System.Drawing.Size(920, 584); this.ControlBox = false; + 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.cboxIsUDPOn); - this.Controls.Add(this.tboxModules); this.Controls.Add(this.label4); this.Controls.Add(this.tboxNets); this.Controls.Add(this.label6); @@ -489,9 +731,9 @@ private void InitializeComponent() this.Controls.Add(this.label2); this.Controls.Add(this.label3); this.Controls.Add(this.label8); - this.Controls.Add(this.pboxSendSteer); this.Controls.Add(this.label5); this.Controls.Add(this.lblSubTimer); + this.Controls.Add(this.pboxSendSteer); 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); @@ -508,6 +750,8 @@ private void InitializeComponent() ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).EndInit(); + this.tableLayoutPanel1.ResumeLayout(false); + this.tableLayoutPanel1.PerformLayout(); this.ResumeLayout(false); this.PerformLayout(); @@ -533,7 +777,6 @@ private void InitializeComponent() private System.Windows.Forms.Label label7; private System.Windows.Forms.TextBox tboxNets; private System.Windows.Forms.Label label4; - private System.Windows.Forms.TextBox tboxModules; private System.Windows.Forms.Label lblHostname; private System.Windows.Forms.Label lblNoAdapter; private System.Windows.Forms.CheckBox cboxUp; @@ -543,5 +786,22 @@ private void InitializeComponent() 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; } } \ No newline at end of file diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index f19acd329..0ad200332 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -1,5 +1,7 @@ using System; using System.ComponentModel; +using System.Diagnostics; +using System.Drawing; using System.Linq; using System.Net; using System.Net.NetworkInformation; @@ -35,10 +37,7 @@ private void FormUDp_Load(object sender, EventArgs e) mf.ipAutoSet[1] = 99; mf.ipAutoSet[2] = 99; - mf.subnetTimer = 11; - lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST - tboxModules.Text = "Scanning"; cboxIsUDPOn.Checked = Properties.Settings.Default.setUDP_isOn; cboxPlugin.Checked = Properties.Settings.Default.setUDP_isUsePluginApp; @@ -64,15 +63,13 @@ private void FormUDp_Load(object sender, EventArgs e) if (!cboxIsUDPOn.Checked) cboxIsUDPOn.BackColor = System.Drawing.Color.Salmon; ScanNetwork(); - //GetIP4AddressList(); } + int tickCounter = 0; + private void timer1_Tick(object sender, EventArgs e) { - mf.subnetTimer++; - lblSubTimer.Text = mf.subnetTimer.ToString(); - - if (mf.subnetTimer > 6) + if(!mf.scanReply.isNewData) { mf.ipAutoSet[0] = 99; mf.ipAutoSet[1] = 99; @@ -84,33 +81,67 @@ private void timer1_Tick(object sender, EventArgs e) btnAutoSet.Enabled = true; } - if (cboxIsUDPOn.Checked) + if (mf.scanReply.isNewSteer) { - cboxIsSendNMEAToUDP.Enabled = true; - cboxPlugin.Enabled = true; + lblSteerIP.Text = mf.scanReply.steerIP; + mf.scanReply.isNewSteer = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; } - else + + if (mf.scanReply.isNewMachine) { - cboxIsSendNMEAToUDP.Enabled = false; - cboxPlugin.Enabled = false; - cboxIsSendNMEAToUDP.Checked = false; - cboxPlugin.Checked = false; + lblMachineIP.Text = mf.scanReply.machineIP; + mf.scanReply.isNewMachine = false; + lblNewSubnet.Text = mf.scanReply.subnetStr; } - ScanNetwork(); + 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++; } private void ScanNetwork() { tboxNets.Text = ""; - tboxModules.Text = mf.scanReturn; - mf.scanReturn = ""; + + 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 }; - //mf.SendUDPMessage(scanModules, mf.epModuleSet); + //Send out 255x4 to each installed network interface foreach (var nic in NetworkInterface.GetAllNetworkInterfaces()) { if (nic.Supports(NetworkInterfaceComponent.IPv4) ) @@ -123,6 +154,7 @@ private void ScanNetwork() Socket scanSocket; try { + //create list of interface properties if ((cboxUp.Checked && nic.OperationalStatus == OperationalStatus.Up) || !cboxUp.Checked) { var properties = nic.GetIPStatistics(); @@ -145,6 +177,7 @@ private void ScanNetwork() 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); @@ -267,46 +300,21 @@ private void btnSendSubnet_Click(object sender, EventArgs e) private void btnAutoSet_Click(object sender, EventArgs e) { - if (mf.ipAutoSet[0] == 99 && mf.ipAutoSet[1] == 99 && mf.ipAutoSet[2] == 99) - { - mf.TimedMessageBox(2000, "No Reply From Module", "No New Subnet From Module"); - } - else - { - nudFirstIP.Value = mf.ipAutoSet[0]; - nudSecndIP.Value = mf.ipAutoSet[1]; - nudThirdIP.Value = mf.ipAutoSet[2]; - ipNew[0] = mf.ipAutoSet[0]; - ipNew[1] = mf.ipAutoSet[1]; - ipNew[2] = mf.ipAutoSet[2]; + 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; - } - - //btnSendSubnet.PerformClick(); } private void nudFirstIP_Click(object sender, EventArgs e) { mf.KeypadToNUD((NumericUpDown)sender, this); ipNew[0] = (byte)nudFirstIP.Value; - btnSendSubnet.Enabled = true; - pboxSendSteer.Visible = true; - btnSerialCancel.Image = Properties.Resources.Cancel64; - } - - private void nudSecondIP_Click(object sender, EventArgs e) - { - mf.KeypadToNUD((NumericUpDown)sender, this); ipNew[1] = (byte)nudSecndIP.Value; - btnSendSubnet.Enabled = true; - pboxSendSteer.Visible = true; - btnSerialCancel.Image = Properties.Resources.Cancel64; - } - - private void nudThirdIP_Click(object sender, EventArgs e) - { - mf.KeypadToNUD((NumericUpDown)sender, this); ipNew[2] = (byte)nudThirdIP.Value; btnSendSubnet.Enabled = true; pboxSendSteer.Visible = true; @@ -319,6 +327,8 @@ private void cboxPlugin_Click(object sender, EventArgs e) Properties.Settings.Default.setUDP_isUsePluginApp = cboxPlugin.Checked; Properties.Settings.Default.setUDP_isSendNMEAToUDP = cboxIsSendNMEAToUDP.Checked; + mf.YesMessageBox("AgIO will Restart to Enable UDP Networking Feature"); + Properties.Settings.Default.Save(); Application.Restart(); Environment.Exit(0); @@ -337,6 +347,11 @@ private void cboxUp_Click(object sender, EventArgs e) } } + private void btnNetworkCPL_Click(object sender, EventArgs e) + { + Process.Start("ncpa.cpl"); + } + ////get the ipv4 address only //public void GetIP4AddressList() //{ diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 08c484d3c..9e6acafb4 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 @@ -42,6 +57,7 @@ public partial class FormLoop //class for counting bytes public CTraffic traffic = new CTraffic(); + public CScanReply scanReply = new CScanReply(); //scan results placed here public string scanReturn = "Scanning..."; @@ -349,57 +365,61 @@ private void ReceiveFromUDP(byte[] data) //scan Reply else if (data[3] == 203) // { - subnetTimer = 0; - 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\nSubnet " - + data[9].ToString() + "." - + data[10].ToString() + "." - + data[11].ToString() - + "\r\n\r\n"; - - ipAutoSet[0] = data[09]; - ipAutoSet[1] = data[10]; - ipAutoSet[2] = data[11]; + 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] == 126) + // + else if (data[2] == 123) //machine module { - scanReturn += "Steer Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\nSubnet " - + data[9].ToString() + "." - + data[10].ToString() + "." - + data[11].ToString() - + "\r\n\r\n"; - - ipAutoSet[0] = data[09]; - ipAutoSet[1] = data[10]; - ipAutoSet[2] = data[11]; + 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(); + + scanReply.isNewData = true; + scanReply.isNewMachine = true; + } - else if (data[2] == 121) + else if (data[2] == 121) //IMU Module { - scanReturn += "IMU 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] == 120) + else if (data[2] == 120) //GPS module { - scanReturn += "Panda Module \r\n"; - scanReturn += data[5].ToString() + "." + data[6].ToString() + "." - + data[7].ToString() + "." + data[8].ToString() + "\r\nSubnet " - + data[9].ToString() + "." - + data[10].ToString() + "." - + data[11].ToString() - + "\r\n\r\n"; - - ipAutoSet[0] = data[09]; - ipAutoSet[1] = data[10]; - ipAutoSet[2] = data[11]; - } + 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; + } } } // end of pgns From 382907caf291190a3a662e3394297705ce12f160 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Mon, 30 Jan 2023 23:25:00 -0700 Subject: [PATCH 14/17] Ethernet loopback setting --- SourceCode/AgIO/Source/AgIO.csproj | 9 + SourceCode/AgIO/Source/App.config | 15 + .../AgIO/Source/Forms/Controls.Designer.cs | 19 +- SourceCode/AgIO/Source/Forms/FormEthernet.cs | 111 ++++++ .../Source/Forms/FormEthernet.designer.cs | 333 ++++++++++++++++++ .../AgIO/Source/Forms/FormEthernet.resx | 120 +++++++ .../AgIO/Source/Forms/FormLoop.Designer.cs | 37 +- SourceCode/AgIO/Source/Forms/FormLoop.cs | 8 +- .../AgIO/Source/Forms/FormUDP.Designer.cs | 326 ++++++----------- SourceCode/AgIO/Source/Forms/FormUDP.cs | 32 -- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 22 +- .../Source/Properties/Settings.Designer.cs | 60 ++++ .../AgIO/Source/Properties/Settings.settings | 15 + 13 files changed, 833 insertions(+), 274 deletions(-) create mode 100644 SourceCode/AgIO/Source/Forms/FormEthernet.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormEthernet.resx diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index 40949c9c8..c54e60b64 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -126,6 +126,12 @@ FormSerialPass.cs + + Form + + + FormEthernet.cs + Form @@ -213,6 +219,9 @@ FormSerialPass.cs + + FormEthernet.cs + FormYes.cs diff --git a/SourceCode/AgIO/Source/App.config b/SourceCode/AgIO/Source/App.config index 2e4ece3e9..ac8b81985 100644 --- a/SourceCode/AgIO/Source/App.config +++ b/SourceCode/AgIO/Source/App.config @@ -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 7510a1197..fdff1d5f6 100644 --- a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs @@ -30,6 +30,14 @@ private void SettingsCommunicationGPS() isGPSCommOpen = false; } + private void SettingsEthernet() + { + using (FormEthernet form = new FormEthernet(this)) + { + form.ShowDialog(this); + } + } + private void SettingsNTRIP() { if (isRadio_RequiredOn) @@ -158,16 +166,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; @@ -198,7 +196,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..013b1fc3e --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.cs @@ -0,0 +1,111 @@ +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(); + + } + + + ////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..607d5ee9e --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs @@ -0,0 +1,333 @@ +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.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(632, 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(41, 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(465, 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(339, 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(213, 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(317, 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(442, 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(591, 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(568, 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; + // + // 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(736, 232); + this.ControlBox = false; + 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; + } +} \ 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 40e73b90f..7a7cb27d7 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -47,7 +47,7 @@ private void InitializeComponent() 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.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(); @@ -226,12 +226,12 @@ private void InitializeComponent() // 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(344, 245); + this.lblFromGPS.Location = new System.Drawing.Point(344, 273); this.lblFromGPS.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblFromGPS.Name = "lblFromGPS"; - this.lblFromGPS.Size = new System.Drawing.Size(23, 18); + this.lblFromGPS.Size = new System.Drawing.Size(26, 18); this.lblFromGPS.TabIndex = 130; this.lblFromGPS.Text = "---"; this.lblFromGPS.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; @@ -274,7 +274,7 @@ private void InitializeComponent() this.toolStripDropDownButton1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripMenuItem1, this.toolStripMenuItem2, - this.toolStripMenuItem4, + this.toolStripEthernet, this.deviceManagerToolStripMenuItem}); this.toolStripDropDownButton1.Image = global::AgIO.Properties.Resources.Settings48; this.toolStripDropDownButton1.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; @@ -288,7 +288,7 @@ private void InitializeComponent() 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.Size = new System.Drawing.Size(311, 70); this.toolStripMenuItem1.Text = "Save"; this.toolStripMenuItem1.Click += new System.EventHandler(this.toolStripMenuItem1_Click); // @@ -297,25 +297,25 @@ private void InitializeComponent() 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.Size = new System.Drawing.Size(311, 70); this.toolStripMenuItem2.Text = "Load"; this.toolStripMenuItem2.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // - // toolStripMenuItem4 + // toolStripEthernet // - 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); + 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(296, 70); + this.deviceManagerToolStripMenuItem.Size = new System.Drawing.Size(311, 70); this.deviceManagerToolStripMenuItem.Text = "Device Manager"; this.deviceManagerToolStripMenuItem.Click += new System.EventHandler(this.deviceManagerToolStripMenuItem_Click); // @@ -724,12 +724,12 @@ private void InitializeComponent() // 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(344, 273); + this.lblToGPS.Location = new System.Drawing.Point(344, 246); this.lblToGPS.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.lblToGPS.Name = "lblToGPS"; - this.lblToGPS.Size = new System.Drawing.Size(23, 18); + this.lblToGPS.Size = new System.Drawing.Size(26, 18); this.lblToGPS.TabIndex = 512; this.lblToGPS.Text = "---"; this.lblToGPS.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; @@ -1201,6 +1201,7 @@ private void InitializeComponent() public System.Windows.Forms.Button btnGPS; public System.Windows.Forms.Button btnMachine; public System.Windows.Forms.Button btnSteer; + private System.Windows.Forms.ToolStripMenuItem toolStripEthernet; } } diff --git a/SourceCode/AgIO/Source/Forms/FormLoop.cs b/SourceCode/AgIO/Source/Forms/FormLoop.cs index 1e7e4811b..9c809ec50 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.cs @@ -811,6 +811,11 @@ private void btnGPSData_Click(object sender, EventArgs e) form.Show(this); } + private void toolStripEthernet_Click(object sender, EventArgs e) + { + SettingsEthernet(); + } + private void lblNTRIPBytes_Click(object sender, EventArgs e) { tripBytes = 0; @@ -830,7 +835,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/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 28f6f7a01..15b2d8d29 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -31,11 +31,6 @@ private void InitializeComponent() this.components = new System.ComponentModel.Container(); this.label6 = new System.Windows.Forms.Label(); this.lblNetworkHelp = new System.Windows.Forms.Label(); - 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(); @@ -60,22 +55,20 @@ private void InitializeComponent() 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.lblMachineIP = new System.Windows.Forms.Label(); this.lblSteerIP = new System.Windows.Forms.Label(); - this.lblIMU_IP = new System.Windows.Forms.Label(); + this.lblBtnSteer = new System.Windows.Forms.Label(); this.label16 = new System.Windows.Forms.Label(); - this.label15 = new System.Windows.Forms.Label(); + this.lblMachineIP = new System.Windows.Forms.Label(); this.label17 = new System.Windows.Forms.Label(); - this.label18 = new System.Windows.Forms.Label(); this.lblNewSubnet = new System.Windows.Forms.Label(); - this.lblBtnSteer = new System.Windows.Forms.Label(); - this.lblBtnMachine = new System.Windows.Forms.Label(); - this.lblBtnGPS = new System.Windows.Forms.Label(); - this.lblBtnIMU = new System.Windows.Forms.Label(); this.btnNetworkCPL = new System.Windows.Forms.Button(); - this.groupBox3.SuspendLayout(); - this.groupBox5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); @@ -107,83 +100,6 @@ private void InitializeComponent() this.lblNetworkHelp.Text = "192 . 168 . 123 . x"; this.lblNetworkHelp.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // 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(734, 226); - 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 = true; - this.cboxIsUDPOn.Click += new System.EventHandler(this.cboxPlugin_Click); - // - // 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(734, 12); - 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"; - // - // 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; - this.cboxIsSendNMEAToUDP.Click += new System.EventHandler(this.cboxPlugin_Click); - // - // 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(734, 106); - 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"; - // - // 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; - this.cboxPlugin.Click += new System.EventHandler(this.cboxPlugin_Click); - // // timer1 // this.timer1.Enabled = true; @@ -293,7 +209,7 @@ private void InitializeComponent() // 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(757, 443); + 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; @@ -383,7 +299,7 @@ private void InitializeComponent() 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.back_button; - this.btnSerialCancel.Location = new System.Drawing.Point(816, 493); + this.btnSerialCancel.Location = new System.Drawing.Point(757, 493); this.btnSerialCancel.Name = "btnSerialCancel"; this.btnSerialCancel.Size = new System.Drawing.Size(92, 79); this.btnSerialCancel.TabIndex = 71; @@ -407,7 +323,7 @@ private void InitializeComponent() // this.pboxSendSteer.BackgroundImage = global::AgIO.Properties.Resources.ConSt_Mandatory; this.pboxSendSteer.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.pboxSendSteer.Location = new System.Drawing.Point(756, 321); + 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; @@ -421,7 +337,7 @@ private void InitializeComponent() 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.SubnetSend; - this.btnSendSubnet.Location = new System.Drawing.Point(729, 361); + this.btnSendSubnet.Location = new System.Drawing.Point(755, 339); this.btnSendSubnet.Name = "btnSendSubnet"; this.btnSendSubnet.Size = new System.Drawing.Size(92, 79); this.btnSendSubnet.TabIndex = 151; @@ -490,7 +406,7 @@ private void InitializeComponent() 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, 20F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 21F)); this.tableLayoutPanel1.Controls.Add(this.lblBtnIMU, 2, 0); this.tableLayoutPanel1.Controls.Add(this.lblBtnGPS, 2, 2); this.tableLayoutPanel1.Controls.Add(this.label18, 0, 0); @@ -513,6 +429,84 @@ private void InitializeComponent() 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(322, 1); + this.lblBtnIMU.Name = "lblBtnIMU"; + this.lblBtnIMU.Size = new System.Drawing.Size(15, 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(322, 89); + this.lblBtnGPS.Name = "lblBtnGPS"; + this.lblBtnGPS.Size = new System.Drawing.Size(15, 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(215, 43); + this.lblIMU_IP.TabIndex = 526; + this.lblIMU_IP.Text = "k"; + 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(322, 133); + this.lblBtnMachine.Name = "lblBtnMachine"; + this.lblBtnMachine.Size = new System.Drawing.Size(15, 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; @@ -521,24 +515,11 @@ private void InitializeComponent() 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(216, 43); + this.lblGPSIP.Size = new System.Drawing.Size(215, 43); this.lblGPSIP.TabIndex = 530; this.lblGPSIP.Text = "k"; this.lblGPSIP.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(216, 43); - this.lblMachineIP.TabIndex = 528; - this.lblMachineIP.Text = "k"; - this.lblMachineIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // // lblSteerIP // this.lblSteerIP.AutoSize = true; @@ -547,23 +528,23 @@ private void InitializeComponent() 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(216, 43); + this.lblSteerIP.Size = new System.Drawing.Size(215, 43); this.lblSteerIP.TabIndex = 526; this.lblSteerIP.Text = "255.255.255.255"; this.lblSteerIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // lblIMU_IP + // lblBtnSteer // - 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(216, 43); - this.lblIMU_IP.TabIndex = 526; - this.lblIMU_IP.Text = "k"; - this.lblIMU_IP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + 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(322, 45); + this.lblBtnSteer.Name = "lblBtnSteer"; + this.lblBtnSteer.Size = new System.Drawing.Size(15, 43); + this.lblBtnSteer.TabIndex = 521; + this.lblBtnSteer.Text = "-"; + this.lblBtnSteer.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // label16 // @@ -578,18 +559,18 @@ private void InitializeComponent() this.label16.Text = "Machine"; this.label16.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // label15 + // lblMachineIP // - 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; + 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(215, 43); + this.lblMachineIP.TabIndex = 528; + this.lblMachineIP.Text = "k"; + this.lblMachineIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // label17 // @@ -604,19 +585,6 @@ private void InitializeComponent() this.label17.Text = "GPS"; this.label17.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; - // // lblNewSubnet // this.lblNewSubnet.BackColor = System.Drawing.SystemColors.ButtonHighlight; @@ -630,58 +598,6 @@ private void InitializeComponent() this.lblNewSubnet.Text = "192 . 168 . 123"; this.lblNewSubnet.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(323, 45); - this.lblBtnSteer.Name = "lblBtnSteer"; - this.lblBtnSteer.Size = new System.Drawing.Size(14, 43); - this.lblBtnSteer.TabIndex = 521; - this.lblBtnSteer.Text = "-"; - this.lblBtnSteer.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(323, 133); - this.lblBtnMachine.Name = "lblBtnMachine"; - this.lblBtnMachine.Size = new System.Drawing.Size(14, 43); - this.lblBtnMachine.TabIndex = 531; - this.lblBtnMachine.Text = "-"; - this.lblBtnMachine.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(323, 89); - this.lblBtnGPS.Name = "lblBtnGPS"; - this.lblBtnGPS.Size = new System.Drawing.Size(14, 43); - this.lblBtnGPS.TabIndex = 532; - this.lblBtnGPS.Text = "-"; - this.lblBtnGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // 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(323, 1); - this.lblBtnIMU.Name = "lblBtnIMU"; - this.lblBtnIMU.Size = new System.Drawing.Size(14, 43); - this.lblBtnIMU.TabIndex = 533; - this.lblBtnIMU.Text = "-"; - this.lblBtnIMU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // // btnNetworkCPL // this.btnNetworkCPL.BackgroundImage = global::AgIO.Properties.Resources.DeviceManager; @@ -702,7 +618,7 @@ private void InitializeComponent() // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 19F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(920, 584); + this.ClientSize = new System.Drawing.Size(861, 584); this.ControlBox = false; this.Controls.Add(this.btnNetworkCPL); this.Controls.Add(this.lblNewSubnet); @@ -714,7 +630,6 @@ private void InitializeComponent() this.Controls.Add(this.cboxUp); this.Controls.Add(this.lblNoAdapter); this.Controls.Add(this.lblHostname); - this.Controls.Add(this.cboxIsUDPOn); this.Controls.Add(this.label4); this.Controls.Add(this.tboxNets); this.Controls.Add(this.label6); @@ -722,9 +637,7 @@ private void InitializeComponent() this.Controls.Add(this.label7); this.Controls.Add(this.btnSendSubnet); this.Controls.Add(this.nudThirdIP); - this.Controls.Add(this.groupBox5); this.Controls.Add(this.nudSecndIP); - this.Controls.Add(this.groupBox3); this.Controls.Add(this.nudFirstIP); this.Controls.Add(this.label1); this.Controls.Add(this.btnSerialCancel); @@ -744,8 +657,6 @@ private void InitializeComponent() 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.nudFirstIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).EndInit(); @@ -759,11 +670,6 @@ private void InitializeComponent() #endregion private System.Windows.Forms.Button btnSerialCancel; - private System.Windows.Forms.CheckBox cboxIsUDPOn; - private System.Windows.Forms.GroupBox groupBox3; - private System.Windows.Forms.CheckBox cboxIsSendNMEAToUDP; - 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; diff --git a/SourceCode/AgIO/Source/Forms/FormUDP.cs b/SourceCode/AgIO/Source/Forms/FormUDP.cs index 0ad200332..c8a8c6bc6 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -39,10 +39,6 @@ private void FormUDp_Load(object sender, EventArgs e) lblHostname.Text = Dns.GetHostName(); // Retrieve the Name of HOST - cboxIsUDPOn.Checked = Properties.Settings.Default.setUDP_isOn; - cboxPlugin.Checked = Properties.Settings.Default.setUDP_isUsePluginApp; - cboxIsSendNMEAToUDP.Checked = Properties.Settings.Default.setUDP_isSendNMEAToUDP; - lblNetworkHelp.Text = Properties.Settings.Default.etIP_SubnetOne.ToString() + " . " + Properties.Settings.Default.etIP_SubnetTwo.ToString() + " . " + @@ -52,16 +48,6 @@ private void FormUDp_Load(object sender, EventArgs e) nudSecndIP.Value = ipNew[1] = ipCurrent[1] = Properties.Settings.Default.etIP_SubnetTwo; nudThirdIP.Value = ipNew[2] = ipCurrent[2] = Properties.Settings.Default.etIP_SubnetThree; - if (!cboxIsUDPOn.Checked) - { - nudFirstIP.Enabled = false; - nudSecndIP.Enabled = false; - nudThirdIP.Enabled = false; - btnSendSubnet.Enabled = false; - } - - if (!cboxIsUDPOn.Checked) cboxIsUDPOn.BackColor = System.Drawing.Color.Salmon; - ScanNetwork(); } @@ -277,10 +263,6 @@ private void btnSendSubnet_Click(object sender, EventArgs e) Properties.Settings.Default.etIP_SubnetTwo = ipCurrent[1] = ipNew[1]; Properties.Settings.Default.etIP_SubnetThree = ipCurrent[2] = ipNew[2]; - 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.epModule = new IPEndPoint(IPAddress.Parse( @@ -321,20 +303,6 @@ private void nudFirstIP_Click(object sender, EventArgs e) btnSerialCancel.Image = Properties.Resources.Cancel64; } - private void cboxPlugin_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; - - mf.YesMessageBox("AgIO will Restart to Enable UDP Networking Feature"); - - Properties.Settings.Default.Save(); - Application.Restart(); - Environment.Exit(0); - Close(); - } - private void cboxUp_Click(object sender, EventArgs e) { if(cboxUp.Checked) diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 9e6acafb4..99698ebc0 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -44,8 +44,26 @@ public partial class FormLoop 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); + + string ip = + Properties.Settings.Default.eth_loopOne.ToString() + "." + + Properties.Settings.Default.eth_loopTwo.ToString() + "." + + Properties.Settings.Default.eth_loopThree.ToString() + "." + + Properties.Settings.Default.eth_loopFour.ToString(); + + + 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() + "." + diff --git a/SourceCode/AgIO/Source/Properties/Settings.Designer.cs b/SourceCode/AgIO/Source/Properties/Settings.Designer.cs index 9ff83cb36..a866be522 100644 --- a/SourceCode/AgIO/Source/Properties/Settings.Designer.cs +++ b/SourceCode/AgIO/Source/Properties/Settings.Designer.cs @@ -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 304d52289..043dfc3ba 100644 --- a/SourceCode/AgIO/Source/Properties/Settings.settings +++ b/SourceCode/AgIO/Source/Properties/Settings.settings @@ -176,5 +176,20 @@ 5 + + 127 + + + 255 + + + 255 + + + 255 + + + + \ No newline at end of file From 033d3711c01da119eba273f684b1e96b0f151236 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 1 Feb 2023 13:48:58 -0700 Subject: [PATCH 15/17] Add Serial Monitor --- SourceCode/AgIO/Source/AgIO.csproj | 10 + .../AgIO/Source/Forms/Controls.Designer.cs | 21 +- SourceCode/AgIO/Source/Forms/FormEthernet.cs | 5 + .../Source/Forms/FormEthernet.designer.cs | 39 ++- .../AgIO/Source/Forms/FormLoop.Designer.cs | 61 +++- SourceCode/AgIO/Source/Forms/FormLoop.cs | 20 +- .../AgIO/Source/Forms/FormNtrip.Designer.cs | 19 ++ SourceCode/AgIO/Source/Forms/FormNtrip.cs | 5 + .../AgIO/Source/Forms/FormSerialMonitor.cs | 259 +++++++++++++++ .../Forms/FormSerialMonitor.designer.cs | 298 ++++++++++++++++++ .../AgIO/Source/Forms/FormSerialMonitor.resx | 179 +++++++++++ .../AgIO/Source/Forms/FormUDP.Designer.cs | 209 +++++++----- SourceCode/AgIO/Source/Forms/FormUDP.cs | 16 + SourceCode/AgIO/Source/Forms/NMEA.Designer.cs | 13 +- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 16 +- .../Source/Properties/Resources.Designer.cs | 10 + .../AgIO/Source/Properties/Resources.resx | 69 ++-- SourceCode/AgIO/Source/btnImages/Help.png | Bin 0 -> 862 bytes SourceCode/AgIO/Source/gStr.Designer.cs | 36 +++ SourceCode/AgIO/Source/gStr.resx | 12 + 20 files changed, 1140 insertions(+), 157 deletions(-) create mode 100644 SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs create mode 100644 SourceCode/AgIO/Source/Forms/FormSerialMonitor.resx create mode 100644 SourceCode/AgIO/Source/btnImages/Help.png diff --git a/SourceCode/AgIO/Source/AgIO.csproj b/SourceCode/AgIO/Source/AgIO.csproj index c54e60b64..cbab15398 100644 --- a/SourceCode/AgIO/Source/AgIO.csproj +++ b/SourceCode/AgIO/Source/AgIO.csproj @@ -90,6 +90,12 @@ FormCommSetGPS.cs + + Form + + + FormSerialMonitor.cs + Form @@ -191,6 +197,9 @@ FormCommSetGPS.cs Designer + + FormSerialMonitor.cs + FormGPSData.cs Designer @@ -312,6 +321,7 @@ + diff --git a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs index fdff1d5f6..89f2c3f76 100644 --- a/SourceCode/AgIO/Source/Forms/Controls.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/Controls.Designer.cs @@ -19,6 +19,17 @@ public void YesMessageBox(string 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; @@ -95,15 +106,9 @@ private void SettingsRadio() private void SettingsUDP() { - using (var form = new FormUDP(this)) + FormUDP formEth = new FormUDP(this); { - form.ShowDialog(this); - //if (form.ShowDialog(this) == DialogResult.OK) - //{ - // //Clicked Save - // Application.Restart(); - // Environment.Exit(0); - //} + formEth.Show(this); } } diff --git a/SourceCode/AgIO/Source/Forms/FormEthernet.cs b/SourceCode/AgIO/Source/Forms/FormEthernet.cs index 013b1fc3e..a56238f89 100644 --- a/SourceCode/AgIO/Source/Forms/FormEthernet.cs +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.cs @@ -75,6 +75,11 @@ private void btnSerialCancel_Click(object sender, EventArgs e) } + private void btnHelp_Click(object sender, EventArgs e) + { + System.Diagnostics.Process.Start(gStr.gsEthernetHelp); + } + ////get the ipv4 address only //public void GetIP4AddressList() diff --git a/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs b/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs index 607d5ee9e..2355f9538 100644 --- a/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormEthernet.designer.cs @@ -42,6 +42,7 @@ private void InitializeComponent() 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(); @@ -59,7 +60,7 @@ private void InitializeComponent() 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(632, 141); + 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; @@ -71,7 +72,7 @@ private void InitializeComponent() 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(41, 23); + 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; @@ -157,7 +158,7 @@ private void InitializeComponent() // 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(465, 27); + this.nudThirdIP.Location = new System.Drawing.Point(426, 27); this.nudThirdIP.Maximum = new decimal(new int[] { 255, 0, @@ -179,7 +180,7 @@ private void InitializeComponent() // 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(339, 27); + this.nudSecndIP.Location = new System.Drawing.Point(300, 27); this.nudSecndIP.Maximum = new decimal(new int[] { 255, 0, @@ -201,7 +202,7 @@ private void InitializeComponent() // 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(213, 27); + this.nudFirstIP.Location = new System.Drawing.Point(174, 27); this.nudFirstIP.Maximum = new decimal(new int[] { 255, 0, @@ -223,7 +224,7 @@ private void InitializeComponent() // 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(317, 21); + 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; @@ -234,7 +235,7 @@ 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(442, 21); + 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; @@ -245,7 +246,7 @@ private void InitializeComponent() // 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(591, 27); + this.nudFourthIP.Location = new System.Drawing.Point(552, 27); this.nudFourthIP.Maximum = new decimal(new int[] { 255, 0, @@ -267,20 +268,37 @@ private void InitializeComponent() // 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(568, 21); + 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(736, 232); + 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); @@ -329,5 +347,6 @@ private void InitializeComponent() 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/FormLoop.Designer.cs b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs index 7a7cb27d7..01115109c 100644 --- a/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormLoop.Designer.cs @@ -98,6 +98,8 @@ private void InitializeComponent() 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(); @@ -191,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(181, 342); + 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); @@ -203,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(181, 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); @@ -215,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(181, 86); + 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); @@ -228,7 +230,7 @@ private void InitializeComponent() this.lblFromGPS.BackColor = System.Drawing.Color.Transparent; 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(344, 273); + 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(26, 18); @@ -241,7 +243,7 @@ private void InitializeComponent() 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(181, 257); + 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); @@ -275,6 +277,7 @@ private void InitializeComponent() 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; @@ -726,7 +729,7 @@ private void InitializeComponent() this.lblToGPS.BackColor = System.Drawing.Color.Transparent; 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(344, 246); + 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(26, 18); @@ -818,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(252, 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); @@ -837,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(252, 155); + 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); @@ -856,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(252, 325); + 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); @@ -875,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(252, 240); + 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); @@ -913,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, 16); + 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); @@ -1026,10 +1029,10 @@ private void InitializeComponent() 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(133, 11); + 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(75, 48); + 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); @@ -1054,6 +1057,31 @@ private void InitializeComponent() 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); @@ -1061,6 +1089,7 @@ private void InitializeComponent() this.BackColor = System.Drawing.Color.Gainsboro; this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; 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); @@ -1112,11 +1141,11 @@ private void InitializeComponent() this.Controls.Add(this.lblCurentLon); this.Controls.Add(this.lblCurrentLat); this.Controls.Add(this.btnRelayTest); - this.Controls.Add(this.btnGPSData); 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; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; @@ -1202,6 +1231,8 @@ private void InitializeComponent() 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 9c809ec50..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; @@ -418,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 @@ -816,6 +829,11 @@ 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; diff --git a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs index 9b160c88c..130b29357 100644 --- a/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormNtrip.Designer.cs @@ -82,6 +82,7 @@ private void InitializeComponent() this.cboxIsNTRIPOn = new System.Windows.Forms.CheckBox(); 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(); @@ -817,6 +818,22 @@ private void InitializeComponent() 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); @@ -906,5 +924,6 @@ private void InitializeComponent() 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 4ea83d57d..e8f0dc398 100644 --- a/SourceCode/AgIO/Source/Forms/FormNtrip.cs +++ b/SourceCode/AgIO/Source/Forms/FormNtrip.cs @@ -443,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..48776ea4f --- /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); + } + } + + 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..f9012e1cc --- /dev/null +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs @@ -0,0 +1,298 @@ +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(449, 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(555, 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(349, 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(255, 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(161, 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(68, 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(573, 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.ShowInTaskbar = false; + 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/jHzZfHj5m1b8Bg0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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/FormUDP.Designer.cs b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs index 15b2d8d29..e861a1516 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.Designer.cs @@ -45,10 +45,6 @@ private void InitializeComponent() this.lblHostname = new System.Windows.Forms.Label(); this.lblNoAdapter = new System.Windows.Forms.Label(); this.cboxUp = new System.Windows.Forms.CheckBox(); - this.btnSerialCancel = new System.Windows.Forms.Button(); - this.btnAutoSet = new System.Windows.Forms.Button(); - this.pboxSendSteer = new System.Windows.Forms.PictureBox(); - this.btnSendSubnet = new System.Windows.Forms.Button(); this.label5 = new System.Windows.Forms.Label(); this.label9 = new System.Windows.Forms.Label(); this.lblSubTimer = new System.Windows.Forms.Label(); @@ -68,12 +64,19 @@ private void InitializeComponent() 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.pboxSendSteer = new System.Windows.Forms.PictureBox(); + this.btnSerialMonitor = new System.Windows.Forms.Button(); + this.label10 = new System.Windows.Forms.Label(); ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).BeginInit(); this.tableLayoutPanel1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).BeginInit(); this.SuspendLayout(); // // label6 @@ -290,61 +293,6 @@ private void InitializeComponent() this.cboxUp.UseVisualStyleBackColor = true; this.cboxUp.Click += new System.EventHandler(this.cboxUp_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.back_button; - this.btnSerialCancel.Location = new System.Drawing.Point(757, 493); - this.btnSerialCancel.Name = "btnSerialCancel"; - this.btnSerialCancel.Size = new System.Drawing.Size(92, 79); - this.btnSerialCancel.TabIndex = 71; - this.btnSerialCancel.UseVisualStyleBackColor = true; - // - // 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); - // - // 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; - // - // btnSendSubnet - // - this.btnSendSubnet.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - 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.SubnetSend; - this.btnSendSubnet.Location = new System.Drawing.Point(755, 339); - this.btnSendSubnet.Name = "btnSendSubnet"; - this.btnSendSubnet.Size = new System.Drawing.Size(92, 79); - this.btnSendSubnet.TabIndex = 151; - this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; - this.btnSendSubnet.UseVisualStyleBackColor = true; - this.btnSendSubnet.Click += new System.EventHandler(this.btnSendSubnet_Click); - // // label5 // this.label5.AutoSize = true; @@ -406,7 +354,7 @@ private void InitializeComponent() 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, 21F)); + 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); @@ -435,9 +383,9 @@ private void InitializeComponent() 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(322, 1); + this.lblBtnIMU.Location = new System.Drawing.Point(317, 1); this.lblBtnIMU.Name = "lblBtnIMU"; - this.lblBtnIMU.Size = new System.Drawing.Size(15, 43); + this.lblBtnIMU.Size = new System.Drawing.Size(20, 43); this.lblBtnIMU.TabIndex = 533; this.lblBtnIMU.Text = "-"; this.lblBtnIMU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -448,9 +396,9 @@ private void InitializeComponent() 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(322, 89); + this.lblBtnGPS.Location = new System.Drawing.Point(317, 89); this.lblBtnGPS.Name = "lblBtnGPS"; - this.lblBtnGPS.Size = new System.Drawing.Size(15, 43); + this.lblBtnGPS.Size = new System.Drawing.Size(20, 43); this.lblBtnGPS.TabIndex = 532; this.lblBtnGPS.Text = "-"; this.lblBtnGPS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -476,9 +424,9 @@ private void InitializeComponent() 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(215, 43); + this.lblIMU_IP.Size = new System.Drawing.Size(210, 43); this.lblIMU_IP.TabIndex = 526; - this.lblIMU_IP.Text = "k"; + this.lblIMU_IP.Text = ".."; this.lblIMU_IP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblBtnMachine @@ -487,9 +435,9 @@ private void InitializeComponent() 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(322, 133); + this.lblBtnMachine.Location = new System.Drawing.Point(317, 133); this.lblBtnMachine.Name = "lblBtnMachine"; - this.lblBtnMachine.Size = new System.Drawing.Size(15, 43); + this.lblBtnMachine.Size = new System.Drawing.Size(20, 43); this.lblBtnMachine.TabIndex = 531; this.lblBtnMachine.Text = "-"; this.lblBtnMachine.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -515,9 +463,9 @@ private void InitializeComponent() 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(215, 43); + this.lblGPSIP.Size = new System.Drawing.Size(210, 43); this.lblGPSIP.TabIndex = 530; - this.lblGPSIP.Text = "k"; + this.lblGPSIP.Text = ".."; this.lblGPSIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblSteerIP @@ -528,9 +476,9 @@ private void InitializeComponent() 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(215, 43); + this.lblSteerIP.Size = new System.Drawing.Size(210, 43); this.lblSteerIP.TabIndex = 526; - this.lblSteerIP.Text = "255.255.255.255"; + this.lblSteerIP.Text = ".."; this.lblSteerIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // lblBtnSteer @@ -539,9 +487,9 @@ private void InitializeComponent() 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(322, 45); + this.lblBtnSteer.Location = new System.Drawing.Point(317, 45); this.lblBtnSteer.Name = "lblBtnSteer"; - this.lblBtnSteer.Size = new System.Drawing.Size(15, 43); + this.lblBtnSteer.Size = new System.Drawing.Size(20, 43); this.lblBtnSteer.TabIndex = 521; this.lblBtnSteer.Text = "-"; this.lblBtnSteer.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -567,9 +515,9 @@ private void InitializeComponent() 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(215, 43); + this.lblMachineIP.Size = new System.Drawing.Size(210, 43); this.lblMachineIP.TabIndex = 528; - this.lblMachineIP.Text = "k"; + this.lblMachineIP.Text = ".."; this.lblMachineIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // label17 @@ -598,6 +546,22 @@ private void InitializeComponent() 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; @@ -614,12 +578,97 @@ private void InitializeComponent() 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.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.SubnetSend; + this.btnSendSubnet.Location = new System.Drawing.Point(755, 339); + this.btnSendSubnet.Name = "btnSendSubnet"; + this.btnSendSubnet.Size = new System.Drawing.Size(92, 79); + this.btnSendSubnet.TabIndex = 151; + this.btnSendSubnet.TextAlign = System.Drawing.ContentAlignment.TopLeft; + this.btnSendSubnet.UseVisualStyleBackColor = true; + this.btnSendSubnet.Click += new System.EventHandler(this.btnSendSubnet_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.back_button; + this.btnSerialCancel.Location = new System.Drawing.Point(757, 493); + 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); + // + // 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", 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(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(861, 584); this.ControlBox = false; + 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); @@ -647,6 +696,7 @@ private void InitializeComponent() 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); @@ -660,9 +710,9 @@ private void InitializeComponent() ((System.ComponentModel.ISupportInitialize)(this.nudFirstIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudSecndIP)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.nudThirdIP)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).EndInit(); this.tableLayoutPanel1.ResumeLayout(false); this.tableLayoutPanel1.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pboxSendSteer)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); @@ -709,5 +759,8 @@ private void InitializeComponent() 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 c8a8c6bc6..f66dd12b6 100644 --- a/SourceCode/AgIO/Source/Forms/FormUDP.cs +++ b/SourceCode/AgIO/Source/Forms/FormUDP.cs @@ -320,6 +320,22 @@ private void btnNetworkCPL_Click(object sender, EventArgs e) Process.Start("ncpa.cpl"); } + private void btnHelp_Click(object sender, EventArgs e) + { + System.Diagnostics.Process.Start(gStr.gsSerialMonHelp); + + } + + private void btnSerialCancel_Click(object sender, EventArgs e) + { + Close(); + } + + private void btnSerialMonitor_Click(object sender, EventArgs e) + { + mf.ShowSerialMonitor(); + } + ////get the ipv4 address only //public void GetIP4AddressList() //{ diff --git a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs index e692c8dc4..673ff43d2 100644 --- a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs @@ -71,6 +71,11 @@ public string Parse(ref string buffer) //the NMEA sentence to be parsed sentence = buffer.Substring(0, end + 1); + if (isLogMonitorOn) + { + logMonitorSentence.Append(sentence); + } + //remove the processed sentence from the rawBuffer buffer = buffer.Substring(end + 1); } @@ -115,10 +120,16 @@ 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"); } + if (isLogMonitorOn) + { + logMonitorSentence.Append("\r\n" + + DateTime.UtcNow.ToString(" Dropped ->> mm:ss.fff ", CultureInfo.InvariantCulture) + "\r\n" + rawBuffer + "\r\n"); + } + rawBuffer = ""; return; } diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 99698ebc0..97e823089 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -45,13 +45,6 @@ public partial class FormLoop //2 endpoints for local and 2 udp - string ip = - Properties.Settings.Default.eth_loopOne.ToString() + "." + - Properties.Settings.Default.eth_loopTwo.ToString() + "." + - Properties.Settings.Default.eth_loopThree.ToString() + "." + - Properties.Settings.Default.eth_loopFour.ToString(); - - private IPEndPoint epAgOpen = new IPEndPoint(IPAddress.Parse( Properties.Settings.Default.eth_loopOne.ToString() + "." + Properties.Settings.Default.eth_loopTwo.ToString() + "." + @@ -352,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) @@ -366,7 +360,7 @@ private void ReceiveFromUDP(byte[] data) } } - else if (data[3] == 123) + else if (data[3] == 123 && data.Length == 11) { traffic.helloFromMachine = 0; @@ -377,11 +371,11 @@ 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] == 126) //steer module { diff --git a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs index 81ec89f0e..0a1fd31e0 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.Designer.cs +++ b/SourceCode/AgIO/Source/Properties/Resources.Designer.cs @@ -300,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. /// diff --git a/SourceCode/AgIO/Source/Properties/Resources.resx b/SourceCode/AgIO/Source/Properties/Resources.resx index 9c7ec2735..ff33f1002 100644 --- a/SourceCode/AgIO/Source/Properties/Resources.resx +++ b/SourceCode/AgIO/Source/Properties/Resources.resx @@ -124,6 +124,9 @@ ..\btnImages\Com_Module2.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\VehFileLoad.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\AgIO_First.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -142,12 +145,12 @@ ..\btnImages\ConS_ImplementAntenna.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\B_Machine.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 @@ -175,24 +178,21 @@ ..\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\Cancel64.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 - - ..\btnImages\Nmea.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\B_UDP.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\DnArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -205,6 +205,9 @@ ..\btnImages\NtripToUDP.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\NTRIP_Client.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -217,8 +220,11 @@ ..\btnImages\ArrowGrnLeft.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\OK64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\btnImages\Com_AutosteerModule.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\satellite.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -226,11 +232,11 @@ ..\btnImages\B_Autosteer.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\B_Machine.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Com_AutosteerModule.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Cancel64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\USB_Disconnect.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -238,17 +244,17 @@ ..\btnImages\LogNMEA.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\SwitchOff.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\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 @@ -259,19 +265,16 @@ ..\btnImages\ArrowRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\VehFileLoad.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\OK64.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\back-button.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\ConSt_Mandatory.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\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/btnImages/Help.png b/SourceCode/AgIO/Source/btnImages/Help.png new file mode 100644 index 0000000000000000000000000000000000000000..901ac04e86f6ec4f2e3da4dc2ef4fe16643f3c2a GIT binary patch literal 862 zcmV-k1EKthP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!2kdb!2!6DYwZ940`o~kK~!i%?blC8 z6j2-p@He|NyQ8h<8cK$UBK=vTz)KJlzVw8vw zS(i*NkrfsZdhsBemcoMKf`3}2Z5?-JXZk(&xv}dg+PtR;?*otb-fv)?@4k6&9mH`Q z$8j9TZ3LP0|G(~f$6n}+)tcRgLeP7mQ6-R`n&YLm^8+E&{<%SNZkJd7_@{#z6aKES z`$(~^?!&15ij*z0lb#A3rhnY%xL+ZP2McVZYOXwA%PQR=NG*NwnxiGQpe&6T21o%6K2Wx1^15=&7s{e zw0u9SKNo8w!v=rpuXe@F!f3jI3Y(P0wvs*0Fb+cnjX+B0W$A&>qh^qK(wt(T!;iHn zoO=7lZ^dn3}olO6F(x;)KZ2fEHv)C|%36e5XRQAw;okGLtjL`%e z+f7PIjVHxJ{vNF#|29FeAy_GLB^6mc%lAX=lmj`?W)s6CeE0ZHy_pi~?7!}GoBcL@ zn#>CMTBZtMh`*5Z&sY~4kK7Wo8&U9a?y#e`P1W06W??2H2D;idjf2-ivlIrSxk6^V zILxCODPyG*@Jy>dJM&9@J{dvRNZAsWfn=M2g7?m4Wt*LV*p=79T<`Gw0PMX}Fx3)O zYiK@l=|s_vaw)DJ`j^j9v<2a7vI5rUa1F4z&HM6)(Q~&?~07*qoM6N<$f?R@{Y5)KL literal 0 HcmV?d00001 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 From ae8b61955f37acd908903fb52a1886940bc72810 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Wed, 1 Feb 2023 20:39:06 -0700 Subject: [PATCH 16/17] Serial Monitor Update --- .../AgIO/Source/Forms/FormSerialMonitor.cs | 4 ++-- .../Source/Forms/FormSerialMonitor.designer.cs | 15 +++++++-------- SourceCode/AgIO/Source/Forms/NMEA.Designer.cs | 17 ++++++----------- 3 files changed, 15 insertions(+), 21 deletions(-) diff --git a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs index 48776ea4f..48a878fc4 100644 --- a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.cs @@ -25,7 +25,6 @@ public partial class FormSerialMonitor : Form private bool logOn = false; - public FormSerialMonitor(Form callingForm) { //get copy of the calling main form @@ -192,7 +191,6 @@ private void btnRescan_Click(object sender, EventArgs e) { cboxPort.Items.Add(s); } - } private void btnCloseSerial_Click(object sender, EventArgs e) @@ -244,6 +242,8 @@ private void btnFileSave_Click(object sender, EventArgs e) { writer.Write(textBoxRcv.Text); } + + mf.TimedMessageBox(2000, "File Saved", "To zAgIO_SerialMon_Log.Txt"); } private void FormSerialMonitor_FormClosing(object sender, FormClosingEventArgs e) diff --git a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs index f9012e1cc..0bdf795ac 100644 --- a/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs +++ b/SourceCode/AgIO/Source/Forms/FormSerialMonitor.designer.cs @@ -55,7 +55,7 @@ private void InitializeComponent() 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(449, 300); + 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; @@ -157,7 +157,7 @@ private void InitializeComponent() this.textBoxRcv.Name = "textBoxRcv"; this.textBoxRcv.ReadOnly = true; this.textBoxRcv.ScrollBars = System.Windows.Forms.ScrollBars.Both; - this.textBoxRcv.Size = new System.Drawing.Size(555, 219); + this.textBoxRcv.Size = new System.Drawing.Size(521, 219); this.textBoxRcv.TabIndex = 539; // // btnRescan @@ -184,7 +184,7 @@ private void InitializeComponent() 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(349, 300); + 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; @@ -204,7 +204,7 @@ private void InitializeComponent() 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(255, 300); + 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; @@ -219,7 +219,7 @@ private void InitializeComponent() 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(161, 300); + 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; @@ -235,7 +235,7 @@ private void InitializeComponent() 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(68, 300); + 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; @@ -248,7 +248,7 @@ private void InitializeComponent() 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(573, 361); + this.ClientSize = new System.Drawing.Size(539, 361); this.ControlBox = false; this.Controls.Add(this.btnHelp); this.Controls.Add(this.btnClear); @@ -269,7 +269,6 @@ private void InitializeComponent() this.MaximizeBox = false; this.MinimizeBox = false; this.Name = "FormSerialMonitor"; - this.ShowInTaskbar = false; 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); diff --git a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs index 673ff43d2..f9ac70b8b 100644 --- a/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs +++ b/SourceCode/AgIO/Source/Forms/NMEA.Designer.cs @@ -71,11 +71,6 @@ public string Parse(ref string buffer) //the NMEA sentence to be parsed sentence = buffer.Substring(0, end + 1); - if (isLogMonitorOn) - { - logMonitorSentence.Append(sentence); - } - //remove the processed sentence from the rawBuffer buffer = buffer.Substring(end + 1); } @@ -124,16 +119,16 @@ public void ParseNMEA(ref string buffer) DateTime.UtcNow.ToString(" ->> mm:ss.fff ", CultureInfo.InvariantCulture) + "\r\n" + rawBuffer + "\r\n"); } - if (isLogMonitorOn) - { - logMonitorSentence.Append("\r\n" + - DateTime.UtcNow.ToString(" Dropped ->> mm:ss.fff ", CultureInfo.InvariantCulture) + "\r\n" + rawBuffer + "\r\n"); - } - rawBuffer = ""; 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) { From c0882d15eff8b0d4944ff5c9589bdbd908a3e3d2 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Thu, 2 Feb 2023 07:00:51 -0700 Subject: [PATCH 17/17] Version to 5.7.1 --- SourceCode/AgIO/Source/Properties/AssemblyInfo.cs | 4 ++-- SourceCode/GPS/Properties/AssemblyInfo.cs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) 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/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