Commit de5831f7 LN

夹爪气缸检测信号修改。

1 个父辈 2540daa0
此文件类型无法预览
......@@ -392,7 +392,7 @@ namespace OnlineStore.AssemblyLine
private void btnFeedSideWayCylinder_Click(object sender, EventArgs e)
{
if (equipBean.MoveCylineIsUp())
if (equipBean.UpdownIsUp())
{
BtnMove(btnFeedSideWayCylinder, "上料横移气缸取料端", "上料横移气缸放料端", IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
}
......
......@@ -3,10 +3,20 @@
新建项目,SO664环形线
移栽修改:夹紧信号需要拿料,气缸上升之后再检测。
上料修改:夹紧信号需要拿料,气缸上升之后再检测。
新加固定气缸,固定气缸固定之后,定位气缸再动作
定位工位的顶升气缸只有在横移料架离开的时候才用。
出料线分为两种。
上料环形线托盘处理模块放入横移处理中,或者T3-C1处理。
夹爪气缸修改。上料模块增加固定气缸
......
......@@ -223,8 +223,8 @@ DI,105,T5料盘检测15寸,SL_TrayCheck4,87,HC,X87
DI,105,T5伺服定位料盘检测,SL_AxisLocationCheck,88,HC,X88
DI,105,T5上料横移气缸取料端,SL_MoveCylinder_Take,89,HC,X89
DI,105,T5上料横移气缸放料端,SL_MoveCylinder_Give,90,HC,X90
DI,105,T5上料气缸放松端,SL_MoveCylinder_Relax,91,HC,X91
DI,105,T5上料气缸料盘检测,SL_MoveCylinder_Check,92,HC,X92
DI,105,T5上料气缸放松端,SL_ClampCylinder_Relax,91,HC,X91
DI,105,T5上料气缸料盘检测,SL_ClampCylinder_Check,92,HC,X92
,,,,93,HC,X93
,,,,94,HC,X94
,,,,95,HC,X95
......@@ -264,8 +264,8 @@ DO,105,T5顶升上升,SL_TopCylinder_Up,78,HC,Y78
DO,105,T5顶升下降,SL_TopCylinder_Down,79,HC,Y79
DO,105,T5上料横移气缸取料,SL_MoveCylinder_Take,80,HC,Y80
DO,105,T5上料横移气缸放料,SL_MoveCylinder_Give,81,HC,Y81
DO,105,T5上料气缸放松,SL_MoveCylinder_Relax,82,HC,Y82
DO,105,T5上料气缸夹紧,SL_MoveCylinder_Work,83,HC,Y83
DO,105,T5上料气缸放松,SL_ClampCylinder_Relax,82,HC,Y82
DO,105,T5上料气缸夹紧,SL_ClampCylinder_Work,83,HC,Y83
DO,105,T5托盘定位气缸前进,SL_TrayLocation_Before,84,HC,Y84
DO,105,T5托盘定位气缸后退,SL_TrayLocation_After,85,HC,Y85
DO,219,HY19横移顶升上升,HY_TopCylinder_UP,86,HC,Y86
......@@ -309,8 +309,8 @@ DI,104,T4料盘检测15寸,SL_TrayCheck4,135,HC,X135
DI,104,T4伺服定位料盘检测,SL_AxisLocationCheck,136,HC,X136
DI,104,T4上料横移气缸取料端,SL_MoveCylinder_Take,137,HC,X137
DI,104,T4上料横移气缸放料端,SL_MoveCylinder_Give,138,HC,X138
DI,104,T4上料气缸放松端,SL_MoveCylinder_Relax,139,HC,X139
DI,104,T4上料气缸料盘检测,SL_MoveCylinder_Check,140,HC,X140
DI,104,T4上料气缸放松端,SL_ClampCylinder_Relax,139,HC,X139
DI,104,T4上料气缸料盘检测,SL_ClampCylinder_Check,140,HC,X140
DI,104,T4出口检测,SL_OutLine_Check,141,HC,X141
,,,,142,HC,X142
,,,,143,HC,X143
......@@ -351,8 +351,8 @@ DO,104,T4顶升上升,SL_TopCylinder_Up,112,HC,Y112
DO,104,T4顶升下降,SL_TopCylinder_Down,113,HC,Y113
DO,104,T4上料横移气缸取料,SL_MoveCylinder_Take,114,HC,Y114
DO,104,T4上料横移气缸放料,SL_MoveCylinder_Give,115,HC,Y115
DO,104,T4上料气缸放松,SL_MoveCylinder_Relax,116,HC,Y116
DO,104,T4上料气缸夹紧,SL_MoveCylinder_Work,117,HC,Y117
DO,104,T4上料气缸放松,SL_ClampCylinder_Relax,116,HC,Y116
DO,104,T4上料气缸夹紧,SL_ClampCylinder_Work,117,HC,Y117
DO,104,T4托盘定位气缸前进,SL_TrayLocation_Before,118,HC,Y118
DO,104,T4托盘定位气缸后退,SL_TrayLocation_After,119,HC,Y119
DO,218,HY18横移顶升上升,HY_TopCylinder_UP,120,HC,Y120
......@@ -564,8 +564,8 @@ DI,103,T3料盘检测15寸,SL_TrayCheck4,263,HC,X263
DI,103,T3伺服定位料盘检测,SL_AxisLocationCheck,264,HC,X264
DI,103,T3上料横移气缸取料端,SL_MoveCylinder_Take,265,HC,X265
DI,103,T3上料横移气缸放料端,SL_MoveCylinder_Give,266,HC,X266
DI,103,T3上料气缸放松端,SL_MoveCylinder_Relax,267,HC,X267
DI,103,T3上料气缸料盘检测,SL_MoveCylinder_Check,268,HC,X268
DI,103,T3上料气缸放松端,SL_ClampCylinder_Relax,267,HC,X267
DI,103,T3上料气缸料盘检测,SL_ClampCylinder_Check,268,HC,X268
DI,103,T3出口检测,SL_OutLine_Check,269,HC,X269
,,,,270,HC,X270
,,,,271,HC,X271
......@@ -588,8 +588,8 @@ DO,103,T3顶升上升,SL_TopCylinder_Up,222,HC,Y222
DO,103,T3顶升下降,SL_TopCylinder_Down,223,HC,Y223
DO,103,T3上料横移气缸取料,SL_MoveCylinder_Take,224,HC,Y224
DO,103,T3上料横移气缸放料,SL_MoveCylinder_Give,225,HC,Y225
DO,103,T3上料气缸放松,SL_MoveCylinder_Relax,226,HC,Y226
DO,103,T3上料气缸夹紧,SL_MoveCylinder_Work,227,HC,Y227
DO,103,T3上料气缸放松,SL_ClampCylinder_Relax,226,HC,Y226
DO,103,T3上料气缸夹紧,SL_ClampCylinder_Work,227,HC,Y227
DO,103,T3托盘定位气缸前进,SL_TrayLocation_Before,228,HC,Y228
DO,103,T3托盘定位气缸后退,SL_TrayLocation_After,229,HC,Y229
,,,,230,HC,Y230
......@@ -802,8 +802,8 @@ DI,101,T1料盘检测15寸,SL_TrayCheck4,375,HC,X375
DI,101,T1伺服定位料盘检测,SL_AxisLocationCheck,376,HC,X376
DI,101,T1上料横移气缸取料端,SL_MoveCylinder_Take,377,HC,X377
DI,101,T1上料横移气缸放料端,SL_MoveCylinder_Give,378,HC,X378
DI,101,T1上料气缸放松端,SL_MoveCylinder_Relax,379,HC,X379
DI,101,T1上料气缸料盘检测,SL_MoveCylinder_Check,380,HC,X380
DI,101,T1上料气缸放松端,SL_ClampCylinder_Relax,379,HC,X379
DI,101,T1上料气缸料盘检测,SL_ClampCylinder_Check,380,HC,X380
,,,,381,HC,X381
,,,,382,HC,X382
,,,,383,HC,X383
......@@ -843,8 +843,8 @@ DO,101,T1顶升上升,SL_TopCylinder_Up,334,HC,Y334
DO,101,T1顶升下降,SL_TopCylinder_Down,335,HC,Y335
DO,101,T1上料横移气缸取料,SL_MoveCylinder_Take,336,HC,Y336
DO,101,T1上料横移气缸放料,SL_MoveCylinder_Give,337,HC,Y337
DO,101,T1上料气缸放松,SL_MoveCylinder_Relax,338,HC,Y338
DO,101,T1上料气缸夹紧,SL_MoveCylinder_Work,339,HC,Y339
DO,101,T1上料气缸放松,SL_ClampCylinder_Relax,338,HC,Y338
DO,101,T1上料气缸夹紧,SL_ClampCylinder_Work,339,HC,Y339
DO,101,T1托盘定位气缸前进,SL_TrayLocation_Before,340,HC,Y340
DO,101,T1托盘定位气缸后退,SL_TrayLocation_After,341,HC,Y341
DO,201,HY1横移顶升上升,HY_TopCylinder_UP,342,HC,Y342
......@@ -888,8 +888,8 @@ DI,102,T2料盘检测15寸,SL_TrayCheck4,423,HC,X423
DI,102,T2伺服定位料盘检测,SL_AxisLocationCheck,424,HC,X424
DI,102,T2上料横移气缸取料端,SL_MoveCylinder_Take,425,HC,X425
DI,102,T2上料横移气缸放料端,SL_MoveCylinder_Give,426,HC,X426
DI,102,T2上料气缸放松端,SL_MoveCylinder_Relax,427,HC,X427
DI,102,T2上料气缸料盘检测,SL_MoveCylinder_Check,428,HC,X428
DI,102,T2上料气缸放松端,SL_ClampCylinder_Relax,427,HC,X427
DI,102,T2上料气缸料盘检测,SL_ClampCylinder_Check,428,HC,X428
,,,,429,HC,X429
,,,,430,HC,X430
,,,,431,HC,X431
......@@ -930,8 +930,8 @@ DO,102,T2顶升上升,SL_TopCylinder_Up,367,HC,Y367
DO,102,T2顶升下降,SL_TopCylinder_Down,368,HC,Y368
DO,102,T2上料横移气缸取料,SL_MoveCylinder_Take,369,HC,Y369
DO,102,T2上料横移气缸放料,SL_MoveCylinder_Give,370,HC,Y370
DO,102,T2上料气缸放松,SL_MoveCylinder_Relax,371,HC,Y371
DO,102,T2上料气缸夹紧,SL_MoveCylinder_Work,372,HC,Y372
DO,102,T2上料气缸放松,SL_ClampCylinder_Relax,371,HC,Y371
DO,102,T2上料气缸夹紧,SL_ClampCylinder_Work,372,HC,Y372
DO,102,T2托盘定位气缸前进,SL_TrayLocation_Before,373,HC,Y373
DO,102,T2托盘定位气缸后退,SL_TrayLocation_After,374,HC,Y374
DO,202,HY2横移顶升上升,HY_TopCylinder_UP,375,HC,Y375
......
......@@ -124,23 +124,11 @@ namespace OnlineStore.DeviceLibrary
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW);
IOMove(IO_Type.SL_Out_StopDown, IO_VALUE.LOW);
//夹紧气缸放松
CylinderMove(null, IO_Type.SL_MoveCylinder_Relax, IO_Type.SL_MoveCylinder_Work);
CylinderMove(null, IO_Type.SL_ClampCylinder_Relax, IO_Type.SL_ClampCylinder_Work);
if (Config.DOList.ContainsKey(IO_Type.SL_RollerLine_Run))
{
IOMove(IO_Type.SL_RollerLine_Run, IO_VALUE.LOW);
}
//if (Config.SidesWayNum <= 0)
//{
// CheckAndMove(IO_Type.FL_StopCylinder_Down1, IO_VALUE.LOW);
// CheckAndMove(IO_Type.FL_StopCylinder_Down2, IO_VALUE.LOW);
// //顶升气缸下降
// CylinderMove(null, IO_Type.FL_TopCylinder_Up, IO_Type.FL_TopCylinder_Down);
//}
//else if (LineManager.Line.runStatus <= LineRunStatus.Wait)
//{
// 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));
......@@ -190,17 +178,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationSideWay_Run, IO_VALUE.LOW));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_OutSideWay_Run, IO_VALUE.LOW));
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
//if (Config.SidesWayNum <= 0)
//{
// //顶升气缸下降
// CylinderMove(MoveInfo, IO_Type.FL_TopCylinder_Up, IO_Type.FL_TopCylinder_Down);
//}
//else if (LineManager.Line.runStatus <= LineRunStatus.Wait)
//{
// CylinderMove(MoveInfo, IO_Type.SW_LocationCylinder_Up, IO_Type.SW_LocationCylinder_Down);
// CylinderMove(MoveInfo, IO_Type.SW_TopCylinder_Up, IO_Type.SW_TopCylinder_Down);
//}
break;
case LineMoveStep.FR_03_CylinderUp:
MoveInfo.NextMoveStep(LineMoveStep.FR_04_UpdownAxisHome);
......@@ -215,9 +193,8 @@ namespace OnlineStore.DeviceLibrary
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
break;
case LineMoveStep.FR_05_UpdownAxis_P1:
if (MoveCylineIsUp())
{
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FR_06_CylinderGive);
if (Config.IsCanOut.Equals(1))
{
......@@ -233,8 +210,8 @@ namespace OnlineStore.DeviceLibrary
else
{
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);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":上料横移机构取料端 前升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
break;
case LineMoveStep.FR_06_CylinderGive:
......@@ -252,22 +229,28 @@ namespace OnlineStore.DeviceLibrary
break;
case LineMoveStep.FR_12_BatchAxisToP2:
MoveInfo.NextMoveStep(LineMoveStep.FR_13_LocationDown);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 放开定位气缸,升降伺服到P1");
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 托盘定位气缸后退,升降伺服到P1");
TrayLCylinderAfter(MoveInfo);
Thread.Sleep(50);
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
break;
case LineMoveStep.FR_13_LocationDown:
MoveInfo.NextMoveStep(LineMoveStep.FR_14_TopDown);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":SL1定位气缸下降SOL,出口顶升气缸下降,夹紧气缸放松");
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Work, IO_Type.SL_MoveCylinder_Relax );
MoveInfo.NextMoveStep(LineMoveStep.FR_14_FixedDown);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ":固定气缸下降");
FixedCylinderDown(MoveInfo);
break;
case LineMoveStep.FR_14_TopDown:
case LineMoveStep.FR_14_FixedDown:
MoveInfo.NextMoveStep(LineMoveStep.FR_15_TopDown);
LogInfo(MoveInfo.MoveType + ":" + MoveInfo.SLog + ": 定位气缸下降 ,出口顶升气缸下降,夹紧气缸放松");
LocationCylinderDown(MoveInfo);
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Work, IO_Type.SL_ClampCylinder_Relax );
break;
case LineMoveStep.FR_15_TopDown:
MoveInfo.NextMoveStep(LineMoveStep.FR_15_BatchAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FR_16_BatchAxisToP1);
//判断定位工位是否有料架
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
......@@ -279,7 +262,13 @@ namespace OnlineStore.DeviceLibrary
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
}
break;
case LineMoveStep.FR_15_BatchAxisToP1:
case LineMoveStep.FR_16_BatchAxisToP1:
MoveInfo.NextMoveStep(LineMoveStep.FR_17_ClampCheck);
DebugInfo(MoveInfo.MoveType + " : 等待夹爪料盘检测信号无料");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.LOW));
break;
case LineMoveStep.FR_17_ClampCheck:
LogInfo("重置完成!");
if (IOValue(IO_Type.SL_Out_Check).Equals(IO_VALUE.HIGH))
{
......@@ -511,9 +500,56 @@ namespace OnlineStore.DeviceLibrary
//CheckAndMove(IO_Type.SL_MoveCylinder_Up, IO_VALUE.LOW);
}
/// <summary>
/// 升降盘定位气缸前进
/// </summary>
#region 气缸判断及动作
public void LocationCylinderUp(LineMoveInfo moveinfo = null)
{
IOMove(IO_Type.SL_LocationCylinder_Down, IO_VALUE.LOW);
IOMove(IO_Type.SL_LocationCylinder_Up, IO_VALUE.HIGH);
if (moveinfo != null)
{
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Down1, IO_VALUE.LOW));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Up1, IO_VALUE.HIGH));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Down2, IO_VALUE.LOW));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Up2, IO_VALUE.HIGH));
}
}
public void LocationCylinderDown(LineMoveInfo moveinfo = null)
{
IOMove(IO_Type.SL_LocationCylinder_Up, IO_VALUE.LOW);
IOMove(IO_Type.SL_LocationCylinder_Down, IO_VALUE.HIGH);
if (moveinfo != null)
{
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Up1, IO_VALUE.LOW));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Down1, IO_VALUE.HIGH));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Up2, IO_VALUE.LOW));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_LocationCylinder_Down2, IO_VALUE.HIGH));
}
}
public void FixedCylinderUp(LineMoveInfo moveinfo = null)
{
IOMove(IO_Type.SL_FixedCylinder_Down, IO_VALUE.LOW);
IOMove(IO_Type.SL_FixedCylinder_Up, IO_VALUE.HIGH);
if (moveinfo != null)
{
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_FixedCylinder_Up1, IO_VALUE.HIGH));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_FixedCylinder_Up2, IO_VALUE.HIGH));
}
}
public void FixedCylinderDown(LineMoveInfo moveinfo = null)
{
IOMove(IO_Type.SL_FixedCylinder_Up, IO_VALUE.LOW);
IOMove(IO_Type.SL_FixedCylinder_Down, IO_VALUE.HIGH);
if (moveinfo != null)
{
moveinfo.WaitList.Add(WaitResultInfo.WaitTime(2000));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_FixedCylinder_Up1, IO_VALUE.LOW));
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_FixedCylinder_Up2, IO_VALUE.LOW));
}
}
public void TrayLCylinderBefore(LineMoveInfo moveinfo = null)
{
IOMove(IO_Type.SL_TrayLocation_After, IO_VALUE.LOW);
......@@ -526,9 +562,7 @@ namespace OnlineStore.DeviceLibrary
moveinfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_TrayLocation2_Before, IO_VALUE.HIGH));
}
}
/// <summary>
/// 升降盘定位气缸后退
/// </summary>
public void TrayLCylinderAfter(LineMoveInfo moveinfo = null)
{
if (TrayLCylinderCanAfter())
......@@ -571,9 +605,7 @@ namespace OnlineStore.DeviceLibrary
}
return false;
}
/// <summary>
/// 升降盘是否在后退端
/// </summary>
public bool IsTrayLCylinderAfter()
{
......@@ -587,20 +619,19 @@ namespace OnlineStore.DeviceLibrary
return false;
}
/// <summary>
/// 判断上料横移机构是否可以横移运动
/// </summary>
/// <returns></returns>
public bool MoveCylineIsUp()
public bool UpdownIsUp()
{
//if(CylinderIsOk(IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up))
// if (IOValue(IO_Type.SL_MoveCylinder_Down).Equals(IO_VALUE.LOW) && IOValue(IO_Type.SL_MoveCylinder_Up).Equals(IO_VALUE.HIGH))
if (UpdownAxis.IsInPosition(Config.UpDownAxisP1))
{
return true;
}
return false;
}
#endregion
#region 提升轴匀速上升处理
private System.Timers.Timer axisCheckTimer = null;
private string TargetIoType = IO_Type.SL_AxisLocationCheck;
......@@ -836,7 +867,7 @@ namespace OnlineStore.DeviceLibrary
}
//等待200毫秒后停止转动
Thread.Sleep(5000);
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_03_LineStart))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_05_LineStart))
{
LogUtil.info(logName + " 等待5000后, MoveInfo.MoveType= FI_03_LineStart 不需要停止链条转动");
}
......
......@@ -50,7 +50,7 @@ namespace OnlineStore.DeviceLibrary
}
public override void CheckAlarmProcess(LineMoveInfo moveInfo, LineAlarmType alarmType)
{
if (moveInfo.MoveStep.Equals(LineMoveStep.FI_18_WaitNoLocationCheck) && alarmType.Equals(LineAlarmType.IoSingleTimeOut))
if (moveInfo.MoveStep.Equals(LineMoveStep.FI_25_CheckTray) && alarmType.Equals(LineAlarmType.IoSingleTimeOut))
{
string code = CodeManager.ProcessCode(NextCodeList);
if (!String.IsNullOrEmpty(code))
......@@ -567,12 +567,12 @@ namespace OnlineStore.DeviceLibrary
{
if (IsTrayLCylinderAfter())
{
MoveInfo.NextMoveStep(LineMoveStep.FI_01_TrayLocation_After);
MoveInfo.NextMoveStep(LineMoveStep.FI_02_TrayLocation_After);
InLog("检测到料架, " + MoveInfo.MoveStep + " :升降盘定位气缸下降");
TrayLCylinderAfter(MoveInfo);
}else
{
MoveInfo.NextMoveStep(LineMoveStep.FI_00_BatchAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FI_01_BatchAxisToP2);
OutLog("检测到料架,升降盘不在后退端 " + MoveInfo.SLog + " :提升伺服先回到P2");
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
}
......@@ -583,7 +583,7 @@ namespace OnlineStore.DeviceLibrary
private void FI_04_WaitTime()
{
//定位工位有料架,等待1秒后再次检测
MoveInfo.NextMoveStep(LineMoveStep.FI_04_WaitTime);
MoveInfo.NextMoveStep(LineMoveStep.FI_06_WaitTime);
InLog("定位工位检测到料架: " + MoveInfo.SLog + ",进料阻挡上升,缓冲阻挡上升, 等待3秒再次检测");
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW);
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW);
......@@ -603,7 +603,7 @@ namespace OnlineStore.DeviceLibrary
//阻挡工位有料架,流水线转动一个工位
else if (IOValue(IO_Type.SL_Stop_Check).Equals(IO_VALUE.HIGH))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_03_LineStart);
MoveInfo.NextMoveStep(LineMoveStep.FI_05_LineStart);
InLog("入料检测: " + MoveInfo.SLog + " 阻挡工位有新料架,清理缓存料架RFID ,进料阻挡下降500,缓冲阻挡前进1000,流水线转动 1000");
UpdateLastShelfID();
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.HIGH, 500);//进料阻挡下降
......@@ -616,7 +616,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Line_Run, IO_VALUE.HIGH));
} else if (IOValue(IO_Type.SL_Entry_Check).Equals(IO_VALUE.HIGH))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_03_LineStart);
MoveInfo.NextMoveStep(LineMoveStep.FI_05_LineStart);
InLog("入料检测: " + MoveInfo.SLog + " 进料口有新料架,进料阻挡上升,缓冲阻挡前进1000,流水线转动 1000");
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW);//进料阻挡上升
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.HIGH, 1000);//缓冲阻挡前进1000
......@@ -648,28 +648,34 @@ namespace OnlineStore.DeviceLibrary
return;
}
#region 入料:料架进入并开始检测托盘
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_00_BatchAxisToP2))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_01_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_01_TrayLocation_After);
MoveInfo.NextMoveStep(LineMoveStep.FI_02_TrayLocation_After);
InLog("料架入库" + MoveInfo.SLog + " :升降盘定位气缸下降");
TrayLCylinderAfter(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_01_TrayLocation_After))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_02_TrayLocation_After))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_02_LocationCylinder_Down);
MoveInfo.NextMoveStep(LineMoveStep.FI_03_LocationDown);
InLog("料架入库" + MoveInfo.SLog + ":定位气缸下降,提升伺服移动到P1");
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
LocationCylinderDown(MoveInfo);
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_02_LocationCylinder_Down))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_03_LocationDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_04_FixedDown);
InLog("料架入库" + MoveInfo.SLog + ":固定气缸下降");
FixedCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_04_FixedDown))
{
LineInStoreProcess();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_03_LineStart))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_05_LineStart))
{
LineInStoreProcess();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_04_WaitTime))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_06_WaitTime))
{
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
......@@ -677,19 +683,19 @@ namespace OnlineStore.DeviceLibrary
if (CurrShelfId.EndsWith("00"))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_33_BatchAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FI_53_BatchAxisToP1);
InLog("料架号【" + CurrShelfId + "】无效,送出料架," + MoveInfo.SLog + ":提升伺服到P1点,定位气缸下降");
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
LocationCylinderDown(MoveInfo);
}
else
{
MoveInfo.ShelfNoTray = false;
//定位工位有料架,直接开始入料
MoveInfo.NextMoveStep(LineMoveStep.FI_05_LocationCylinder_Up);
InLog("定位工位检测到料架: " + MoveInfo.SLog + " 缓冲阻挡上升, 定位气缸上升,读取并缓存料架RFID" + CurrShelfId);
MoveInfo.NextMoveStep(LineMoveStep.FI_07_FixedUp);
InLog("定位工位检测到料架: " + MoveInfo.SLog + " 缓冲阻挡上升, 固定气缸上升,读取并缓存料架RFID" + CurrShelfId);
UpdateLastShelfID(CurrShelfId);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Down, IO_Type.SL_LocationCylinder_Up);
FixedCylinderUp(MoveInfo);
}
}
else
......@@ -699,44 +705,49 @@ namespace OnlineStore.DeviceLibrary
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_05_LocationCylinder_Up))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_07_FixedUp))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_08_LocationUp);
InLog("定位工位检测到料架: " + MoveInfo.SLog + " 定位气缸上升");
LocationCylinderUp(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_08_LocationUp))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_06_BatchAxisToP2);
InLog("料架入库" + MoveInfo.SLog + ":提升轴下降到位P2,定位气缸上升");
MoveInfo.NextMoveStep(LineMoveStep.FI_11_BatchAxisToP2);
InLog("料架入库" + MoveInfo.SLog + ":提升轴下降到位P2 ");
if (!ProcessShelfEnter)
{
IOMove(IO_Type.SL_Line_Run, IO_VALUE.LOW);
}
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Down, IO_Type.SL_LocationCylinder_Up);
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_06_BatchAxisToP2))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_11_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_07_TrayLocation_Before);
MoveInfo.NextMoveStep(LineMoveStep.FI_12_TrayLocation_Before);
InLog("料架入库" + MoveInfo.SLog + ":升降盘定位气缸第一次前进 2秒,清空条码信息");
LastCodeList = new List<string>();
NextCodeList = new List<string>();
TrayLCylinderBefore(null);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(2000));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_07_TrayLocation_Before))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_12_TrayLocation_Before))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_08_TrayLocation_Back);
MoveInfo.NextMoveStep(LineMoveStep.FI_13_TrayLocation_Back);
InLog("料架入库" + MoveInfo.SLog + ":升降盘定位气缸后退,等待再次前进");
TrayLCylinderAfter(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_08_TrayLocation_Back))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_13_TrayLocation_Back))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_09_TrayLocation_Before);
MoveInfo.NextMoveStep(LineMoveStep.FI_14_TrayLocation_Before);
InLog("料架入库" + MoveInfo.SLog + ":升降盘定位气缸前进,清空条码信息");
LastCodeList = new List<string>();
NextCodeList = new List<string>();
TrayLCylinderBefore(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_09_TrayLocation_Before))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_14_TrayLocation_Before))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_10_AxisUpMove);
MoveInfo.NextMoveStep(LineMoveStep.FI_15_AxisUpMove);
InLog("料架入库" + MoveInfo.SLog + ":上料轴开始慢速上升到P3点,等待检测到料盘");
MoveInfo.ShelfNoTray = false;
BatchAxisToP3();
......@@ -744,23 +755,23 @@ namespace OnlineStore.DeviceLibrary
#endregion
#region 检测到托盘,扫码,取料并放入托盘
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_10_AxisUpMove))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_15_AxisUpMove))
{
CheckHasTray();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_11_CylinderUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_16_CylinderUp))
{
FI_12_MoveCylinder_Give();
FI_17_CylinderGive();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_12_CylinderGive))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_17_CylinderGive))
{
FI_13_ScanCode();
FI_18_ScanCode();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_13_ScanCode))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_18_ScanCode))
{
if (ScanCodeTask == null || ScanCodeTask.IsCompleted)
{
MoveInfo.NextMoveStep(LineMoveStep.FI_14_CylinderTake);
MoveInfo.NextMoveStep(LineMoveStep.FI_21_CylinderTake);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移取料端");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
ClearTimeoutAlarm("扫码执行结束超时");
......@@ -772,61 +783,65 @@ namespace OnlineStore.DeviceLibrary
Alarm(LineAlarmType.IoSingleTimeOut);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_14_CylinderTake))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_21_CylinderTake))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_15_UpdownAxisToP3);
MoveInfo.NextMoveStep(LineMoveStep.FI_22_UpdownAxisToP3);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴到P3");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP3, Config.UpdownAxis_P3Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_15_UpdownAxisToP3))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_22_UpdownAxisToP3))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_16_CylinderTighten);
MoveInfo.NextMoveStep(LineMoveStep.FI_23_CylinderTighten);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移机构夹紧");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Relax, IO_Type.SL_MoveCylinder_Work);
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Relax, IO_Type.SL_ClampCylinder_Work);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_16_CylinderTighten))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_23_CylinderTighten))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_17_UpdownAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FI_24_UpdownAxisToP1);
InLog("料盘移栽" + MoveInfo.SLog + ":升降伺服到P1点");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_17_UpdownAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_24_UpdownAxisToP1))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_18_WaitNoLocationCheck);
InLog("料盘移栽" + MoveInfo.SLog + ":等待 SL_AxisLocationCheck=LOW");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_AxisLocationCheck, IO_VALUE.LOW));
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FI_25_CheckTray);
InLog("料盘移栽" + MoveInfo.SLog + ":等待 SL_ClampCylinder_Check=HIGH,SL_AxisLocationCheck=LOW");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_ClampCylinder_Check, IO_VALUE.HIGH));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_AxisLocationCheck, IO_VALUE.LOW));
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FI_24_UpdownAxisToP1);
InLog("料盘移栽" + MoveInfo.SLog + ":升降伺服到P1点");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_18_WaitNoLocationCheck))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_25_CheckTray))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_19_BatchAxisToP3);
MoveInfo.NextMoveStep(LineMoveStep.FI_26_BatchAxisToP3);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
LastWidth = GetWidth();
InLog("料盘移栽" + MoveInfo.SLog + ":提升伺服运动到P3,盘宽【" + LastWidth + "】,横移气缸上升 ");
//if (!CylinderIsOk(IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up))
//{
// CylinderMove(null, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
//}
//else
{
CylinderMove(null, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
}
CylinderMove(null, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
BatchAxisToP3(false);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_19_BatchAxisToP3))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_26_BatchAxisToP3))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_20_SaveSize);
if (MoveCylineIsUp())
MoveInfo.NextMoveStep(LineMoveStep.FI_27_SaveSize);
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FI_21_CylinderGive);
MoveInfo.NextMoveStep(LineMoveStep.FI_28_CylinderGive);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移气缸放料SOL");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FI_20_SaveSize);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移气缸放料SOL前先上升横移气缸");
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FI_27_SaveSize);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移机构取料端 前升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
LastHeight = GetHeight();
......@@ -872,23 +887,24 @@ namespace OnlineStore.DeviceLibrary
YuScanCode();
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_20_SaveSize))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_27_SaveSize))
{
if (MoveCylineIsUp())
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FI_21_CylinderGive);
MoveInfo.NextMoveStep(LineMoveStep.FI_28_CylinderGive);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移气缸放料SOL");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FI_20_SaveSize);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移气缸放料SOL前先上升横移气缸");
MoveInfo.NextMoveStep(LineMoveStep.FI_27_SaveSize);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移机构取料端 前升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_21_CylinderGive))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_28_CylinderGive))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_22_BatchAxisDown);
MoveInfo.NextMoveStep(LineMoveStep.FI_29_BatchAxisDown);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
if (!MoveInfo.ShelfNoTray)
{
......@@ -899,28 +915,19 @@ namespace OnlineStore.DeviceLibrary
InLog("料盘移栽" + MoveInfo.SLog + ": " + log + "");
UpdownAxis.AbsMove(MoveInfo, targetPositon, Config.UpdownAxis_P2Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_22_BatchAxisDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_29_BatchAxisDown))
{
//if (Config.DIList.ContainsKey(IO_Type.ReelCheck) && IOValue(IO_Type.ReelCheck).Equals(IO_VALUE.LOW))
//{
// MoveInfo.NextMoveStep(LineMoveStep.FI_23_WaitReelCheck);
// InLog(" " + MoveInfo.SLog + " 等待料盘检测信号:ReelCheck");
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ReelCheck, IO_VALUE.HIGH));
//}
//else
{
FI_24_GetPosID();
}
FI_31_GetPosID();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_23_WaitReelCheck))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_30_WaitReelCheck))
{
FI_24_GetPosID();
FI_31_GetPosID();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_24_GetPosID))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_31_GetPosID))
{
if (getPosTask.IsCompleted && LastPosParam != null)
{
MoveInfo.NextMoveStep(LineMoveStep.FI_25_WaitTray);
MoveInfo.NextMoveStep(LineMoveStep.FI_32_WaitTray);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(100));
InLog(" " + MoveInfo.SLog + " 开始拦截空托盘 " + LastPosParam.ToStr() + "");
......@@ -933,15 +940,15 @@ namespace OnlineStore.DeviceLibrary
Alarm(LineAlarmType.IoSingleTimeOut);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_25_WaitTray))//TODO
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_32_WaitTray))//TODO
{
if (SecondMoveInfo.MoveStep.Equals(LineMoveStep.MO_11_CodeRember))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_26_CylinderDown);
MoveInfo.NextMoveStep(LineMoveStep.FI_33_CylinderDown);
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Up, IO_Type.SL_MoveCylinder_Down);
if (Config.SidesWayNum > 0)
{
// CylinderMove(MoveInfo, IO_Type.SW_LocationCylinder_Down, IO_Type.SW_LocationCylinder_Up);
// CylinderMove(MoveInfo, IO_Type.SW_LocationCylinder_Down, IO_Type.SW_LocationCylinder_Up);
}
LastPosParam.TrayNumber = currTrayNum;
InLog("料盘移栽" + MoveInfo.SLog + ":上料机构下降, 托盘号【" + currTrayNum + "】,更新托盘信息 :" + LastPosParam.ToShortStr());
......@@ -951,7 +958,7 @@ namespace OnlineStore.DeviceLibrary
if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.LOW) && MoveInfo.ShelfNoTray.Equals(false))
{
InLog("获取库位" + MoveInfo.SLog + ": 上料轴开始慢速上升到P3点,不等待结果");
BatchAxisToP3(false,false);
BatchAxisToP3(false, false);
}
}
else if (MoveInfo.IsTimeOut(180))
......@@ -961,29 +968,29 @@ namespace OnlineStore.DeviceLibrary
Alarm(LineAlarmType.IoSingleTimeOut);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_26_CylinderDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_33_CylinderDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_27_CylinderRelax);
MoveInfo.NextMoveStep(LineMoveStep.FI_34_CylinderRelax);
InLog("料盘移栽" + MoveInfo.SLog + ":上料气缸放松");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Work, IO_Type.SL_MoveCylinder_Relax);
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Work, IO_Type.SL_ClampCylinder_Relax);
ClearTimeoutAlarm("等待空托盘到达超时");
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_27_CylinderRelax))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_28_WaitCylinderUp);
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_34_CylinderRelax))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_35_WaitCylinderUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(100));
//MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_MoveCylinder_Down, IO_VALUE.LOW));
//CylinderMove(null, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
TrayPreMove();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_28_WaitCylinderUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_35_WaitCylinderUp))
{
TrayMoveOk();
FI_29_CylinderUp();
FI_36_CylinderUp();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_29_CylinderUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_36_CylinderUp))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_30_UpDownAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FI_37_UpDownAxisToP1);
// InLog("料盘移栽" + MoveInfo.SLog + ":升降伺服到P1点");
TrayMoveOk(true);
if (!UpdownAxis.IsInPosition(Config.UpDownAxisP1))
......@@ -996,7 +1003,7 @@ namespace OnlineStore.DeviceLibrary
InLog("料盘移栽" + MoveInfo.SLog + ":升降轴已在P1点,托盘放行");
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_30_UpDownAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_37_UpDownAxisToP1))
{
if (getPosTask == null || getPosTask.IsCompleted)
{
......@@ -1006,7 +1013,7 @@ namespace OnlineStore.DeviceLibrary
}
BatchAxisStopCheck();
//如果批量轴还在运动中,停止运动
AxisManager.instance.SuddenStop(BatchAxis.Config.DeviceName,BatchAxis.Config.GetAxisValue());
AxisManager.instance.SuddenStop(BatchAxis.Config.DeviceName, BatchAxis.Config.GetAxisValue());
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移机构上升已到位 ");
CheckHasTray();
......@@ -1020,49 +1027,55 @@ namespace OnlineStore.DeviceLibrary
#region 未检测到托盘或放料完成
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_31_BatchAxisToP2))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_51_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_32_TrayLocationCylinder_After);
MoveInfo.NextMoveStep(LineMoveStep.FI_52_TrayLocation_After);
InLog("上料完成" + MoveInfo.SLog + ": 升降盘定位气缸后退, 清理料架信息clearPutInRfid[" + CurrShelfId + "]");
TrayLCylinderAfter(MoveInfo);
SServerManager.clearPutInRfid(Name, CurrShelfId);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_32_TrayLocationCylinder_After))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_52_TrayLocation_After))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_33_BatchAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FI_53_BatchAxisToP1);
InLog("上料完成" + MoveInfo.SLog + ":提升伺服到P1点,定位气缸下降");
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
LocationCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_33_BatchAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_53_BatchAxisToP1))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_34_OutCheck);
MoveInfo.NextMoveStep(LineMoveStep.FI_54_FixedDown);
InLog("上料完成" + MoveInfo.SLog + ",固定气缸下降");
FixedCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_54_FixedDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_55_OutCheck);
InLog("上料完成" + MoveInfo.SLog + ",等待出料线体无料架");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Out_Check, IO_VALUE.LOW));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Out_StopDown, IO_VALUE.LOW));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_34_OutCheck))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_55_OutCheck))
{
if (!ProcessShelfOut)
{
MoveInfo.NextMoveStep(LineMoveStep.FI_35_OutTopCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FI_56_OutTopCylinder_Up);
InLog("上料完成" + MoveInfo.SLog + ",出口顶升气缸上升,出料缓冲阻挡上升");
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Down, IO_Type.SL_OutTopCylinder_Up);
IOMove(IO_Type.SL_Out_StopDown, IO_VALUE.LOW);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_35_OutTopCylinder_Up))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_56_OutTopCylinder_Up))
{
//TODO
MoveInfo.NextMoveStep(LineMoveStep.FI_36_SideWayLineRun);
MoveInfo.NextMoveStep(LineMoveStep.FI_57_SideWayLineRun);
InLog("上料完成" + MoveInfo.SLog + ", 线体横移电机运转,等待料架离开上料工位");
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.LOW));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_36_SideWayLineRun))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_57_SideWayLineRun))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_37_WaitShelfGo);
MoveInfo.NextMoveStep(LineMoveStep.FI_58_WaitShelfGo);
InLog("上料完成" + MoveInfo.SLog + ", 线体横移电机运转,等待料架到达出口");
IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.HIGH);
......@@ -1070,24 +1083,24 @@ namespace OnlineStore.DeviceLibrary
//MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(10000));
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Out_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_37_WaitShelfGo))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_58_WaitShelfGo))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_38_LineStop);
MoveInfo.NextMoveStep(LineMoveStep.FI_59_LineStop);
InLog("上料完成" + MoveInfo.SLog + ", 料架到达出口,线体横移电机停止 ");
IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.LOW);
IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.LOW);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_38_LineStop))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_59_LineStop))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_39_TopDown);
MoveInfo.NextMoveStep(LineMoveStep.FI_60_TopDown);
InLog("上料完成" + MoveInfo.SLog + ", 料架到达出口,出口顶升下降 ,清理缓存料架RFID ");
UpdateLastShelfID();
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_39_TopDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_60_TopDown))
{
MoveEndS();
// MoveInfo.NextMoveStep(LineMoveStep.FI_39_OutLineRun);
......@@ -1100,9 +1113,9 @@ namespace OnlineStore.DeviceLibrary
}
private Task getPosTask = null;
private InOutParam LastPosParam = null;
private void FI_24_GetPosID()
private void FI_31_GetPosID()
{
MoveInfo.NextMoveStep(LineMoveStep.FI_24_GetPosID);
MoveInfo.NextMoveStep(LineMoveStep.FI_31_GetPosID);
InLog("清空LastPosResult,从服务器获取入库库位");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
LastPosParam = null;
......@@ -1159,9 +1172,9 @@ namespace OnlineStore.DeviceLibrary
});
}
private void FI_29_CylinderUp()
private void FI_36_CylinderUp()
{
MoveInfo.NextMoveStep(LineMoveStep.FI_29_CylinderUp);
MoveInfo.NextMoveStep(LineMoveStep.FI_36_CylinderUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
//如果是小料盘,且升降轴需要上升,
......@@ -1262,28 +1275,29 @@ namespace OnlineStore.DeviceLibrary
}
}
}
private void FI_12_MoveCylinder_Give()
private void FI_17_CylinderGive()
{
if (MoveCylineIsUp())
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FI_12_CylinderGive);
InLog("料盘移栽" + MoveInfo.SLog + ":上料机构检测到料盘,横移机构到放料端");
MoveInfo.NextMoveStep(LineMoveStep.FI_17_CylinderGive);
InLog("料盘移栽" + MoveInfo.SLog + ":上料机构检测到料盘,横移机构到放料端,等待夹爪料盘检测=LOW");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_ClampCylinder_Check, IO_VALUE.LOW));
}
else
{
//有料盘
MoveInfo.NextMoveStep(LineMoveStep.FI_11_CylinderUp);
InLog("料盘移栽" + MoveInfo.SLog + ":上料机构检测到料盘,横移机构上升");
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FI_16_CylinderUp);
InLog("料盘移栽" + MoveInfo.SLog + ":上料机构检测到料盘,升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
private Task ScanCodeTask = null;
private void FI_13_ScanCode()
private void FI_18_ScanCode()
{
if (CylinderIsOk(IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give))
{
MoveInfo.NextMoveStep(LineMoveStep.FI_13_ScanCode);
MoveInfo.NextMoveStep(LineMoveStep.FI_18_ScanCode);
bool isScan = ConfigAppSettings.GetIntValue(Setting_Init.NeedScanCode).Equals(1);
LastCodeList = new List<string>();
......@@ -1295,7 +1309,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
LastCodeList = new List<string>(NextCodeList);
NextCodeList = new List<string>();
MoveInfo.NextMoveStep(LineMoveStep.FI_14_CylinderTake);
MoveInfo.NextMoveStep(LineMoveStep.FI_21_CylinderTake);
InLog("料盘移栽" + MoveInfo.SLog + ":上料横移取料端");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
}
......@@ -1334,14 +1348,14 @@ namespace OnlineStore.DeviceLibrary
}
else
{
FI_12_MoveCylinder_Give();
FI_17_CylinderGive();
}
}
private void CheckHasTray()
{
if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.HIGH) && MoveInfo.ShelfNoTray.Equals(false))
{
FI_13_ScanCode();
FI_18_ScanCode();
}
else
{
......@@ -1352,7 +1366,7 @@ namespace OnlineStore.DeviceLibrary
int chaz = Math.Abs(currP - Config.BatchAxisP3);
if (chaz > BatchAxis.Config.CanErrorCountMax)
{
MoveInfo.NextMoveStep(LineMoveStep.FI_10_AxisUpMove);
MoveInfo.NextMoveStep(LineMoveStep.FI_15_AxisUpMove);
InLog("料架入库" + MoveInfo.SLog + ":CheckHasTray:上料轴开始慢速上升到P3点,等待检测到料盘");
MoveInfo.ShelfNoTray = false;
BatchAxisToP3(false );
......@@ -1361,7 +1375,7 @@ namespace OnlineStore.DeviceLibrary
}
//无料盘
MoveInfo.ShelfNoTray = true;
MoveInfo.NextMoveStep(LineMoveStep.FI_31_BatchAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FI_51_BatchAxisToP2);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(3000));
InLog("料盘移栽" + MoveInfo.SLog + ":未检测到料盘,提升伺服到P2点");
BatchAxis.SuddenStop();
......@@ -1524,7 +1538,7 @@ namespace OnlineStore.DeviceLibrary
}
//如果已经开始送出料架,暂不处理
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && MoveInfo.MoveStep >= LineMoveStep.FO_30_BatchAxisToP2)
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && MoveInfo.MoveStep >= LineMoveStep.FO_51_BatchAxisToP2)
{
LogUtil.error(Name + " 【" + info.ToStr() + "】需要出库,正在送出料架,暂不处理", DeviceID * 1000 + 18);
return false;
......@@ -1555,7 +1569,7 @@ namespace OnlineStore.DeviceLibrary
if (trayCanUse && runStatus.Equals(LineRunStatus.Busy) && MoveInfo.MoveType.Equals(LineMoveType.InStore))
{
//入料执行中, 且需要空托盘
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_25_WaitTray) && MoveInfo.IsInWait.Equals(false))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_32_WaitTray) && MoveInfo.IsInWait.Equals(false))
//if (MoveInfo.MoveStep >= LineMoveStep.FI_11_CylinderUp && MoveInfo.MoveStep <= LineMoveStep.FI_20_WaitTray)
{
......@@ -1599,7 +1613,7 @@ namespace OnlineStore.DeviceLibrary
if (runStatus.Equals(LineRunStatus.Busy) && MoveInfo.MoveType.Equals(LineMoveType.InStore))
{
//入料执行中, 且需要空托盘
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_25_WaitTray) && MoveInfo.IsInWait.Equals(false))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FI_32_WaitTray) && MoveInfo.IsInWait.Equals(false))
{
return true;
}
......
......@@ -15,7 +15,7 @@ namespace OnlineStore.DeviceLibrary
private int OutStoreCount = -1;
private TaskData taskData = null;
private InOutParam LastOutParam = new InOutParam();
private bool NeedCheckShelf = true ;
private bool NeedCheckShelf = true;
internal bool CanStartCheckOut(int trayNum)
{
......@@ -46,17 +46,17 @@ namespace OnlineStore.DeviceLibrary
return false;
}
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.LOW) || OutStoreHeight < 0)
{
{
LogUtil.error(Name + "出库" + outParam.ToStr() + "失败,未准备好料架,托盘先离开");
TrayMoveOk();
return false;
}
}
//如果已经开始送出料架,暂不处理
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && MoveInfo.MoveStep >= LineMoveStep.FO_30_BatchAxisToP2)
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && MoveInfo.MoveStep >= LineMoveStep.FO_51_BatchAxisToP2)
{
LogUtil.error(Name + "出库" + outParam.ToStr() + "失败,正在送出料架,托盘先离开");
TrayMoveOk();
TrayMoveOk();
return false;
}
......@@ -68,8 +68,8 @@ namespace OnlineStore.DeviceLibrary
runStatus = LineRunStatus.Busy;
lineStatus = LineStatus.OutStoreExecute;
string lastXuniRfid = LastOutParam.rfid;
if (lastXuniRfid.Equals("") || lastXuniRfid.Equals(outParam.rfid))
{
......@@ -83,7 +83,7 @@ namespace OnlineStore.DeviceLibrary
//如果流水线还有次料架的任务,暂不送出
int count = TrayManager.GetOutTaskByRfid(lastXuniRfid);
if (count <= 0)
{
{
LogUtil.info(Name + "出库" + outParam.ToStr() + "失败,料架号不一致[" + lastXuniRfid + "][" + outParam.rfid + "],当前料架暂时无任务,送出料架,托盘先离开");
TrayMoveOk();
MoveInfo.NewMove(LineMoveType.OutStore, LastOutParam);
......@@ -92,7 +92,7 @@ namespace OnlineStore.DeviceLibrary
}
else
{
LogUtil.info(Name + "出库" + outParam.ToStr() + "失败,料架号不一致[" + lastXuniRfid + "][" + outParam.rfid + "],当前料架还有【"+count+"】个任务,托盘先离开");
LogUtil.info(Name + "出库" + outParam.ToStr() + "失败,料架号不一致[" + lastXuniRfid + "][" + outParam.rfid + "],当前料架还有【" + count + "】个任务,托盘先离开");
TrayMoveOk();
return false;
}
......@@ -101,8 +101,8 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.NewMove(LineMoveType.OutStore, outParam);
LastOutParam = outParam;
//可以开始出库啦
MoveInfo.NextMoveStep(LineMoveStep.FO_211_AxisDownMove);
// CylinderMove(MoveInfo, IO_Type.SW_LocationCylinder_Down, IO_Type.SW_LocationCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FO_21_AxisDownMove);
// CylinderMove(MoveInfo, IO_Type.SW_LocationCylinder_Down, IO_Type.SW_LocationCylinder_Up);
int height = outParam.PlateH + 4;
int targetPosition = BatchAxis.GetAclPosition() - height * Config.Height_ChangeValue;
if (targetPosition < Config.BatchAxisP2)
......@@ -110,32 +110,23 @@ namespace OnlineStore.DeviceLibrary
targetPosition = Config.BatchAxisP2;
}
OutLog("出库移栽 " + MoveInfo.SLog + " :提升伺服下降" + height + "mm,目标:" + targetPosition);
if (MoveCylineIsUp()||MoveInfo.MoveParam.PlateW.Equals(7))
if (UpdownIsUp() )
{
//已经在取料端
if (CylinderIsOk(IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take))
{
if (MoveInfo.MoveParam.PlateW.Equals(7))
{
//升降先下降
//CylinderMove(null, IO_Type.SL_MoveCylinder_Up, IO_Type.SL_MoveCylinder_Down);
}
{
int targetP = Config.GetUpdownP2Detial(MoveInfo.MoveParam.PlateH, MoveInfo.MoveParam.PlateW);
UpdownAxis.AbsMove(MoveInfo, targetP, Config.UpdownAxis_P2Speed);
}
else if(MoveCylineIsUp())
else if (UpdownIsUp())
{
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
}
else
{
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
}
}
}
else
{
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
BatchAxis.AbsMove(MoveInfo, targetPosition, Config.BatchAxis_P2Speed);
return true;
......@@ -155,13 +146,13 @@ namespace OnlineStore.DeviceLibrary
}
else if (LastOutParam.cutReel && taskData.cutTask <= 0)
{
MoveInfo.NewMove(LineMoveType.OutStore,LastOutParam);
MoveInfo.NewMove(LineMoveType.OutStore, LastOutParam);
LogUtil.info(Name + "定时获取到 " + LastOutParam.ToShortStr() + " 已无剩余任务:" + taskData.ToStr());
SendOutShelfOut("分盘料,cutTask=" + taskData.cutTask + ",需要送出料架");
}
else if (LastOutParam.urgentReel && taskData.urgentTask <= 0)
{
MoveInfo.NewMove(LineMoveType.OutStore,LastOutParam);
MoveInfo.NewMove(LineMoveType.OutStore, LastOutParam);
LogUtil.info(Name + "定时获取到 " + LastOutParam.ToShortStr() + " 已无剩余任务:" + taskData.ToStr());
SendOutShelfOut("紧急料,urgentTask=" + taskData.urgentTask + ",需要送出料架");
}
......@@ -192,7 +183,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.NewMove(LineMoveType.OutStore);
MoveInfo.MoveParam = new InOutParam();
taskData = null;
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH)&& IsTrayLCylinderAfter())
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH) && IsTrayLCylinderAfter())
{
FO_04_WaitTime();
}
......@@ -201,13 +192,13 @@ namespace OnlineStore.DeviceLibrary
//如果升降盘在锁紧状态,需要返回P2
if (IsTrayLCylinderAfter())
{
MoveInfo.NextMoveStep(LineMoveStep.FO_01_TrayLocation_After);
MoveInfo.NextMoveStep(LineMoveStep.FO_02_TrayLocation_After);
OutLog("准备出库料架, " + MoveInfo.SLog + " :升降盘定位气缸后退");
TrayLCylinderAfter(MoveInfo);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_00_BatchAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FO_01_BatchAxisToP2);
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
OutLog("准备出库料架,升降盘不在后退端 " + MoveInfo.SLog + " :提升伺服先回到P2");
}
......@@ -217,7 +208,7 @@ namespace OnlineStore.DeviceLibrary
private void FO_04_WaitTime()
{
//定位工位有料架,等待1秒后再次检测
MoveInfo.NextMoveStep(LineMoveStep.FO_04_WaitTime);
MoveInfo.NextMoveStep(LineMoveStep.FO_06_WaitTime);
OutLog("准备出库料架 " + MoveInfo.SLog + "定位工位检测到料架:进料阻挡上升, 等待3秒再次检测");
IOMove(IO_Type.SL_Line_Run, IO_VALUE.HIGH);
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.LOW);
......@@ -229,7 +220,7 @@ namespace OnlineStore.DeviceLibrary
private void LineOutStoreProcess()
{
//判断是哪个工位有料架
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
......@@ -238,10 +229,10 @@ namespace OnlineStore.DeviceLibrary
//阻挡工位有料架,流水线转动一个工位
else if (IOValue(IO_Type.SL_Stop_Check).Equals(IO_VALUE.HIGH))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_03_LineStart);
MoveInfo.NextMoveStep(LineMoveStep.FO_05_LineStart);
OutLog("准备出库料架: " + MoveInfo.SLog + " 阻挡工位有新料架,清理缓存料架RFID,进料阻挡下降500ms,缓冲阻挡前进1000,流水线转动 5000");
UpdateLastShelfID();
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.HIGH,500);
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.HIGH, 500);
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.HIGH, 1000);//缓冲阻挡前进1000
IOMove(IO_Type.SL_Line_Run, IO_VALUE.HIGH);
//等待指定时间
......@@ -251,7 +242,7 @@ namespace OnlineStore.DeviceLibrary
}
else if (IOValue(IO_Type.SL_Entry_Check).Equals(IO_VALUE.HIGH))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_03_LineStart);
MoveInfo.NextMoveStep(LineMoveStep.FO_05_LineStart);
OutLog("准备出库料架: " + MoveInfo.SLog + " 进料口有新料架,进料阻挡上升,缓冲阻挡前进1000,流水线转动 1000");
IOMove(IO_Type.SL_Entry_StopDown, IO_VALUE.LOW);//进料阻挡上升
IOMove(IO_Type.SL_Buffer_StopDown, IO_VALUE.HIGH, 1000);//缓冲阻挡前进1000
......@@ -283,28 +274,34 @@ namespace OnlineStore.DeviceLibrary
{
return;
}
if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_00_BatchAxisToP2))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_01_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_01_TrayLocation_After);
MoveInfo.NextMoveStep(LineMoveStep.FO_02_TrayLocation_After);
TrayLCylinderAfter(MoveInfo);
OutLog("准备出库料架, " + MoveInfo.SLog + " :升降盘定位气缸后退");
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_01_TrayLocation_After))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_02_TrayLocation_After))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_02_LocationDown);
MoveInfo.NextMoveStep(LineMoveStep.FO_03_LocationDown);
OutLog("出库: " + MoveInfo.SLog + " 开始:定位气缸下降,提升轴移动到P1");
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
LocationCylinderDown(MoveInfo);
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_02_LocationDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_03_LocationDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_04_FixedDown);
OutLog("出库: " + MoveInfo.SLog + " 开始:固定气缸下降");
FixedCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_04_FixedDown))
{
LineOutStoreProcess();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_03_LineStart))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_05_LineStart))
{
LineOutStoreProcess();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_04_WaitTime))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_06_WaitTime))
{
if (IOValue(IO_Type.SL_Location_Check).Equals(IO_VALUE.HIGH))
{
......@@ -336,10 +333,10 @@ namespace OnlineStore.DeviceLibrary
}
//定位工位有料架,直接开始入料
MoveInfo.NextMoveStep(LineMoveStep.FO_05_LocationUp);
MoveInfo.NextMoveStep(LineMoveStep.FO_08_LocationUp);
OutLog("定位工位检测到料架: " + MoveInfo.SLog + " 缓冲阻挡下降, 定位气缸上升,读取并缓存料架RFID");
UpdateLastShelfID(CurrShelfId);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Down, IO_Type.SL_LocationCylinder_Up);
LocationCylinderUp(MoveInfo);
}
else
......@@ -348,44 +345,43 @@ namespace OnlineStore.DeviceLibrary
OutLog(" 未检测到料架,料架处理结束");
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_05_LocationUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_08_LocationUp))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_06_BatchAxisToP2);
OutLog("准备出库料架 " + MoveInfo.SLog + " :提升轴下降到位P2,定位气缸上升");
MoveInfo.NextMoveStep(LineMoveStep.FO_11_BatchAxisToP2);
OutLog("准备出库料架 " + MoveInfo.SLog + " :提升轴下降到位P2");
if (!ProcessShelfEnter)
{
IOMove(IO_Type.SL_Line_Run, IO_VALUE.LOW);
}
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Down, IO_Type.SL_LocationCylinder_Up);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_06_BatchAxisToP2))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_11_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_07_TrayLocation_Before);
MoveInfo.NextMoveStep(LineMoveStep.FO_12_TrayLocation_Before);
OutLog("准备出库料架 " + MoveInfo.SLog + " :升降盘定位气缸第一次前进 2秒");
TrayLCylinderBefore(null);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(2000));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_07_TrayLocation_Before))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_12_TrayLocation_Before))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_08_TrayLocation_Back);
MoveInfo.NextMoveStep(LineMoveStep.FO_13_TrayLocation_Back);
OutLog("准备出库料架 " + MoveInfo.SLog + " :升降盘定位气缸后退,等待再次前进");
TrayLCylinderAfter(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_08_TrayLocation_Back))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_13_TrayLocation_Back))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_09_TrayLocation_Before);
MoveInfo.NextMoveStep(LineMoveStep.FO_14_TrayLocation_Before);
OutLog("准备出库料架 " + MoveInfo.SLog + " :升降盘定位气缸前进");
TrayLCylinderBefore(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_09_TrayLocation_Before))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_14_TrayLocation_Before))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_10_AxisUpMove);
MoveInfo.NextMoveStep(LineMoveStep.FO_15_AxisUpMove);
OutLog("准备出库料架 " + MoveInfo.SLog + " :上料轴开始慢速上升到P3点,等待检测到料盘");
BatchAxisToP3();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_10_AxisUpMove))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_15_AxisUpMove))
{
//判断信号是否亮
if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.LOW))
......@@ -407,13 +403,13 @@ namespace OnlineStore.DeviceLibrary
if (tp < Config.BatchAxisP2)
{
OutLog("准备出库料架 " + MoveInfo.SLog + " :检测到料盘,下降的目标高度为【" + tp + "】<【" + Config.BatchAxisP2 + "】,料架已满,直接送出料架");
MoveInfo.NextMoveStep(LineMoveStep.FO_30_BatchAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FO_51_BatchAxisToP2);
OutLog("出库移栽 " + MoveInfo.SLog + ":提升伺服到P2点");
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP2, Config.BatchAxis_P2Speed);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_10_AxisUpMove);
MoveInfo.NextMoveStep(LineMoveStep.FO_15_AxisUpMove);
OutLog("准备出库料架 " + MoveInfo.SLog + " :检测到料盘,需要下降指定高度,目标位置:" + tp + ",等待检测不到料盘");
MoveInfo.TimeOutSeconds = 200;
MoveInfo.CanWhileCount = 0;
......@@ -425,82 +421,88 @@ namespace OnlineStore.DeviceLibrary
}
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_30_BatchAxisToP2))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_51_BatchAxisToP2))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_31_TrayLocation_After);
MoveInfo.NextMoveStep(LineMoveStep.FO_52_TrayLocation_After);
OutLog("送出料串: " + MoveInfo.SLog + ": 升降盘定位气缸后退,重置 OutEndSendShelfOut=fasle ,OutStoreCount = 0");
OutEndSendShelfOut = false;
OutStoreHeight = -1;
OutStoreCount = 0;
TrayLCylinderAfter(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_31_TrayLocation_After))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_52_TrayLocation_After))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_32_BatchAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FO_53_BatchAxisToP1);
OutLog("送出料串: " + MoveInfo.SLog + ":提升伺服到P1点,定位气缸下降");
BatchAxis.AbsMove(MoveInfo, Config.BatchAxisP1, Config.BatchAxis_P1Speed);
CylinderMove(MoveInfo, IO_Type.SL_LocationCylinder_Up, IO_Type.SL_LocationCylinder_Down);
LocationCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_32_BatchAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_53_BatchAxisToP1))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_34_OutCheck);
MoveInfo.NextMoveStep(LineMoveStep.FO_54_FixedDown);
OutLog("送出料串: " + MoveInfo.SLog + ":固定气缸下降");
FixedCylinderDown(MoveInfo);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_54_FixedDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_55_OutCheck);
OutLog("送出料串: " + MoveInfo.SLog + ",等待出料线体无料架");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_Out_Check, IO_VALUE.LOW));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_34_OutCheck))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_55_OutCheck))
{
if (!ProcessShelfOut)
{
MoveInfo.NextMoveStep(LineMoveStep.FO_34_OutTopCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FO_56_OutTopCylinder_Up);
OutLog("送出料串: " + MoveInfo.SLog + ",出口顶升气缸上升,出料缓冲阻挡上升");
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Down, IO_Type.SL_OutTopCylinder_Up);
IOMove(IO_Type.SL_Out_StopDown, IO_VALUE.LOW);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_34_OutTopCylinder_Up))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_56_OutTopCylinder_Up))
{
//TODO
MoveInfo.NextMoveStep(LineMoveStep.FO_35_SideWayLineRun);
MoveInfo.NextMoveStep(LineMoveStep.FO_57_SideWayLineRun);
OutLog("送出料串: " + MoveInfo.SLog + ", 线体横移电机运转,等待料架离开定位工位");
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.LOW));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_35_SideWayLineRun))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_57_SideWayLineRun))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_36_WaitShelfGo);
MoveInfo.NextMoveStep(LineMoveStep.FO_58_WaitShelfGo);
OutLog("送出料串:" + MoveInfo.SLog + ", 线体横移电机运转,等待料架到达出口");
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_Out_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_36_WaitShelfGo))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_58_WaitShelfGo))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_37_LineStop);
MoveInfo.NextMoveStep(LineMoveStep.FO_59_LineStop);
OutLog("送出料串: " + MoveInfo.SLog + ", 料架到达出口,线体横移电机停止 ");
IOMove(IO_Type.SL_LocationSideWay_Run, IO_VALUE.LOW);
IOMove(IO_Type.SL_OutSideWay_Run, IO_VALUE.LOW);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_37_LineStop))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_59_LineStop))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_38_TopDown);
MoveInfo.NextMoveStep(LineMoveStep.FO_60_TopDown);
OutLog("送出料串: " + MoveInfo.SLog + ", 料架到达出口,出口顶升下降 ,清空LastOutParam,清理缓存料架RFID ");
UpdateLastShelfID();
CylinderMove(MoveInfo, IO_Type.SL_OutTopCylinder_Up, IO_Type.SL_OutTopCylinder_Down);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
LastOutParam = new InOutParam();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_38_TopDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_60_TopDown))
{
MoveEndS();
// MoveInfo.NextMoveStep(LineMoveStep.FO_39_OutLineRun);
OutLog("送出料串: " + MoveInfo.SLog + ", 出口线体运转,料架到达出口处, 通知AGV取空料架, 出料结束");
AgvClient.NeedLeave(Config.AgvOutName, LastOutShelfId, Asa.ClientLevel.High);
}
else if (MoveInfo.MoveStep >= LineMoveStep.FO_211_AxisDownMove && MoveInfo.MoveStep < LineMoveStep.FO_30_BatchAxisToP2)
else if (MoveInfo.MoveStep >= LineMoveStep.FO_21_AxisDownMove && MoveInfo.MoveStep < LineMoveStep.FO_51_BatchAxisToP2)
{
TrayOutProcess();
}
......@@ -517,14 +519,14 @@ namespace OnlineStore.DeviceLibrary
{
outType = "分盘料 ";
}
if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_211_AxisDownMove))
if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_21_AxisDownMove))
{
//判断伺服检测信号是否亮
//if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.LOW) || BatchAxis.IsInPosition(Config.BatchAxisP2))
if (IOValue(IO_Type.SL_AxisLocationCheck).Equals(IO_VALUE.HIGH) && BatchAxis.IsInPosition(Config.BatchAxisP2).Equals(false))
{
//可以开始出库啦
MoveInfo.NextMoveStep(LineMoveStep.FO_211_AxisDownMove);
MoveInfo.NextMoveStep(LineMoveStep.FO_21_AxisDownMove);
int height = MoveInfo.MoveParam.PlateH + 4;
int targetPosition = BatchAxis.GetAclPosition() - height * Config.Height_ChangeValue;
if (targetPosition < Config.BatchAxisP2)
......@@ -544,83 +546,61 @@ namespace OnlineStore.DeviceLibrary
if (UpdownAxis.IsInPosition(targetP))
{
FO_214_CylinderDown(outType);
FO_25_CylinderTighten(outType);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_213_UpdownAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FO_23_UpdownAxisToP2);
OutLog(outType + MoveInfo.SLog + ":升降伺服下降到P2:" + targetP);
if (MoveInfo.MoveParam.PlateW.Equals(7))
{
//升降先下降
//CylinderMove(null, IO_Type.SL_MoveCylinder_Up, IO_Type.SL_MoveCylinder_Down);
}
UpdownAxis.AbsMove(MoveInfo, targetP, Config.UpdownAxis_P2Speed);
}
}
else
{
if (MoveCylineIsUp())
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FO_212_CylinderTake);
MoveInfo.NextMoveStep(LineMoveStep.FO_22_CylinderTake);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_211_AxisDownMove);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端 前先上升横移气缸");
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FO_21_AxisDownMove);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端 前升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_212_CylinderTake))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_22_CylinderTake))
{
if (CylinderIsOk(IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_213_UpdownAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FO_23_UpdownAxisToP2);
int targetP = Config.GetUpdownP2Detial(MoveInfo.MoveParam.PlateH, MoveInfo.MoveParam.PlateW);
OutLog(outType + MoveInfo.SLog + ":升降伺服下降到P2:" + targetP);
UpdownAxis.AbsMove(MoveInfo, targetP, Config.UpdownAxis_P2Speed);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_212_CylinderTake);
MoveInfo.NextMoveStep(LineMoveStep.FO_22_CylinderTake);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_213_UpdownAxisToP2))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_23_UpdownAxisToP2))
{
FO_214_CylinderDown(outType);
FO_25_CylinderTighten(outType);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_214_CylinderDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_24_CylinderDown))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_215_CylinderTighten);
MoveInfo.NextMoveStep(LineMoveStep.FO_25_CylinderTighten);
OutLog(outType + MoveInfo.SLog + ":上料气缸夹紧");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Relax, IO_Type.SL_MoveCylinder_Work);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_215_CylinderTighten))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_216_CylinderUp);
OutLog(outType + MoveInfo.SLog + ":上料横移机构上升");
// TODO
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
//if (Config.SidesWayNum.Equals(3) && MoveInfo.MoveParam.PlateW.Equals(7))
//{
// InLog(MoveInfo.SLog + " 提前下降顶升气缸 ,环形线定位气缸先下降,顶升气缸同时下降");
// CylinderMove(null, IO_Type.SW_LocationCylinder_Up, IO_Type.SW_LocationCylinder_Down);
// CylinderMove(SecondMoveInfo, IO_Type.SW_TopCylinder_Up, IO_Type.SW_TopCylinder_Down);
// //七寸时伺服可以先动作
// UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
//}
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Relax, IO_Type.SL_ClampCylinder_Work);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_216_CylinderUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_25_CylinderTighten))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_217_UpdownAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FO_26_UpdownAxisToP1);
OutLog(outType + MoveInfo.SLog + ":升降伺服到P1");
if (!UpdownAxis.IsInPosition(Config.UpDownAxisP1))
{
......@@ -633,40 +613,46 @@ namespace OnlineStore.DeviceLibrary
//SecondMoveInfo.NextMoveStep(LineMoveStep.MO_12_MoveOk);
TrayMoveOk();
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_217_UpdownAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_26_UpdownAxisToP1))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_27_ClampCheck);
OutLog(outType + MoveInfo.SLog + ":检测夹爪料盘检测=HIGH");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_ClampCylinder_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_27_ClampCheck))
{
if (MoveCylineIsUp())
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FO_218_CylinderGive);
MoveInfo.NextMoveStep(LineMoveStep.FO_28_CylinderGive);
OutLog(outType + MoveInfo.SLog + ":上料横移机构到放料端");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Take, IO_Type.SL_MoveCylinder_Give);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_217_UpdownAxisToP1);
OutLog(outType + MoveInfo.SLog + ":上料横移机构到放料端前,先上升横移气缸");
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FO_26_UpdownAxisToP1);
OutLog(outType + MoveInfo.SLog + ":上料横移机构到放料端前,先升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_218_CylinderGive))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_28_CylinderGive))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_219_UpdownAxisToP3);
MoveInfo.NextMoveStep(LineMoveStep.FO_29_UpdownAxisToP3);
OutLog(outType + MoveInfo.SLog + ":移栽伺服到P3");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP3, Config.UpdownAxis_P3Speed);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_219_UpdownAxisToP3))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_29_UpdownAxisToP3))
{
OutStoreHeight += MoveInfo.MoveParam.PlateH;
OutStoreCount++;
MoveInfo.NextMoveStep(LineMoveStep.FO_220_CylinderSlack);
MoveInfo.NextMoveStep(LineMoveStep.FO_30_CylinderSlack);
OutLog(outType + MoveInfo.SLog + ":出料横移机构放松,累积出库【" + OutStoreCount + "】盘【" + OutStoreHeight + "】mm");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Work, IO_Type.SL_MoveCylinder_Relax);
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Work, IO_Type.SL_ClampCylinder_Relax);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_220_CylinderSlack))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_30_CylinderSlack))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_221_UpdownAxisToP1);
MoveInfo.NextMoveStep(LineMoveStep.FO_31_UpdownAxisToP1);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
OutLog(outType + MoveInfo.SLog + ":移栽伺服上升到待机点P1,通知服务器 afterPutCut");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
......@@ -679,11 +665,17 @@ namespace OnlineStore.DeviceLibrary
}
afterPutOk = true;
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_221_UpdownAxisToP1))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_31_UpdownAxisToP1))
{
if (MoveCylineIsUp())
MoveInfo.NextMoveStep(LineMoveStep.FO_32_ClampCheck);
OutLog(outType + MoveInfo.SLog + ":检测夹爪料盘检测=LOW");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.SL_ClampCylinder_Check, IO_VALUE.LOW));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_32_ClampCheck))
{
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.FO_222_CylinderTake);
MoveInfo.NextMoveStep(LineMoveStep.FO_33_CylinderTake);
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Give, IO_Type.SL_MoveCylinder_Take);
//只有提升轴位置过低时才需要到P3
int currPosition = BatchAxis.GetAclPosition();
......@@ -699,12 +691,12 @@ namespace OnlineStore.DeviceLibrary
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.FO_221_UpdownAxisToP1);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端 前先上升横移气缸");
//CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Down, IO_Type.SL_MoveCylinder_Up);
MoveInfo.NextMoveStep(LineMoveStep.FO_31_UpdownAxisToP1);
OutLog(outType + MoveInfo.SLog + ":上料横移机构取料端 前升降轴先到P1");
UpdownAxis.AbsMove(MoveInfo, Config.UpDownAxisP1, Config.UpdownAxis_P1Speed);
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_222_CylinderTake))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.FO_33_CylinderTake))
{
if (afterPutOk)
{
......@@ -752,24 +744,16 @@ namespace OnlineStore.DeviceLibrary
}
}
private bool afterPutOk = false;
private void FO_214_CylinderDown(string outType)
private void FO_25_CylinderTighten(string outType)
{
//if (CylinderIsOk(IO_Type.SL_MoveCylinder_Up, IO_Type.SL_MoveCylinder_Down))
{
MoveInfo.NextMoveStep(LineMoveStep.FO_215_CylinderTighten);
OutLog(outType + MoveInfo.SLog + ":上料气缸夹紧");
CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Relax, IO_Type.SL_MoveCylinder_Work);
}
//else
//{
// MoveInfo.NextMoveStep(LineMoveStep.FO_214_CylinderDown);
// OutLog(outType + MoveInfo.SLog + ":上料横移机构下降");
// CylinderMove(MoveInfo, IO_Type.SL_MoveCylinder_Up, IO_Type.SL_MoveCylinder_Down);
//}
MoveInfo.NextMoveStep(LineMoveStep.FO_25_CylinderTighten);
OutLog(outType + MoveInfo.SLog + ":上料气缸夹紧");
CylinderMove(MoveInfo, IO_Type.SL_ClampCylinder_Relax, IO_Type.SL_ClampCylinder_Work);
}
private void SendOutShelfOut(string msg="")
private void SendOutShelfOut(string msg = "")
{
MoveInfo.NextMoveStep(LineMoveStep.FO_30_BatchAxisToP2);
MoveInfo.NextMoveStep(LineMoveStep.FO_51_BatchAxisToP2);
OutStoreHeight = -1;
//包装料会发往分盘区, 紧急料区, 包装线区
// urgentReel 这个为true是紧急料 出到紧急料区
......
......@@ -331,7 +331,7 @@ namespace OnlineStore.DeviceLibrary
{
return true;
}
else if (move.MoveInfo.MoveStep.Equals(LineMoveStep.MO_56_CylinderAfter) && move.MoveInfo.IsInWait.Equals(false)
else if (move.MoveInfo.MoveStep.Equals(LineMoveStep.MO_57_CylinderAfter) && move.MoveInfo.IsInWait.Equals(false)
&&move.CylinderIsOk(IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After))
{
return true;
......
......@@ -26,18 +26,11 @@ namespace OnlineStore.DeviceLibrary
Name = (" " + "_"+ GetNByID() + "_进仓" + DeviceID.ToString().PadLeft(2, '0') + "_" ).ToUpper();
Init();
MoveInfo = new LineMoveInfo(DeviceID, "[" + Name.Trim() + "-Move]");
SecondMoveInfo = new LineMoveInfo(DeviceID, "[" + Name.Trim() + "-SMove]");
UseAxis = config.UpDownUseAxis.Equals(1);
//if (UseAxis)
//{
// Config.UpDown_Axis.ServerOnDO = IO_Type.UpDownAxis_ServoOn;
// Config.UpDown_Axis.BreakOnDO = IO_Type.UpDownAxis_BreakOn;
//}
UseAxis = config.UpDownUseAxis.Equals(1);
UpdownAxis = new AxisBean(config.UpDown_Axis, Name);
}
private string GetNByID()
......@@ -146,22 +139,27 @@ namespace OnlineStore.DeviceLibrary
//复位时夹紧气缸需要发送,不然后面出入库会有问题
switch (MoveInfo.MoveStep)
{
case LineMoveStep.MH_UpDownHome:
MoveInfo.NextMoveStep(LineMoveStep.MH_CylinderUp);
case LineMoveStep.MH_01_UpDownHome:
MoveInfo.NextMoveStep(LineMoveStep.MH_02_CylinderUp);
DebugInfo(MoveInfo.MoveType + " : 升降轴走到待机点");
UpdownUpMove();
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(2000));
break;
case LineMoveStep.MH_CylinderUp:
case LineMoveStep.MH_02_CylinderUp:
MoveInfo.NextMoveStep(LineMoveStep.MH_OtherCylinderBack);
MoveInfo.NextMoveStep(LineMoveStep.MH_03_OtherBack);
DebugInfo(MoveInfo.MoveType + " : 上升气缸到位,顶升气缸下降,前后气缸后退,夹紧气缸放松");
CylinderMove(MoveInfo, IO_Type.TopCylinder_UP, IO_Type.TopCylinder_Down);
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
CylinderMove(MoveInfo, IO_Type.ClampCylinder_Work, IO_Type.ClampCylinder_Relax);
break;
case LineMoveStep.MH_OtherCylinderBack:
case LineMoveStep.MH_03_OtherBack:
MoveInfo.NextMoveStep(LineMoveStep.MH_04_ClampCheck);
DebugInfo(MoveInfo.MoveType + " : 等待夹爪气缸料盘检测无料");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.LOW));
break;
case LineMoveStep.MH_04_ClampCheck:
LogInfo(MoveInfo.MoveType + " 完成!");
runStatus = LineRunStatus.Runing;
......@@ -252,10 +250,7 @@ namespace OnlineStore.DeviceLibrary
}
OutStoreListPro();
}
/// <summary>
/// 出库队列处理
/// </summary>
private void OutStoreListPro()
{
//料仓出库完成,进仓装置开始出库检测
......@@ -374,17 +369,18 @@ namespace OnlineStore.DeviceLibrary
{
if (UseAxis)
{
MoveInfo.NextMoveStep(LineMoveStep.MH_UpDownHome);
MoveInfo.NextMoveStep(LineMoveStep.MH_01_UpDownHome);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
UpdownAxis.HomeMove(MoveInfo);
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.MH_CylinderUp);
MoveInfo.NextMoveStep(LineMoveStep.MH_02_CylinderUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Down, IO_Type.UpDownCylinder_Up);
}
}
#endregion
}
......
......@@ -64,8 +64,9 @@ namespace OnlineStore.DeviceLibrary
{
MoveInfo.NextMoveStep(LineMoveStep.MO_51_CylinderBefore);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
OutLog("出库 " + MoveInfo.MoveStep + ": 前后气缸前进");
OutLog("出库 " + MoveInfo.MoveStep + ": 前后气缸前进,等待夹爪料盘检测信号=LOW");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.LOW));
}
else
{
......@@ -117,13 +118,20 @@ namespace OnlineStore.DeviceLibrary
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_55_CylinderUp))
{
MoveInfo.NextMoveStep(LineMoveStep.MO_56_ClampCheck);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
OutLog("出库 " + MoveInfo.SLog + ": 检测夹爪料盘检测=HIGH");
MoveInfo.WaitList.Add (WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_56_ClampCheck))
{
if (UpdownIsUp())
{
if (IsBigStore())
{
if (TrayIsOk())
{
MoveInfo.NextMoveStep(LineMoveStep.MO_56_CylinderAfter);
MoveInfo.NextMoveStep(LineMoveStep.MO_57_CylinderAfter);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
OutLog("出库 " + MoveInfo.SLog + ": 前后气缸后退");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
......@@ -131,7 +139,7 @@ namespace OnlineStore.DeviceLibrary
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.MO_56_CylinderAfter);
MoveInfo.NextMoveStep(LineMoveStep.MO_57_CylinderAfter);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
OutLog("出库 " + MoveInfo.SLog + ": 前后气缸后退");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
......@@ -147,12 +155,10 @@ namespace OnlineStore.DeviceLibrary
#endregion
#region 移载装置,放物品到流水线操作
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_56_CylinderAfter))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_57_CylinderAfter))
{
if (CylinderIsOk(IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After))
{
//if (SecondMoveInfo.MoveStep.Equals(LineMoveStep.MO_11_CodeRember) && !SecondMoveInfo.IsInWait)
//{
if (TrayIsOk())
{
int trayNum = SecondMoveInfo.MoveParam.TrayNumber;
......@@ -173,13 +179,6 @@ namespace OnlineStore.DeviceLibrary
UpdownDownP2Move(MoveInfo.MoveParam.PlateH, MoveInfo.MoveParam.PlateW);
CylinderMove(MoveInfo, IO_Type.TopCylinder_Down, IO_Type.TopCylinder_UP);
}
//}
//else if (MoveInfo.IsTimeOut(180))
//{
// WarnMsg = MoveInfo.Name + "[" + MoveInfo.MoveType + "][" + MoveInfo.SLog + "]等待空托盘到达超时[" + Math.Round(MoveInfo.StepSpan().TotalSeconds, 1) + "]秒";
// LogUtil.error(WarnMsg, DeviceID + 12);
// Alarm(LineAlarmType.IoSingleTimeOut);
//}
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MO_58_CylinderDown))
......@@ -248,14 +247,22 @@ namespace OnlineStore.DeviceLibrary
lineStatus = LineStatus.InStoreExecute;
MoveInfo.MoveParam = param;
MoveInfo.NewMove(LineMoveType.InStore);
LogInfo("入库【" + posId + "】处理(移栽):MI_05_ToLineUp, 前后气缸后退)");
//MoveInfo.NextMoveStep(LineMoveStep.MI_06_CylinderDown);
//MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
//UpdownDownP2Move(MoveInfo.MoveParam.PlateH);
MoveInfo.NextMoveStep(LineMoveStep.MI_05_ToLineUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
if (UpdownIsUp())
{
LogInfo("入库【" + posId + "】处理(移栽):MI_02_ToLineUp, 前后气缸后退,等待夹爪检测=LOW");
MoveInfo.NextMoveStep(LineMoveStep.MI_02_ToLineUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.HIGH));
}
else
{
LogInfo("入库【" + posId + "】处理(移栽):MI_01_UpdownUp, 顶升气缸先上升");
MoveInfo.NextMoveStep(LineMoveStep.MI_01_UpdownUp);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
UpdownUpMove();
}
return true;
}
else
......@@ -280,36 +287,49 @@ namespace OnlineStore.DeviceLibrary
return;
}
string posId = MoveInfo.MoveParam != null ? MoveInfo.MoveParam.PosId : "";
if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_05_ToLineUp))
if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_01_UpdownUp))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_02_ToLineUp);
InLog("入库 " + MoveInfo.SLog + ": 前后气缸后退,等待夹爪检测=LOW");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(1000));
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_Before, IO_Type.BeforeAfterCylinder_After);
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_02_ToLineUp))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_06_CylinderDown);
MoveInfo.NextMoveStep(LineMoveStep.MI_03_CylinderDown);
InLog("入库 " + MoveInfo.SLog + ": 升降下降,顶升上升");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
UpdownDownP2Move(MoveInfo.MoveParam.PlateH, MoveInfo.MoveParam.PlateW);
CylinderMove(MoveInfo, IO_Type.TopCylinder_Down, IO_Type.TopCylinder_UP);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_06_CylinderDown))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_03_CylinderDown))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_07_DownWait);
MoveInfo.NextMoveStep(LineMoveStep.MI_04_DownWait);
InLog("入库 " + MoveInfo.SLog + ": 等待200ms后夹紧");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(200));
}
//只有当BOX可以进行出入库时,移栽物品,防止卡住
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_07_DownWait))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_04_DownWait))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_08_CylinderOpen);
MoveInfo.NextMoveStep(LineMoveStep.MI_05_CylinderOpen);
InLog("入库 " + MoveInfo.SLog + ": 夹料气缸夹紧");
CylinderMove(MoveInfo, IO_Type.ClampCylinder_Relax, IO_Type.ClampCylinder_Work);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_08_CylinderOpen))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_05_CylinderOpen))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_09_CylinderUp);
MoveInfo.NextMoveStep(LineMoveStep.MI_06_CylinderUp);
InLog("入库 " + MoveInfo.SLog + ": 上下气缸上升");
UpdownUpMove();
CylinderMove(null, IO_Type.TopCylinder_UP, IO_Type.TopCylinder_Down);
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_09_CylinderUp))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_06_CylinderUp))
{
MoveInfo.NextMoveStep(LineMoveStep.MI_07_ClampCheck);
InLog("入库 " + MoveInfo.SLog + ": 等待夹爪料盘检测信号=HIGH");
MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.ClampCylinder_Check, IO_VALUE.HIGH));
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_07_ClampCheck)) {
int num = MoveInfo.MoveParam.TrayNumber;
MoveInfo.NextMoveStep(LineMoveStep.MI_10_WaitBox);
LogInfo("入库【" + posId + "】 " + MoveInfo.SLog + ": 等待box可入库,更新托盘【" + num + "】为空盘");
......@@ -324,7 +344,7 @@ namespace OnlineStore.DeviceLibrary
{
if (UpdownIsUp())
{
MoveInfo.NextMoveStep(LineMoveStep.MI_10_CylinderBefore);
MoveInfo.NextMoveStep(LineMoveStep.MI_08_CylinderBefore);
InLog("入库: " + MoveInfo.SLog + " 前后气缸1前进");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before);
}
......@@ -335,7 +355,7 @@ namespace OnlineStore.DeviceLibrary
UpdownUpMove();
}
}
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_10_CylinderBefore))
else if (MoveInfo.MoveStep.Equals(LineMoveStep.MI_08_CylinderBefore))
{
if (CylinderIsOk(IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before))
{
......@@ -345,7 +365,7 @@ namespace OnlineStore.DeviceLibrary
}
else
{
MoveInfo.NextMoveStep(LineMoveStep.MI_10_CylinderBefore);
MoveInfo.NextMoveStep(LineMoveStep.MI_08_CylinderBefore);
InLog("入库: " + MoveInfo.SLog + " 前后气缸1前进");
CylinderMove(MoveInfo, IO_Type.BeforeAfterCylinder_After, IO_Type.BeforeAfterCylinder_Before);
}
......@@ -462,7 +482,7 @@ namespace OnlineStore.DeviceLibrary
}
bool isFull = TrayManager.TrayIsFull(currTrayNum);
bool moveOk = (IsBigStore() && MoveInfo.MoveStep >= LineMoveStep.MO_55_CylinderUp) || MoveInfo.MoveStep >= LineMoveStep.MO_56_CylinderAfter;
bool moveOk = (IsBigStore() && MoveInfo.MoveStep >= LineMoveStep.MO_55_CylinderUp) || MoveInfo.MoveStep >= LineMoveStep.MO_57_CylinderAfter;
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && moveOk
&& (!MoveInfo.MoveStep.Equals(LineMoveStep.MO_60_CylinderUp)))
{
......@@ -481,7 +501,7 @@ namespace OnlineStore.DeviceLibrary
{
return false;
}
bool moveOk = (IsBigStore() && MoveInfo.MoveStep >= LineMoveStep.MO_55_CylinderUp) || MoveInfo.MoveStep >= LineMoveStep.MO_56_CylinderAfter;
bool moveOk = (IsBigStore() && MoveInfo.MoveStep >= LineMoveStep.MO_55_CylinderUp) || MoveInfo.MoveStep >= LineMoveStep.MO_57_CylinderAfter;
if (MoveInfo.MoveType.Equals(LineMoveType.OutStore) && moveOk
&& (!MoveInfo.MoveStep.Equals(LineMoveStep.MO_60_CylinderUp)))
{
......
......@@ -492,17 +492,30 @@ namespace OnlineStore.DeviceLibrary
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(300));
}
//如果是进仓门口 夹紧
if (baseConfig.DType.Equals(DeviceType.MoveEquip) && (IoHighType.Equals(IO_Type.ClampCylinder_Work)))
{
if (baseConfig.DType.Equals(DeviceType.MoveEquip) && (IoHighType.Equals(IO_Type.SL_ClampCylinder_Work)))
{
//夹爪夹紧
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
moveInfo.WaitList.Add(WaitResultInfo.WaitIO(IoLowType, IO_VALUE.LOW));
}
if (baseConfig.DType.Equals(DeviceType.MoveEquip) && (IoHighType.Equals(IO_Type.SL_ClampCylinder_Relax)))
{
//夹爪放松
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
moveInfo.WaitList.Add(WaitResultInfo.WaitIO(IoHighType, IO_VALUE.HIGH));
}
else if (baseConfig.DType.Equals(DeviceType.MoveEquip) && (IoHighType.Equals(IO_Type.ClampCylinder_Relax)))
{
//进仓门口放松
//夹爪放松
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
moveInfo.WaitList.Add(WaitResultInfo.WaitIO(IoHighType, IO_VALUE.HIGH));
}
else if (baseConfig.DType.Equals(DeviceType.MoveEquip) && (IoHighType.Equals(IO_Type.ClampCylinder_Work)))
{
//夹爪夹紧
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
moveInfo.WaitList.Add(WaitResultInfo.WaitIO(IoLowType, IO_VALUE.LOW));
}
else
{
moveInfo.WaitList.Add(WaitResultInfo.WaitIO(IoLowType, IO_VALUE.LOW));
......
......@@ -177,51 +177,63 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 上下气缸回原点
/// </summary>
MH_UpDownHome = 2000,
MH_01_UpDownHome = 2001,
/// <summary>
/// 料仓移栽装置,上下气缸上升端
/// </summary>
MH_CylinderUp = 2001,
MH_02_CylinderUp,
/// <summary>
/// 料仓移载装置,其他气缸运行到初始状态( 顶升气缸下降端,前后气缸后退端,夹料气缸放松端,阻挡气缸输入=0 )
/// </summary>
MH_OtherCylinderBack = 2002,
MH_03_OtherBack,
/// <summary>
/// 料仓移载装置,等待夹爪气缸料盘检测无料
/// </summary>
MH_04_ClampCheck,
#endregion
#region 移载装置入库处理 3000-3050
/// <summary>
///移载装置入库处理,顶升气缸先上升
/// </summary>
MI_01_UpdownUp = 3001,
/// <summary>
///移载装置入库处理,横移气缸到流水线上方
/// </summary>
MI_05_ToLineUp = 3005,
MI_02_ToLineUp ,
/// <summary>
///移载装置入库处理,编码与仓位一致,上下气缸1下降
/// </summary>
MI_06_CylinderDown = 3006,
MI_03_CylinderDown ,
/// <summary>
///移载装置入库处理,编码与仓位一致,上下气缸1下降后,等待0.3秒,防止没有 下降到位就夹紧
/// </summary>
MI_07_DownWait = 3007,
MI_04_DownWait,
/// <summary>
///移载装置入库处理,夹料气缸1夹紧
/// </summary>
MI_08_CylinderOpen = 3008,
MI_05_CylinderOpen,
/// <summary>
///移载装置入库处理,上下气缸1上升
/// </summary>
MI_09_CylinderUp = 3009,
MI_06_CylinderUp,
/// <summary>
/// 移载装置入库处理,检测夹爪料盘检测信号
/// </summary>
MI_07_ClampCheck,
/// <summary>
///移载装置入库处理,,前后气缸1前进
/// </summary>
MI_10_CylinderBefore = 3010,
MI_08_CylinderBefore,
/// <summary>
/// 移载装置入库处理,等待box等待状态才能继续操作
/// </summary>
MI_10_WaitBox = 3030,
MI_10_WaitBox,
/// <summary>
///移载装置入库处理,上下气缸1下降
/// </summary>
......@@ -372,10 +384,15 @@ namespace OnlineStore.DeviceLibrary
/// 移栽装置出库处理。 上下气缸1上升
/// </summary>
MO_55_CylinderUp = 3155,
/// <summary>
/// 移栽装置出库处理。 夹料气缸检测
/// </summary>
MO_56_ClampCheck = 3156,
/// <summary>
/// 移栽装置出库处理。 前后气缸1后退
/// </summary>
MO_56_CylinderAfter = 3156,
MO_57_CylinderAfter = 3157,
/// <summary>
/// 移载(流水线)装置出库处理,上下气缸1下降
......@@ -518,7 +535,7 @@ namespace OnlineStore.DeviceLibrary
#region 入料装置原点返回,10000开始
/// <summary>
/// 复位之前,所有阻挡先上升到位
/// 上料模块复位,所有阻挡先上升到位
/// </summary>
FR_01_StopUp = 10001,
/// <summary>
......@@ -526,63 +543,58 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
FR_02_LineRun = 10002,
/// <summary>
/// 横移装置上升,
/// 上料模块复位:横移装置上升,
/// </summary>
FR_03_CylinderUp = 10003,
/// <summary>
/// 升降伺服回原点
/// 上料模块复位:升降伺服回原点
/// </summary>
FR_04_UpdownAxisHome = 10004,
/// <summary>
///上料装置:上料气缸放松SOL,升降机构到待机点
///上料模块复位:上料气缸放松SOL,升降机构到待机点
/// </summary>
FR_05_UpdownAxis_P1 = 10005,
/// <summary>
///上料装置:上料横移气缸取料端SOL
///上料模块复位:上料横移气缸取料端SOL
/// </summary>
FR_06_CylinderGive = 10006,
/// <summary>
/// 提升伺服回原点,夹紧装置放松
///上料模块复位: 提升伺服回原点,夹紧装置放松
/// </summary>
FR_11_BatchAxisHome = 10011,
/// <summary>
/// 然后提升伺服下降到P2点
/// 上料模块复位:然后提升伺服下降到P2点
/// </summary>
FR_12_BatchAxisToP2,
/// <summary>
/// 放开定位气缸
/// 上料模块复位:放开定位气缸
/// </summary>
FR_13_LocationDown,
/// <summary>
/// 顶升气缸下降
/// 上料模块复位:放开固定气缸
/// </summary>
FR_14_TopDown,
FR_14_FixedDown,
/// <summary>
/// 提升伺服在上升到P1点
///上料模块复位: 顶升气缸下降
/// </summary>
FR_15_BatchAxisToP1,
///// <summary>
/////上料装置:上料横移机构上升SOL
///// </summary>
//FR_07_MoveCylinder_Up = 10007,
///// <summary>
/////上料装置:上料气缸放松SOL
///// </summary>
//FR_08_MoveCylinder_Slack = 10008,
///// <summary>
/////上料装置:上料横移气缸取料端SOL
///// </summary>
//FR_09_MoveCylinder_Give = 10009,
///// <summary>
/////上料装置:出口顶升下降SOL
///// </summary>
//FR_10_OutTopCylinder_Down = 10010,
FR_15_TopDown,
/// <summary>
/// 上料模块复位:提升伺服在上升到P1点
/// </summary>
FR_16_BatchAxisToP1,
/// <summary>
/// 上料模块复位:检测夹爪料盘检测信号无料
/// </summary>
FR_17_ClampCheck,
#endregion
......@@ -618,357 +630,386 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 提升轴先返回P2
/// </summary>
FI_00_BatchAxisToP2 = 11000,
FI_01_BatchAxisToP2 = 11001,
/// <summary>
/// 入料流程:升降盘定位气缸后退
/// </summary>
FI_01_TrayLocation_After = 11001,
FI_02_TrayLocation_After ,
/// <summary>
/// 入料流程:定位气缸下降
/// </summary>
FI_02_LocationCylinder_Down = 11002,
FI_03_LocationDown,
/// <summary>
/// 入料流程:固定气缸下降
/// </summary>
FI_04_FixedDown,
/// <summary>
/// 入口流水线转动,等待入料检测信号消失
/// </summary>
FI_03_LineStart = 11003,
FI_05_LineStart,
/// <summary>
/// 入口流水线转动,等待定位工位信号稳定1秒
/// </summary>
FI_04_WaitTime = 11004,
FI_06_WaitTime,
/// <summary>
///入料检测: 工位检测信号,固定气缸上升
/// </summary>
FI_07_FixedUp,
/// <summary>
///入料检测: 工位检测信号,定位气缸上升
/// </summary>
FI_05_LocationCylinder_Up,
FI_08_LocationUp,
/// <summary>
/// 入料检测:提升轴下降到位P2
/// </summary>
FI_06_BatchAxisToP2,
FI_11_BatchAxisToP2,
/// <summary>
/// 入料检测:升降盘定位气缸第一次前进
/// </summary>
FI_07_TrayLocation_Before,
FI_12_TrayLocation_Before,
/// <summary>
/// 入料检测:升降盘定位气缸第一次后退
/// </summary>
FI_08_TrayLocation_Back,
FI_13_TrayLocation_Back,
/// <summary>
/// 入料检测:升降盘定位气缸前进
/// </summary>
FI_09_TrayLocation_Before,
FI_14_TrayLocation_Before,
/// <summary>
/// 入料检测:上料轴开始慢速上升到P3点,等待检测到料盘
/// </summary>
FI_10_AxisUpMove,
FI_15_AxisUpMove,
/// <summary>
/// 入料取料:横移机构先上升
/// </summary>
FI_11_CylinderUp,
FI_16_CylinderUp,
/// <summary>
/// 入料取料:上料机构到放料端
/// </summary>
FI_12_CylinderGive,
FI_17_CylinderGive,
/// <summary>
/// 入料检测到料盘:扫码
/// </summary>
FI_13_ScanCode,
FI_18_ScanCode,
/// <summary>
/// 料盘移栽:有料盘:上料横移机构取料
/// </summary>
FI_14_CylinderTake,
FI_21_CylinderTake,
/// <summary>
/// 料盘移栽:升降轴到P3
/// </summary>
FI_15_UpdownAxisToP3,
FI_22_UpdownAxisToP3,
/// <summary>
/// 料盘移栽:上料横移机构夹紧
/// </summary>
FI_16_CylinderTighten,
FI_23_CylinderTighten,
/// <summary>
/// 料盘移栽:升降伺服到P1点
/// </summary>
FI_17_UpdownAxisToP1,
FI_24_UpdownAxisToP1,
/// <summary>
/// 料盘移栽:等待没有伺服料盘检测信号
/// </summary>
FI_18_WaitNoLocationCheck,
FI_25_CheckTray,
/// <summary>
/// 料盘移栽:批量轴到P3点,检测是否有料盘
/// </summary>
FI_19_BatchAxisToP3,
FI_26_BatchAxisToP3,
/// <summary>
/// 料盘移栽:记录高度尺寸
/// </summary>
FI_20_SaveSize,
FI_27_SaveSize,
/// <summary>
/// 料盘移栽: 上料横移气缸放料SOL
/// </summary>
FI_21_CylinderGive,
FI_28_CylinderGive,
/// <summary>
/// 提升轴下降到料盘不溢出的位置
/// </summary>
FI_22_BatchAxisDown,
FI_29_BatchAxisDown,
/// <summary>
/// 等待料盘检测信号
/// </summary>
FI_23_WaitReelCheck,
FI_30_WaitReelCheck,
/// <summary>
/// 料盘移栽:从服务器获取入库库位号
/// </summary>
FI_24_GetPosID,
FI_31_GetPosID,
/// <summary>
/// 料盘移栽:等待空托盘到达,移栽伺服下降到P2,并预扫码
/// </summary>
FI_25_WaitTray,
FI_32_WaitTray,
/// <summary>
/// 料盘移栽: 上料机构下降
/// </summary>
FI_26_CylinderDown,
FI_33_CylinderDown,
/// <summary>
/// 料盘移栽: 上料气缸放松
/// </summary>
FI_27_CylinderRelax,
FI_34_CylinderRelax,
/// <summary>
/// 料盘移栽: 上料横移机构上升
/// </summary>
FI_28_WaitCylinderUp,
FI_35_WaitCylinderUp,
/// <summary>
/// 料盘移栽:上料横移机构上升,定位或者顶升可以先下降
/// </summary>
FI_29_CylinderUp,
FI_36_CylinderUp,
/// <summary>
/// 料盘移栽:升降伺服到P1点
/// </summary>
FI_30_UpDownAxisToP1,
FI_37_UpDownAxisToP1,
/// <summary>
/// 上料完成,未检测到料盘,提升伺服到P2点
/// </summary>
FI_31_BatchAxisToP2 = 11031,
FI_51_BatchAxisToP2 = 11051,
/// <summary>
/// 上料完成,升降盘定位气缸后退
/// </summary>
FI_32_TrayLocationCylinder_After,
FI_52_TrayLocation_After,
/// <summary>
/// 上料完成,提升伺服到P1点
/// 上料完成,提升伺服到P1点,定位气缸下降
/// </summary>
FI_53_BatchAxisToP1,
/// <summary>
/// 上料完成,固定气缸下降
/// </summary>
FI_33_BatchAxisToP1,
FI_54_FixedDown,
/// <summary>
/// 上料完成,等待出料线体无料架
/// </summary>
FI_34_OutCheck,
FI_55_OutCheck,
/// <summary>
/// 上料完成,出口顶升气缸上升
/// </summary>
FI_35_OutTopCylinder_Up,
FI_56_OutTopCylinder_Up,
/// <summary>
///上料完成, 线体横移电机运转,等待料架到达出口
/// </summary>
FI_36_SideWayLineRun,
FI_57_SideWayLineRun,
/// <summary>
///上料完成,等待料架到达出口
/// </summary>
FI_37_WaitShelfGo,
FI_58_WaitShelfGo,
/// <summary>
///上料完成, 料架到达出口,线体横移电机停止
/// </summary>
FI_38_LineStop,
FI_59_LineStop,
/// <summary>
///上料完成, 料架到达出口,出口顶升下降,定位气缸下降,
/// </summary>
FI_39_TopDown,
FI_60_TopDown,
/// <summary>
///上料完成, 出口线体运转,料架到达出口处, 通知AGV取空料架
/// </summary>
FI_39_OutLineRun,
FI_61_OutLineRun,
/// <summary>
///上料完成, AGV到达,继续转动出口线体,送走出料料架,
/// </summary>
FI_40_OutLineRun,
FI_62_OutLineRun,
/// <summary>
///上料完成, 料架送出,
/// </summary>
FI_41_OutLineRun,
FI_63_OutLineRun,
#endregion
#region 入料装置出料处理,12000开始
/// <summary>
/// 出库流程:提升伺服到P2
/// </summary>
FO_00_BatchAxisToP2 = 12000,
FO_01_BatchAxisToP2 = 12001,
/// <summary>
/// 出料流程:升降盘定位气缸后退
/// </summary>
FO_01_TrayLocation_After = 12001,
FO_02_TrayLocation_After,
/// <summary>
/// 出料流程:定位气缸下降
/// </summary>
FO_02_LocationDown = 12002,
FO_03_LocationDown,
/// 出料流程:固定气缸下降
/// </summary>
FO_04_FixedDown,
/// <summary>
/// 入口流水线转动,等待出料检测信号消失
/// </summary>
FO_03_LineStart = 12003,
FO_05_LineStart,
/// <summary>
/// 定位工位检测到料架,等待1秒钟后重新检测
/// </summary>
FO_04_WaitTime = 12004,
FO_06_WaitTime,
/// <summary>
///出料检测: 工位检测信号,固定气缸上升
/// </summary>
FO_07_FixedUp,
/// <summary>
///出料检测: 工位检测信号,定位气缸上升
/// </summary>
FO_05_LocationUp = 12005,
FO_08_LocationUp,
/// <summary>
/// 出料检测:提升轴下降到位P2
/// </summary>
FO_06_BatchAxisToP2 = 12006,
FO_11_BatchAxisToP2,
/// <summary>
/// 出料检测:升降盘定位气缸第一次前进
/// </summary>
FO_07_TrayLocation_Before,
FO_12_TrayLocation_Before,
/// <summary>
/// 出料检测:升降盘定位气缸第一次后退
/// </summary>
FO_08_TrayLocation_Back,
FO_13_TrayLocation_Back,
/// <summary>
/// 出料检测:升降盘定位气缸前进
/// </summary>
FO_09_TrayLocation_Before,
FO_14_TrayLocation_Before,
/// <summary>
/// 出料检测:上料轴开始慢速上升到P3点
/// </summary>
FO_10_AxisUpMove,
FO_15_AxisUpMove,
/// <summary>
/// 紧急出料移栽:上料轴下降指定的高度,同时升降轴回待机点
/// </summary>
FO_211_AxisDownMove = 12211,
FO_21_AxisDownMove=12021,
/// <summary>
/// 紧急出料移栽:上料横移机构取料端
/// /// </summary>
FO_212_CylinderTake = 12212,
FO_22_CylinderTake,
/// <summary>
/// 紧急出料移栽:升降伺服下降到P2
/// /// </summary>
FO_213_UpdownAxisToP2 = 12213,
FO_23_UpdownAxisToP2,
/// <summary>
/// 紧急出料移栽:上料横移机构下降
/// /// </summary>
FO_214_CylinderDown = 12214,
FO_24_CylinderDown,
/// <summary>
/// 紧急出料移栽:上料气缸夹紧
/// /// </summary>
FO_215_CylinderTighten = 12215,
FO_25_CylinderTighten,
/// <summary>
/// 紧急出料移栽:上料横移机构上升
/// 紧急出料移栽:升降伺服到P1
/// /// </summary>
FO_216_CylinderUp = 12216,
FO_26_UpdownAxisToP1,
/// <summary>
/// 紧急出料移栽:升降伺服到P1
/// 紧急出料移栽:检测夹爪料盘检测是否有料
/// /// </summary>
FO_217_UpdownAxisToP1 = 12217,
FO_27_ClampCheck,
/// <summary>
/// 紧急出料移栽:上料横移机构到放料端
/// /// </summary>
FO_218_CylinderGive = 12218,
FO_28_CylinderGive,
/// <summary>
/// 紧急出料移栽:升降伺服到P3
/// </summary>
FO_219_UpdownAxisToP3 = 12219,
FO_29_UpdownAxisToP3,
/// <summary>
/// 紧急出料移栽:出料横移机构放松
/// </summary>
FO_220_CylinderSlack = 12220,
FO_30_CylinderSlack,
/// <summary>
/// 紧急出料移栽:升降伺服回P1
/// </summary>
FO_221_UpdownAxisToP1 = 12221,
FO_31_UpdownAxisToP1,
/// <summary>
/// 紧急出料移栽:上料横移机构到取料端
/// 紧急出料移栽:检测夹爪料盘检测信号无料
/// </summary>
FO_222_CylinderTake = 12222,
FO_32_ClampCheck,
/// <summary>
/// 紧急出料移栽:上料横移机构到取料端
/// </summary>
FO_33_CylinderTake,
/// <summary>
/// 出料完成,料盘已放入料架,提升伺服到P2点
/// </summary>
FO_30_BatchAxisToP2 = 12330,
FO_51_BatchAxisToP2 = 12051,
/// <summary>
/// 出料完成,升降盘定位气缸后退
/// </summary>
FO_31_TrayLocation_After,
FO_52_TrayLocation_After,
/// <summary>
/// 出料完成,提升伺服到P1点
/// 出料完成,提升伺服到P1点,定位气缸下降
/// </summary>
FO_32_BatchAxisToP1,
FO_53_BatchAxisToP1,
/// <summary>
/// 出料完成,固定气缸下降
/// </summary>
FO_54_FixedDown,
/// <summary>
/// 出料完成,等待出料线体无料架
/// </summary>
FO_34_OutCheck,
FO_55_OutCheck,
/// <summary>
/// 出料完成,出口顶升气缸上升
/// </summary>
FO_34_OutTopCylinder_Up,
FO_56_OutTopCylinder_Up,
/// <summary>
///出料完成, 线体横移电机运转,等待料架到达出口
/// </summary>
FO_35_SideWayLineRun,
FO_57_SideWayLineRun,
/// <summary>
///出料完成, 等待料架离开定位工位
/// </summary>
FO_36_WaitShelfGo,
FO_58_WaitShelfGo,
/// <summary>
///出料完成, 料架到达出口,线体横移电机停止
/// </summary>
FO_37_LineStop,
FO_59_LineStop,
/// <summary>
///出料完成, 料架到达出口,出口顶升下降,定位气缸下降,
/// </summary>
FO_38_TopDown,
FO_60_TopDown,
/// <summary>
///出料完成, 出口线体运转,料架到达出口处, 通知AGV取空料架
/// </summary>
FO_39_OutLineRun,
FO_61_OutLineRun,
/// <summary>
///出料完成, AGV到达,继续转动出口线体,送走出料料架,
/// </summary>
FO_40_OutLineRun,
FO_62_OutLineRun,
/// <summary>
///出料完成, 料架送出,
/// </summary>
FO_41_OutLineRun,
FO_63_OutLineRun,
#endregion
#region 出料装置移栽出料,20000开始
......
......@@ -313,13 +313,13 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
public static string SL_MoveCylinder_Give = "SL_MoveCylinder_Give";
/// <summary>
/// DI,105,T5上料气缸放松端,SL_MoveCylinder_Relax,91,HC,X91
/// DI,105,T5上料气缸放松端,SL_ClampCylinder_Relax,91,HC,X91
/// </summary>
public static string SL_MoveCylinder_Relax = "SL_MoveCylinder_Relax";
public static string SL_ClampCylinder_Relax = "SL_ClampCylinder_Relax";
/// <summary>
/// DI,105,T5上料气缸料盘检测,SL_MoveCylinder_Check,92,HC,X92
/// DI,105,T5上料气缸料盘检测,SL_ClampCylinder_Check,92,HC,X92
/// </summary>
public static string SL_MoveCylinder_Check = "SL_MoveCylinder_Check";
public static string SL_ClampCylinder_Check = "SL_ClampCylinder_Check";
/// <summary>
/// DO,105,T5运行指示灯,SL_HddLed,64,HC,Y64
/// </summary>
......@@ -369,9 +369,9 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
public static string SL_FixedCylinder_Down = "SL_FixedCylinder_Down";
/// <summary>
/// DO,105,T5上料气缸夹紧,SL_MoveCylinder_Work,83,HC,Y83
/// DO,105,T5上料气缸夹紧,SL_ClampCylinder_Work,83,HC,Y83
/// </summary>
public static string SL_MoveCylinder_Work = "SL_MoveCylinder_Work";
public static string SL_ClampCylinder_Work = "SL_ClampCylinder_Work";
/// <summary>
/// DO,105,T5托盘定位气缸前进,SL_TrayLocation_Before,84,HC,Y84
/// </summary>
......@@ -614,13 +614,13 @@ namespace OnlineStore.LoadCSVLibrary
//public static string SL_MoveCylinder_Down = "SL_MoveCylinder_Down";
///// <summary>
///// DI /DO SL1上料气缸放松端 SL_MoveCylinder_Relax X128
///// DI /DO SL1上料气缸放松端 SL_ClampCylinder_Relax X128
///// </summary>
//public static string SL_MoveCylinder_Relax = "SL_MoveCylinder_Relax";
//public static string SL_ClampCylinder_Relax = "SL_ClampCylinder_Relax";
///// <summary>
///// DI /DO SL1上料气缸夹紧端 SL_MoveCylinder_Work X129
///// DI /DO SL1上料气缸夹紧端 SL_ClampCylinder_Work X129
///// </summary>
//public static string SL_MoveCylinder_Work = "SL_MoveCylinder_Work";
//public static string SL_ClampCylinder_Work = "SL_ClampCylinder_Work";
///// <summary>
///// DI SL1线体出口横移检测 SL_SideWay_OutCheck X136
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!