init: 北航大学BH-DAS项目首次入库

This commit is contained in:
XingCheng3
2026-06-08 17:06:10 +08:00
commit 10f06d99cd
207 changed files with 40597 additions and 0 deletions

610
CCYQ_JieFang/OP/OP30/DAS_OP30.Designer.cs generated Normal file
View File

@@ -0,0 +1,610 @@
namespace MesWork
{
partial class DAS_OP30: PlcLinkForm
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DAS_OP30));
this.timHSCZ = new System.Windows.Forms.Timer(this.components);
this.label9 = new System.Windows.Forms.Label();
this.timUI = new System.Windows.Forms.Timer(this.components);
this.labelTime = new System.Windows.Forms.Label();
this.label18 = new System.Windows.Forms.Label();
this.panel7 = new System.Windows.Forms.Panel();
this.panel3 = new System.Windows.Forms.Panel();
this.pictureBox12_end_2 = new System.Windows.Forms.PictureBox();
this.pictureBox2_start_2 = new System.Windows.Forms.PictureBox();
this.pictureBox12_end_1 = new System.Windows.Forms.PictureBox();
this.pictureBox2_start_1 = new System.Windows.Forms.PictureBox();
this.textBox_MeasureValue_2 = new System.Windows.Forms.TextBox();
this.textBox_MeasureValue_1 = new System.Windows.Forms.TextBox();
this.label6 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.panel1 = new System.Windows.Forms.Panel();
this.label16 = new System.Windows.Forms.Label();
this.button_running = new System.Windows.Forms.Button();
this.button_alarm = new System.Windows.Forms.Button();
this.button_finished = new System.Windows.Forms.Button();
this.button_empty = new System.Windows.Forms.Button();
this.panel2 = new System.Windows.Forms.Panel();
this.label_AgvLeaved = new System.Windows.Forms.Label();
this.label19 = new System.Windows.Forms.Label();
this.label_AgvCanLeave = new System.Windows.Forms.Label();
this.label15 = new System.Windows.Forms.Label();
this.label_AgvRequestLeave = new System.Windows.Forms.Label();
this.button5_heartBeat_Ning = new System.Windows.Forms.Button();
this.button5_heartBeat = new System.Windows.Forms.Button();
this.label_AgvCanEnter = new System.Windows.Forms.Label();
this.textBox1_PartPosition = new System.Windows.Forms.TextBox();
this.label_AgvSongliao = new System.Windows.Forms.Label();
this.label_AgvRequestEnter = new System.Windows.Forms.Label();
this.label17 = new System.Windows.Forms.Label();
this.textBox1_EngineID = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.panel7.SuspendLayout();
this.panel3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox12_end_2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2_start_2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox12_end_1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2_start_1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout();
//
// timHSCZ
//
this.timHSCZ.Enabled = true;
//
// label9
//
this.label9.Font = new System.Drawing.Font("微软雅黑", 15.75F, System.Drawing.FontStyle.Bold);
this.label9.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label9.Location = new System.Drawing.Point(-136, -165);
this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(685, 50);
this.label9.TabIndex = 22;
this.label9.Text = "微型减速机";
this.label9.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
// timUI
//
this.timUI.Enabled = true;
//
// labelTime
//
this.labelTime.Font = new System.Drawing.Font("Microsoft Sans Serif", 21.75F);
this.labelTime.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.labelTime.Location = new System.Drawing.Point(898, -165);
this.labelTime.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.labelTime.Name = "labelTime";
this.labelTime.Size = new System.Drawing.Size(647, 58);
this.labelTime.TabIndex = 23;
this.labelTime.Text = "2021-03-09 12:30:30";
this.labelTime.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// label18
//
this.label18.BackColor = System.Drawing.Color.Transparent;
this.label18.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.label18.Cursor = System.Windows.Forms.Cursors.Hand;
this.label18.Font = new System.Drawing.Font("微软雅黑", 10.5F);
this.label18.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label18.Location = new System.Drawing.Point(188, 177);
this.label18.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label18.Name = "label18";
this.label18.Size = new System.Drawing.Size(93, 54);
this.label18.TabIndex = 1;
this.label18.Text = "查询";
this.label18.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.label18.Visible = false;
//
// panel7
//
this.panel7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.panel7.Controls.Add(this.label18);
this.panel7.Location = new System.Drawing.Point(-144, -112);
this.panel7.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.panel7.Name = "panel7";
this.panel7.Size = new System.Drawing.Size(1688, 68);
this.panel7.TabIndex = 24;
//
// panel3
//
this.panel3.Controls.Add(this.pictureBox12_end_2);
this.panel3.Controls.Add(this.pictureBox2_start_2);
this.panel3.Controls.Add(this.pictureBox12_end_1);
this.panel3.Controls.Add(this.pictureBox2_start_1);
this.panel3.Controls.Add(this.textBox_MeasureValue_2);
this.panel3.Controls.Add(this.textBox_MeasureValue_1);
this.panel3.Controls.Add(this.label6);
this.panel3.Controls.Add(this.label5);
this.panel3.Controls.Add(this.pictureBox1);
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel3.Location = new System.Drawing.Point(3, 77);
this.panel3.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(1767, 684);
this.panel3.TabIndex = 4;
//
// pictureBox12_end_2
//
this.pictureBox12_end_2.Image = global::CCYQ_JieFang.Properties.Resources.OK;
this.pictureBox12_end_2.Location = new System.Drawing.Point(678, 238);
this.pictureBox12_end_2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.pictureBox12_end_2.Name = "pictureBox12_end_2";
this.pictureBox12_end_2.Size = new System.Drawing.Size(57, 53);
this.pictureBox12_end_2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox12_end_2.TabIndex = 9;
this.pictureBox12_end_2.TabStop = false;
//
// pictureBox2_start_2
//
this.pictureBox2_start_2.Image = global::CCYQ_JieFang.Properties.Resources.;
this.pictureBox2_start_2.Location = new System.Drawing.Point(678, 238);
this.pictureBox2_start_2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.pictureBox2_start_2.Name = "pictureBox2_start_2";
this.pictureBox2_start_2.Size = new System.Drawing.Size(57, 53);
this.pictureBox2_start_2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox2_start_2.TabIndex = 10;
this.pictureBox2_start_2.TabStop = false;
//
// pictureBox12_end_1
//
this.pictureBox12_end_1.Image = global::CCYQ_JieFang.Properties.Resources.OK;
this.pictureBox12_end_1.Location = new System.Drawing.Point(678, 161);
this.pictureBox12_end_1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.pictureBox12_end_1.Name = "pictureBox12_end_1";
this.pictureBox12_end_1.Size = new System.Drawing.Size(57, 53);
this.pictureBox12_end_1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox12_end_1.TabIndex = 9;
this.pictureBox12_end_1.TabStop = false;
//
// pictureBox2_start_1
//
this.pictureBox2_start_1.Image = global::CCYQ_JieFang.Properties.Resources.;
this.pictureBox2_start_1.Location = new System.Drawing.Point(678, 161);
this.pictureBox2_start_1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.pictureBox2_start_1.Name = "pictureBox2_start_1";
this.pictureBox2_start_1.Size = new System.Drawing.Size(57, 53);
this.pictureBox2_start_1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox2_start_1.TabIndex = 10;
this.pictureBox2_start_1.TabStop = false;
//
// textBox_MeasureValue_2
//
this.textBox_MeasureValue_2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.textBox_MeasureValue_2.Font = new System.Drawing.Font("宋体", 17F);
this.textBox_MeasureValue_2.ForeColor = System.Drawing.SystemColors.ControlText;
this.textBox_MeasureValue_2.Location = new System.Drawing.Point(505, 246);
this.textBox_MeasureValue_2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.textBox_MeasureValue_2.Name = "textBox_MeasureValue_2";
this.textBox_MeasureValue_2.ReadOnly = true;
this.textBox_MeasureValue_2.Size = new System.Drawing.Size(158, 40);
this.textBox_MeasureValue_2.TabIndex = 4;
this.textBox_MeasureValue_2.Text = "0";
//
// textBox_MeasureValue_1
//
this.textBox_MeasureValue_1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.textBox_MeasureValue_1.Font = new System.Drawing.Font("宋体", 17F);
this.textBox_MeasureValue_1.ForeColor = System.Drawing.SystemColors.ControlText;
this.textBox_MeasureValue_1.Location = new System.Drawing.Point(505, 169);
this.textBox_MeasureValue_1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.textBox_MeasureValue_1.Name = "textBox_MeasureValue_1";
this.textBox_MeasureValue_1.ReadOnly = true;
this.textBox_MeasureValue_1.Size = new System.Drawing.Size(158, 40);
this.textBox_MeasureValue_1.TabIndex = 4;
this.textBox_MeasureValue_1.Text = "0";
//
// label6
//
this.label6.AutoSize = true;
this.label6.BackColor = System.Drawing.Color.White;
this.label6.Font = new System.Drawing.Font("宋体", 17F);
this.label6.Location = new System.Drawing.Point(411, 250);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(86, 29);
this.label6.TabIndex = 6;
this.label6.Text = "压力2";
//
// label5
//
this.label5.AutoSize = true;
this.label5.BackColor = System.Drawing.Color.White;
this.label5.Font = new System.Drawing.Font("宋体", 17F);
this.label5.Location = new System.Drawing.Point(411, 173);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(86, 29);
this.label5.TabIndex = 6;
this.label5.Text = "压力1";
//
// pictureBox1
//
this.pictureBox1.BackColor = System.Drawing.Color.White;
this.pictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
this.pictureBox1.Image = global::CCYQ_JieFang.Properties.Resources._03_卫星模型;
this.pictureBox1.Location = new System.Drawing.Point(116, 13);
this.pictureBox1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(1501, 668);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox1.TabIndex = 0;
this.pictureBox1.TabStop = false;
//
// panel1
//
this.panel1.Controls.Add(this.label16);
this.panel1.Controls.Add(this.button_running);
this.panel1.Controls.Add(this.button_alarm);
this.panel1.Controls.Add(this.button_finished);
this.panel1.Controls.Add(this.button_empty);
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(3, 765);
this.panel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(1767, 71);
this.panel1.TabIndex = 3;
//
// label16
//
this.label16.BackColor = System.Drawing.Color.Black;
this.label16.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.label16.Location = new System.Drawing.Point(0, 3);
this.label16.Name = "label16";
this.label16.Size = new System.Drawing.Size(1760, 3);
this.label16.TabIndex = 10;
//
// button_running
//
this.button_running.BackColor = System.Drawing.Color.Gray;
this.button_running.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.button_running.Font = new System.Drawing.Font("宋体", 12F);
this.button_running.ForeColor = System.Drawing.Color.White;
this.button_running.Location = new System.Drawing.Point(34, 12);
this.button_running.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button_running.Name = "button_running";
this.button_running.Size = new System.Drawing.Size(296, 55);
this.button_running.TabIndex = 4;
this.button_running.Text = "设备运行(禁止上下料)";
this.button_running.UseVisualStyleBackColor = false;
//
// button_alarm
//
this.button_alarm.BackColor = System.Drawing.Color.Gray;
this.button_alarm.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.button_alarm.Font = new System.Drawing.Font("宋体", 12F);
this.button_alarm.ForeColor = System.Drawing.Color.White;
this.button_alarm.Location = new System.Drawing.Point(1113, 13);
this.button_alarm.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button_alarm.Name = "button_alarm";
this.button_alarm.Size = new System.Drawing.Size(296, 55);
this.button_alarm.TabIndex = 5;
this.button_alarm.Text = "设备故障";
this.button_alarm.UseVisualStyleBackColor = false;
//
// button_finished
//
this.button_finished.BackColor = System.Drawing.Color.Gray;
this.button_finished.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.button_finished.Font = new System.Drawing.Font("宋体", 12F);
this.button_finished.ForeColor = System.Drawing.Color.White;
this.button_finished.Location = new System.Drawing.Point(393, 12);
this.button_finished.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button_finished.Name = "button_finished";
this.button_finished.Size = new System.Drawing.Size(296, 55);
this.button_finished.TabIndex = 6;
this.button_finished.Text = "完成装配(请求下料)";
this.button_finished.UseVisualStyleBackColor = false;
//
// button_empty
//
this.button_empty.BackColor = System.Drawing.Color.Gray;
this.button_empty.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.button_empty.Font = new System.Drawing.Font("宋体", 12F);
this.button_empty.ForeColor = System.Drawing.Color.White;
this.button_empty.Location = new System.Drawing.Point(754, 13);
this.button_empty.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button_empty.Name = "button_empty";
this.button_empty.Size = new System.Drawing.Size(296, 55);
this.button_empty.TabIndex = 7;
this.button_empty.Text = "设备空闲(请求上料)";
this.button_empty.UseVisualStyleBackColor = false;
//
// panel2
//
this.panel2.Controls.Add(this.label_AgvLeaved);
this.panel2.Controls.Add(this.label19);
this.panel2.Controls.Add(this.label_AgvCanLeave);
this.panel2.Controls.Add(this.label15);
this.panel2.Controls.Add(this.label_AgvRequestLeave);
this.panel2.Controls.Add(this.button5_heartBeat_Ning);
this.panel2.Controls.Add(this.button5_heartBeat);
this.panel2.Controls.Add(this.label_AgvCanEnter);
this.panel2.Controls.Add(this.textBox1_PartPosition);
this.panel2.Controls.Add(this.label_AgvSongliao);
this.panel2.Controls.Add(this.label_AgvRequestEnter);
this.panel2.Controls.Add(this.label17);
this.panel2.Controls.Add(this.textBox1_EngineID);
this.panel2.Controls.Add(this.label1);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(3, 2);
this.panel2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(1767, 71);
this.panel2.TabIndex = 2;
//
// label_AgvLeaved
//
this.label_AgvLeaved.AutoSize = true;
this.label_AgvLeaved.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvLeaved.Location = new System.Drawing.Point(1238, 10);
this.label_AgvLeaved.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvLeaved.Name = "label_AgvLeaved";
this.label_AgvLeaved.Size = new System.Drawing.Size(134, 19);
this.label_AgvLeaved.TabIndex = 9;
this.label_AgvLeaved.Text = "●AGV已经离开";
//
// label19
//
this.label19.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.label19.Location = new System.Drawing.Point(1561, 13);
this.label19.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label19.Name = "label19";
this.label19.Size = new System.Drawing.Size(2, 37);
this.label19.TabIndex = 9;
//
// label_AgvCanLeave
//
this.label_AgvCanLeave.AutoSize = true;
this.label_AgvCanLeave.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvCanLeave.Location = new System.Drawing.Point(1089, 38);
this.label_AgvCanLeave.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvCanLeave.Name = "label_AgvCanLeave";
this.label_AgvCanLeave.Size = new System.Drawing.Size(134, 19);
this.label_AgvCanLeave.TabIndex = 9;
this.label_AgvCanLeave.Text = "●AGV可以离开";
//
// label15
//
this.label15.BackColor = System.Drawing.Color.Black;
this.label15.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.label15.Location = new System.Drawing.Point(0, 62);
this.label15.Name = "label15";
this.label15.Size = new System.Drawing.Size(1760, 3);
this.label15.TabIndex = 9;
//
// label_AgvRequestLeave
//
this.label_AgvRequestLeave.AutoSize = true;
this.label_AgvRequestLeave.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvRequestLeave.Location = new System.Drawing.Point(1089, 10);
this.label_AgvRequestLeave.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvRequestLeave.Name = "label_AgvRequestLeave";
this.label_AgvRequestLeave.Size = new System.Drawing.Size(134, 19);
this.label_AgvRequestLeave.TabIndex = 9;
this.label_AgvRequestLeave.Text = "●AGV请求离开";
//
// button5_heartBeat_Ning
//
this.button5_heartBeat_Ning.BackColor = System.Drawing.Color.Gray;
this.button5_heartBeat_Ning.Font = new System.Drawing.Font("宋体", 12F);
this.button5_heartBeat_Ning.ForeColor = System.Drawing.Color.White;
this.button5_heartBeat_Ning.Location = new System.Drawing.Point(1569, 10);
this.button5_heartBeat_Ning.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button5_heartBeat_Ning.Name = "button5_heartBeat_Ning";
this.button5_heartBeat_Ning.Size = new System.Drawing.Size(89, 43);
this.button5_heartBeat_Ning.TabIndex = 5;
this.button5_heartBeat_Ning.Text = "拧紧枪";
this.button5_heartBeat_Ning.UseVisualStyleBackColor = false;
this.button5_heartBeat_Ning.Visible = false;
//
// button5_heartBeat
//
this.button5_heartBeat.BackColor = System.Drawing.Color.Gray;
this.button5_heartBeat.Font = new System.Drawing.Font("宋体", 12F);
this.button5_heartBeat.ForeColor = System.Drawing.Color.White;
this.button5_heartBeat.Location = new System.Drawing.Point(1674, 10);
this.button5_heartBeat.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button5_heartBeat.Name = "button5_heartBeat";
this.button5_heartBeat.Size = new System.Drawing.Size(89, 43);
this.button5_heartBeat.TabIndex = 5;
this.button5_heartBeat.Text = "PLC";
this.button5_heartBeat.UseVisualStyleBackColor = false;
//
// label_AgvCanEnter
//
this.label_AgvCanEnter.AutoSize = true;
this.label_AgvCanEnter.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvCanEnter.Location = new System.Drawing.Point(927, 38);
this.label_AgvCanEnter.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvCanEnter.Name = "label_AgvCanEnter";
this.label_AgvCanEnter.Size = new System.Drawing.Size(134, 19);
this.label_AgvCanEnter.TabIndex = 9;
this.label_AgvCanEnter.Text = "●AGV可以进入";
//
// textBox1_PartPosition
//
this.textBox1_PartPosition.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.textBox1_PartPosition.Font = new System.Drawing.Font("宋体", 20F);
this.textBox1_PartPosition.Location = new System.Drawing.Point(615, 8);
this.textBox1_PartPosition.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.textBox1_PartPosition.Name = "textBox1_PartPosition";
this.textBox1_PartPosition.ReadOnly = true;
this.textBox1_PartPosition.Size = new System.Drawing.Size(105, 46);
this.textBox1_PartPosition.TabIndex = 1;
//
// label_AgvSongliao
//
this.label_AgvSongliao.AutoSize = true;
this.label_AgvSongliao.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvSongliao.Location = new System.Drawing.Point(785, 12);
this.label_AgvSongliao.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvSongliao.Name = "label_AgvSongliao";
this.label_AgvSongliao.Size = new System.Drawing.Size(134, 19);
this.label_AgvSongliao.TabIndex = 9;
this.label_AgvSongliao.Text = "●AGV准备送料";
//
// label_AgvRequestEnter
//
this.label_AgvRequestEnter.AutoSize = true;
this.label_AgvRequestEnter.Font = new System.Drawing.Font("宋体", 11F);
this.label_AgvRequestEnter.Location = new System.Drawing.Point(927, 10);
this.label_AgvRequestEnter.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label_AgvRequestEnter.Name = "label_AgvRequestEnter";
this.label_AgvRequestEnter.Size = new System.Drawing.Size(134, 19);
this.label_AgvRequestEnter.TabIndex = 9;
this.label_AgvRequestEnter.Text = "●AGV请求进入";
//
// label17
//
this.label17.AutoSize = true;
this.label17.Font = new System.Drawing.Font("宋体", 16F);
this.label17.Location = new System.Drawing.Point(467, 15);
this.label17.Name = "label17";
this.label17.Size = new System.Drawing.Size(147, 27);
this.label17.TabIndex = 0;
this.label17.Text = "装配位置:";
//
// textBox1_EngineID
//
this.textBox1_EngineID.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.textBox1_EngineID.Font = new System.Drawing.Font("宋体", 20F);
this.textBox1_EngineID.Location = new System.Drawing.Point(151, 8);
this.textBox1_EngineID.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.textBox1_EngineID.Name = "textBox1_EngineID";
this.textBox1_EngineID.ReadOnly = true;
this.textBox1_EngineID.Size = new System.Drawing.Size(310, 46);
this.textBox1_EngineID.TabIndex = 1;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("宋体", 16F);
this.label1.Location = new System.Drawing.Point(3, 17);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(147, 27);
this.label1.TabIndex = 0;
this.label1.Text = "产品编码:";
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.ColumnCount = 1;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.Controls.Add(this.panel2, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.panel1, 0, 2);
this.tableLayoutPanel1.Controls.Add(this.panel3, 0, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 3;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 75F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 75F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(1773, 838);
this.tableLayoutPanel1.TabIndex = 25;
//
// DAS_OP30
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.White;
this.ClientSize = new System.Drawing.Size(1773, 838);
this.Controls.Add(this.tableLayoutPanel1);
this.Controls.Add(this.label9);
this.Controls.Add(this.labelTime);
this.Controls.Add(this.panel7);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "DAS_OP30";
this.Text = "OP30工位-卫星模型";
this.panel7.ResumeLayout(false);
this.panel3.ResumeLayout(false);
this.panel3.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox12_end_2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2_start_2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox12_end_1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2_start_1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.panel1.ResumeLayout(false);
this.panel2.ResumeLayout(false);
this.panel2.PerformLayout();
this.tableLayoutPanel1.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Timer timHSCZ;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.Timer timUI;
private System.Windows.Forms.Label labelTime;
private System.Windows.Forms.Label label18;
private System.Windows.Forms.Panel panel7;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.TextBox textBox_MeasureValue_2;
private System.Windows.Forms.TextBox textBox_MeasureValue_1;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Label label16;
private System.Windows.Forms.Button button_running;
private System.Windows.Forms.Button button_alarm;
private System.Windows.Forms.Button button_finished;
private System.Windows.Forms.Button button_empty;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Label label_AgvLeaved;
private System.Windows.Forms.Label label19;
private System.Windows.Forms.Label label_AgvCanLeave;
private System.Windows.Forms.Label label15;
private System.Windows.Forms.Label label_AgvRequestLeave;
private System.Windows.Forms.Button button5_heartBeat;
private System.Windows.Forms.Label label_AgvCanEnter;
private System.Windows.Forms.TextBox textBox1_PartPosition;
private System.Windows.Forms.Label label_AgvRequestEnter;
private System.Windows.Forms.Label label17;
private System.Windows.Forms.TextBox textBox1_EngineID;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Label label_AgvSongliao;
private System.Windows.Forms.Button button5_heartBeat_Ning;
private System.Windows.Forms.PictureBox pictureBox12_end_1;
private System.Windows.Forms.PictureBox pictureBox2_start_1;
private System.Windows.Forms.PictureBox pictureBox12_end_2;
private System.Windows.Forms.PictureBox pictureBox2_start_2;
}
}

