Commit 227f7be8 LN

fuwei

1 个父辈 8f31be6a
此文件类型无法预览
此文件太大,无法显示。
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<Prefer32Bit>true</Prefer32Bit> <Prefer32Bit>true</Prefer32Bit>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
......
...@@ -107,6 +107,7 @@ namespace OnlineStore.AssemblyLine ...@@ -107,6 +107,7 @@ namespace OnlineStore.AssemblyLine
if (equipBase.runStatus >= LineRunStatus.HomeMoving) if (equipBase.runStatus >= LineRunStatus.HomeMoving)
{ {
equipBase.StopRun(); equipBase.StopRun();
FormStatus(false);
} }
else else
{ {
......
...@@ -127,9 +127,9 @@ ...@@ -127,9 +127,9 @@
this.groupBox1.Controls.Add(this.txtWriteTime); this.groupBox1.Controls.Add(this.txtWriteTime);
this.groupBox1.Controls.Add(this.label5); this.groupBox1.Controls.Add(this.label5);
this.groupBox1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.groupBox1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.groupBox1.Location = new System.Drawing.Point(3, 488); this.groupBox1.Location = new System.Drawing.Point(3, 527);
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(394, 158); this.groupBox1.Size = new System.Drawing.Size(394, 169);
this.groupBox1.TabIndex = 105; this.groupBox1.TabIndex = 105;
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "DO写入"; this.groupBox1.Text = "DO写入";
...@@ -276,7 +276,7 @@ ...@@ -276,7 +276,7 @@
this.groupBox4.Controls.Add(this.tableLayoutPanel2); this.groupBox4.Controls.Add(this.tableLayoutPanel2);
this.groupBox4.Location = new System.Drawing.Point(488, 6); this.groupBox4.Location = new System.Drawing.Point(488, 6);
this.groupBox4.Name = "groupBox4"; this.groupBox4.Name = "groupBox4";
this.groupBox4.Size = new System.Drawing.Size(240, 475); this.groupBox4.Size = new System.Drawing.Size(240, 519);
this.groupBox4.TabIndex = 104; this.groupBox4.TabIndex = 104;
this.groupBox4.TabStop = false; this.groupBox4.TabStop = false;
this.groupBox4.Text = "DO列表"; this.groupBox4.Text = "DO列表";
...@@ -293,7 +293,7 @@ ...@@ -293,7 +293,7 @@
this.tableLayoutPanel2.RowCount = 2; this.tableLayoutPanel2.RowCount = 2;
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel2.Size = new System.Drawing.Size(229, 455); this.tableLayoutPanel2.Size = new System.Drawing.Size(229, 499);
this.tableLayoutPanel2.TabIndex = 103; this.tableLayoutPanel2.TabIndex = 103;
// //
// groupBox3 // groupBox3
...@@ -303,7 +303,7 @@ ...@@ -303,7 +303,7 @@
this.groupBox3.Controls.Add(this.tableLayoutPanel1); this.groupBox3.Controls.Add(this.tableLayoutPanel1);
this.groupBox3.Location = new System.Drawing.Point(6, 6); this.groupBox3.Location = new System.Drawing.Point(6, 6);
this.groupBox3.Name = "groupBox3"; this.groupBox3.Name = "groupBox3";
this.groupBox3.Size = new System.Drawing.Size(240, 475); this.groupBox3.Size = new System.Drawing.Size(240, 519);
this.groupBox3.TabIndex = 103; this.groupBox3.TabIndex = 103;
this.groupBox3.TabStop = false; this.groupBox3.TabStop = false;
this.groupBox3.Text = "DI列表"; this.groupBox3.Text = "DI列表";
...@@ -320,7 +320,7 @@ ...@@ -320,7 +320,7 @@
this.tableLayoutPanel1.RowCount = 2; this.tableLayoutPanel1.RowCount = 2;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(229, 455); this.tableLayoutPanel1.Size = new System.Drawing.Size(229, 499);
this.tableLayoutPanel1.TabIndex = 102; this.tableLayoutPanel1.TabIndex = 102;
// //
// groupBox5 // groupBox5
...@@ -345,7 +345,7 @@ ...@@ -345,7 +345,7 @@
this.groupBox5.Controls.Add(this.btnFeedSideWay); this.groupBox5.Controls.Add(this.btnFeedSideWay);
this.groupBox5.Location = new System.Drawing.Point(974, 6); this.groupBox5.Location = new System.Drawing.Point(974, 6);
this.groupBox5.Name = "groupBox5"; this.groupBox5.Name = "groupBox5";
this.groupBox5.Size = new System.Drawing.Size(338, 475); this.groupBox5.Size = new System.Drawing.Size(338, 519);
this.groupBox5.TabIndex = 255; this.groupBox5.TabIndex = 255;
this.groupBox5.TabStop = false; this.groupBox5.TabStop = false;
this.groupBox5.Text = "IO操作测试"; this.groupBox5.Text = "IO操作测试";
...@@ -657,10 +657,10 @@ ...@@ -657,10 +657,10 @@
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.tabControl1.Controls.Add(this.tabPage1); this.tabControl1.Controls.Add(this.tabPage1);
this.tabControl1.Controls.Add(this.tabPage2); this.tabControl1.Controls.Add(this.tabPage2);
this.tabControl1.Location = new System.Drawing.Point(5, 69); this.tabControl1.Location = new System.Drawing.Point(5, 64);
this.tabControl1.Name = "tabControl1"; this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0; this.tabControl1.SelectedIndex = 0;
this.tabControl1.Size = new System.Drawing.Size(1327, 687); this.tabControl1.Size = new System.Drawing.Size(1327, 731);
this.tabControl1.TabIndex = 257; this.tabControl1.TabIndex = 257;
// //
// tabPage1 // tabPage1
...@@ -675,7 +675,7 @@ ...@@ -675,7 +675,7 @@
this.tabPage1.Location = new System.Drawing.Point(4, 26); this.tabPage1.Location = new System.Drawing.Point(4, 26);
this.tabPage1.Name = "tabPage1"; this.tabPage1.Name = "tabPage1";
this.tabPage1.Padding = new System.Windows.Forms.Padding(3); this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
this.tabPage1.Size = new System.Drawing.Size(1319, 657); this.tabPage1.Size = new System.Drawing.Size(1319, 701);
this.tabPage1.TabIndex = 0; this.tabPage1.TabIndex = 0;
this.tabPage1.Text = " IO列表 "; this.tabPage1.Text = " IO列表 ";
this.tabPage1.UseVisualStyleBackColor = true; this.tabPage1.UseVisualStyleBackColor = true;
...@@ -688,9 +688,9 @@ ...@@ -688,9 +688,9 @@
this.groupBox6.Controls.Add(this.lblAgvInfo); this.groupBox6.Controls.Add(this.lblAgvInfo);
this.groupBox6.Controls.Add(this.lblInstoreList); this.groupBox6.Controls.Add(this.lblInstoreList);
this.groupBox6.Controls.Add(this.lblThisSta); this.groupBox6.Controls.Add(this.lblThisSta);
this.groupBox6.Location = new System.Drawing.Point(403, 488); this.groupBox6.Location = new System.Drawing.Point(403, 527);
this.groupBox6.Name = "groupBox6"; this.groupBox6.Name = "groupBox6";
this.groupBox6.Size = new System.Drawing.Size(909, 160); this.groupBox6.Size = new System.Drawing.Size(909, 171);
this.groupBox6.TabIndex = 278; this.groupBox6.TabIndex = 278;
this.groupBox6.TabStop = false; this.groupBox6.TabStop = false;
this.groupBox6.Text = "消息"; this.groupBox6.Text = "消息";
...@@ -711,7 +711,7 @@ ...@@ -711,7 +711,7 @@
this.lblAgvInfo.AutoSize = true; this.lblAgvInfo.AutoSize = true;
this.lblAgvInfo.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblAgvInfo.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblAgvInfo.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.lblAgvInfo.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblAgvInfo.Location = new System.Drawing.Point(237, 29); this.lblAgvInfo.Location = new System.Drawing.Point(248, 25);
this.lblAgvInfo.Name = "lblAgvInfo"; this.lblAgvInfo.Name = "lblAgvInfo";
this.lblAgvInfo.Size = new System.Drawing.Size(61, 17); this.lblAgvInfo.Size = new System.Drawing.Size(61, 17);
this.lblAgvInfo.TabIndex = 276; this.lblAgvInfo.TabIndex = 276;
...@@ -736,7 +736,7 @@ ...@@ -736,7 +736,7 @@
this.groupBox7.Controls.Add(this.tableLayoutPanel3); this.groupBox7.Controls.Add(this.tableLayoutPanel3);
this.groupBox7.Location = new System.Drawing.Point(247, 6); this.groupBox7.Location = new System.Drawing.Point(247, 6);
this.groupBox7.Name = "groupBox7"; this.groupBox7.Name = "groupBox7";
this.groupBox7.Size = new System.Drawing.Size(240, 475); this.groupBox7.Size = new System.Drawing.Size(240, 519);
this.groupBox7.TabIndex = 279; this.groupBox7.TabIndex = 279;
this.groupBox7.TabStop = false; this.groupBox7.TabStop = false;
this.groupBox7.Text = "DI列表"; this.groupBox7.Text = "DI列表";
...@@ -753,7 +753,7 @@ ...@@ -753,7 +753,7 @@
this.tableLayoutPanel3.RowCount = 2; this.tableLayoutPanel3.RowCount = 2;
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel3.Size = new System.Drawing.Size(229, 455); this.tableLayoutPanel3.Size = new System.Drawing.Size(229, 499);
this.tableLayoutPanel3.TabIndex = 102; this.tableLayoutPanel3.TabIndex = 102;
// //
// groupBox8 // groupBox8
...@@ -763,7 +763,7 @@ ...@@ -763,7 +763,7 @@
this.groupBox8.Controls.Add(this.tableLayoutPanel4); this.groupBox8.Controls.Add(this.tableLayoutPanel4);
this.groupBox8.Location = new System.Drawing.Point(728, 6); this.groupBox8.Location = new System.Drawing.Point(728, 6);
this.groupBox8.Name = "groupBox8"; this.groupBox8.Name = "groupBox8";
this.groupBox8.Size = new System.Drawing.Size(240, 475); this.groupBox8.Size = new System.Drawing.Size(240, 519);
this.groupBox8.TabIndex = 280; this.groupBox8.TabIndex = 280;
this.groupBox8.TabStop = false; this.groupBox8.TabStop = false;
this.groupBox8.Text = "DO列表"; this.groupBox8.Text = "DO列表";
...@@ -780,7 +780,7 @@ ...@@ -780,7 +780,7 @@
this.tableLayoutPanel4.RowCount = 2; this.tableLayoutPanel4.RowCount = 2;
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F)); this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
this.tableLayoutPanel4.Size = new System.Drawing.Size(229, 455); this.tableLayoutPanel4.Size = new System.Drawing.Size(229, 499);
this.tableLayoutPanel4.TabIndex = 103; this.tableLayoutPanel4.TabIndex = 103;
// //
// tabPage2 // tabPage2
...@@ -1082,7 +1082,7 @@ ...@@ -1082,7 +1082,7 @@
this.panel1.Controls.Add(this.btnReset); this.panel1.Controls.Add(this.btnReset);
this.panel1.Location = new System.Drawing.Point(2, 1); this.panel1.Location = new System.Drawing.Point(2, 1);
this.panel1.Name = "panel1"; this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(1326, 68); this.panel1.Size = new System.Drawing.Size(1326, 62);
this.panel1.TabIndex = 258; this.panel1.TabIndex = 258;
// //
// chbMoveStop // chbMoveStop
...@@ -1126,7 +1126,7 @@ ...@@ -1126,7 +1126,7 @@
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F); this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1338, 762); this.ClientSize = new System.Drawing.Size(1338, 797);
this.Controls.Add(this.panel1); this.Controls.Add(this.panel1);
this.Controls.Add(this.tabControl1); this.Controls.Add(this.tabControl1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
......
...@@ -258,7 +258,7 @@ namespace OnlineStore.AssemblyLine ...@@ -258,7 +258,7 @@ namespace OnlineStore.AssemblyLine
IOManager.instance.CloseAllConnection(); IOManager.instance.CloseAllConnection();
//AIManager.CloseConnect(); //AIManager.CloseConnect();
ACServerManager.CloseAllPort(); ACServerManager.CloseAllPort();
CodeManager.CloseAllCamera(); // CodeManager.CloseAllCamera();
RFIDManager.CloseAllConnection(); RFIDManager.CloseAllConnection();
//this.Close(); //this.Close();
System.Environment.Exit(System.Environment.ExitCode); System.Environment.Exit(System.Environment.ExitCode);
......
...@@ -42,12 +42,11 @@ ...@@ -42,12 +42,11 @@
this.numNum = new System.Windows.Forms.NumericUpDown(); this.numNum = new System.Windows.Forms.NumericUpDown();
this.btnFind = new System.Windows.Forms.Button(); this.btnFind = new System.Windows.Forms.Button();
this.lblHas = new System.Windows.Forms.Label(); this.lblHas = new System.Windows.Forms.Label();
this.txtSearchIp = new System.Windows.Forms.TextBox();
this.btnSearch = new System.Windows.Forms.Button(); this.btnSearch = new System.Windows.Forms.Button();
this.cmbLocalIp = new System.Windows.Forms.ComboBox(); this.cmbLocalIp = new System.Windows.Forms.ComboBox();
this.label5 = new System.Windows.Forms.Label(); this.label5 = new System.Windows.Forms.Label();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
this.label6 = new System.Windows.Forms.Label(); this.listView1 = new System.Windows.Forms.ListView();
this.groupBox2 = new System.Windows.Forms.GroupBox(); this.groupBox2 = new System.Windows.Forms.GroupBox();
this.btnClose = new System.Windows.Forms.Button(); this.btnClose = new System.Windows.Forms.Button();
this.btnConnect = new System.Windows.Forms.Button(); this.btnConnect = new System.Windows.Forms.Button();
...@@ -61,7 +60,7 @@ ...@@ -61,7 +60,7 @@
this.label1.AutoSize = true; this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label1.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label1.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label1.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label1.Location = new System.Drawing.Point(80, 36); this.label1.Location = new System.Drawing.Point(28, 36);
this.label1.Name = "label1"; this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(107, 20); this.label1.Size = new System.Drawing.Size(107, 20);
this.label1.TabIndex = 0; this.label1.TabIndex = 0;
...@@ -72,7 +71,7 @@ ...@@ -72,7 +71,7 @@
// //
this.btnNext.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnNext.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnNext.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnNext.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnNext.Location = new System.Drawing.Point(405, 178); this.btnNext.Location = new System.Drawing.Point(270, 168);
this.btnNext.Name = "btnNext"; this.btnNext.Name = "btnNext";
this.btnNext.Size = new System.Drawing.Size(120, 45); this.btnNext.Size = new System.Drawing.Size(120, 45);
this.btnNext.TabIndex = 275; this.btnNext.TabIndex = 275;
...@@ -85,7 +84,7 @@ ...@@ -85,7 +84,7 @@
// //
this.btnBack.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnBack.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnBack.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnBack.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnBack.Location = new System.Drawing.Point(412, 238); this.btnBack.Location = new System.Drawing.Point(196, 286);
this.btnBack.Name = "btnBack"; this.btnBack.Name = "btnBack";
this.btnBack.Size = new System.Drawing.Size(120, 45); this.btnBack.Size = new System.Drawing.Size(120, 45);
this.btnBack.TabIndex = 274; this.btnBack.TabIndex = 274;
...@@ -96,19 +95,23 @@ ...@@ -96,19 +95,23 @@
// txtIP // txtIP
// //
this.txtIP.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.txtIP.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtIP.Location = new System.Drawing.Point(196, 82); this.txtIP.Location = new System.Drawing.Point(144, 82);
this.txtIP.Name = "txtIP"; this.txtIP.Name = "txtIP";
this.txtIP.Size = new System.Drawing.Size(233, 26); this.txtIP.Size = new System.Drawing.Size(189, 26);
this.txtIP.TabIndex = 276; this.txtIP.TabIndex = 276;
// //
// comboxType // comboxType
// //
this.comboxType.DropDownHeight = 200;
this.comboxType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; this.comboxType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboxType.DropDownWidth = 200;
this.comboxType.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.comboxType.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.comboxType.FormattingEnabled = true; this.comboxType.FormattingEnabled = true;
this.comboxType.Location = new System.Drawing.Point(196, 33); this.comboxType.IntegralHeight = false;
this.comboxType.ItemHeight = 20;
this.comboxType.Location = new System.Drawing.Point(144, 33);
this.comboxType.Name = "comboxType"; this.comboxType.Name = "comboxType";
this.comboxType.Size = new System.Drawing.Size(233, 28); this.comboxType.Size = new System.Drawing.Size(189, 28);
this.comboxType.TabIndex = 277; this.comboxType.TabIndex = 277;
this.comboxType.SelectedIndexChanged += new System.EventHandler(this.comboxType_SelectedIndexChanged); this.comboxType.SelectedIndexChanged += new System.EventHandler(this.comboxType_SelectedIndexChanged);
// //
...@@ -117,7 +120,7 @@ ...@@ -117,7 +120,7 @@
this.label2.AutoSize = true; this.label2.AutoSize = true;
this.label2.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label2.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label2.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label2.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label2.Location = new System.Drawing.Point(109, 84); this.label2.Location = new System.Drawing.Point(57, 84);
this.label2.Name = "label2"; this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(78, 20); this.label2.Size = new System.Drawing.Size(78, 20);
this.label2.TabIndex = 278; this.label2.TabIndex = 278;
...@@ -136,7 +139,7 @@ ...@@ -136,7 +139,7 @@
"C", "C",
"D", "D",
"E"}); "E"});
this.comType.Location = new System.Drawing.Point(196, 129); this.comType.Location = new System.Drawing.Point(144, 129);
this.comType.Name = "comType"; this.comType.Name = "comType";
this.comType.Size = new System.Drawing.Size(120, 28); this.comType.Size = new System.Drawing.Size(120, 28);
this.comType.TabIndex = 280; this.comType.TabIndex = 280;
...@@ -146,7 +149,7 @@ ...@@ -146,7 +149,7 @@
this.label3.AutoSize = true; this.label3.AutoSize = true;
this.label3.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label3.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label3.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label3.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label3.Location = new System.Drawing.Point(122, 132); this.label3.Location = new System.Drawing.Point(70, 132);
this.label3.Name = "label3"; this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(65, 20); this.label3.Size = new System.Drawing.Size(65, 20);
this.label3.TabIndex = 279; this.label3.TabIndex = 279;
...@@ -157,7 +160,7 @@ ...@@ -157,7 +160,7 @@
// //
this.btnRead.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnRead.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnRead.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnRead.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnRead.Location = new System.Drawing.Point(286, 238); this.btnRead.Location = new System.Drawing.Point(196, 238);
this.btnRead.Name = "btnRead"; this.btnRead.Name = "btnRead";
this.btnRead.Size = new System.Drawing.Size(120, 45); this.btnRead.Size = new System.Drawing.Size(120, 45);
this.btnRead.TabIndex = 281; this.btnRead.TabIndex = 281;
...@@ -170,7 +173,7 @@ ...@@ -170,7 +173,7 @@
this.label4.AutoSize = true; this.label4.AutoSize = true;
this.label4.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label4.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label4.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label4.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label4.Location = new System.Drawing.Point(136, 180); this.label4.Location = new System.Drawing.Point(84, 180);
this.label4.Name = "label4"; this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(51, 20); this.label4.Size = new System.Drawing.Size(51, 20);
this.label4.TabIndex = 282; this.label4.TabIndex = 282;
...@@ -180,7 +183,7 @@ ...@@ -180,7 +183,7 @@
// numNum // numNum
// //
this.numNum.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.numNum.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.numNum.Location = new System.Drawing.Point(196, 178); this.numNum.Location = new System.Drawing.Point(144, 178);
this.numNum.Name = "numNum"; this.numNum.Name = "numNum";
this.numNum.Size = new System.Drawing.Size(120, 26); this.numNum.Size = new System.Drawing.Size(120, 26);
this.numNum.TabIndex = 283; this.numNum.TabIndex = 283;
...@@ -189,7 +192,7 @@ ...@@ -189,7 +192,7 @@
// //
this.btnFind.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnFind.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnFind.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnFind.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnFind.Location = new System.Drawing.Point(405, 129); this.btnFind.Location = new System.Drawing.Point(270, 119);
this.btnFind.Name = "btnFind"; this.btnFind.Name = "btnFind";
this.btnFind.Size = new System.Drawing.Size(120, 45); this.btnFind.Size = new System.Drawing.Size(120, 45);
this.btnFind.TabIndex = 284; this.btnFind.TabIndex = 284;
...@@ -203,7 +206,7 @@ ...@@ -203,7 +206,7 @@
this.lblHas.AutoSize = true; this.lblHas.AutoSize = true;
this.lblHas.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblHas.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblHas.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.lblHas.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblHas.Location = new System.Drawing.Point(531, 178); this.lblHas.Location = new System.Drawing.Point(339, 216);
this.lblHas.Name = "lblHas"; this.lblHas.Name = "lblHas";
this.lblHas.Size = new System.Drawing.Size(51, 20); this.lblHas.Size = new System.Drawing.Size(51, 20);
this.lblHas.TabIndex = 285; this.lblHas.TabIndex = 285;
...@@ -211,20 +214,11 @@ ...@@ -211,20 +214,11 @@
this.lblHas.TextAlign = System.Drawing.ContentAlignment.MiddleRight; this.lblHas.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblHas.Visible = false; this.lblHas.Visible = false;
// //
// txtSearchIp
//
this.txtSearchIp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtSearchIp.Location = new System.Drawing.Point(196, 87);
this.txtSearchIp.Multiline = true;
this.txtSearchIp.Name = "txtSearchIp";
this.txtSearchIp.Size = new System.Drawing.Size(233, 244);
this.txtSearchIp.TabIndex = 286;
//
// btnSearch // btnSearch
// //
this.btnSearch.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSearch.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSearch.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnSearch.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSearch.Location = new System.Drawing.Point(446, 68); this.btnSearch.Location = new System.Drawing.Point(28, 136);
this.btnSearch.Name = "btnSearch"; this.btnSearch.Name = "btnSearch";
this.btnSearch.Size = new System.Drawing.Size(120, 45); this.btnSearch.Size = new System.Drawing.Size(120, 45);
this.btnSearch.TabIndex = 287; this.btnSearch.TabIndex = 287;
...@@ -237,9 +231,9 @@ ...@@ -237,9 +231,9 @@
this.cmbLocalIp.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; this.cmbLocalIp.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cmbLocalIp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.cmbLocalIp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.cmbLocalIp.FormattingEnabled = true; this.cmbLocalIp.FormattingEnabled = true;
this.cmbLocalIp.Location = new System.Drawing.Point(196, 38); this.cmbLocalIp.Location = new System.Drawing.Point(28, 80);
this.cmbLocalIp.Name = "cmbLocalIp"; this.cmbLocalIp.Name = "cmbLocalIp";
this.cmbLocalIp.Size = new System.Drawing.Size(233, 28); this.cmbLocalIp.Size = new System.Drawing.Size(120, 28);
this.cmbLocalIp.TabIndex = 288; this.cmbLocalIp.TabIndex = 288;
// //
// label5 // label5
...@@ -247,7 +241,7 @@ ...@@ -247,7 +241,7 @@
this.label5.AutoSize = true; this.label5.AutoSize = true;
this.label5.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label5.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label5.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label5.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label5.Location = new System.Drawing.Point(81, 38); this.label5.Location = new System.Drawing.Point(14, 36);
this.label5.Name = "label5"; this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(106, 20); this.label5.Size = new System.Drawing.Size(106, 20);
this.label5.TabIndex = 289; this.label5.TabIndex = 289;
...@@ -256,34 +250,35 @@ ...@@ -256,34 +250,35 @@
// //
// groupBox1 // groupBox1
// //
this.groupBox1.Controls.Add(this.label6); this.groupBox1.Controls.Add(this.listView1);
this.groupBox1.Controls.Add(this.cmbLocalIp); this.groupBox1.Controls.Add(this.cmbLocalIp);
this.groupBox1.Controls.Add(this.label5); this.groupBox1.Controls.Add(this.label5);
this.groupBox1.Controls.Add(this.txtSearchIp);
this.groupBox1.Controls.Add(this.btnSearch); this.groupBox1.Controls.Add(this.btnSearch);
this.groupBox1.Location = new System.Drawing.Point(22, 12); this.groupBox1.Location = new System.Drawing.Point(22, 12);
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(614, 350); this.groupBox1.Size = new System.Drawing.Size(364, 350);
this.groupBox1.TabIndex = 290; this.groupBox1.TabIndex = 290;
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "搜索RFID"; this.groupBox1.Text = "搜索RFID";
// //
// label6 // listView1
// //
this.label6.AutoSize = true; this.listView1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.label6.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); | System.Windows.Forms.AnchorStyles.Right)));
this.label6.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.listView1.FullRowSelect = true;
this.label6.Location = new System.Drawing.Point(108, 90); this.listView1.HideSelection = false;
this.label6.Name = "label6"; this.listView1.Location = new System.Drawing.Point(173, 22);
this.label6.Size = new System.Drawing.Size(79, 20); this.listView1.Name = "listView1";
this.label6.TabIndex = 290; this.listView1.Size = new System.Drawing.Size(174, 309);
this.label6.Text = "搜素结果:"; this.listView1.TabIndex = 291;
this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleRight; this.listView1.UseCompatibleStateImageBehavior = false;
this.listView1.View = System.Windows.Forms.View.List;
// //
// groupBox2 // groupBox2
// //
this.groupBox2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) this.groupBox2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left))); | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox2.Controls.Add(this.btnClose); this.groupBox2.Controls.Add(this.btnClose);
this.groupBox2.Controls.Add(this.btnConnect); this.groupBox2.Controls.Add(this.btnConnect);
this.groupBox2.Controls.Add(this.comboxType); this.groupBox2.Controls.Add(this.comboxType);
...@@ -299,9 +294,9 @@ ...@@ -299,9 +294,9 @@
this.groupBox2.Controls.Add(this.label3); this.groupBox2.Controls.Add(this.label3);
this.groupBox2.Controls.Add(this.label4); this.groupBox2.Controls.Add(this.label4);
this.groupBox2.Controls.Add(this.comType); this.groupBox2.Controls.Add(this.comType);
this.groupBox2.Location = new System.Drawing.Point(22, 368); this.groupBox2.Location = new System.Drawing.Point(392, 12);
this.groupBox2.Name = "groupBox2"; this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(614, 301); this.groupBox2.Size = new System.Drawing.Size(412, 350);
this.groupBox2.TabIndex = 291; this.groupBox2.TabIndex = 291;
this.groupBox2.TabStop = false; this.groupBox2.TabStop = false;
this.groupBox2.Text = "读取RFID"; this.groupBox2.Text = "读取RFID";
...@@ -310,7 +305,7 @@ ...@@ -310,7 +305,7 @@
// //
this.btnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnClose.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnClose.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnClose.Location = new System.Drawing.Point(160, 238); this.btnClose.Location = new System.Drawing.Point(34, 286);
this.btnClose.Name = "btnClose"; this.btnClose.Name = "btnClose";
this.btnClose.Size = new System.Drawing.Size(120, 45); this.btnClose.Size = new System.Drawing.Size(120, 45);
this.btnClose.TabIndex = 287; this.btnClose.TabIndex = 287;
...@@ -334,7 +329,7 @@ ...@@ -334,7 +329,7 @@
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F); this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(662, 693); this.ClientSize = new System.Drawing.Size(816, 374);
this.Controls.Add(this.groupBox2); this.Controls.Add(this.groupBox2);
this.Controls.Add(this.groupBox1); this.Controls.Add(this.groupBox1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
...@@ -365,14 +360,13 @@ ...@@ -365,14 +360,13 @@
private System.Windows.Forms.NumericUpDown numNum; private System.Windows.Forms.NumericUpDown numNum;
private System.Windows.Forms.Button btnFind; private System.Windows.Forms.Button btnFind;
private System.Windows.Forms.Label lblHas; private System.Windows.Forms.Label lblHas;
private System.Windows.Forms.TextBox txtSearchIp;
private System.Windows.Forms.Button btnSearch; private System.Windows.Forms.Button btnSearch;
private System.Windows.Forms.ComboBox cmbLocalIp; private System.Windows.Forms.ComboBox cmbLocalIp;
private System.Windows.Forms.Label label5; private System.Windows.Forms.Label label5;
private System.Windows.Forms.GroupBox groupBox1; private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.GroupBox groupBox2; private System.Windows.Forms.GroupBox groupBox2;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.Button btnConnect; private System.Windows.Forms.Button btnConnect;
private System.Windows.Forms.Button btnClose; private System.Windows.Forms.Button btnClose;
private System.Windows.Forms.ListView listView1;
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -140,9 +140,8 @@ namespace OnlineStore.AssemblyLine ...@@ -140,9 +140,8 @@ namespace OnlineStore.AssemblyLine
string[] ip = RFIDManager.SearchIP(text); string[] ip = RFIDManager.SearchIP(text);
foreach(string ipstr in ip) foreach(string ipstr in ip)
{ {
txtSearchIp.Text += ipstr + "\n"; listView1.Items.Add(ipstr);
} }
// txtSearchIp.Text = ip;
} }
private void btnConnect_Click(object sender, EventArgs e) private void btnConnect_Click(object sender, EventArgs e)
......
...@@ -8,9 +8,9 @@ PRO,0,上料流水线入口AGV小车站号名称,AgvInName,D1,,,,, ...@@ -8,9 +8,9 @@ PRO,0,上料流水线入口AGV小车站号名称,AgvInName,D1,,,,,
PRO,0,上料流水线出口AGV小车站号名称,AgvOutName,D2,,,,, PRO,0,上料流水线出口AGV小车站号名称,AgvOutName,D2,,,,,
,,,,,,,,, ,,,,,,,,,
AXIS,0,提升上料轴,Batch_Axis,5,COM5,0,,, AXIS,0,提升上料轴,Batch_Axis,5,COM5,0,,,
PRO,0,提升上料轴上升待机点 P1,BatchAxisP1,10000,,,,, PRO,0,提升上料轴上升待机点 P1,BatchAxisP1,23453414,,,,,
PRO,0,提升上料轴下降位置P2,BatchAxisP2,-2000,,,,, PRO,0,提升上料轴下降位置P2,BatchAxisP2,0,,,,,
PRO,0,提升上料缓慢上升目标位置P3,BatchAxisP3,10000,,,,, PRO,0,提升上料缓慢上升目标位置P3,BatchAxisP3,22283118,,,,,
PRO,0,提升上料轴目标速度,BatchAxis_TargetSpeed,1500,,,,, PRO,0,提升上料轴目标速度,BatchAxis_TargetSpeed,1500,,,,,
PRO,0,提升上料轴加速度,BatchAxis_AddSpeed,400,,,,, PRO,0,提升上料轴加速度,BatchAxis_AddSpeed,400,,,,,
PRO,0,提升上料轴减速度,BatchAxis_DelSpeed,400,,,,, PRO,0,提升上料轴减速度,BatchAxis_DelSpeed,400,,,,,
...@@ -24,8 +24,8 @@ PRO,0,提升上料轴高度转换系数(1mm对应的脉冲),Height_ChangeValue,5000,,,,, ...@@ -24,8 +24,8 @@ PRO,0,提升上料轴高度转换系数(1mm对应的脉冲),Height_ChangeValue,5000,,,,,
,,,,,,,,, ,,,,,,,,,
AXIS,0,移栽上下轴,UpDown_Axis,6,COM5,0,,, AXIS,0,移栽上下轴,UpDown_Axis,6,COM5,0,,,
PRO,0,移栽上下轴待机点 P1,UpDownAxisP1,2000,,,,, PRO,0,移栽上下轴待机点 P1,UpDownAxisP1,2000,,,,,
PRO,0,移栽上下轴P2移栽机构下降位置,UpDownP2List,0=180000;,,,,, PRO,0,移栽上下轴P2移栽机构下降位置,UpDownP2List,0=180000,,,,,
PRO,0,移栽上下轴P3取料位置,UpDownAxisP3,20000,,,,, PRO,0,移栽上下轴P3取料位置,UpDownAxisP3,310000,,,,,
PRO,0,移栽上下轴目标速度,UpdownAxis_TargetSpeed,150,,,,, PRO,0,移栽上下轴目标速度,UpdownAxis_TargetSpeed,150,,,,,
PRO,0,移栽上下轴加速度,UpdownAxis_AddSpeed,400,,,,, PRO,0,移栽上下轴加速度,UpdownAxis_AddSpeed,400,,,,,
PRO,0,移栽上下轴减速度,UpdownAxis_DelSpeed,400,,,,, PRO,0,移栽上下轴减速度,UpdownAxis_DelSpeed,400,,,,,
......
...@@ -130,7 +130,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -130,7 +130,7 @@ namespace OnlineStore.DeviceLibrary
lastProTimer = DateTime.Now; lastProTimer = DateTime.Now;
try try
{ {
if (IsDebug) if (IsDebug&&runStatus<=LineRunStatus.Wait)
{ {
isInPro = false; isInPro = false;
return; return;
...@@ -461,6 +461,8 @@ namespace OnlineStore.DeviceLibrary ...@@ -461,6 +461,8 @@ namespace OnlineStore.DeviceLibrary
msg += "preTrayNum:".PadRight(tLength, ' ') + preTrayNum + "\n"; msg += "preTrayNum:".PadRight(tLength, ' ') + preTrayNum + "\n";
msg += "currTrayNum:".PadRight(tLength, ' ') + currTrayNum + "\n"; msg += "currTrayNum:".PadRight(tLength, ' ') + currTrayNum + "\n";
msg += "runStatus:".PadRight(tLength, ' ') + runStatus + "\n";
msg += "lineStatus:".PadRight(tLength, ' ') + lineStatus + "\n";
msg += "MoveType:".PadRight(tLength, ' ') + MoveInfo.MoveType+"\n"; msg += "MoveType:".PadRight(tLength, ' ') + MoveInfo.MoveType+"\n";
msg += "MoveStep:".PadRight(tLength, ' ') + MoveInfo.MoveStep + "\n"; msg += "MoveStep:".PadRight(tLength, ' ') + MoveInfo.MoveStep + "\n";
msg += "SMoveType:".PadRight(tLength, ' ') + SecondMoveInfo.MoveType + "\n"; msg += "SMoveType:".PadRight(tLength, ' ') + SecondMoveInfo.MoveType + "\n";
......
...@@ -64,8 +64,10 @@ namespace OnlineStore.DeviceLibrary ...@@ -64,8 +64,10 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.NewMove(LineMoveType.ReturnHome); MoveInfo.NewMove(LineMoveType.ReturnHome);
StartReset(); StartReset();
if (isDebug) if (isDebug)
{ {
LogInfo("开始调试,启动定时器 ");
mainTimer.Start(); mainTimer.Start();
} }
return true; return true;
...@@ -138,12 +140,14 @@ namespace OnlineStore.DeviceLibrary ...@@ -138,12 +140,14 @@ namespace OnlineStore.DeviceLibrary
break; break;
case LineMoveStep.FR_01_MoveCylinder_Up: case LineMoveStep.FR_01_MoveCylinder_Up:
MoveInfo.NextMoveStep(LineMoveStep.FR_02_BatchAxisHome); MoveInfo.NextMoveStep(LineMoveStep.FR_02_BatchAxisHome);
MoveInfo.TimeOutSeconds = 120;
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.MoveStep + ":提升伺服回原点,升降伺服回原点,所有阻挡气缸上升"); LogInfo(MoveInfo.MoveType + ":" + MoveInfo.MoveStep + ":提升伺服回原点,升降伺服回原点,所有阻挡气缸上升");
BatchAxis.HomeMove(MoveInfo); BatchAxis.HomeMove(MoveInfo);
UpdownAxis.HomeMove(MoveInfo); UpdownAxis.HomeMove(MoveInfo);
break; break;
case LineMoveStep.FR_02_BatchAxisHome: case LineMoveStep.FR_02_BatchAxisHome:
LogInfo(MoveInfo.MoveType + ":FR_03_BatchAxisToP2:提升伺服下降到P2点,升降伺服上升到待机点"); LogInfo(MoveInfo.MoveType + ":FR_03_BatchAxisToP2:提升伺服下降到P2点,升降伺服上升到待机点");
MoveInfo.TimeOutSeconds = 120;
MoveInfo.NextMoveStep(LineMoveStep.FR_03_BatchAxisToP2); MoveInfo.NextMoveStep(LineMoveStep.FR_03_BatchAxisToP2);
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed); BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed); UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
...@@ -182,9 +186,9 @@ namespace OnlineStore.DeviceLibrary ...@@ -182,9 +186,9 @@ namespace OnlineStore.DeviceLibrary
case LineMoveStep.FR_08_MoveCylinder_Slack: case LineMoveStep.FR_08_MoveCylinder_Slack:
if (MoveCylineCanTakeOrGive()) if (MoveCylineCanTakeOrGive())
{ {
LogInfo(MoveInfo.MoveType + ":FR_09_MoveCylinder_Take: 上料横移气缸取料端SOL"); LogInfo(MoveInfo.MoveType + ":FR_09_MoveCylinder_Give: 上料横移气缸放料端SOL");
MoveInfo.NextMoveStep(LineMoveStep.FR_09_MoveCylinder_Take); MoveInfo.NextMoveStep(LineMoveStep.FR_09_MoveCylinder_Give);
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take); CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
} }
else else
{ {
...@@ -193,7 +197,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -193,7 +197,7 @@ namespace OnlineStore.DeviceLibrary
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up); CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
} }
break; break;
case LineMoveStep.FR_09_MoveCylinder_Take: case LineMoveStep.FR_09_MoveCylinder_Give:
LogInfo(MoveInfo.MoveType + ":FR_10_OutTopCylinder_Down: 出口顶升下降SOL"); LogInfo(MoveInfo.MoveType + ":FR_10_OutTopCylinder_Down: 出口顶升下降SOL");
MoveInfo.NextMoveStep(LineMoveStep.FR_10_OutTopCylinder_Down); MoveInfo.NextMoveStep(LineMoveStep.FR_10_OutTopCylinder_Down);
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down); CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
...@@ -201,6 +205,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -201,6 +205,7 @@ namespace OnlineStore.DeviceLibrary
case LineMoveStep.FR_10_OutTopCylinder_Down: case LineMoveStep.FR_10_OutTopCylinder_Down:
LogInfo("重置完成!"); LogInfo("重置完成!");
runStatus = LineRunStatus.Runing; runStatus = LineRunStatus.Runing;
lineStatus = LineStatus.StoreOnline;
MoveInfo.EndMove(); MoveInfo.EndMove();
break; break;
default: break; default: break;
...@@ -283,7 +288,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -283,7 +288,7 @@ namespace OnlineStore.DeviceLibrary
{ {
StartCheckFixture(); StartCheckFixture();
} }
if (MoveInfo.MoveType.Equals(LineMoveType.None) && Config.IsCanOut.Equals(false)) if ( Config.IsCanOut.Equals(false))
{ {
StartInStoreP(); StartInStoreP();
} }
......
...@@ -212,15 +212,20 @@ namespace OnlineStore.DeviceLibrary ...@@ -212,15 +212,20 @@ namespace OnlineStore.DeviceLibrary
public string CanStart() public string CanStart()
{ {
if (MoveEquipMap == null)
{
return "启动失败:未加载到移栽信息";
}
if (IsDebug)
{
return "";
}
if (!canStart) if (!canStart)
{ {
return "启动失败:设备未初始化完成" ; return "启动失败:设备未初始化完成" ;
} }
if (MoveEquipMap == null)
{
return "启动失败:未加载到移栽信息";
}
if (IOValue(IO_Type.SuddenStop_BTN).Equals(IO_VALUE.LOW)) if (IOValue(IO_Type.SuddenStop_BTN).Equals(IO_VALUE.LOW))
{ {
return "启动失败:急停未开"; return "启动失败:急停未开";
......
...@@ -14,7 +14,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -14,7 +14,7 @@ namespace OnlineStore.DeviceLibrary
public bool LineCanRun() public bool LineCanRun()
{ {
if (IOValue(IO_Type.Line_Run).Equals(IO_VALUE.HIGH)) //if (IOValue(IO_Type.Line_Run).Equals(IO_VALUE.HIGH))
{ {
return true; return true;
} }
...@@ -23,6 +23,10 @@ namespace OnlineStore.DeviceLibrary ...@@ -23,6 +23,10 @@ namespace OnlineStore.DeviceLibrary
public bool CanProcessLine(bool isCheckSleep = true) public bool CanProcessLine(bool isCheckSleep = true)
{ {
if (IsDebug)
{
return true;
}
if (LineCanRun() && if (LineCanRun() &&
IOManager.IOValue(IO_Type.DriveMotor_Run1, 0).Equals(IO_VALUE.HIGH) && IOManager.IOValue(IO_Type.DriveMotor_Run1, 0).Equals(IO_VALUE.HIGH) &&
IOManager.IOValue(IO_Type.DriveMotor_Run2, 0).Equals(IO_VALUE.HIGH) && IOManager.IOValue(IO_Type.DriveMotor_Run2, 0).Equals(IO_VALUE.HIGH) &&
......
...@@ -6,7 +6,7 @@ using System.Drawing; ...@@ -6,7 +6,7 @@ using System.Drawing;
using System.IO; using System.IO;
using System.Linq; using System.Linq;
using System.Runtime.ExceptionServices; using System.Runtime.ExceptionServices;
using System.Threading.Tasks; using System.Text;
using System.Windows.Forms; using System.Windows.Forms;
namespace OnlineStore.DeviceLibrary namespace OnlineStore.DeviceLibrary
...@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary
{ {
try try
{ {
CodeLibrary.HIKCManager.Load(); CodeLibrary.HIKCamera.Instance.Load();
} }
catch (Exception ex) catch (Exception ex)
{ {
...@@ -61,14 +61,14 @@ namespace OnlineStore.DeviceLibrary ...@@ -61,14 +61,14 @@ namespace OnlineStore.DeviceLibrary
} }
try try
{ {
CodeLibrary.BaslerCManager.Load(); CodeLibrary.BaslerCamera.Instance.Load();
} }
catch (Exception ex) catch (Exception ex)
{ {
LogUtil.error("加载Basler相机出错:" + ex.ToString()); LogUtil.error("加载Basler相机出错:" + ex.ToString());
} }
} }
string[] names = CodeLibrary.HIKCManager.CameraName; string[] names = CodeLibrary.HIKCamera.Instance.CameraName;
if (names != null) if (names != null)
...@@ -79,7 +79,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -79,7 +79,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil.info("加载到HIK相机:" + name); LogUtil.info("加载到HIK相机:" + name);
} }
} }
names = CodeLibrary.BaslerCManager.CameraName; names = CodeLibrary.BaslerCamera.Instance.CameraName;
if (names != null) if (names != null)
{ {
balserNameList.AddRange(names); balserNameList.AddRange(names);
...@@ -89,23 +89,10 @@ namespace OnlineStore.DeviceLibrary ...@@ -89,23 +89,10 @@ namespace OnlineStore.DeviceLibrary
} }
} }
} }
public static void CloseCamera(string name) public static void CloseCamera()
{ {
//BaslerCamera.Instance.Close(); BaslerCamera.Instance.Close();
//HIKCamera.Instance.Close(); HIKCamera.Instance.Close();
if (HIKCManager.CameraName.Contains(name))
{
HIKCManager.Close(name);
}
else
{
BaslerCManager.Close(name);
}
}
public static void CloseAllCamera()
{
HIKCManager.CloseAll();
BaslerCManager.CloseAll();
} }
public static Bitmap GetCamerImage(string cameraName) public static Bitmap GetCamerImage(string cameraName)
...@@ -115,15 +102,13 @@ namespace OnlineStore.DeviceLibrary ...@@ -115,15 +102,13 @@ namespace OnlineStore.DeviceLibrary
{ {
if (balserNameList.Contains(cameraName)) if (balserNameList.Contains(cameraName))
{ {
bool result = true; bool result = BaslerCamera.Instance.Open(cameraName);
if (!BaslerCManager.IsOpen(cameraName))
{
result = BaslerCManager.Open(cameraName);
}
// LogUtil.info("打开相机:" + cameraName + "(" + result + ")"); // LogUtil.info("打开相机:" + cameraName + "(" + result + ")");
if (result) if (result)
{ {
bitm= BaslerCManager.GrabOne(cameraName); BaslerCamera.Instance.GrabOne();
bitm = BaslerCamera.Instance.Image;
BaslerCamera.Instance.Close();
} }
else else
{ {
...@@ -132,16 +117,13 @@ namespace OnlineStore.DeviceLibrary ...@@ -132,16 +117,13 @@ namespace OnlineStore.DeviceLibrary
} }
else if (hikNameList.Contains(cameraName)) else if (hikNameList.Contains(cameraName))
{ {
bool result = true; bool result = HIKCamera.Instance.Open(cameraName);
if (!HIKCManager.IsOpen(cameraName))
{
result = HIKCManager.Open(cameraName);
}
// LogUtil.info("打开相机:" + cameraName + "(" + result + ")"); // LogUtil.info("打开相机:" + cameraName + "(" + result + ")");
if (result) if (result)
{ {
bitm = HIKCManager.GrabOne(cameraName); HIKCamera.Instance.GrabOne();
bitm = HIKCamera.Instance.Image;
HIKCamera.Instance.Close();
} }
else else
{ {
...@@ -167,23 +149,25 @@ namespace OnlineStore.DeviceLibrary ...@@ -167,23 +149,25 @@ namespace OnlineStore.DeviceLibrary
} }
[HandleProcessCorruptedStateExceptions] [HandleProcessCorruptedStateExceptions]
public static List<string> CameraScan(List<string> cameraNameList ) public static List<string> CameraScan(List<string> cameraNameList = null)
{ {
List<string> codeList = new List<string>(); List<string> codeList = new List<string>();
//List<CodeInfo> allCodeList = new List<CodeInfo>();
if (cameraNameList == null)
{
return codeList;
}
try try
{ {
List<Task<List<CodeInfo>>> taskList = new List<Task<List<CodeInfo>>>();
foreach (string cameraName in cameraNameList) foreach (string cameraName in cameraNameList)
{ {
Task.Factory.StartNew(delegate ()
{
using (Bitmap bitmap = GetCamerImage(cameraName)) using (Bitmap bitmap = GetCamerImage(cameraName))
{ {
if (bitmap == null) if (bitmap == null)
{ {
LogUtil.error(" 摄像机【" + cameraName + "】获取图片失败,关闭相机"); LogUtil.error(" 摄像机【" + cameraName + "】获取图片失败,关闭相机");
CloseCamera(cameraName); CloseCamera();
return; continue;
} }
LogUtil.debug(" 摄像机【" + cameraName + "】获取图片完成"); LogUtil.debug(" 摄像机【" + cameraName + "】获取图片完成");
...@@ -193,21 +177,15 @@ namespace OnlineStore.DeviceLibrary ...@@ -193,21 +177,15 @@ namespace OnlineStore.DeviceLibrary
List<CodeInfo> cc = new List<CodeInfo>(); List<CodeInfo> cc = new List<CodeInfo>();
foreach (string codeType in codeTypeList) foreach (string codeType in codeTypeList)
{ {
Task<List<CodeInfo>> typeDeCode = new Task<List<CodeInfo>>(delegate () //判断是否是一维码
if (codeType.ToLower().Equals("barcode"))
{ {
return DeCode(ho_Image, codeType); cc = HDCodeHelper.DecodeBarCode(ho_Image);
});
taskList.Add(typeDeCode);
typeDeCode.Start();
}
}
});
} }
else
Task.WaitAll(taskList.ToArray());
foreach (Task<List<CodeInfo>> t in taskList)
{ {
List<CodeInfo> cc = t.Result; cc = HDCodeHelper.DecodeCode(ho_Image, 1, GetCodeParamFilePath(codeType), codeType);
}
if (cc.Count > 0) if (cc.Count > 0)
{ {
string r = ""; string r = "";
...@@ -216,7 +194,9 @@ namespace OnlineStore.DeviceLibrary ...@@ -216,7 +194,9 @@ namespace OnlineStore.DeviceLibrary
codeList.Add(c.CodeStr); codeList.Add(c.CodeStr);
r = r + "##" + c.CodeStr; r = r + "##" + c.CodeStr;
} }
LogUtil.debug(" 【" + cameraName + "】【" + codeType + "】扫码完成:"+r);
}
}
} }
} }
} }
...@@ -232,30 +212,6 @@ namespace OnlineStore.DeviceLibrary ...@@ -232,30 +212,6 @@ namespace OnlineStore.DeviceLibrary
return codeList; return codeList;
} }
private static List<CodeInfo> DeCode(HalconDotNet.HObject ho_Image,string codeType)
{
List<CodeInfo> cc = new List<CodeInfo>();
//判断是否是一维码
if (codeType.ToLower().Equals("barcode"))
{
cc = HDCodeHelper.DecodeBarCode(ho_Image);
}
else
{
cc = HDCodeHelper.DecodeCode(ho_Image, 1, GetCodeParamFilePath(codeType), codeType);
}
//if (cc.Count > 0)
//{
// string r = "";
// foreach (CodeInfo c in cc)
// {
// codeList.Add(c.CodeStr);
// r = r + "##" + c.CodeStr;
// }
// LogUtil.debug(" 【" + cameraName + "】【" + codeType + "】扫码完成:" + r);
//}
return cc;
}
public static string GetCodeParamFilePath(string codePath) public static string GetCodeParamFilePath(string codePath)
{ {
......
...@@ -6,7 +6,7 @@ using System.Drawing; ...@@ -6,7 +6,7 @@ using System.Drawing;
using System.IO; using System.IO;
using System.Linq; using System.Linq;
using System.Runtime.ExceptionServices; using System.Runtime.ExceptionServices;
using System.Text; using System.Threading.Tasks;
using System.Windows.Forms; using System.Windows.Forms;
namespace OnlineStore.DeviceLibrary namespace OnlineStore.DeviceLibrary
...@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary
{ {
try try
{ {
CodeLibrary.HIKCamera.Instance.Load(); CodeLibrary.HIKCManager.Load();
} }
catch (Exception ex) catch (Exception ex)
{ {
...@@ -61,14 +61,14 @@ namespace OnlineStore.DeviceLibrary ...@@ -61,14 +61,14 @@ namespace OnlineStore.DeviceLibrary
} }
try try
{ {
CodeLibrary.BaslerCamera.Instance.Load(); CodeLibrary.BaslerCManager.Load();
} }
catch (Exception ex) catch (Exception ex)
{ {
LogUtil.error("加载Basler相机出错:" + ex.ToString()); LogUtil.error("加载Basler相机出错:" + ex.ToString());
} }
} }
string[] names = CodeLibrary.HIKCamera.Instance.CameraName; string[] names = CodeLibrary.HIKCManager.CameraName;
if (names != null) if (names != null)
...@@ -79,7 +79,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -79,7 +79,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil.info("加载到HIK相机:" + name); LogUtil.info("加载到HIK相机:" + name);
} }
} }
names = CodeLibrary.BaslerCamera.Instance.CameraName; names = CodeLibrary.BaslerCManager.CameraName;
if (names != null) if (names != null)
{ {
balserNameList.AddRange(names); balserNameList.AddRange(names);
...@@ -89,10 +89,23 @@ namespace OnlineStore.DeviceLibrary ...@@ -89,10 +89,23 @@ namespace OnlineStore.DeviceLibrary
} }
} }
} }
public static void CloseCamera() public static void CloseCamera(string name)
{ {
BaslerCamera.Instance.Close(); //BaslerCamera.Instance.Close();
HIKCamera.Instance.Close(); //HIKCamera.Instance.Close();
if (HIKCManager.CameraName.Contains(name))
{
HIKCManager.Close(name);
}
else
{
BaslerCManager.Close(name);
}
}
public static void CloseAllCamera()
{
HIKCManager.CloseAll();
BaslerCManager.CloseAll();
} }
public static Bitmap GetCamerImage(string cameraName) public static Bitmap GetCamerImage(string cameraName)
...@@ -102,13 +115,15 @@ namespace OnlineStore.DeviceLibrary ...@@ -102,13 +115,15 @@ namespace OnlineStore.DeviceLibrary
{ {
if (balserNameList.Contains(cameraName)) if (balserNameList.Contains(cameraName))
{ {
bool result = BaslerCamera.Instance.Open(cameraName); bool result = true;
if (!BaslerCManager.IsOpen(cameraName))
{
result = BaslerCManager.Open(cameraName);
}
// LogUtil.info("打开相机:" + cameraName + "(" + result + ")"); // LogUtil.info("打开相机:" + cameraName + "(" + result + ")");
if (result) if (result)
{ {
BaslerCamera.Instance.GrabOne(); bitm= BaslerCManager.GrabOne(cameraName);
bitm = BaslerCamera.Instance.Image;
BaslerCamera.Instance.Close();
} }
else else
{ {
...@@ -117,13 +132,16 @@ namespace OnlineStore.DeviceLibrary ...@@ -117,13 +132,16 @@ namespace OnlineStore.DeviceLibrary
} }
else if (hikNameList.Contains(cameraName)) else if (hikNameList.Contains(cameraName))
{ {
bool result = HIKCamera.Instance.Open(cameraName); bool result = true;
if (!HIKCManager.IsOpen(cameraName))
{
result = HIKCManager.Open(cameraName);
}
// LogUtil.info("打开相机:" + cameraName + "(" + result + ")"); // LogUtil.info("打开相机:" + cameraName + "(" + result + ")");
if (result) if (result)
{ {
HIKCamera.Instance.GrabOne(); bitm = HIKCManager.GrabOne(cameraName);
bitm = HIKCamera.Instance.Image;
HIKCamera.Instance.Close();
} }
else else
{ {
...@@ -149,25 +167,23 @@ namespace OnlineStore.DeviceLibrary ...@@ -149,25 +167,23 @@ namespace OnlineStore.DeviceLibrary
} }
[HandleProcessCorruptedStateExceptions] [HandleProcessCorruptedStateExceptions]
public static List<string> CameraScan(List<string> cameraNameList = null) public static List<string> CameraScan(List<string> cameraNameList )
{ {
List<string> codeList = new List<string>(); List<string> codeList = new List<string>();
//List<CodeInfo> allCodeList = new List<CodeInfo>();
if (cameraNameList == null)
{
return codeList;
}
try try
{ {
List<Task<List<CodeInfo>>> taskList = new List<Task<List<CodeInfo>>>();
foreach (string cameraName in cameraNameList) foreach (string cameraName in cameraNameList)
{ {
Task.Factory.StartNew(delegate ()
{
using (Bitmap bitmap = GetCamerImage(cameraName)) using (Bitmap bitmap = GetCamerImage(cameraName))
{ {
if (bitmap == null) if (bitmap == null)
{ {
LogUtil.error(" 摄像机【" + cameraName + "】获取图片失败,关闭相机"); LogUtil.error(" 摄像机【" + cameraName + "】获取图片失败,关闭相机");
CloseCamera(); CloseCamera(cameraName);
continue; return;
} }
LogUtil.debug(" 摄像机【" + cameraName + "】获取图片完成"); LogUtil.debug(" 摄像机【" + cameraName + "】获取图片完成");
...@@ -177,15 +193,21 @@ namespace OnlineStore.DeviceLibrary ...@@ -177,15 +193,21 @@ namespace OnlineStore.DeviceLibrary
List<CodeInfo> cc = new List<CodeInfo>(); List<CodeInfo> cc = new List<CodeInfo>();
foreach (string codeType in codeTypeList) foreach (string codeType in codeTypeList)
{ {
//判断是否是一维码 Task<List<CodeInfo>> typeDeCode = new Task<List<CodeInfo>>(delegate ()
if (codeType.ToLower().Equals("barcode"))
{ {
cc = HDCodeHelper.DecodeBarCode(ho_Image); return DeCode(ho_Image, codeType);
});
taskList.Add(typeDeCode);
typeDeCode.Start();
} }
else
{
cc = HDCodeHelper.DecodeCode(ho_Image, 1, GetCodeParamFilePath(codeType), codeType);
} }
});
}
Task.WaitAll(taskList.ToArray());
foreach (Task<List<CodeInfo>> t in taskList)
{
List<CodeInfo> cc = t.Result;
if (cc.Count > 0) if (cc.Count > 0)
{ {
string r = ""; string r = "";
...@@ -194,9 +216,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -194,9 +216,7 @@ namespace OnlineStore.DeviceLibrary
codeList.Add(c.CodeStr); codeList.Add(c.CodeStr);
r = r + "##" + c.CodeStr; r = r + "##" + c.CodeStr;
} }
LogUtil.debug(" 【" + cameraName + "】【" + codeType + "】扫码完成:"+r);
}
}
} }
} }
} }
...@@ -212,6 +232,30 @@ namespace OnlineStore.DeviceLibrary ...@@ -212,6 +232,30 @@ namespace OnlineStore.DeviceLibrary
return codeList; return codeList;
} }
private static List<CodeInfo> DeCode(HalconDotNet.HObject ho_Image,string codeType)
{
List<CodeInfo> cc = new List<CodeInfo>();
//判断是否是一维码
if (codeType.ToLower().Equals("barcode"))
{
cc = HDCodeHelper.DecodeBarCode(ho_Image);
}
else
{
cc = HDCodeHelper.DecodeCode(ho_Image, 1, GetCodeParamFilePath(codeType), codeType);
}
//if (cc.Count > 0)
//{
// string r = "";
// foreach (CodeInfo c in cc)
// {
// codeList.Add(c.CodeStr);
// r = r + "##" + c.CodeStr;
// }
// LogUtil.debug(" 【" + cameraName + "】【" + codeType + "】扫码完成:" + r);
//}
return cc;
}
public static string GetCodeParamFilePath(string codePath) public static string GetCodeParamFilePath(string codePath)
{ {
......
...@@ -507,7 +507,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -507,7 +507,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary> /// <summary>
///上料装置:上料横移气缸取料端SOL ///上料装置:上料横移气缸取料端SOL
/// </summary> /// </summary>
FR_09_MoveCylinder_Take = 10009, FR_09_MoveCylinder_Give = 10009,
/// <summary> /// <summary>
///上料装置:出口顶升下降SOL ///上料装置:出口顶升下降SOL
/// </summary> /// </summary>
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!