|
@@ -92,6 +92,7 @@ namespace Venus_RT.Modules
|
|
|
int _LLASlotNumber = 4;
|
|
|
int _LLBSlotNumber = 4;
|
|
|
int _efemRobotSingleArmOption = 0;
|
|
|
+ SequenceLLInOutPath _LLInOutPath = SequenceLLInOutPath.DInDOut;
|
|
|
|
|
|
List<MoveItem> _movingItems = new List<MoveItem>();
|
|
|
List<MoveItem> _efemMovingItems = new List<MoveItem>();
|
|
@@ -574,6 +575,7 @@ namespace Venus_RT.Modules
|
|
|
UpdateProcessJobStatus();
|
|
|
UpdateControlJobStatus();
|
|
|
StartNewJob();
|
|
|
+ UpdateLLInOutPathProperty();
|
|
|
}
|
|
|
|
|
|
private void driveVacSystem()
|
|
@@ -1187,22 +1189,25 @@ namespace Venus_RT.Modules
|
|
|
|
|
|
return nCount;
|
|
|
}
|
|
|
- private bool IsReadyPushWaferIn()
|
|
|
+
|
|
|
+ private int CanPushInWaferNumber()
|
|
|
{
|
|
|
var llaWaferStatus = GetLLProcessStatusCount(ModuleName.LLA);
|
|
|
var llbWaferStatus = GetLLProcessStatusCount(ModuleName.LLB);
|
|
|
var pmWaferStatus = GetPMWaferExistence();
|
|
|
|
|
|
- if (llaWaferStatus.Item1 + llbWaferStatus.Item1 > 0)
|
|
|
- return false;
|
|
|
-
|
|
|
- if (_LLAInSlot.Count + _LLBInSlot.Count + pmWaferStatus.Item2 - llaWaferStatus.Item2 - llbWaferStatus.Item2 <= 2)
|
|
|
- return false;
|
|
|
-
|
|
|
- if (GetEfemRoborWaferCount() >= 1 && GetAtmInerWaferCount() > 0)
|
|
|
- return false;
|
|
|
-
|
|
|
- return true;
|
|
|
+ if(_LLInOutPath == SequenceLLInOutPath.AInBOut)
|
|
|
+ {
|
|
|
+ return _LLASlotNumber - llaWaferStatus.Item1 - llaWaferStatus.Item2 - GetAtmInerWaferCount() - GetEfemRoborWaferCount();
|
|
|
+ }
|
|
|
+ else if(_LLInOutPath == SequenceLLInOutPath.BInAOut)
|
|
|
+ {
|
|
|
+ return _LLBSlotNumber - llbWaferStatus.Item1 - llbWaferStatus.Item2 - GetAtmInerWaferCount() - GetEfemRoborWaferCount();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return (_LLASlotNumber + _LLBSlotNumber) / 2 + pmWaferStatus.Item2 - GetTMRobotWaferCount() - GetEfemRoborWaferCount() - GetAtmInerWaferCount();
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
private bool IsForwardPathBlocking(ModuleName mod, int slot)
|
|
@@ -1248,7 +1253,8 @@ namespace Venus_RT.Modules
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- if(_efemMovingItems.Count == 0 && IsReadyPushWaferIn())
|
|
|
+ var canPushInWafers = CanPushInWaferNumber();
|
|
|
+ if(_efemMovingItems.Count == 0 && canPushInWafers > 0)
|
|
|
{
|
|
|
var outSlots = GetNextWaferInJobQueue(lp);
|
|
|
|
|
@@ -1258,13 +1264,14 @@ namespace Venus_RT.Modules
|
|
|
_efemMovingItems.Add(new MoveItem(lp, outSlots[0], ModuleName.EfemRobot, (int)hand, hand));
|
|
|
}
|
|
|
|
|
|
-
|
|
|
- hand = GetEFEMRobotFreeHand();
|
|
|
- if (hand != Hand.None && outSlots.Count> 1 && !IsForwardPathBlocking(lp, outSlots[1]))
|
|
|
+ if(canPushInWafers > 1)
|
|
|
{
|
|
|
- _efemMovingItems.Add(new MoveItem(lp, outSlots[1], ModuleName.EfemRobot, (int)hand, hand));
|
|
|
+ hand = GetEFEMRobotFreeHand();
|
|
|
+ if (hand != Hand.None && outSlots.Count > 1 && !IsForwardPathBlocking(lp, outSlots[1]))
|
|
|
+ {
|
|
|
+ _efemMovingItems.Add(new MoveItem(lp, outSlots[1], ModuleName.EfemRobot, (int)hand, hand));
|
|
|
+ }
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
|
|
|
return _efemMovingItems.Count > 0;
|
|
@@ -1902,9 +1909,6 @@ namespace Venus_RT.Modules
|
|
|
if (_lstControlJobs.Count == 0)
|
|
|
return;
|
|
|
|
|
|
- //if (_curAction.state != ActionState.Done)
|
|
|
- // return;
|
|
|
-
|
|
|
bool allControlJobComplete = true;
|
|
|
List<ControlJobInfo> cjRemoveList = new List<ControlJobInfo>();
|
|
|
foreach (var cj in _lstControlJobs)
|
|
@@ -2039,13 +2043,42 @@ namespace Venus_RT.Modules
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private void UpdateLLInOutPathProperty()
|
|
|
+ {
|
|
|
+ if (_lstControlJobs.Count == 0)
|
|
|
+ return;
|
|
|
+
|
|
|
+ List<SequenceLLInOutPath> inOutPaths = new List<SequenceLLInOutPath>();
|
|
|
+ foreach (var cj in _lstControlJobs)
|
|
|
+ {
|
|
|
+ if (cj.State == EnumControlJobState.Executing)
|
|
|
+ {
|
|
|
+ bool allPjCompleted = true;
|
|
|
+ foreach (var pjName in cj.ProcessJobNameList)
|
|
|
+ {
|
|
|
+ var pj = _lstProcessJobs.Find(x => x.Name == pjName);
|
|
|
+ if (pj == null || pj.State != EnumProcessJobState.Processing)
|
|
|
+ continue;
|
|
|
+
|
|
|
+ if (!inOutPaths.Exists(item => item == pj.Sequence.LLInOutPath))
|
|
|
+ inOutPaths.Add(pj.Sequence.LLInOutPath);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ if (inOutPaths.Count == 1)
|
|
|
+ {
|
|
|
+ _LLInOutPath = inOutPaths[0];
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
private static WaferInfo GetCloneWafer(ModuleName mod, int slot)
|
|
|
{
|
|
|
var Wafer = WaferManager.Instance.GetWafer(mod, slot);
|
|
|
if (Wafer.IsEmpty || Wafer.ProcessJob == null || Wafer.ProcessJob.Sequence == null)
|
|
|
return Wafer;
|
|
|
|
|
|
- var cloneWafer = Wafer.Clone(Wafer);
|
|
|
+ var cloneWafer = SerializeHelper.DeepCopyJson(Wafer);
|
|
|
|
|
|
if (Wafer.IsEmpty || Wafer.ProcessJob == null || Wafer.ProcessJob.Sequence == null)
|
|
|
return Wafer;
|