View File

@@ -0,0 +1,626 @@
using DK_DC_Tool;
using HslCommunication.Core;
using Newtonsoft.Json;
using NPOI.SS.UserModel;
using OpcBasic;
using Robot.Common;
using Serilog.Events;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Data.SqlClient;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;
using SystemFramework;
namespace MesWork
{
public partial class DAS_OP30
{
InitServer initServer = null;
/// <summary>
///
/// </summary>
private static string OpNameCurrent = "";
/// <summary>
/// 字典 存储12个开始测量图片控件key为测量位置value为图片控件
/// </summary>
Dictionary<int, PictureBox> dicStartMasurePictureBox = new Dictionary<int, PictureBox>();
/// <summary>
/// 字典 存储12个结束测量图片控件key为测量位置value为图片控件
/// </summary>
Dictionary<int, PictureBox> dicEndMasurePictureBox = new Dictionary<int, PictureBox>();
/// <summary>
/// 字典 存储12个结束测量文本框控件key为测量位置value文本框的值
/// </summary>
Dictionary<int, TextBox> dicMeasureTextBox = new Dictionary<int, TextBox>();
/// <summary>
/// PLC事件变化委托
/// </summary>
public static Action<DeviceDriver_BasicData.CustomeEvetnArgs> MIS_Funtion_PLC_OP = null;
/// <summary>
/// PLC事件变化委托
/// </summary>
public static Action<string> AGV_Task_change = null;
/// <summary>
/// PLC事件变化委托--处理托盘信息
/// </summary>
public static Action<string> AGV_Task_Info = null;
// 每个工位的满工件数量
// 工位OP30 4个
public static int partCount = 4;
public static bool isConnect = false;
public DAS_OP30(string opName)
{
InitializeComponent();
publicCore.partCount = partCount;
OpNameCurrent = opName;
Tighten.E_DeviceHeartBeat -= DeviceHeartBeat_NingJinQiang;
Tighten.E_DeviceHeartBeat += DeviceHeartBeat_NingJinQiang;
MesWorkForm.MIS_Funtion_PLC_MeasureFinish -= SolvePicAndMeasureValueWorking;
MesWorkForm.MIS_Funtion_PLC_MeasureFinish += SolvePicAndMeasureValueWorking;
MIS_Funtion_PLC_OP -= MIS_Funtion_PLC;
MIS_Funtion_PLC_OP += MIS_Funtion_PLC;
AGV_Task_change -= SolveAgvDeviceStatus;
AGV_Task_change += SolveAgvDeviceStatus;
if (MesWorkForm.IsDemoMesServer == 1)
{
MoNiHeartBeat();
}
SolvePicAndMeasureValueInit();
new Thread(new ThreadStart(delegate () {
while (true)
{
try
{
SolveDeviceStatusInit(publicCore.SolveDeviceStatus_Read(OpNameCurrent));
}
catch (Exception err) { }
Thread.Sleep(2000);
}
}))
{ IsBackground = true }.Start();
//var aa =
//new Thread(new ThreadStart(delegate () {
// while (true)
// {
// try
// {
// if (!isConnect)
// {
// if (publicCore.Get_PartPosition(OpNameCurrent) != -1)
// {
// isConnect = true;
// ProductInfo_search();
// }
// }
// }
// catch (Exception err) { }
// Thread.Sleep(1000);
// }
//}));
//aa.IsBackground = true;
//aa.Start();
}
public void MIS_Funtion_PLC(DeviceDriver_BasicData.CustomeEvetnArgs msgEvent)
{
try
{
var tagID = msgEvent.TagID.ToString();
// var opName = msgEvent.OpName.ToString();
var tagTypeCodeID = (int)msgEvent.TagTypeCodeID;
var tagTypeID = (EnumTagTypeID)msgEvent.TagTypeID;
string tagValue;
switch (tagTypeID)
{
case EnumTagTypeID.BOOL:
tagValue = (Convert.ToInt32(msgEvent.TagValue)).ToString();
break;
default:
tagValue = msgEvent.TagValue.ToString();
break;
}
switch (tagTypeCodeID)
{
case 14:
DeviceHeartBeat(tagValue);
break;
// AGV任务
case 50:
publicCore.SolveAgvTaskNum(OpNameCurrent, tagValue);
break;
// 51 空闲(请求上料)
// 52 完成(请求下料)
// 53 故障
case 51:
case 52:
case 53:
publicCore.SolveDeviceStatus(OpNameCurrent);
SolveDeviceStatusInit(publicCore.SolveDeviceStatus_Read(OpNameCurrent));
break;
// 54 第几个件
case 54:
ProductInfo_search();
SolvePicAndMeasureValueWorking();
break;
case 55:
publicCore.MeasurePositionChange(OpNameCurrent, 2);
SolvePicAndMeasureValueWorking();
break;
//读电批
case 56:
if (tagValue == "1")
{
publicCore.LogInsert("OP30", "Info", "【PLC_读电批置位】");
// 不在这个地方写true,写在接收数据的地方写
}
else
{
publicCore.LogInsert("OP30", "Info", "【PLC_读电批复位】");
MesWorkForm.WritePLC(83, OpNameCurrent, false);
publicCore.LogInsert("OP30", "Info", "【IPC_读电批完成复位】");
}
break;
//读泄漏量1 2或者压力
case 59:
if (tagValue == "1")
{
//publicCore.ReadQualityData_LeakageRate(OpNameCurrent);
publicCore.ReadQualityData_Pressure(OpNameCurrent);
MesWorkForm.WritePLC(84, OpNameCurrent, true);
}
else
{
MesWorkForm.WritePLC(84, OpNameCurrent, false);
}
break;
}
}
catch (Exception ex)
{
}
}
/// <summary>
/// 初始化界面显示
/// </summary>
private void SolvePicAndMeasureValueInit()
{
try
{
dicStartMasurePictureBox.Add(1, pictureBox2_start_1);
dicStartMasurePictureBox.Add(2, pictureBox2_start_2);
dicEndMasurePictureBox.Add(1, pictureBox12_end_1);
dicEndMasurePictureBox.Add(2, pictureBox12_end_2);
dicMeasureTextBox.Add(1, textBox_MeasureValue_1);
dicMeasureTextBox.Add(2, textBox_MeasureValue_2);
foreach (var item in dicStartMasurePictureBox)
{
item.Value.Visible = false;
}
foreach (var item in dicEndMasurePictureBox)
{
item.Value.Visible = false;
}
foreach (var item in dicMeasureTextBox)
{
item.Value.Text = "";
}
int partPosition = publicCore.Get_PartPosition(OpNameCurrent);
publicCore.GetQualityInfo_Init(OpNameCurrent, partPosition, out DataTable dt, out string errMsg);
if (dt.Rows.Count > 0)
{
for (int i = 0; i < dt.Rows.Count; i++)
{
int measureStatus = Convert.ToInt32(dt.Rows[i]["测量状态"]);
int measurePosition = Convert.ToInt32(dt.Rows[i]["测量位置"]);
string tagValue = dt.Rows[i]["测量值"].ToString();
string isOk = dt.Rows[i]["是否合格"].ToString();
// 测量状态为1 表示初始状态,两张图片都不显示
// 测量状态为2 表示正在测量,显示第二张图片
// 测量状态为3 表示测量完成,显示第一张图片
var control_DicStartMasurePictureBox = dicStartMasurePictureBox[measurePosition];
var control_DicEndMasurePictureBox = dicEndMasurePictureBox[measurePosition];
var control_DicMeasureTextBox = dicMeasureTextBox[measurePosition];
if (measureStatus == 1)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, false);
ShowPicBoxControl(control_DicEndMasurePictureBox, false);
}
else if (measureStatus == 2)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, true);
ShowPicBoxControl(control_DicEndMasurePictureBox, false);
}
else if (measureStatus == 3)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, false);
ShowPicBoxControl(control_DicEndMasurePictureBox, true);
}
if (isOk == "1")
{
ShowTextBoxControl(control_DicMeasureTextBox, tagValue, Color.White);
}
else
{
ShowTextBoxControl(control_DicMeasureTextBox, tagValue, Color.Red);
}
}
}
}
catch (Exception err)
{
}
}
/// <summary>
/// 工作时界面显示
/// </summary>
private void SolvePicAndMeasureValueWorking()
{
try
{
int partPosition = publicCore.Get_PartPosition(OpNameCurrent);
publicCore.GetQualityInfo_Init(OpNameCurrent, partPosition, out DataTable dt, out string errMsg);
if (dt.Rows.Count > 0)
{
for (int i = 0; i < dt.Rows.Count; i++)
{
int measureStatus = Convert.ToInt32(dt.Rows[i]["测量状态"]);
int measurePosition = Convert.ToInt32(dt.Rows[i]["测量位置"]);
string tagValue = dt.Rows[i]["测量值"].ToString();
string isOk = dt.Rows[i]["是否合格"].ToString();
// 测量状态为1 表示初始状态,两张图片都不显示
// 测量状态为2 表示正在测量,显示第二张图片
// 测量状态为3 表示测量完成,显示第一张图片
var control_DicStartMasurePictureBox = dicStartMasurePictureBox[measurePosition];
var control_DicEndMasurePictureBox = dicEndMasurePictureBox[measurePosition];
var control_DicMeasureTextBox = dicMeasureTextBox[measurePosition];
if (measureStatus == 1)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, false);
ShowPicBoxControl(control_DicEndMasurePictureBox, false);
}
else if (measureStatus == 2)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, true);
ShowPicBoxControl(control_DicEndMasurePictureBox, false);
}
else if (measureStatus == 3)
{
ShowPicBoxControl(control_DicStartMasurePictureBox, false);
ShowPicBoxControl(control_DicEndMasurePictureBox, true);
}
if (isOk == "2")
{
ShowTextBoxControl(control_DicMeasureTextBox, tagValue, Color.Red);
}
else
{
ShowTextBoxControl(control_DicMeasureTextBox, tagValue, Color.White);
}
}
}
}
catch (Exception err)
{
}
}
/// <summary>
/// 界面产品编码和装配位置的显示
/// </summary>
public void ProductInfo_search()
{
try
{
//textBox1_EngineID.Text = "";
//textBox1_PartPosition.Text = "";
ShowTextBoxControl(textBox1_EngineID, "", Color.White);
ShowTextBoxControl(textBox1_PartPosition, "", Color.White);
int PartPosition = publicCore.Get_PartPosition(OpNameCurrent);
publicCore.GetProductInfo_Init(OpNameCurrent, PartPosition, out DataTable dt, out string errMsg);
if (dt.Rows.Count > 0)
{
ShowTextBoxControl(textBox1_EngineID, dt.Rows[0]["发动机号"].ToString(), Color.White);
ShowTextBoxControl(textBox1_PartPosition, dt.Rows[0]["装配位置"].ToString(), Color.White);
//textBox1_EngineID.Text = dt.Rows[0]["发动机号"].ToString();
//textBox1_PartPosition.Text = dt.Rows[0]["装配位置"].ToString();
}
}
catch (Exception err)
{
}
}
private void ShowPicBoxControl(Control c, bool ststus)
{
c.BeginInvoke(new Action(delegate () {
c.Visible = ststus;
}));
}
private void ShowTextBoxControl(Control c, string value, Color color)
{
c.BeginInvoke(new Action(delegate () {
c.Text = value;
c.BackColor = color;
}));
}
private void ShowLabelControl(Control c, Color color)
{
//if (c.InvokeRequired)
//{
//}
//else
//{
// c.ForeColor = color;
//}
c.BeginInvoke(new Action(delegate () {
c.ForeColor = color;
}));
}
private void ShowButtonControl(Control c, Color color)
{
c.BeginInvoke(new Action(delegate () {
c.BackColor = color;
}));
}
/// <summary>
/// 初始化设备状态
/// 1工作中 2空闲请求上料 3完成请求下料 4 报警
/// </summary>
private void SolveDeviceStatusInit(string currentStatus)
{
try
{
ShowButtonControl(button_running, Color.Gray);
ShowButtonControl(button_finished, Color.Gray);
ShowButtonControl(button_empty, Color.Gray);
ShowButtonControl(button_alarm, Color.Gray);
//button_running.BackColor = Color.Gray;
//button_finished.BackColor = Color.Gray;
//button_empty.BackColor = Color.Gray;
//button_alarm.BackColor = Color.Gray;
if (currentStatus == "1")
{
ShowButtonControl(button_running, Color.Green);
//button_running.BackColor = Color.Green;
}
else if (currentStatus == "2")
{
ShowButtonControl(button_empty, Color.SkyBlue);
//button_empty.BackColor = Color.SkyBlue;
}
else if (currentStatus == "3")
{
ShowButtonControl(button_finished, Color.DarkOrange);
//button_finished.BackColor = Color.DarkOrange;
}
else if (currentStatus == "4")
{
ShowButtonControl(button_alarm, Color.Red);
//button_alarm.BackColor = Color.Red;
}
}
catch (Exception err)
{
}
}
/// <summary>
/// AGV设备状态显示
/// </summary>
/// <param name="PLC_AgvTaskNum"></param>
private void SolveAgvDeviceStatus(string PLC_AgvTaskNum)
{
try
{
// 77 反馈AGV任务
switch (PLC_AgvTaskNum)
{
case "10":
// AGV触发装配任务 正在送料
//label_AgvSongliao.ForeColor = Color.Green;
//label_AgvRequestLeave.ForeColor = Color.Black;
//label_AgvRequestEnter.ForeColor = Color.Black;
//label_AgvCanEnter.ForeColor = Color.Black;
//label_AgvCanLeave.ForeColor = Color.Black;
//label_AgvLeaved.ForeColor = Color.Black;
ShowLabelControl(label_AgvSongliao, Color.Green);
ShowLabelControl(label_AgvRequestLeave, Color.Black);
ShowLabelControl(label_AgvRequestEnter, Color.Black);
ShowLabelControl(label_AgvCanEnter, Color.Black);
ShowLabelControl(label_AgvCanLeave, Color.Black);
ShowLabelControl(label_AgvLeaved, Color.Black);
ProductInfo_search();
SolvePicAndMeasureValueWorking();
break;
case "11":
ShowLabelControl(label_AgvRequestLeave, Color.Black);
ShowLabelControl(label_AgvRequestEnter, Color.Green);
//label_AgvRequestEnter.ForeColor = Color.Green;
//label_AgvRequestLeave.ForeColor = Color.Black;
break;
// 允许AGV进行上料 --允许进入
// 允许AGV进行下料 --允许进入
case "2":
case "4":
ShowLabelControl(label_AgvCanEnter, Color.Green);
ShowLabelControl(label_AgvCanLeave, Color.Black);
//label_AgvCanEnter.ForeColor = Color.Green;
//label_AgvCanLeave.ForeColor = Color.Black;
break;
case "21":
// AGV 上料完成
ShowLabelControl(label_AgvRequestLeave, Color.Black);
ShowLabelControl(label_AgvRequestEnter, Color.Green);
//label_AgvRequestLeave.ForeColor = Color.Black;
//label_AgvRequestEnter.ForeColor = Color.Green;
break;
case "3":
// 1.调用FSS-接收IPC下料请求的接口
// 2.反馈任务号30 AGV已呼叫成功正在去往下料区
break;
case "31":
ShowLabelControl(label_AgvRequestEnter, Color.Black);
ShowLabelControl(label_AgvRequestLeave, Color.Green);
//label_AgvRequestEnter.ForeColor = Color.Black;
//label_AgvRequestLeave.ForeColor = Color.Green;
// AGV已到达下料区
break;
case "41":
// AGV下料完成
break;
// 允许AGV离开
case "5":
ShowLabelControl(label_AgvCanEnter, Color.Black);
ShowLabelControl(label_AgvCanLeave, Color.Green);
//label_AgvCanEnter.ForeColor = Color.Black;
//label_AgvCanLeave.ForeColor = Color.Green;
break;
case "51":
//label_AgvSongliao.ForeColor = Color.Black;
//label_AgvRequestLeave.ForeColor = Color.Black;
//label_AgvRequestEnter.ForeColor = Color.Black;
//label_AgvCanEnter.ForeColor = Color.Black;
//label_AgvCanLeave.ForeColor = Color.Black;
//label_AgvLeaved.ForeColor = Color.Green;
ShowLabelControl(label_AgvSongliao, Color.Black);
ShowLabelControl(label_AgvRequestLeave, Color.Black);
ShowLabelControl(label_AgvRequestEnter, Color.Black);
ShowLabelControl(label_AgvCanEnter, Color.Black);
ShowLabelControl(label_AgvCanLeave, Color.Black);
ShowLabelControl(label_AgvLeaved, Color.Green);
ProductInfo_search();
SolvePicAndMeasureValueWorking();
break;
}
}
catch (Exception err)
{
}
}
/// <summary>
/// 设备PLC心跳button5_heartBeat_Ning
/// </summary>
/// <param name="tagValue"></param>
private void DeviceHeartBeat(string tagValue)
{
WritePLC(15, OpNameCurrent, tagValue);
if (tagValue == "1")
{
ShowButtonControl(button5_heartBeat, Color.Green);
//button5_heartBeat.BackColor = Color.Green;
}
else
{
ShowButtonControl(button5_heartBeat, Color.Gray);
//button5_heartBeat.BackColor = Color.Gray;
}
}
/// <summary>
/// 设备PLC心跳
/// </summary>
/// <param name="tagValue"></param>
private void DeviceHeartBeat_NingJinQiang(string tagValue)
{
if (tagValue == "1")
{
ShowButtonControl(button5_heartBeat_Ning, Color.Green);
//button5_heartBeat_Ning.BackColor = Color.Green;
}
else
{
ShowButtonControl(button5_heartBeat_Ning, Color.Red);
//button5_heartBeat_Ning.BackColor = Color.Red;
}
}
private void MoNiHeartBeat()
{
bool tv = false;
new Thread(new ThreadStart(delegate () {
while (true)
{
try
{
WritePLC(14, OpNameCurrent, tv);
tv = !tv;
}
catch (Exception err) { }
Thread.Sleep(2000);
}
}))
{ IsBackground = true }.Start();
}
private void label5_Click(object sender, EventArgs e)
{
}
private void textBox_MeasureValue_4_TextChanged(object sender, EventArgs e)
{
}
}
}

