新增凹版收卷结束信号30S不做处理逻辑

master
CaesarBao 4 weeks ago
parent 4407d8d326
commit 50fbf67d3e

@ -418,7 +418,7 @@ namespace MaterialTraceability.Business.Impl
return;
}
//下发禁止下料
sendError(position);
//sendError(position);
//调用MES获取数量接口
string upMaterialEaValue = GetUpMaterialQty(position, shaftInfo.bindSfc, logStr);
@ -427,7 +427,7 @@ namespace MaterialTraceability.Business.Impl
LogRefreshEvent?.Invoke(LogType.MesLog, String.Format("通过MES获取收卷位{0}物料EA值为空", shaftInfo.bindSfc));
return;
}
downRecord.eaValue = int.Parse(upMaterialEaValue);
downRecord.eaValue = (int)float.Parse(upMaterialEaValue);
LogRefreshEvent?.Invoke(LogType.RfidLog, "收卷位物料EA" + upMaterialEaValue);
if (!SpiltAccount(position, shaftInfo, downRecord.eaValue, shaftInfo.bindSfc, new ProUpRecord(), downRecord).Result)
{
@ -552,7 +552,7 @@ namespace MaterialTraceability.Business.Impl
/// <returns></returns>
private string GetUpMaterialQty(int position,string bindSfc, string logStr)
{
LogHelper.Info(logStr + "通过MES接口获取放卷物料的EA值");
LogHelper.Info(logStr + "通过MES接口获取物料的EA值");
MiSFCQueryQtyServiceServiceParam sFCQueryQtyServiceServiceParam = new MiSFCQueryQtyServiceServiceParam()
{
url = inifile.IniReadValue("MiSFCQueryQtyServiceServiceParam", "url"),
@ -931,7 +931,7 @@ namespace MaterialTraceability.Business.Impl
{
url = inifile.IniReadValue("ResourceSlotConfigurationSetupForJITServiceParam", "url"),
site = inifile.IniReadValue("ResourceSlotConfigurationSetupForJITServiceParam", "site"),
resource = inifile.IniReadValue("ResourceSlotConfigurationSetupForJITServiceParam", "resource"),
resource = appConfig.resource,
operation = inifile.IniReadValue("ResourceSlotConfigurationSetupForJITServiceParam", "operation"),
barcodeId = epc,
barcodeType = inifile.IniReadValue("ResourceSlotConfigurationSetupForJITServiceParam", "barcodeType"),

@ -30,6 +30,11 @@ namespace MaterialTraceability.Business
private static DateTime lastReadTime_Force;
private static DateTime lastReadTime_ForceSecond; //模切暂用
private static DateTime AB_lastReadTime_SJForceSinal; //凹版收卷结束信号
private static DateTime AB_lastReadTime_SJEndSinal; //凹版收卷结束信号
#endregion
@ -78,6 +83,8 @@ namespace MaterialTraceability.Business
lastReadTime_B_End = initTime;
lastReadTime_Force = initTime;
lastReadTime_ForceSecond = initTime;
AB_lastReadTime_SJForceSinal = initTime;
AB_lastReadTime_SJEndSinal = initTime;
#endregion
return plcInstance;
@ -209,26 +216,34 @@ namespace MaterialTraceability.Business
if (plcInstance.readInt32ByAddress(appConfig.AbAddress.) == 1)
{
lock (string.Empty)
{
if (isReadFlag(ref AB_lastReadTime_SJEndSinal))
{
plcInstance.writeInt32ByAddress(appConfig.AbAddress., 0);
SignalRefreshEvent?.Invoke(4, 1);
}
}
}
//异常下料-1A
if (plcInstance.readInt32ByAddress(appConfig.AbAddress.) == 1)
{
plcInstance.writeInt32ByAddress(appConfig.AbAddress., 0);
SignalRefreshEvent?.Invoke(5, 1);
SignalRefreshEvent?.Invoke(5, 0);
}
//异常下料-1B
if (plcInstance.readInt32ByAddress(appConfig.AbAddress.) == 1)
{
if (isReadFlag(ref AB_lastReadTime_SJForceSinal))
{
plcInstance.writeInt32ByAddress(appConfig.AbAddress., 0);
SignalRefreshEvent?.Invoke(5, 2);
SignalRefreshEvent?.Invoke(5, 1);
}
}
}
#endregion
#region 涂布

Loading…
Cancel
Save