Browse Source

1:GemModel重复项
2:CJStop/CJAbort区分

jiangjy 1 week ago
parent
commit
4a1a7e1634

+ 0 - 1
Furnace/FurnaceRT/Config/FurnaceGemModel.xml

@@ -9353,7 +9353,6 @@
 		<DVID id="3524" valueType="Ascii" logicalName="StepId" value="" eventTrigger="" description="StepId" isArray="false" />
 		<DVID id="3525" valueType="Ascii" logicalName="RecipeName" value="" eventTrigger="" description="RecipeName" isArray="false" />
 		<DVID id="3526" valueType="List" logicalName="BoatSlotMapList" value="" eventTrigger="" description="List of boat map slot result.&#xD;&#xA;L, n&#xD;&#xA;L, 3&#xD;&#xA;&lt;SlotMapInt&gt; &#xD;&#xA;&lt;TimeIn&gt;&#xD;&#xA;&lt;TimeOut&gt;" isArray="false" />
-		<DVID id="3526" valueType="List" logicalName="BoatSlotMapList" value="" eventTrigger="" description="List of boat map slot result.&#xD;&#xA;L, n&#xD;&#xA;L, 3&#xD;&#xA;&lt;SlotMapInt&gt; &#xD;&#xA;&lt;TimeIn&gt;&#xD;&#xA;&lt;TimeOut&gt;" isArray="false" />
 	</DataVariables>
 	<DataCollections useAnnotatedEvent="false">
 		<RPTIDs>

+ 14 - 1
Furnace/FurnaceRT/Equipments/Jobs/AutoTransfer.cs

@@ -49,6 +49,7 @@ using MECF.Framework.Common.CommonData.SorterDefines;
 using MECF.Framework.Common.Extens;
 using MECF.Framework.RT.EquipmentLibrary.HardwareUnits.LoadPorts.TDK;
 using System.Windows.Ink;
+using Aitex.Core.UI.Control;
 
 namespace FurnaceRT.Equipments.Jobs
 {
@@ -197,7 +198,19 @@ namespace FurnaceRT.Equipments.Jobs
                 return stockerUseSlots;
             });
         }
+        public void FACallBack(string faAction)
+        {
+            if (faAction == "CJ_ABORTED")
+            {
+                var cjActive = _lstControlJobs.Find(x => x.State == EnumControlJobState.Executing);
+                if (cjActive != null)
+                {
+                    var pj = GetFirstProcessJob(cjActive);
+                    _faCallback.CJAbort(cjActive, pj);
+                }
+            }
 
+        }
         public void Clear()
         {
             _carrierRobot.ResetTask();
@@ -800,7 +813,7 @@ namespace FurnaceRT.Equipments.Jobs
                     if (pj.State == EnumProcessJobState.Processing)
                     {
                         _faCallback.JobAborted(cj, pj);
-                        _faCallback.CJAbort(cj, pj);
+                        _faCallback.CJStop(cj, pj);
 
                     }
                     pj.SetState(EnumProcessJobState.Aborting);

+ 15 - 1
Furnace/FurnaceRT/Equipments/Schedulers/SchedulerFACallback.cs

@@ -98,7 +98,7 @@ namespace FurnaceRT.Equipments.Schedulers
                 EV.Subscribe(new EventItem("Event", UniversalEvents.SideDummyStateWarning, $"SideDummyStateWarning"));
                 EV.Subscribe(new EventItem("Event", UniversalEvents.ExtraDummyStateWarning, $"ExtraDummyStateWarning"));
 
-            
+
 
 
                 PortId[module] = i.ToString();
@@ -596,6 +596,19 @@ namespace FurnaceRT.Equipments.Schedulers
                 {
                     {DataVariables.CJID,  cj.Name},
                        {DataVariables.PRJobID,  pj.Name},
+                       {DataVariables.RecID,  pj.JobRecipe},
+                });
+            }
+        }
+        public void CJStop(ControlJobInfo cj, ProcessJobInfo pj)
+        {
+            if (cj != null)
+            {
+                EV.Notify(Gem300Events.CJ_STOPPED, new SerializableDictionary<string, object>()
+                {
+                    {DataVariables.CJID,  cj.Name},
+                    {DataVariables.PRJobID,  pj.Name},
+                    {DataVariables.RecID,  pj.JobRecipe},
                 });
             }
         }
@@ -607,6 +620,7 @@ namespace FurnaceRT.Equipments.Schedulers
                 {
                     {DataVariables.CJID,  cj.Name},
                     {DataVariables.PRJobID,  pj.Name},
+                    {DataVariables.RecID,  pj.JobRecipe},
                 });
             }
         }

+ 3 - 0
Furnace/FurnaceRT/Equipments/Systems/EquipmentManager.cs

@@ -33,6 +33,7 @@ using MECF.Framework.Common.Alarms;
 using MECF.Framework.Common.DataCenter;
 using MECF.Framework.Common.Device.Bases;
 using MECF.Framework.Common.Equipment;
+using MECF.Framework.Common.FAServices;
 using MECF.Framework.Common.Jobs;
 using MECF.Framework.Common.SCCore;
 using MECF.Framework.Common.SubstrateTrackings;
@@ -1059,6 +1060,8 @@ namespace FurnaceRT.Equipments.Systems
 
             if (FsmState == (int)RtState.AutoRunning)
             {
+                _auto.FACallBack(Gem300Events.CJ_ABORTED);
+
                 _auto.Clear();
             }
 

+ 1 - 1
Furnace/FurnaceUI/Views/Status/ControlJobStatusViewModel.cs

@@ -77,7 +77,7 @@ namespace FurnaceUI.Views.Status
             {
                 if (LocalProcessJobs != null&&!string.IsNullOrEmpty(SelectedControlJobsObjtID))
                 {
-                    return LocalProcessJobs.Where(a => a.ControlJobName == SelectedControlJobsObjtID).FirstOrDefault().LayoutRecipe;
+                    return LocalProcessJobs.Where(a => a.ControlJobName == SelectedControlJobsObjtID).FirstOrDefault()?.LayoutRecipe;
                 }
                 return SelectedControlJob != null ? SelectedControlJob.Name : "";
             }