Commit 671eef54 张东亮

添加料盘没有入到位撞到抽屉信号检查

1 个父辈 19012a25
......@@ -91,6 +91,11 @@ DI,2,出料防护门下降端,UnderArea_OutstoreDoor_DownCheck,72,HC,X72,,,,,,,,
DI,1,上料机构左侧防护门门禁,Feeding_LDoor_Limit,73,HC,X73,,,,,,,,,,,,
DI,1,上料机构右侧防护门门禁,Feeding_RDoor_Limit,74,HC,X74,,,,,,,,,,,,
,,,,,,,,,,,,,,,,,,
DI,2,左料叉7寸入料到位检测,ForkA_Tray7_InPos_Check,75,HC,X75,,,,,,,,,,,,
DI,2,左料叉13寸入料到位检测,ForkA_Tray13_InPos_Check,76,HC,X76,,,,,,,,,,,,
DI,2,右料叉7寸入料到位检测,ForkB_Tray7_InPos_Check,77,HC,X77,,,,,,,,,,,,
DI,2,右料叉13寸入料到位检测,ForkB_Tray13_InPos_Check,78,HC,X78,,,,,,,,,,,,
,,,,,,,,,,,,,,,,,,
DO,2,自动绿色指示灯(存储机构),RunSign_HddLed,0,HC,Y00,,,,,,,,,,,,
DO,2,故障红色指示灯(存储机构),Alarm_HddLed,1,HC,Y01,,,,,,,,,,,,
DO,2,待机黄色指示灯(存储机构),AutoRun_HddLed,2,HC,Y02,,,,,,,,,,,,
......
......@@ -477,7 +477,7 @@ namespace OnlineStore.DeviceLibrary
/// 料仓入库:进入库位中,移栽升降轴到A/B面料屉取放点
/// </summary>
SI_13_GetReel,
SI_13_CheckPos,
///// <summary>
///// 料仓入库:压紧轴开始缓慢释放,A/B面移栽压紧轴到P2(压紧前点)
///// </summary>
......
using CodeLibrary;
using OnlineStore.Common;
using OnlineStore.Common;
using OnlineStore.DeviceLibrary.deviceLibrary;
using OnlineStore.LoadCSVLibrary;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms.VisualStyles;
namespace OnlineStore.DeviceLibrary
{
partial class BoxEquip
{
/// <summary>
/// 料盘是否在库位正常
/// </summary>
/// <param name="posId"></param>
/// <param name="width"></param>
/// <returns></returns>
bool isReelInpos(string posId, int width)
{
if (ConfigHelper.Config.Get("入库料盘到位检测启用", false))
{
return true;
}
else
{
if (posId.Contains("A"))
{
if (width == 7)
{
return IOValue(IO_Type.ForkA_Tray7_InPos_Check).Equals(IO_VALUE.LOW);
}
else
{
return IOValue(IO_Type.ForkA_Tray13_InPos_Check).Equals(IO_VALUE.LOW);
}
}
else
{
if (width == 7)
{
return IOValue(IO_Type.ForkB_Tray7_InPos_Check).Equals(IO_VALUE.LOW);
}
else
{
return IOValue(IO_Type.ForkB_Tray13_InPos_Check).Equals(IO_VALUE.LOW);
}
}
}
}
#region 入库
/// <summary>
/// 检查另一个料叉上是否有料,有料则开始入库
......@@ -414,10 +444,21 @@ namespace OnlineStore.DeviceLibrary
UpdownAxisToP7_P13();
break;
case StepEnum.SI_13_GetReel:
MoveInfo.NextMoveStep(StepEnum.SI_14_ReleaseCompress);
MoveInfo.NextMoveStep(StepEnum.SI_13_CheckPos);
LogInfo($"入库 {MoveInfo.SLog}:压紧轴开始缓慢释放,移栽压紧轴到压紧前点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
ComAxis_To_P2();
break;
case StepEnum.SI_13_CheckPos:
MoveInfo.NextMoveStep(StepEnum.SI_14_ReleaseCompress);
var inpos = isReelInpos(MoveInfo.MoveParam.PosInfo.PosId, MoveInfo.MoveParam.PosInfo.PlateW);
if (!inpos)
{
SetCriticalMsg($"入库料盘异常,请检查料盘是否放置正确,确认无误后点击继续");
LogInfo($"入库 {MoveInfo.SLog}:入库料盘异常,请检查料盘是否放置正确,确认无误后点击继续");
MoveStop = true;
}
LogInfo($"入库 {MoveInfo.SLog}:料盘到位检测完成[{inpos}]:{MoveInfo.MoveParam.PosInfo.PosId},{MoveInfo.MoveParam.PosInfo.PlateW}");
break;
case StepEnum.SI_14_ReleaseCompress:
if (!StoreManager.XLRStore.boxEquip.SendStoreState(MoveInfo.MoveParam.PosInfo.PosId, MoveInfo.MoveParam.PosInfo.barcode, DeviceStatus.InStoreEnd))
return;
......
......@@ -3,7 +3,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
namespace OnlineStore.LoadCSVLibrary
{
......@@ -26,7 +26,7 @@ namespace OnlineStore.LoadCSVLibrary
}
return TypeList;
}
/// <summary>
......@@ -351,7 +351,14 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
public static string Feeding_RDoor_Limit = "Feeding_RDoor_Limit";
// X75 左料叉7寸入料到位检测
//X76 左料叉13寸入料到位检测
//X77 右料叉7寸入料到位检测
//X78 右料叉13寸入料到位检测
public static string ForkA_Tray7_InPos_Check = "ForkA_Tray7_InPos_Check";
public static string ForkA_Tray13_InPos_Check = "ForkA_Tray13_InPos_Check";
public static string ForkB_Tray7_InPos_Check = "ForkB_Tray7_InPos_Check";
public static string ForkB_Tray13_InPos_Check = "ForkB_Tray13_InPos_Check";
/// <summary>
/// DO,2,自动绿色指示灯(存储机构),RunSign_HddLed,0,HC,Y00,,,,,,,,,,,,
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!