View File

@@ -0,0 +1,144 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="timHSCZ.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>432, 221</value>
</metadata>
<metadata name="timUI.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>573, 221</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>33</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAABAAEAGhoAAAAAIAAHAgAAFgAAAIlQTkcNChoKAAAADUlIRFIAAAAaAAAAGggGAAAAqUpMzgAAAAFz
UkdCAK7OHOkAAAAEZ0FNQQAAsY8L/GEFAAAACXBIWXMAAA7DAAAOwwHHb6hkAAABnElEQVRIS+2Uz2rC
QBDGfZRc+h7ec/Mmxhgx2CQGYi65ivUB9NZCArl4EC/SqwgePBRKwUfw0AfZzrfshvVPY1IjlNKBj0xm
Z+a3m0xS+7ciZhjGqN1uM0iE7mO/D9RsNh+QXEZkRpIkDArDcJsLoqQREofDYUrFrIwkpBTItu3VaSPX
dVkURWwymXD/dL0yECDSB0xdgyoD4RQAqEBVlYGu6a6gfv8x828GbTYfXPP5ik2nz1zwZbxS0Gz2wkzT
PBJilYMcx2NBELDl8pUtFivuI3YzSP1g1+t3foLx+Ik3huAjhrUfgeI4rgOGq2xQ9ERpmmpUa6HecZw0
F6SaCiryjkQZN7q//lOl3Wq6ru9RjPFFM+i7qZMj7vv+djAYpOhRCETJdSrKdpon9TtCDYQedF/sRPjd
0OSVEmpokwf0AEiKN71kOL7cned5rNvtbqkAj/Kier3eTuYDhCciWuVbp9PZobllWXt5/FardaArRvZI
Io6cT9Q1Go03AieiVb6JQi7a8YgaaGLpzLBGORblZt8NiQ/EX7da7Qtz50LQDuTBxQAAAABJRU5ErkJg
gg==
</value>
</data>
</root>