Commit f9d5f91d LN

入库取料失败(升降气缸下降超)时禁用托盘

1 个父辈 3c40c3b3
......@@ -51,8 +51,12 @@
this.btnOutStore = new System.Windows.Forms.Button();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.tabPage1 = new System.Windows.Forms.TabPage();
this.groupBox6 = new System.Windows.Forms.GroupBox();
this.chbUseTrayCheck = new System.Windows.Forms.CheckBox();
this.groupBox8 = new System.Windows.Forms.GroupBox();
this.label7 = new System.Windows.Forms.Label();
this.txtPosId = new System.Windows.Forms.TextBox();
this.btnClear = new System.Windows.Forms.Button();
this.groupBox6 = new System.Windows.Forms.GroupBox();
this.lblInoutInfo = new System.Windows.Forms.Label();
this.lblMoveInfo = new System.Windows.Forms.Label();
this.lblInstoreList = new System.Windows.Forms.Label();
......@@ -88,23 +92,19 @@
this.txtP2 = new System.Windows.Forms.TextBox();
this.panel1 = new System.Windows.Forms.Panel();
this.lblName = new System.Windows.Forms.Label();
this.groupBox8 = new System.Windows.Forms.GroupBox();
this.label7 = new System.Windows.Forms.Label();
this.txtPosId = new System.Windows.Forms.TextBox();
this.btnClear = new System.Windows.Forms.Button();
this.groupBox1.SuspendLayout();
this.groupBox4.SuspendLayout();
this.groupBox3.SuspendLayout();
this.groupBox5.SuspendLayout();
this.tabControl1.SuspendLayout();
this.tabPage1.SuspendLayout();
this.groupBox8.SuspendLayout();
this.groupBox6.SuspendLayout();
this.tabPage2.SuspendLayout();
this.groupBox7.SuspendLayout();
this.groupDetial.SuspendLayout();
this.groupBox2.SuspendLayout();
this.panel1.SuspendLayout();
this.groupBox8.SuspendLayout();
this.SuspendLayout();
//
// timer1
......@@ -538,6 +538,7 @@
//
// tabPage1
//
this.tabPage1.Controls.Add(this.chbUseTrayCheck);
this.tabPage1.Controls.Add(this.groupBox8);
this.tabPage1.Controls.Add(this.groupBox6);
this.tabPage1.Controls.Add(this.groupBox3);
......@@ -552,12 +553,65 @@
this.tabPage1.Text = " IO列表 ";
this.tabPage1.UseVisualStyleBackColor = true;
//
// chbUseTrayCheck
//
this.chbUseTrayCheck.AutoSize = true;
this.chbUseTrayCheck.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbUseTrayCheck.Location = new System.Drawing.Point(520, 435);
this.chbUseTrayCheck.Name = "chbUseTrayCheck";
this.chbUseTrayCheck.Size = new System.Drawing.Size(112, 24);
this.chbUseTrayCheck.TabIndex = 282;
this.chbUseTrayCheck.Text = "启用料盘检测";
this.chbUseTrayCheck.UseVisualStyleBackColor = true;
this.chbUseTrayCheck.CheckedChanged += new System.EventHandler(this.chbUseTrayCheck_CheckedChanged);
//
// groupBox8
//
this.groupBox8.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox8.Controls.Add(this.label7);
this.groupBox8.Controls.Add(this.txtPosId);
this.groupBox8.Controls.Add(this.btnClear);
this.groupBox8.Location = new System.Drawing.Point(659, 414);
this.groupBox8.Name = "groupBox8";
this.groupBox8.Size = new System.Drawing.Size(647, 63);
this.groupBox8.TabIndex = 280;
this.groupBox8.TabStop = false;
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(14, 28);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(47, 17);
this.label7.TabIndex = 284;
this.label7.Text = "库位号:";
//
// txtPosId
//
this.txtPosId.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtPosId.Location = new System.Drawing.Point(72, 23);
this.txtPosId.Name = "txtPosId";
this.txtPosId.Size = new System.Drawing.Size(150, 26);
this.txtPosId.TabIndex = 283;
//
// btnClear
//
this.btnClear.BackColor = System.Drawing.Color.White;
this.btnClear.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnClear.Location = new System.Drawing.Point(233, 19);
this.btnClear.Name = "btnClear";
this.btnClear.Size = new System.Drawing.Size(105, 35);
this.btnClear.TabIndex = 286;
this.btnClear.Text = "清空入库任务";
this.btnClear.UseVisualStyleBackColor = false;
this.btnClear.Click += new System.EventHandler(this.btnClear_Click);
//
// groupBox6
//
this.groupBox6.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox6.Controls.Add(this.chbUseTrayCheck);
this.groupBox6.Controls.Add(this.lblInoutInfo);
this.groupBox6.Controls.Add(this.lblMoveInfo);
this.groupBox6.Controls.Add(this.lblInstoreList);
......@@ -569,18 +623,6 @@
this.groupBox6.TabStop = false;
this.groupBox6.Text = "消息";
//
// chbUseTrayCheck
//
this.chbUseTrayCheck.AutoSize = true;
this.chbUseTrayCheck.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbUseTrayCheck.Location = new System.Drawing.Point(9, 228);
this.chbUseTrayCheck.Name = "chbUseTrayCheck";
this.chbUseTrayCheck.Size = new System.Drawing.Size(112, 24);
this.chbUseTrayCheck.TabIndex = 282;
this.chbUseTrayCheck.Text = "启用料盘检测";
this.chbUseTrayCheck.UseVisualStyleBackColor = true;
this.chbUseTrayCheck.CheckedChanged += new System.EventHandler(this.chbUseTrayCheck_CheckedChanged);
//
// lblInoutInfo
//
this.lblInoutInfo.ForeColor = System.Drawing.Color.Green;
......@@ -622,7 +664,7 @@
this.tabPage2.Location = new System.Drawing.Point(4, 26);
this.tabPage2.Name = "tabPage2";
this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
this.tabPage2.Size = new System.Drawing.Size(1315, 483);
this.tabPage2.Size = new System.Drawing.Size(1315, 485);
this.tabPage2.TabIndex = 1;
this.tabPage2.Text = " 伺服信息 ";
this.tabPage2.UseVisualStyleBackColor = true;
......@@ -1029,48 +1071,6 @@
this.lblName.Text = "出料流水线";
this.lblName.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// groupBox8
//
this.groupBox8.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox8.Controls.Add(this.label7);
this.groupBox8.Controls.Add(this.txtPosId);
this.groupBox8.Controls.Add(this.btnClear);
this.groupBox8.Location = new System.Drawing.Point(498, 414);
this.groupBox8.Name = "groupBox8";
this.groupBox8.Size = new System.Drawing.Size(808, 63);
this.groupBox8.TabIndex = 280;
this.groupBox8.TabStop = false;
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(14, 28);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(47, 17);
this.label7.TabIndex = 284;
this.label7.Text = "库位号:";
//
// txtPosId
//
this.txtPosId.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtPosId.Location = new System.Drawing.Point(72, 23);
this.txtPosId.Name = "txtPosId";
this.txtPosId.Size = new System.Drawing.Size(150, 26);
this.txtPosId.TabIndex = 283;
//
// btnClear
//
this.btnClear.BackColor = System.Drawing.Color.White;
this.btnClear.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnClear.Location = new System.Drawing.Point(233, 19);
this.btnClear.Name = "btnClear";
this.btnClear.Size = new System.Drawing.Size(105, 35);
this.btnClear.TabIndex = 286;
this.btnClear.Text = "清空入库任务";
this.btnClear.UseVisualStyleBackColor = false;
this.btnClear.Click += new System.EventHandler(this.btnClear_Click);
//
// FrmMoveEquip
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
......@@ -1093,6 +1093,9 @@
this.groupBox5.ResumeLayout(false);
this.tabControl1.ResumeLayout(false);
this.tabPage1.ResumeLayout(false);
this.tabPage1.PerformLayout();
this.groupBox8.ResumeLayout(false);
this.groupBox8.PerformLayout();
this.groupBox6.ResumeLayout(false);
this.groupBox6.PerformLayout();
this.tabPage2.ResumeLayout(false);
......@@ -1104,8 +1107,6 @@
this.groupBox2.PerformLayout();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.groupBox8.ResumeLayout(false);
this.groupBox8.PerformLayout();
this.ResumeLayout(false);
}
......
......@@ -253,7 +253,7 @@ namespace OnlineStore.DeviceLibrary
}
#endregion
}
}
private void MO_55_CylinderUp()
{
MoveInfo.NextMoveStep(LineMoveStep.MO_55_CylinderUp);
......@@ -327,11 +327,31 @@ namespace OnlineStore.DeviceLibrary
{
CheckWait(SecondMoveInfo);
}
string posId = MoveInfo.MoveParam != null ? MoveInfo.MoveParam.PosId : "";
if (MoveInfo.IsInWait)
{
if (!UseAxis)
{
if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_03_CylinderDown)&&MoveInfo.IsTimeOut(20))
{
//顶升气缸上升到位,升降气缸下降不到位
if(CylinderIsOk(IO_Type.TopCylinder_Down, IO_Type.TopCylinder_UP)&&
IOValue(IO_Type.UpDownCylinder_Up).Equals(IO_VALUE.LOW) &&
IOValue(IO_Type.UpDownCylinder_Down).Equals(IO_VALUE.LOW))
{
LogUtil.error(Name + "入库 [" + posId + "],升降气缸下降到托盘[" + currTrayNum + "]取料失败,升降轴上升,禁用托盘,同时放行托盘");
MoveInfo.NextMoveStep(LineMoveStep.MI_18_UpdownUp);
LogInfo("入库 [" + posId + "]" + MoveInfo.SLog + ": 升降轴上升,禁用托盘,同时放行托盘,顶升气缸1下降");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Down, IO_Type.UpDownCylinder_Up);
TrayDisableManager.AddDisable(currTrayNum, Name, "入库取料失败");
SecondMoveInfo.NextMoveStep(LineMoveStep.MO_14_TopDown);
CylinderMove(SecondMoveInfo, IO_Type.TopCylinder_UP, IO_Type.TopCylinder_Down);
}
}
}
return;
}
string posId = MoveInfo.MoveParam != null ? MoveInfo.MoveParam.PosId : "";
if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_02_ToLineUp))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_03_CylinderDown);
......@@ -482,6 +502,10 @@ namespace OnlineStore.DeviceLibrary
{
LogInfo("入库【" + posId + "】处理(移栽)全部完成!");
MoveEndS();
}else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_18_UpdownUp))
{
LogInfo("入库【" + posId + "】失败,自动复位完成");
MoveEndS();
}
}
......
......@@ -260,7 +260,10 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
MI_16_SendEnd = 3016,
/// <summary>
///入库:升降轴下降取料盘失败,升降轴上升,托盘禁用,托盘放行
/// </summary>
MI_18_UpdownUp=3018,
#endregion
#region 移栽装置出入库共同模块 3080-3100
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!