Commit 67deef22 LN

上料模块复位时先上升阻挡气缸,再转动流水线

1 个父辈 1764f0e8
......@@ -97,6 +97,7 @@
this.chbMoveStop = new System.Windows.Forms.CheckBox();
this.lblName = new System.Windows.Forms.Label();
this.btnScan = new System.Windows.Forms.Button();
this.btnOutStopDown = new System.Windows.Forms.Button();
this.groupBox1.SuspendLayout();
this.groupBox4.SuspendLayout();
this.groupBox3.SuspendLayout();
......@@ -334,6 +335,7 @@
this.groupBox5.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.groupBox5.Controls.Add(this.btnOutStopDown);
this.groupBox5.Controls.Add(this.btnSwStop);
this.groupBox5.Controls.Add(this.btnFLStop1);
this.groupBox5.Controls.Add(this.btnFLStop2Down);
......@@ -365,7 +367,7 @@
this.btnSwStop.BackColor = System.Drawing.Color.White;
this.btnSwStop.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSwStop.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSwStop.Location = new System.Drawing.Point(9, 258);
this.btnSwStop.Location = new System.Drawing.Point(8, 258);
this.btnSwStop.Name = "btnSwStop";
this.btnSwStop.Size = new System.Drawing.Size(153, 34);
this.btnSwStop.TabIndex = 271;
......@@ -482,7 +484,7 @@
this.btnFL_TopCylinder.BackColor = System.Drawing.Color.White;
this.btnFL_TopCylinder.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnFL_TopCylinder.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnFL_TopCylinder.Location = new System.Drawing.Point(168, 218);
this.btnFL_TopCylinder.Location = new System.Drawing.Point(9, 296);
this.btnFL_TopCylinder.Name = "btnFL_TopCylinder";
this.btnFL_TopCylinder.Size = new System.Drawing.Size(153, 34);
this.btnFL_TopCylinder.TabIndex = 262;
......@@ -495,7 +497,7 @@
this.btnSwLocationCylinder.BackColor = System.Drawing.Color.White;
this.btnSwLocationCylinder.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSwLocationCylinder.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSwLocationCylinder.Location = new System.Drawing.Point(9, 296);
this.btnSwLocationCylinder.Location = new System.Drawing.Point(168, 258);
this.btnSwLocationCylinder.Name = "btnSwLocationCylinder";
this.btnSwLocationCylinder.Size = new System.Drawing.Size(153, 34);
this.btnSwLocationCylinder.TabIndex = 261;
......@@ -586,7 +588,7 @@
this.btnFeedCylinder.BackColor = System.Drawing.Color.White;
this.btnFeedCylinder.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnFeedCylinder.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnFeedCylinder.Location = new System.Drawing.Point(9, 218);
this.btnFeedCylinder.Location = new System.Drawing.Point(168, 217);
this.btnFeedCylinder.Name = "btnFeedCylinder";
this.btnFeedCylinder.Size = new System.Drawing.Size(153, 34);
this.btnFeedCylinder.TabIndex = 249;
......@@ -599,7 +601,7 @@
this.btnFeedSideWay.BackColor = System.Drawing.Color.White;
this.btnFeedSideWay.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnFeedSideWay.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnFeedSideWay.Location = new System.Drawing.Point(168, 179);
this.btnFeedSideWay.Location = new System.Drawing.Point(9, 217);
this.btnFeedSideWay.Name = "btnFeedSideWay";
this.btnFeedSideWay.Size = new System.Drawing.Size(153, 34);
this.btnFeedSideWay.TabIndex = 246;
......@@ -1192,6 +1194,19 @@
this.btnScan.UseVisualStyleBackColor = false;
this.btnScan.Click += new System.EventHandler(this.btnScan_Click);
//
// btnOutStopDown
//
this.btnOutStopDown.BackColor = System.Drawing.Color.White;
this.btnOutStopDown.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnOutStopDown.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnOutStopDown.Location = new System.Drawing.Point(168, 179);
this.btnOutStopDown.Name = "btnOutStopDown";
this.btnOutStopDown.Size = new System.Drawing.Size(153, 34);
this.btnOutStopDown.TabIndex = 272;
this.btnOutStopDown.Text = "SL出料阻挡下降";
this.btnOutStopDown.UseVisualStyleBackColor = false;
this.btnOutStopDown.Click += new System.EventHandler(this.btnOutStopDown_Click);
//
// FrmFeedingEquip
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
......@@ -1312,6 +1327,7 @@
private System.Windows.Forms.Button btnFLStop2Down;
private System.Windows.Forms.CheckBox chbBoxSendShelf;
private System.Windows.Forms.Button btnSwStop;
private System.Windows.Forms.Button btnOutStopDown;
}
}
......@@ -613,6 +613,12 @@ namespace OnlineStore.AssemblyLine
{
BtnMove(btnSwStop, "环形线阻挡气缸下降", "环形线阻挡气缸上升", IO_Type.SW_StopDown);
}
private void btnOutStopDown_Click(object sender, EventArgs e)
{
BtnMove(btnOutStopDown, "SL出料阻挡下降", "SL出料阻挡上升", IO_Type.SL_Out_StopDown);
}
}
}
......
......@@ -109,26 +109,11 @@ namespace OnlineStore.DeviceLibrary
ResetClearData();
lineStatus = LineStatus.ResetMove;
IOMove(IO_Type.SL_HddLed, IO_VALUE.HIGH);
MoveInfo.NextMoveStep(LineMoveStep.FR_00_LineRun);
//阻挡上升
if(IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,检测到定位工位有信号,不转动链条");
}
else
{
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,链条先转动3秒钟 ");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(3000));
//线体开始转动
IOMove(IO_Type.SL_Line_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.HIGH);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Location_Check, IO_VALUE.HIGH));
MoveInfo.OneWaitCanEndStep = true;
}
CheckAndMove(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW);
CheckAndMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW);
CheckAndMove(IO_Type.SL_Out_StopDown, IO_VALUE.LOW);
MoveInfo.NextMoveStep(LineMoveStep.FR_01_StopUp);
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW);
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW);
IOMove(IO_Type.SL_Out_StopDown, IO_VALUE.LOW);
if (Config.SidesWayNum <= 0)
{
CheckAndMove(IO_Type.FL_StopCylinder_Down1, IO_VALUE.LOW);
......@@ -141,7 +126,25 @@ namespace OnlineStore.DeviceLibrary
CylinderMove(null, IO_Type.SW_LocationCylinder_Up, IO_Type.SW_LocationCylinder_Down);
CylinderMove(null, IO_Type.SW_TopCylinder_Up, IO_Type.SW_TopCylinder_Down);
}
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Out_StopDown, IO_VALUE.LOW));
////阻挡上升
//if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
//{
// LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,检测到定位工位有信号,不转动链条");
//}
//else
//{
// LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,链条先转动3秒钟 ");
// MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(3000));
// //线体开始转动
// IOMove(IO_Type.SL_Line_Run, IO_VALUE.HIGH);
// IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.HIGH);
// IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.HIGH);
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Location_Check, IO_VALUE.HIGH));
// MoveInfo.OneWaitCanEndStep = true;
//}
isInPro = false;
}
//复位时,应该先提升伺服回原点,然后提升伺服下降到P2点,放开定位气缸,顶升气缸下降,提升伺服在上升到P1点。
......@@ -158,8 +161,27 @@ namespace OnlineStore.DeviceLibrary
case LineMoveStep.Wait:
StartReset();
break;
case LineMoveStep.FR_00_LineRun:
MoveInfo.NextMoveStep(LineMoveStep.FR_01_MoveCylinder_Up);
case LineMoveStep.FR_01_StopUp:
MoveInfo.NextMoveStep(LineMoveStep.FR_02_LineRun);
//阻挡上升
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,检测到定位工位有信号,不转动链条");
}
else
{
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":开始复位,放料顶升下降, 所有阻挡上升,链条先转动3秒钟 ");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(3000));
//线体开始转动
IOMove(IO_Type.SL_Line_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.HIGH);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Location_Check, IO_VALUE.HIGH));
MoveInfo.OneWaitCanEndStep = true;
}
break;
case LineMoveStep.FR_02_LineRun:
MoveInfo.NextMoveStep(LineMoveStep.FR_03_MoveCylinder_Up);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":链条停止转动,上料横移机构上升,出口顶升下降,所有阻挡气缸上升");
//线体停止
IOMove(IO_Type.SL_Line_Run, IO_VALUE.LOW);
......@@ -181,22 +203,22 @@ namespace OnlineStore.DeviceLibrary
CylinderMove(MoveInfo, IO_Type.SW_TopCylinder_Up, IO_Type.SW_TopCylinder_Down);
}
break;
case LineMoveStep.FR_01_MoveCylinder_Up:
MoveInfo.NextMoveStep(LineMoveStep.FR_02_UpdownAxisHome);
case LineMoveStep.FR_03_MoveCylinder_Up:
MoveInfo.NextMoveStep(LineMoveStep.FR_04_UpdownAxisHome);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 升降伺服回原点");
UpdownAxis.HomeMove(MoveInfo);
break;
case LineMoveStep.FR_02_UpdownAxisHome:
MoveInfo.NextMoveStep(LineMoveStep.FR_03_UpdownAxis_P1);
case LineMoveStep.FR_04_UpdownAxisHome:
MoveInfo.NextMoveStep(LineMoveStep.FR_05_UpdownAxis_P1);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 升降伺服到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
break;
case LineMoveStep.FR_03_UpdownAxis_P1:
case LineMoveStep.FR_05_UpdownAxis_P1:
if (MoveCylineCanTakeOrGive())
{
MoveInfo.NextMoveStep(LineMoveStep.FR_04_MoveCylinder_Give);
MoveInfo.NextMoveStep(LineMoveStep.FR_06_MoveCylinder_Give);
if (Config.IsCanOut.Equals(1))
{
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 上料横移气缸取料端SOL");
......@@ -210,12 +232,12 @@ namespace OnlineStore.DeviceLibrary
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FR_03_UpdownAxis_P1);
MoveInfo.NextMoveStep(LineMoveStep.FR_05_UpdownAxis_P1);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":上料横移机构上升SOL");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
}
break;
case LineMoveStep.FR_04_MoveCylinder_Give:
case LineMoveStep.FR_06_MoveCylinder_Give:
MoveInfo.NextMoveStep(LineMoveStep.FR_11_BatchAxisHome);
MoveInfo.TimeOutSeconds = 120;
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":提升伺服回原点");
......
......@@ -458,28 +458,33 @@ namespace OnlineStore.DeviceLibrary
#endregion
#region 入料装置原点返回,10000开始
/// <summary>
/// 复位之前,所有阻挡先上升到位
/// </summary>
FR_01_StopUp = 10001,
/// <summary>
/// 复位之前,所有的链条先转动3秒钟
/// </summary>
FR_00_LineRun=10000,
FR_02_LineRun=10002,
/// <summary>
/// 横移装置上升,
/// </summary>
FR_01_MoveCylinder_Up = 10001,
FR_03_MoveCylinder_Up = 10003,
/// <summary>
/// 升降伺服回原点
/// </summary>
FR_02_UpdownAxisHome = 10002,
FR_04_UpdownAxisHome = 10004,
/// <summary>
///上料装置:上料气缸放松SOL,升降机构到待机点
/// </summary>
FR_03_UpdownAxis_P1 = 10003,
FR_05_UpdownAxis_P1 = 10005,
/// <summary>
///上料装置:上料横移气缸取料端SOL
/// </summary>
FR_04_MoveCylinder_Give = 10004,
FR_06_MoveCylinder_Give = 10006,
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!