Commit afb5dcce LN

2.出料随意放条件修改。

1 个父辈 4a70e617
20200323
。出库料盘在料仓门口,入库又拿了一盘料。
皮带线6有时会转两个盘到接驳台
20200324
1.入库逻辑修改:提升轴先上升后需要下降到料盘不溢出的位置,横移气缸才能动作。
2.出料模块取料条件修改:随意放时需要等皮带线空闲。
20200323
。出库料盘在料仓门口,入库又拿了一盘料。
皮带线6有时会转两个盘到接驳台
20200317
1.托盘检测的还会报警。
2.伺服问题?测高不准确。
3.条码扫一种类型后,判断有有效条码则不再扫码。
3.条码扫一种类型后,判断有有效条码则不再扫码。
20200315:
皮带线报警后不继续转动皮带线。
http发送去掉ping。
http发送去掉ping。
20200314:
出料机构:如果是7寸盘,提前放行托盘
皮带线123:增加NG气缸逻辑
急停判断修改。
急停判断修改。
......
......@@ -422,6 +422,7 @@ namespace OnlineStore.DeviceLibrary
IoCheckTimer.Enabled = false;
mainTimer.Enabled = false;
AgvClient.SetCancelState(true);
RFIDManager.Close();
//停止运行时,把阻挡气缸上升
//StopMove();
foreach (EquipBase equip in this.AllEquipMap.Values)
......@@ -451,7 +452,6 @@ namespace OnlineStore.DeviceLibrary
WriteDrivetMotorRun(IO_VALUE.LOW);
LineServer.StopServer();
RFIDManager.Close();
TimeSpan span = DateTime.Now - StartTime;
LogUtil.info(Name + ",停止运行,总运行时间:" + span.ToString());
}
......
......@@ -107,7 +107,7 @@ namespace OnlineStore.DeviceLibrary
}
private void MO_14_TopCylinder_Down()
{
// SecondMoveInfo.NewMove(LineMoveType.CheckFixture);
// SecondMoveInfo.NewMove(LineMoveType.CheckFixture);
OutLog("放托盘(放开阻挡)" + MoveInfo.SLog + " 物品已移走,顶升气缸1下降");
SecondMoveInfo.NextMoveStep(LineMoveStep.MO_14_TopDown);
if (Config.SidesWayNum <= 0)
......@@ -122,7 +122,7 @@ namespace OnlineStore.DeviceLibrary
CheckLog("托盘放行 " + SecondMoveInfo.SLog + " ,阻挡2下降");
IOMove(IO_Type.StopCylinder_Down2, IO_VALUE.HIGH);
SecondMoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.StopCylinder_Down2, IO_VALUE.HIGH));
}
}
}
else
{
......@@ -130,9 +130,9 @@ namespace OnlineStore.DeviceLibrary
CheckLog("托盘放行 结束,触发 TrayPEndEvent ");
lastStopDown = DateTime.Now.AddSeconds(-2);
this.TrayPEndEvent?.Invoke(Config.SidesWayNum, currTrayNum);
}
}
}
private InOutParam CheckIsNeedOutStore(out string outMsg )
private InOutParam CheckIsNeedOutStore(out string outMsg)
{
outMsg = "";
int lineNum = DeviceID % 100;
......@@ -152,8 +152,8 @@ namespace OnlineStore.DeviceLibrary
}
else if (trayInfo.InOrOutStore.Equals(ReelType.OutStore) && inoup.urgentReel.Equals(false) && inoup.cutReel.Equals(false))
{
List<int> mustLine = new List<int> ();
List<int> firstLine = new List<int> ();
List<int> mustLine = new List<int>();
List<int> firstLine = new List<int>();
//urgentReel: true 表示紧急料,需要出到料串上
//cutReel: true 表示分盘料,需要出到料串上
//smallReel: true 小料(7x8),放置到小料架上
......@@ -164,17 +164,17 @@ namespace OnlineStore.DeviceLibrary
{
//-1时随意放
}
else if (inoup.smallReel)
{
else if (inoup.smallReel)
{
if (inoup.rfidLoc >= 70 && inoup.rfidLoc <= 72)
{
// 70,71,72时只能分配到3 / 4号皮带线;
mustLine = new List<int> { 3,4};
}
mustLine = new List<int> { 3, 4 };
}
else if (inoup.rfidLoc <= 46)
{
// 小料时,架位为1 - 46优先走1 / 2号皮带线
firstLine = new List<int> { 1, 2 };
firstLine = new List<int> { 1, 2 };
}
else if (inoup.rfidLoc >= 47)
{
......@@ -191,7 +191,7 @@ namespace OnlineStore.DeviceLibrary
{
// 大料12号只能走1号2后皮带线
mustLine = new List<int> { 1, 2 };
}
}
else if (inoup.rfidLoc <= 6)
{
firstLine = new List<int> { 1, 2 };
......@@ -199,9 +199,9 @@ namespace OnlineStore.DeviceLibrary
else if (inoup.rfidLoc >= 7)
{
firstLine = new List<int> { 3, 4 };
}
}
}
bool kongxian = MoveInfo.MoveType.Equals(LineMoveType.None)||MoveInfo.MoveStep>=LineMoveStep. PO_08_CylinderRelax;
bool kongxian = MoveInfo.MoveType.Equals(LineMoveType.None) || MoveInfo.MoveStep >= LineMoveStep.PO_08_CylinderRelax;
if (mustLine.Count > 0)
{
if (mustLine.Contains(lineNum))
......@@ -209,34 +209,44 @@ namespace OnlineStore.DeviceLibrary
outMsg = "必须线";
return inoup;
}
}else if (firstLine.Count > 0 )
}
else if (firstLine.Count > 0)
{
if (firstLine.Contains(lineNum)&& kongxian)
if (firstLine.Contains(lineNum) && kongxian)
{
outMsg = "优先线且空闲";
return inoup;
}else if (LineManager.Line.ProvidingCanUse(firstLine).Equals(false)&& kongxian)
}
else if (LineManager.Line.ProvidingCanUse(firstLine).Equals(false) && kongxian && LineNotBusy())
{
outMsg = "优先线不可用";
//优先线不可用
return inoup;
}else if(span.TotalSeconds > youxianS&& kongxian)
}
else if (span.TotalSeconds > youxianS && kongxian && LineNotBusy())
{
outMsg = "超过180秒";
//超过指定的时间
return inoup;
}
else if (span.TotalSeconds > youxianS * 3 && kongxian)
{
outMsg = "超过9分钟";
//超过指定的时间
return inoup;
}
}
else
else
{
if (kongxian)
//空闲且皮带线出料已结束
if (kongxian && LineNotBusy())
{
outMsg = "随意放";
return inoup;
}
}
}
//TODO 判断是否是需要移栽出料的料盘
return null;
}
......@@ -330,8 +340,8 @@ namespace OnlineStore.DeviceLibrary
}
else if (SecondMoveInfo.MoveStep.Equals(LineMoveStep.MIO_05_WaitTime))
{
SecondMoveInfo.NextMoveStep(LineMoveStep.MIO_06_TopUp);
CylinderMove(SecondMoveInfo, IO_Type.TopCylinder_Down, IO_Type.TopCylinder_UP);
SecondMoveInfo.NextMoveStep(LineMoveStep.MIO_06_TopUp);
CylinderMove(SecondMoveInfo, IO_Type.TopCylinder_Down, IO_Type.TopCylinder_UP);
if (Config.SidesWayNum.Equals(4) && LineManager.Line.SwCanUpMove(1))
{
CheckLog("托盘阻挡 " + SecondMoveInfo.SLog + " 顶升气缸上升,同时横移1处的顶升也可以上升 ");
......@@ -370,7 +380,7 @@ namespace OnlineStore.DeviceLibrary
else
{
SecondMoveInfo.NextMoveStep(LineMoveStep.MO_15_WaitCanGo);
CheckLog("托盘放行 " + SecondMoveInfo.SLog + " ,等待 NextStopCheck=0");
CheckLog("托盘放行 " + SecondMoveInfo.SLog + " ,等待 NextStopCheck=0");
// SecondMoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.NextStopCheck, IO_VALUE.LOW));
}
......@@ -411,7 +421,7 @@ namespace OnlineStore.DeviceLibrary
#region 料盘移栽处理
public override bool StartOutStoreMove(InOutParam param)
{
string posId = param != null ? param.PosId : "";
string posId = param != null ? param.PosId : "";
if (runStatus.Equals(LineRunStatus.Runing))
{
runStatus = LineRunStatus.Busy;
......@@ -481,13 +491,13 @@ namespace OnlineStore.DeviceLibrary
MoveInfo.NextMoveStep(LineMoveStep.PO_04_CylinderUp);
OutLog("出料 " + MoveInfo.SLog + " : 上下气缸上升,皮带线准备出料");
UpdownUpMove();
StartLineOut(MoveInfo.MoveParam);
StartLineOut(MoveInfo.MoveParam);
if (MoveInfo.MoveParam.PlateW.Equals(7))
{
MO_14_TopCylinder_Down();
}
else if (Config.SidesWayNum <= 0)
{
{
CylinderMove(null, IO_Type.TopCylinder_UP, IO_Type.TopCylinder_Down);
}
}
......@@ -590,7 +600,7 @@ namespace OnlineStore.DeviceLibrary
}
catch (Exception ex)
{
LogUtil.error(Name,ex);
LogUtil.error(Name, ex);
}
return null;
}
......@@ -655,7 +665,24 @@ namespace OnlineStore.DeviceLibrary
{
LogUtil.error(Name + "StartLineOut未找到对应的皮带线");
}
}
#endregion
}
private bool LineNotBusy()
{
OutTrayLineBean outline = GetDisLine();
if (outline != null)
{
if (outline.equipBean.MoveInfo.MoveType.Equals(LineMoveType.None))
{
return true;
}
}
else
{
LogUtil.error(Name + "StartLineOut未找到对应的皮带线");
}
return false;
}
#endregion
}
}
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!