Commit 975c3354 LN

bug修改

1 个父辈 ccb5e455
......@@ -220,7 +220,11 @@ namespace OnlineStore.AssemblyLine
string code = txtTrayCode.Text.Trim();
if (hasTray)
{
InOutParam inoutP = new InOutParam(num, "CodeTest", posId, ph, pw, inNg, urg, cutReel, isSmall, "", loc);
if (String.IsNullOrEmpty(code))
{
code = "CodeTest";
}
InOutParam inoutP = new InOutParam(num, code, posId, ph, pw, inNg, urg, cutReel, isSmall, "", loc);
TrayManager.UpdateTrayInfo(num, hasTray, trayType, inoutP, "InStoreNG ");
}
else
......
......@@ -76,6 +76,10 @@
this.label4 = new System.Windows.Forms.Label();
this.btnP2 = new System.Windows.Forms.Button();
this.txtP2 = new System.Windows.Forms.TextBox();
this.groupBox5 = 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.panBase.SuspendLayout();
this.groupBox1.SuspendLayout();
this.groupBox4.SuspendLayout();
......@@ -87,6 +91,7 @@
this.tabPage2.SuspendLayout();
this.groupDetial.SuspendLayout();
this.groupBox2.SuspendLayout();
this.groupBox5.SuspendLayout();
this.SuspendLayout();
//
// panBase
......@@ -142,9 +147,9 @@
this.groupBox1.Controls.Add(this.txtSlaveId);
this.groupBox1.Controls.Add(this.cmbWriteIO);
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(500, 175);
this.groupBox1.Location = new System.Drawing.Point(500, 176);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(373, 151);
this.groupBox1.Size = new System.Drawing.Size(373, 150);
this.groupBox1.TabIndex = 105;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "DO写入";
......@@ -353,9 +358,9 @@
this.groupDO.Controls.Add(this.BeforeAfterCylinder_Before);
this.groupDO.Controls.Add(this.TopCylinder_Up);
this.groupDO.Controls.Add(this.UpDownCylinder_Up);
this.groupDO.Location = new System.Drawing.Point(500, 332);
this.groupDO.Location = new System.Drawing.Point(500, 329);
this.groupDO.Name = "groupDO";
this.groupDO.Size = new System.Drawing.Size(652, 117);
this.groupDO.Size = new System.Drawing.Size(652, 111);
this.groupDO.TabIndex = 255;
this.groupDO.TabStop = false;
this.groupDO.Text = "IO操作测试";
......@@ -497,7 +502,7 @@
this.lblThisSta.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblThisSta.ForeColor = System.Drawing.Color.Red;
this.lblThisSta.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblThisSta.Location = new System.Drawing.Point(199, 127);
this.lblThisSta.Location = new System.Drawing.Point(199, 126);
this.lblThisSta.Name = "lblThisSta";
this.lblThisSta.Size = new System.Drawing.Size(942, 28);
this.lblThisSta.TabIndex = 246;
......@@ -519,6 +524,7 @@
//
// tabPage1
//
this.tabPage1.Controls.Add(this.groupBox5);
this.tabPage1.Controls.Add(this.groupDO);
this.tabPage1.Controls.Add(this.clampJawControl1);
this.tabPage1.Controls.Add(this.groupBox6);
......@@ -561,7 +567,7 @@
this.lblInoutInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblInoutInfo.ForeColor = System.Drawing.Color.Green;
this.lblInoutInfo.Location = new System.Drawing.Point(2, 17);
this.lblInoutInfo.Location = new System.Drawing.Point(2, 16);
this.lblInoutInfo.Name = "lblInoutInfo";
this.lblInoutInfo.Size = new System.Drawing.Size(1138, 23);
this.lblInoutInfo.TabIndex = 281;
......@@ -585,7 +591,7 @@
this.lblInstoreList.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblInstoreList.ForeColor = System.Drawing.Color.Green;
this.lblInstoreList.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblInstoreList.Location = new System.Drawing.Point(199, 45);
this.lblInstoreList.Location = new System.Drawing.Point(199, 44);
this.lblInstoreList.Name = "lblInstoreList";
this.lblInstoreList.Size = new System.Drawing.Size(942, 77);
this.lblInstoreList.TabIndex = 277;
......@@ -889,6 +895,48 @@
this.txtP2.TabIndex = 305;
this.txtP2.Text = "-1";
//
// groupBox5
//
this.groupBox5.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox5.Controls.Add(this.label7);
this.groupBox5.Controls.Add(this.txtPosId);
this.groupBox5.Controls.Add(this.btnClear);
this.groupBox5.Location = new System.Drawing.Point(500, 443);
this.groupBox5.Name = "groupBox5";
this.groupBox5.Size = new System.Drawing.Size(652, 66);
this.groupBox5.TabIndex = 280;
this.groupBox5.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);
......@@ -921,6 +969,8 @@
this.groupDetial.PerformLayout();
this.groupBox2.ResumeLayout(false);
this.groupBox2.PerformLayout();
this.groupBox5.ResumeLayout(false);
this.groupBox5.PerformLayout();
this.ResumeLayout(false);
}
......@@ -986,6 +1036,10 @@
private System.Windows.Forms.Label lblP2;
private System.Windows.Forms.Label lblP3List;
private useControl.ClampJawControl clampJawControl1;
private System.Windows.Forms.GroupBox groupBox5;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.TextBox txtPosId;
private System.Windows.Forms.Button btnClear;
}
}
......@@ -682,7 +682,38 @@ namespace OnlineStore.AssemblyLine
LogUtil.info(equipBean.Name + "用户切换是否暂停: " + equipBean.MoveStop);
}
private void btnClear_Click(object sender, EventArgs e)
{
string posId = txtPosId.Text.Trim();
if (String.IsNullOrEmpty(posId))
{
MessageBox.Show("请输入正确的库位号", "提示", MessageBoxButtons.OK, MessageBoxIcon.Error, MessageBoxDefaultButton.Button1);
txtPosId.Focus();
return;
}
LogUtil.info("点击 " + btnClear.Text + " , 库位号[" + posId + "]");
InOutParam param = null;
List<InOutParam> paramList = new List<InOutParam>(equipBean.waitInStoreList);
foreach (InOutParam p in paramList)
{
if (p.PosId.Equals(posId))
{
param = p;
break;
}
}
if (param == null)
{
MessageBox.Show("未找到对应的任务,请输入正确的库位号", "提示", MessageBoxButtons.OK, MessageBoxIcon.Error, MessageBoxDefaultButton.Button1);
txtPosId.Focus();
return;
}
else
{
equipBean.RemoveInStore(param, "手动清除入库任务");
txtPosId.Clear();
}
}
}
}
......
......@@ -189,6 +189,12 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.NextMoveStep(LineMoveStep.FR_05_UpdownAxis_P1);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 升降伺服到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
currTrayNum = -1;
if (LineManager.Line.TrayIsReady(DeviceID, out currTrayNum))
{
LogInfo("复位中,发现托盘准备完成,放托盘离开");
TrayMoveOk();
}
break;
case LineMoveStep.FR_05_UpdownAxis_P1:
if (UpdownIsInP1())
......
......@@ -518,20 +518,8 @@ namespace OnlineStore.DeviceLibrary
int targetPositon = Config.GetUpdownP2Detial(LastHeight, LastWidth);
UpdownAxis.AbsMove(MoveInfo, targetPositon, Config.UpdownAxis_P2Speed);
LastPosParam.TrayNumber = currTrayNum;
if (LastResult.Equals(98))
{
TrayManager.UpdateTrayInfo(currTrayNum, true, ReelType.OutStore, LastPosParam.Clone(), LastPosParam.NgMsg);
TrayInfo tray = TrayManager.GetTrayInfo(currTrayNum);
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P2: [" + targetPositon + "] 更新料盘位置,更新托盘信息【" + tray.ToStr() + "】");
SServerManager.UpdateTrayLoc(Name, LastPosParam.WareCode, LocStatus.INLINE, "E" + currTrayNum.ToString().PadLeft(2, '0'));
}
else
{
TrayManager.UpdateTrayInfo(currTrayNum, true, ReelType.InStore, LastPosParam.Clone(), LastPosParam.NgMsg);
TrayInfo tray = TrayManager.GetTrayInfo(currTrayNum);
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P2: [" + targetPositon + "] 更新托盘信息【" + tray.ToStr() + "】");
SServerManager.SendPosToStoreCheck(Name, LastPosParam.Clone());
}
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P2: [" + targetPositon + "] 暂不更新托盘信息");
if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.LOW) && MoveInfo.ShelfNoTray.Equals(false))
{
InLog("获取库位" + MoveInfo.SLog + ": 上料轴开始慢速上升到P3点,不等待结果");
......@@ -554,9 +542,22 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.IsStep(LineMoveStep.FI_34_CylinderRelax))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_35_AxisToP1);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P1点 [" + Config.UpDownAxisP1 + "]");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
if (LastResult.Equals(98))
{
TrayManager.UpdateTrayInfo(currTrayNum, true, ReelType.OutStore, LastPosParam.Clone(), LastPosParam.NgMsg);
TrayInfo tray = TrayManager.GetTrayInfo(currTrayNum);
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P1点 [" + Config.UpDownAxisP1 + "] 更新料盘位置,更新托盘信息【" + tray.ToStr() + "】");
SServerManager.UpdateTrayLoc(Name, LastPosParam.WareCode, LocStatus.INLINE, "E" + currTrayNum.ToString().PadLeft(2, '0'));
}
else
{
TrayManager.UpdateTrayInfo(currTrayNum, true, ReelType.InStore, LastPosParam.Clone(), LastPosParam.NgMsg);
TrayInfo tray = TrayManager.GetTrayInfo(currTrayNum);
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P1点 [" + Config.UpDownAxisP1 + "] 更新托盘信息【" + tray.ToStr() + "】");
SServerManager.SendPosToStoreCheck(Name, LastPosParam.Clone());
}
}
else if (MoveInfo.IsStep(LineMoveStep.FI_35_AxisToP1))
{
......
......@@ -70,10 +70,10 @@ namespace OnlineStore.LoadCSVLibrary
[CSVAttribute("加速度")]
public short AddSpeed { get; set; }
public int AddSpeed { get; set; }
[CSVAttribute("减速度")]
public short DelSpeed { get; set; }
public int DelSpeed { get; set; }
[CSVAttribute("回零低速")]
public int HomeLowSpeed { get; set; }
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!