Commit 329855a6 LN

出库逻辑修改

1 个父辈 1f745870
...@@ -829,10 +829,16 @@ namespace OnlineStore.DeviceLibrary ...@@ -829,10 +829,16 @@ namespace OnlineStore.DeviceLibrary
return true; return true;
} }
//前进后退气缸后退以后才可以出库 //前进后退气缸后退以后才可以出库
else if (move.runStatus.Equals(LineRunStatus.Busy) && move.MoveInfo.MoveType.Equals(LineMoveType.OutStore) && else if (move.runStatus.Equals(LineRunStatus.Busy) && move.MoveInfo.MoveType.Equals(LineMoveType.OutStore))
move.MoveInfo.MoveStep >= (LineMoveStep.MO_58_CylinderDown))
{ {
return true; if (move.MoveInfo.MoveStep >= (LineMoveStep.MO_58_CylinderDown))
{
return true;
}
else if (move.MoveInfo.MoveStep.Equals(LineMoveStep.MO_56_CylinderAfter) && move.MoveInfo.IsInWait.Equals(false))
{
return true;
}
} }
} }
return false; return false;
......
...@@ -58,13 +58,13 @@ namespace OnlineStore.DeviceLibrary ...@@ -58,13 +58,13 @@ namespace OnlineStore.DeviceLibrary
if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_50_StartOutProcess)) if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_50_StartOutProcess))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MO_51_CylinderBefore); MoveInfo.NextMoveStep(LineMoveStep.MO_51_CylinderBefore);
OutLog("出库 "+MoveInfo.MoveStep+": 前后气缸前进 )"); OutLog("出库 "+MoveInfo.MoveStep+": 前后气缸前进");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before); CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before);
} }
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_51_CylinderBefore)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_51_CylinderBefore))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MO_52_CylinderDown); MoveInfo.NextMoveStep(LineMoveStep.MO_52_CylinderDown);
OutLog("出库 " + MoveInfo.SLog + ": 上下气缸下降 )"); OutLog("出库 " + MoveInfo.SLog + ": 上下气缸下降 ");
UpdownDownP3Move(MoveInfo.MoveParam.PlateH); UpdownDownP3Move(MoveInfo.MoveParam.PlateH);
// CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Up, IO_Type.UpDownCylinder_Down); // CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Up, IO_Type.UpDownCylinder_Down);
} }
...@@ -87,7 +87,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -87,7 +87,7 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_54_CylinderOpen)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_54_CylinderOpen))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MO_55_CylinderUp); MoveInfo.NextMoveStep(LineMoveStep.MO_55_CylinderUp);
OutLog("出库 " + MoveInfo.SLog + ": 上下气缸上升)"); OutLog("出库 " + MoveInfo.SLog + ": 上下气缸上升");
UpdownUpMove(); UpdownUpMove();
// CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Down, IO_Type.UpDownCylinder_Up); // CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Down, IO_Type.UpDownCylinder_Up);
...@@ -95,7 +95,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -95,7 +95,7 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_55_CylinderUp)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_55_CylinderUp))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MO_56_CylinderAfter); MoveInfo.NextMoveStep(LineMoveStep.MO_56_CylinderAfter);
OutLog("出库 " + MoveInfo.SLog + ": 前后气缸后退)"); OutLog("出库 " + MoveInfo.SLog + ": 前后气缸后退");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After); CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
} }
#endregion #endregion
...@@ -143,7 +143,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -143,7 +143,7 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_59_CylinderRelax)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_59_CylinderRelax))
{ {
this.MoveInfo.NextMoveStep(LineMoveStep.MO_60_CylinderUp); this.MoveInfo.NextMoveStep(LineMoveStep.MO_60_CylinderUp);
OutLog("出库 " + MoveInfo.SLog + ": 上下气缸上升"); OutLog("出库 " + MoveInfo.SLog + ": 上下气缸上升");
UpdownUpMove(); UpdownUpMove();
} }
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_60_CylinderUp)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_60_CylinderUp))
...@@ -215,13 +215,13 @@ namespace OnlineStore.DeviceLibrary ...@@ -215,13 +215,13 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_07_DownWait)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_07_DownWait))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MI_08_CylinderOpen); MoveInfo.NextMoveStep(LineMoveStep.MI_08_CylinderOpen);
InLog("入库 " + MoveInfo.SLog + ": 夹料气缸夹紧"); InLog("入库 " + MoveInfo.SLog + ": 夹料气缸夹紧");
CylinderMove(MoveInfo, IO_Type.ClampCylinder_Tighten, IO_Type.ClampCylinder_Slack); CylinderMove(MoveInfo, IO_Type.ClampCylinder_Tighten, IO_Type.ClampCylinder_Slack);
} }
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_08_CylinderOpen)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_08_CylinderOpen))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MI_09_CylinderUp); MoveInfo.NextMoveStep(LineMoveStep.MI_09_CylinderUp);
InLog("入库 " + MoveInfo.SLog + ": 上下气缸上升"); InLog("入库 " + MoveInfo.SLog + ": 上下气缸上升");
UpdownUpMove(); UpdownUpMove();
} }
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_09_CylinderUp)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_09_CylinderUp))
...@@ -265,7 +265,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -265,7 +265,7 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_13_UpdownCylinderUp)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_13_UpdownCylinderUp))
{ {
MoveInfo.NextMoveStep(LineMoveStep.MI_14_CylinderAfter); MoveInfo.NextMoveStep(LineMoveStep.MI_14_CylinderAfter);
InLog("入库 " + MoveInfo.SLog + ",前后气缸后退,等待1000 "); InLog("入库 " + MoveInfo.SLog + ",前后气缸后退,等待1000 ");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After); CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000)); MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
//此时box就可以入库操作了 //触发事件,BOX入库 //此时box就可以入库操作了 //触发事件,BOX入库
...@@ -286,12 +286,12 @@ namespace OnlineStore.DeviceLibrary ...@@ -286,12 +286,12 @@ namespace OnlineStore.DeviceLibrary
//判断料仓是否在入库中,如果么有在入库中,需要重新发送入库消息 //判断料仓是否在入库中,如果么有在入库中,需要重新发送入库消息
if (!LineServer.IsInStorePro(DeviceID)) if (!LineServer.IsInStorePro(DeviceID))
{ {
InLog("入库 " + MoveInfo.SLog + " , 送料流程完成,料仓还未开始入库,再次发送starIn命令"); InLog("入库 " + MoveInfo.SLog + " , 送料流程完成,料仓还未开始入库,再次发送starIn命令");
LineServer.StartInStore(DeviceID, MoveInfo.MoveParam); LineServer.StartInStore(DeviceID, MoveInfo.MoveParam);
} }
else else
{ {
InLog("入库 " + MoveInfo.SLog + " , 送料流程完成,料仓已开始入库"); InLog("入库 " + MoveInfo.SLog + " , 送料流程完成,料仓已开始入库");
} }
} }
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_16_SendEnd)) else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_16_SendEnd))
......
...@@ -40,7 +40,7 @@ namespace OnlineStore.LoadCSVLibrary ...@@ -40,7 +40,7 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary> /// </summary>
public static string Reset_BTN = "Reset_BTN"; public static string Reset_BTN = "Reset_BTN";
/// <summary> /// <summary>
/// DI 0 启动 Start_BTN 2 启动 X03 DI-03 /// DI 0 启动 Start_BTN 2 联动按钮 X03 DI-03
/// </summary> /// </summary>
public static string Start_BTN = "Start_BTN"; public static string Start_BTN = "Start_BTN";
/// <summary> /// <summary>
...@@ -51,71 +51,8 @@ namespace OnlineStore.LoadCSVLibrary ...@@ -51,71 +51,8 @@ namespace OnlineStore.LoadCSVLibrary
/// DI 0 气压检测 Airpressure_Check 4 气压检测 X05 DI-05 /// DI 0 气压检测 Airpressure_Check 4 气压检测 X05 DI-05
/// </summary> /// </summary>
public static string Airpressure_Check = "Airpressure_Check"; public static string Airpressure_Check = "Airpressure_Check";
///// <summary>
///// DI 0 上料工位料盘检测1 InStore_TrayCheck1 5 上料工位料盘检测1 X06 DI-06
///// </summary>
//public static string InStore_TrayCheck1 = "InStore_TrayCheck1";
///// <summary>
///// DI 0 上料工位料盘检测2 InStore_TrayCheck2 6 上料工位料盘检测2 X07 DI-07
///// </summary>
//public static string InStore_TrayCheck2 = "InStore_TrayCheck2";
///// <summary>
///// DI 0 阻挡0-1夹具检测 StopCylinder_Check 7 阻挡0-1夹具检测 X08 DI-08
///// </summary>
//public static string StopCylinder_Check = "StopCylinder_Check";
///// <summary>
///// DI 0 上料工位夹具检测0-1 Fixture_Check_1 8 上料工位夹具检测0-1 X09 DI-09
///// </summary>
//public static string Fixture_Check_1 = "Fixture_Check_1";
///// <summary>
///// DI 0 上料工位夹具检测0-2 Fixture_Check_2 9 上料工位夹具检测0-2 X10 DI-10
///// </summary>
//public static string Fixture_Check_2 = "Fixture_Check_2";
///// <summary>
///// DI 0 上料工位夹具检测0-3 Fixture_Check_3 10 上料工位夹具检测0-3 X11 DI-11
///// </summary>
//public static string Fixture_Check_3 = "Fixture_Check_3";
///// <summary>
///// DI 0 上料工位夹具检测0-4 Fixture_Check_4 11 上料工位夹具检测0-4 X12 DI-12
///// </summary>
//public static string Fixture_Check_4 = "Fixture_Check_4";
///// <summary>
///// DI 0 横移轨道1阻挡夹具检测 SidesWay1_StopFixtureCheck 14 横移轨道1阻挡夹具检测 X15 DI-15
///// </summary>
//public static string SidesWay1_StopFixtureCheck = "SidesWay1_StopFixtureCheck";
///// <summary>
///// DI 0 横移轨道1夹具检测 SidesWay1_FixtureCheck 15 横移轨道1夹具检测 X16 DI-16
///// </summary>
//public static string SidesWay1_FixtureCheck = "SidesWay1_FixtureCheck";
///// <summary>
///// DI 0 横移轨道1顶升气缸上升端 SidesWay1_TopCylinder_Up 16 横移轨道1顶升气缸上升端 X17 DI-17
///// </summary>
//public static string SidesWay1_TopCylinder_Up = "SidesWay1_TopCylinder_Up";
///// <summary>
///// DI 0 横移轨道1顶升气缸下降端 SidesWay1_TopCylinder_Down 17 横移轨道1顶升气缸下降端 X18 DI-18
///// </summary>
//public static string SidesWay1_TopCylinder_Down = "SidesWay1_TopCylinder_Down";
///// <summary>
///// DI 0 横移轨道2夹具检测 SidesWay2_FixtureCheck 18 横移轨道2夹具检测 X19 DI-19
///// </summary>
//public static string SidesWay2_FixtureCheck = "SidesWay2_FixtureCheck";
///// <summary>
///// DI 0 横移轨道2顶升气缸上升端 SidesWay2_TopCylinder_Up 19 横移轨道2顶升气缸上升端 X20 DI-20
///// </summary>
//public static string SidesWay2_TopCylinder_Up = "SidesWay2_TopCylinder_Up";
///// <summary>
///// DI 0 横移轨道2顶升气缸下降端 SidesWay2_TopCylinder_Down 20 横移轨道2顶升气缸下降端 X21 DI-21
///// </summary>
//public static string SidesWay2_TopCylinder_Down = "SidesWay2_TopCylinder_Down";
///// <summary>
///// DI 0 驱动电机INV1状态 DriveMotor_INV1 21 驱动电机INV1状态 X22 DI-22
///// </summary>
//public static string DriveMotor_INV1 = "DriveMotor_INV1";
///// <summary>
///// DI 0 驱动电机INV2状态 DriveMotor_INV2 22 驱动电机INV2状态 X23 DI-23
///// </summary>
//public static string DriveMotor_INV2 = "DriveMotor_INV2";
/// <summary> /// <summary>
/// DO 0 待机状态(指示灯) AutoRun_HddLed 24 待机状态(指示灯) Y01 DO-01 /// DO 0 待机状态(指示灯) AutoRun_HddLed 24 待机状态(指示灯) Y01 DO-01
/// </summary> /// </summary>
...@@ -131,21 +68,6 @@ namespace OnlineStore.LoadCSVLibrary ...@@ -131,21 +68,6 @@ namespace OnlineStore.LoadCSVLibrary
///// <summary>
///// DO 0 驱动电机正转 DriveMotorRun 27 驱动电机正转 Y04 DO-04
///// </summary>
//public static string DriveMotorRun = "DriveMotorRun";
///// <summary>
///// DO 0 横移电机1.2驱动 SidesWay12_DriveMotor 28 横移电机1.2驱动 Y05 DO-05
///// </summary>
//public static string SidesWay12_DriveMotor = "SidesWay12_DriveMotor";
///// <summary>
///// DO 0 横移电机3.4驱动 SidesWay34_DriveMotor 29 横移电机3.4驱动 Y06 DO-06
///// </summary>
//public static string SidesWay34_DriveMotor = "SidesWay34_DriveMotor";
/// <summary> /// <summary>
/// DO 0 阻挡气缸0-1下降SOL StopCylinder_Down1 16 阻挡气缸0-1下降SOL Y11 DO-11 /// DO 0 阻挡气缸0-1下降SOL StopCylinder_Down1 16 阻挡气缸0-1下降SOL Y11 DO-11
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!