init: 潍柴发动机线 中央控制程序 项目首次入库
This commit is contained in:
334
SCADA/数据测试/F_TestPage.Designer.cs
generated
Normal file
334
SCADA/数据测试/F_TestPage.Designer.cs
generated
Normal file
@@ -0,0 +1,334 @@
|
||||
namespace DC_A95
|
||||
{
|
||||
partial class F_TestPage
|
||||
{
|
||||
/// <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.btn_PartOn = new System.Windows.Forms.Button();
|
||||
this.btn_Part_OnLine = new System.Windows.Forms.Button();
|
||||
this.Btn_PartOff = new System.Windows.Forms.Button();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.txt_EngineNo = new System.Windows.Forms.TextBox();
|
||||
this.lb_Station = new System.Windows.Forms.ListBox();
|
||||
this.groupBox5 = new System.Windows.Forms.GroupBox();
|
||||
this.btn_TransferSort = new System.Windows.Forms.Button();
|
||||
this.txt_PrintCode = new System.Windows.Forms.TextBox();
|
||||
this.txt_SortName = new System.Windows.Forms.TextBox();
|
||||
this.txt_SortNo = new System.Windows.Forms.TextBox();
|
||||
this.label7 = new System.Windows.Forms.Label();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.txt_PartCode = new System.Windows.Forms.TextBox();
|
||||
this.txt_PalletNo = new System.Windows.Forms.TextBox();
|
||||
this.txt_OrderNo = new System.Windows.Forms.TextBox();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.btn_Heartbeat = new System.Windows.Forms.Button();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.btn_AllowSave = new System.Windows.Forms.Button();
|
||||
this.groupBox5.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// btn_PartOn
|
||||
//
|
||||
this.btn_PartOn.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.btn_PartOn.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.btn_PartOn.Location = new System.Drawing.Point(180, 193);
|
||||
this.btn_PartOn.Name = "btn_PartOn";
|
||||
this.btn_PartOn.Size = new System.Drawing.Size(81, 27);
|
||||
this.btn_PartOn.TabIndex = 3;
|
||||
this.btn_PartOn.Text = "4-进站";
|
||||
this.btn_PartOn.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.btn_PartOn.UseVisualStyleBackColor = false;
|
||||
this.btn_PartOn.Click += new System.EventHandler(this.btn_PartOn_Click);
|
||||
//
|
||||
// btn_Part_OnLine
|
||||
//
|
||||
this.btn_Part_OnLine.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.btn_Part_OnLine.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.btn_Part_OnLine.Location = new System.Drawing.Point(177, 341);
|
||||
this.btn_Part_OnLine.Name = "btn_Part_OnLine";
|
||||
this.btn_Part_OnLine.Size = new System.Drawing.Size(235, 27);
|
||||
this.btn_Part_OnLine.TabIndex = 3;
|
||||
this.btn_Part_OnLine.Text = "申请上线";
|
||||
this.btn_Part_OnLine.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.btn_Part_OnLine.UseVisualStyleBackColor = false;
|
||||
this.btn_Part_OnLine.Click += new System.EventHandler(this.btn_Part_OnLine_Click);
|
||||
//
|
||||
// Btn_PartOff
|
||||
//
|
||||
this.Btn_PartOff.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.Btn_PartOff.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.Btn_PartOff.Location = new System.Drawing.Point(440, 193);
|
||||
this.Btn_PartOff.Name = "Btn_PartOff";
|
||||
this.Btn_PartOff.Size = new System.Drawing.Size(80, 27);
|
||||
this.Btn_PartOff.TabIndex = 3;
|
||||
this.Btn_PartOff.Text = "1-离站";
|
||||
this.Btn_PartOff.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.Btn_PartOff.UseVisualStyleBackColor = false;
|
||||
this.Btn_PartOff.Click += new System.EventHandler(this.Btn_PartOff_Click);
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(178, 42);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(41, 12);
|
||||
this.label1.TabIndex = 6;
|
||||
this.label1.Text = "流水号";
|
||||
//
|
||||
// txt_EngineNo
|
||||
//
|
||||
this.txt_EngineNo.Location = new System.Drawing.Point(251, 39);
|
||||
this.txt_EngineNo.Name = "txt_EngineNo";
|
||||
this.txt_EngineNo.Size = new System.Drawing.Size(214, 21);
|
||||
this.txt_EngineNo.TabIndex = 5;
|
||||
this.txt_EngineNo.Text = "9922G000244";
|
||||
//
|
||||
// lb_Station
|
||||
//
|
||||
this.lb_Station.FormattingEnabled = true;
|
||||
this.lb_Station.ItemHeight = 12;
|
||||
this.lb_Station.Location = new System.Drawing.Point(6, 19);
|
||||
this.lb_Station.Name = "lb_Station";
|
||||
this.lb_Station.Size = new System.Drawing.Size(150, 376);
|
||||
this.lb_Station.TabIndex = 9;
|
||||
this.lb_Station.SelectedIndexChanged += new System.EventHandler(this.lb_Station_SelectedIndexChanged);
|
||||
//
|
||||
// groupBox5
|
||||
//
|
||||
this.groupBox5.Controls.Add(this.lb_Station);
|
||||
this.groupBox5.Controls.Add(this.btn_TransferSort);
|
||||
this.groupBox5.Controls.Add(this.txt_PrintCode);
|
||||
this.groupBox5.Controls.Add(this.txt_SortName);
|
||||
this.groupBox5.Controls.Add(this.txt_SortNo);
|
||||
this.groupBox5.Controls.Add(this.txt_EngineNo);
|
||||
this.groupBox5.Controls.Add(this.label7);
|
||||
this.groupBox5.Controls.Add(this.label6);
|
||||
this.groupBox5.Controls.Add(this.label2);
|
||||
this.groupBox5.Controls.Add(this.txt_PartCode);
|
||||
this.groupBox5.Controls.Add(this.txt_PalletNo);
|
||||
this.groupBox5.Controls.Add(this.txt_OrderNo);
|
||||
this.groupBox5.Controls.Add(this.label5);
|
||||
this.groupBox5.Controls.Add(this.btn_Heartbeat);
|
||||
this.groupBox5.Controls.Add(this.btn_PartOn);
|
||||
this.groupBox5.Controls.Add(this.label4);
|
||||
this.groupBox5.Controls.Add(this.Btn_PartOff);
|
||||
this.groupBox5.Controls.Add(this.label3);
|
||||
this.groupBox5.Controls.Add(this.btn_Part_OnLine);
|
||||
this.groupBox5.Controls.Add(this.label1);
|
||||
this.groupBox5.Controls.Add(this.btn_AllowSave);
|
||||
this.groupBox5.Location = new System.Drawing.Point(9, 12);
|
||||
this.groupBox5.Name = "groupBox5";
|
||||
this.groupBox5.Size = new System.Drawing.Size(545, 407);
|
||||
this.groupBox5.TabIndex = 12;
|
||||
this.groupBox5.TabStop = false;
|
||||
this.groupBox5.Text = "功能测试";
|
||||
//
|
||||
// btn_TransferSort
|
||||
//
|
||||
this.btn_TransferSort.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.btn_TransferSort.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.btn_TransferSort.Location = new System.Drawing.Point(267, 193);
|
||||
this.btn_TransferSort.Name = "btn_TransferSort";
|
||||
this.btn_TransferSort.Size = new System.Drawing.Size(81, 27);
|
||||
this.btn_TransferSort.TabIndex = 3;
|
||||
this.btn_TransferSort.Text = "传递机型";
|
||||
this.btn_TransferSort.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.btn_TransferSort.UseVisualStyleBackColor = false;
|
||||
this.btn_TransferSort.Click += new System.EventHandler(this.btn_TransferSort_Click);
|
||||
//
|
||||
// txt_PrintCode
|
||||
//
|
||||
this.txt_PrintCode.Location = new System.Drawing.Point(251, 287);
|
||||
this.txt_PrintCode.Name = "txt_PrintCode";
|
||||
this.txt_PrintCode.Size = new System.Drawing.Size(245, 21);
|
||||
this.txt_PrintCode.TabIndex = 5;
|
||||
this.txt_PrintCode.Text = "WP14T610E62_001";
|
||||
//
|
||||
// txt_SortName
|
||||
//
|
||||
this.txt_SortName.Location = new System.Drawing.Point(251, 93);
|
||||
this.txt_SortName.Name = "txt_SortName";
|
||||
this.txt_SortName.Size = new System.Drawing.Size(214, 21);
|
||||
this.txt_SortName.TabIndex = 5;
|
||||
this.txt_SortName.Text = "WP14T610E62";
|
||||
//
|
||||
// txt_SortNo
|
||||
//
|
||||
this.txt_SortNo.Location = new System.Drawing.Point(251, 66);
|
||||
this.txt_SortNo.Name = "txt_SortNo";
|
||||
this.txt_SortNo.Size = new System.Drawing.Size(214, 21);
|
||||
this.txt_SortNo.TabIndex = 5;
|
||||
this.txt_SortNo.Text = "2";
|
||||
//
|
||||
// label7
|
||||
//
|
||||
this.label7.AutoSize = true;
|
||||
this.label7.Location = new System.Drawing.Point(179, 317);
|
||||
this.label7.Name = "label7";
|
||||
this.label7.Size = new System.Drawing.Size(65, 12);
|
||||
this.label7.TabIndex = 6;
|
||||
this.label7.Text = "缸体二维码";
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Location = new System.Drawing.Point(178, 151);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(41, 12);
|
||||
this.label6.TabIndex = 6;
|
||||
this.label6.Text = "托盘号";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Location = new System.Drawing.Point(178, 124);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(41, 12);
|
||||
this.label2.TabIndex = 6;
|
||||
this.label2.Text = "订单号";
|
||||
//
|
||||
// txt_PartCode
|
||||
//
|
||||
this.txt_PartCode.Location = new System.Drawing.Point(251, 314);
|
||||
this.txt_PartCode.Name = "txt_PartCode";
|
||||
this.txt_PartCode.Size = new System.Drawing.Size(245, 21);
|
||||
this.txt_PartCode.TabIndex = 5;
|
||||
this.txt_PartCode.Text = "4XX030123223909204E905110R_304__";
|
||||
//
|
||||
// txt_PalletNo
|
||||
//
|
||||
this.txt_PalletNo.Location = new System.Drawing.Point(251, 147);
|
||||
this.txt_PalletNo.Name = "txt_PalletNo";
|
||||
this.txt_PalletNo.Size = new System.Drawing.Size(214, 21);
|
||||
this.txt_PalletNo.TabIndex = 5;
|
||||
this.txt_PalletNo.Text = "457";
|
||||
//
|
||||
// txt_OrderNo
|
||||
//
|
||||
this.txt_OrderNo.Location = new System.Drawing.Point(251, 120);
|
||||
this.txt_OrderNo.Name = "txt_OrderNo";
|
||||
this.txt_OrderNo.Size = new System.Drawing.Size(214, 21);
|
||||
this.txt_OrderNo.TabIndex = 5;
|
||||
this.txt_OrderNo.Text = "5221052206000018";
|
||||
//
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Location = new System.Drawing.Point(178, 290);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(65, 12);
|
||||
this.label5.TabIndex = 6;
|
||||
this.label5.Text = "缸体打印码";
|
||||
//
|
||||
// btn_Heartbeat
|
||||
//
|
||||
this.btn_Heartbeat.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.btn_Heartbeat.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.btn_Heartbeat.Location = new System.Drawing.Point(181, 226);
|
||||
this.btn_Heartbeat.Name = "btn_Heartbeat";
|
||||
this.btn_Heartbeat.Size = new System.Drawing.Size(81, 27);
|
||||
this.btn_Heartbeat.TabIndex = 3;
|
||||
this.btn_Heartbeat.Text = "心跳";
|
||||
this.btn_Heartbeat.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.btn_Heartbeat.UseVisualStyleBackColor = false;
|
||||
this.btn_Heartbeat.Click += new System.EventHandler(this.btn_Heartbeat_Click);
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Location = new System.Drawing.Point(178, 96);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(29, 12);
|
||||
this.label4.TabIndex = 6;
|
||||
this.label4.Text = "机型";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Location = new System.Drawing.Point(178, 69);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(53, 12);
|
||||
this.label3.TabIndex = 6;
|
||||
this.label3.Text = "机型代码";
|
||||
//
|
||||
// btn_AllowSave
|
||||
//
|
||||
this.btn_AllowSave.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||
this.btn_AllowSave.ImeMode = System.Windows.Forms.ImeMode.NoControl;
|
||||
this.btn_AllowSave.Location = new System.Drawing.Point(354, 193);
|
||||
this.btn_AllowSave.Name = "btn_AllowSave";
|
||||
this.btn_AllowSave.Size = new System.Drawing.Size(80, 27);
|
||||
this.btn_AllowSave.TabIndex = 3;
|
||||
this.btn_AllowSave.Text = "允许保存";
|
||||
this.btn_AllowSave.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.btn_AllowSave.UseVisualStyleBackColor = false;
|
||||
this.btn_AllowSave.Click += new System.EventHandler(this.btn_AllowSave_Click);
|
||||
//
|
||||
// F_TestPage
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(566, 427);
|
||||
this.Controls.Add(this.groupBox5);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
|
||||
this.Name = "F_TestPage";
|
||||
this.ShowIcon = false;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "测试页面";
|
||||
this.groupBox5.ResumeLayout(false);
|
||||
this.groupBox5.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
private System.Windows.Forms.ListBox lb_Station;
|
||||
private System.Windows.Forms.GroupBox groupBox5;
|
||||
private System.Windows.Forms.Button Btn_PartOff;
|
||||
private System.Windows.Forms.Button btn_PartOn;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.TextBox txt_EngineNo;
|
||||
private System.Windows.Forms.Button btn_Part_OnLine;
|
||||
private System.Windows.Forms.Button btn_TransferSort;
|
||||
private System.Windows.Forms.Button btn_AllowSave;
|
||||
private System.Windows.Forms.TextBox txt_PrintCode;
|
||||
private System.Windows.Forms.TextBox txt_SortName;
|
||||
private System.Windows.Forms.TextBox txt_SortNo;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.TextBox txt_OrderNo;
|
||||
private System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Label label7;
|
||||
private System.Windows.Forms.Label label6;
|
||||
private System.Windows.Forms.TextBox txt_PartCode;
|
||||
private System.Windows.Forms.TextBox txt_PalletNo;
|
||||
private System.Windows.Forms.Button btn_Heartbeat;
|
||||
}
|
||||
}
|
||||
163
SCADA/数据测试/F_TestPage.cs
Normal file
163
SCADA/数据测试/F_TestPage.cs
Normal file
@@ -0,0 +1,163 @@
|
||||
using MesWork;
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace DC_A95
|
||||
{
|
||||
public partial class F_TestPage : Form
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
static string stationName = "";
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public F_TestPage()
|
||||
{
|
||||
InitializeComponent();
|
||||
foreach (var item in MesWorkForm.opNameList)
|
||||
{
|
||||
lb_Station.Items.Add(item);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void lb_Station_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
var sele = lb_Station.SelectedItem;
|
||||
if (sele != null)
|
||||
{
|
||||
stationName = sele.ToString();
|
||||
}
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void btn_Heartbeat_Click(object sender, EventArgs e)
|
||||
{
|
||||
var val = MesWorkForm.ReadPLC(14, stationName).ToString().ToLower().Replace("true", "1").Replace("false", "0");
|
||||
MesWorkForm.WritePLC_IF(14, stationName, val == "1" ? false : true);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void btn_PartOn_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrEmpty(stationName))
|
||||
{
|
||||
MessageBox.Show("请先选择一个工位号!");
|
||||
return;
|
||||
}
|
||||
|
||||
var engineNo = txt_EngineNo.Text;
|
||||
var sortNo = Convert.ToInt32(txt_SortNo.Text);
|
||||
var sortName = txt_SortName.Text;
|
||||
var orderNo = txt_OrderNo.Text;
|
||||
var palletNo = Convert.ToInt32(txt_PalletNo.Text);
|
||||
|
||||
var printCode = txt_PrintCode.Text;
|
||||
var partCode = txt_PartCode.Text;
|
||||
|
||||
/*
|
||||
14 系统健康(PLC)
|
||||
2 工件到位(PLC)
|
||||
43 申请零件编号(PLC)
|
||||
44 传递机型(PLC)
|
||||
63 禁用MES(PLC)
|
||||
9 机型标志(PLC)
|
||||
10 变速箱总成编号(PLC)
|
||||
11 产品型号(PLC)
|
||||
80 托盘编号(PLC)
|
||||
22 0空托盘,1合格件,2不合格件(PLC)
|
||||
19 质量数据可以读数据(PLC)
|
||||
21 质量数据工位合格标志(PLC)
|
||||
23 0正常件,1返修件(PLC)
|
||||
39 缸体打印码(PLC)
|
||||
40 订单号(PLC)
|
||||
120 上线缸体码(PLC)
|
||||
*/
|
||||
MesWorkForm.WritePLC_IF(10, stationName, engineNo);
|
||||
MesWorkForm.WritePLC_IF(9, stationName, sortNo);
|
||||
MesWorkForm.WritePLC_IF(11, stationName, sortName);
|
||||
MesWorkForm.WritePLC_IF(40, stationName, orderNo);
|
||||
MesWorkForm.WritePLC_IF(80, stationName, palletNo);
|
||||
MesWorkForm.WritePLC_IF(39, stationName, printCode);
|
||||
MesWorkForm.WritePLC_IF(120, stationName, partCode);
|
||||
MesWorkForm.WritePLC_IF(2, stationName, true);
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void btn_Part_OnLine_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrEmpty(stationName))
|
||||
{
|
||||
MessageBox.Show("请先选择一个工位号!");
|
||||
return;
|
||||
}
|
||||
|
||||
MesWorkForm.WritePLC_IF(43, stationName, true);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void btn_TransferSort_Click(object sender, EventArgs e)
|
||||
{
|
||||
MesWorkForm.WritePLC_IF(44, stationName, true);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void btn_AllowSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
MesWorkForm.WritePLC_IF(21, stationName, 1);
|
||||
MesWorkForm.WritePLC_IF(19, stationName, true);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void Btn_PartOff_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrEmpty(stationName))
|
||||
{
|
||||
MessageBox.Show("请先选择一个工位号!");
|
||||
return;
|
||||
}
|
||||
|
||||
MesWorkForm.WritePLC_IF(10, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(9, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(11, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(40, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(80, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(39, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(120, stationName, 0);
|
||||
MesWorkForm.WritePLC_IF(2, stationName, false);
|
||||
|
||||
MesWorkForm.WritePLC_IF(43, stationName, false);
|
||||
MesWorkForm.WritePLC_IF(44, stationName, false);
|
||||
MesWorkForm.WritePLC_IF(19, stationName, false);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
120
SCADA/数据测试/F_TestPage.resx
Normal file
120
SCADA/数据测试/F_TestPage.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?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>
|
||||
</root>
|
||||
Reference in New Issue
Block a user