|
@@ -5,6 +5,7 @@ using Aitex.Core.RT.Event;
|
|
|
using Aitex.Core.RT.IOCore;
|
|
|
using Aitex.Core.RT.Log;
|
|
|
using Aitex.Core.RT.OperationCenter;
|
|
|
+using Aitex.Core.RT.Routine;
|
|
|
using Aitex.Core.RT.SCCore;
|
|
|
using Aitex.Core.Util;
|
|
|
using DocumentFormat.OpenXml.VariantTypes;
|
|
@@ -210,9 +211,8 @@ namespace FurnaceRT.Equipments.PMs
|
|
|
{
|
|
|
if (item == null)
|
|
|
continue;
|
|
|
- // var data=Math.Round(stepTime, 1, MidpointRounding.AwayFromZero);
|
|
|
-
|
|
|
- Singleton<ScheduleMaintenanceDataManager>.Instance.Increase(item.Item, (float)stepTime);
|
|
|
+ var data = Math.Round(stepTime, 1, MidpointRounding.AwayFromZero);
|
|
|
+ Singleton<ScheduleMaintenanceDataManager>.Instance.Increase(item.Item, (float)data);
|
|
|
|
|
|
|
|
|
|
|
@@ -251,26 +251,15 @@ namespace FurnaceRT.Equipments.PMs
|
|
|
/// 根据RecipeName统计 Recipe执行 累计次数
|
|
|
/// </summary>
|
|
|
/// <param name="processRecipeName"></param>
|
|
|
- public void UpdateRecipeFre(string recipeName, out bool result)
|
|
|
+ public void UpdateRecipeFre(string recipeName)
|
|
|
{
|
|
|
- result = true;
|
|
|
|
|
|
if (string.IsNullOrEmpty(recipeName))
|
|
|
return;
|
|
|
var item = Singleton<ScheduleMaintenanceDataManager>.Instance.Item.Values.Where(a => a.Item == MaintenanceItemEnum.RecipeExecuteFreq.ToString() && a.Path == $"{DataItemEnum.Reactor}.{ReactorsEnum.Recipe}" && a.AdditionInformationDisplay == recipeName).FirstOrDefault();
|
|
|
if (item == null)
|
|
|
return;
|
|
|
-
|
|
|
- if (item.CurrentValue > item.StartValue && item.CurrentValue < item.LimitValue)
|
|
|
- MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeExecuteFreqWarning.Set, $"more than {item.StartValue} times"));
|
|
|
-
|
|
|
- if (item.CurrentValue >= item.LimitValue)
|
|
|
- {
|
|
|
- MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeExecuteFreqAlarm.Set, $"more than {item.LimitValue} times"));
|
|
|
- result = false;
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
+
|
|
|
if (item != null && item.Item == MaintenanceItemEnum.RecipeExecuteFreq.ToString())
|
|
|
Singleton<ScheduleMaintenanceDataManager>.Instance.Increase(item.Item);
|
|
|
|
|
@@ -293,17 +282,58 @@ namespace FurnaceRT.Equipments.PMs
|
|
|
if (item != null && item.Item == MaintenanceItemEnum.RecipeThickness.ToString())
|
|
|
Singleton<ScheduleMaintenanceDataManager>.Instance.Increase(item.Item, thickness);
|
|
|
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ #endregion
|
|
|
+
|
|
|
+ #region 检查是否超过设定值
|
|
|
+
|
|
|
+ public bool CheckRecipeExecuteFreqMoreThan(string recipeName)
|
|
|
+ {
|
|
|
+
|
|
|
+ if (string.IsNullOrEmpty(recipeName))
|
|
|
+ return false;
|
|
|
+ var item = Singleton<ScheduleMaintenanceDataManager>.Instance.Item.Values.Where(a => a.Item == MaintenanceItemEnum.RecipeExecuteFreq.ToString() && a.Path == $"{DataItemEnum.Reactor}.{ReactorsEnum.Recipe}" && a.AdditionInformationDisplay == recipeName).FirstOrDefault();
|
|
|
+ if (item == null)
|
|
|
+ return false;
|
|
|
+
|
|
|
if (item.CurrentValue > item.StartValue && item.CurrentValue < item.LimitValue)
|
|
|
+ {
|
|
|
+ MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeExecuteFreqWarning.Set, $"more than {item.StartValue} times"));
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (item.CurrentValue >= item.LimitValue)
|
|
|
+ {
|
|
|
+ MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeExecuteFreqAlarm.Set, $"more than {item.LimitValue} times"));
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ public bool CheckRecipeThicknessMoreThan(string recipeName)
|
|
|
+ {
|
|
|
+ if (string.IsNullOrEmpty(recipeName))
|
|
|
+ return false;
|
|
|
+ var item = Singleton<ScheduleMaintenanceDataManager>.Instance.Item.Values.Where(a => a.Item == MaintenanceItemEnum.RecipeThickness.ToString() && a.Path == $"{DataItemEnum.Reactor}.{ReactorsEnum.Recipe}" && a.AdditionInformationDisplay == recipeName).FirstOrDefault();
|
|
|
+
|
|
|
+ if (item == null)
|
|
|
+ return false;
|
|
|
+
|
|
|
+ if (item.CurrentValue > item.StartValue && item.CurrentValue < item.LimitValue)
|
|
|
+ {
|
|
|
MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeThicknessWarning.Set, $"more than {item.StartValue} Å"));
|
|
|
+ return false;
|
|
|
+ }
|
|
|
|
|
|
if (item.CurrentValue >= item.LimitValue)
|
|
|
+ {
|
|
|
MaintenanceProcessingCommandExec(item.MaintenanceProcessing, new AlarmReportItem(Singleton<EquipmentManager>.Instance.RecipeThicknessAlarm.Set, $"more than {item.LimitValue} Å"));
|
|
|
+ return true;
|
|
|
+ }
|
|
|
|
|
|
-
|
|
|
+ return false;
|
|
|
}
|
|
|
-
|
|
|
#endregion
|
|
|
-
|
|
|
-
|
|
|
}
|
|
|
}
|