Example #1
0
        public static bool IsFilterPreventLayerChange(AoEquipment aeqp, FabLot lot)
        {
            var eqp = aeqp.ToFabAoEquipment();

            //if (eqp.EqpID == "THCVDC00" && eqp.NowDT >= LcdHelper.StringToDateTime("20200108 090229"))
            //	Console.WriteLine("B");

            WeightFactor wf = WeightHelper.GetWeightFactor(eqp.Target.Preset, Constants.WF_PREVENT_LAYER_CHANGE_FILTER);

            if (wf == null || wf.Factor == 0)
            {
                return(false);
            }

            var step = lot.CurrentFabStep;

            if (IsLastRunStep(eqp, step))
            {
                return(false);
            }

            var stepList = SimHelper.GetDspEqpSteps(eqp.DspEqpGroupID);

            if (stepList == null || stepList.Count <= 1)
            {
                return(false);
            }

            var last = eqp.GetLastPlan();

            if (last == null)
            {
                return(false);
            }

            bool isFilter = ExistRunEqpByDspEqpGroup(eqp, last.FabStep) == false;

            //if (isFilter)
            //	info.FilterReason = string.Format("");

            return(isFilter);
        }
Example #2
0
        public LayerStats(FabAoEquipment eqp)
        {
            var factor = WeightHelper.GetWeightFactor(eqp.Target.Preset, Constants.WF_LAYER_BALANCE_PRIORITY);

            if (factor == null)
            {
                return;
            }

            string            dspEqpGroupID = eqp.DspEqpGroupID;
            List <FabStdStep> steps         = SimHelper.GetDspEqpSteps(dspEqpGroupID);

            for (int i = 0; i < steps.Count; i++)
            {
                FabStdStep step = steps[i];

                int qty = InFlowMaster.GetStepWipQtyforLayerBalance(step.BalanceSteps);

                StepWipStat stat;
                if (dic.TryGetValue(step.StepID, out stat) == false)
                {
                    stat = new StepWipStat(this, step);
                    dic.Add(step.StepID, stat);
                }

                stat.AddQty(qty);
            }


            this.MinQty = decimal.MaxValue;
            this.MaxQty = decimal.MinValue;

            foreach (StepWipStat stat in dic.Values)
            {
                this.MinQty = Math.Min(stat.GapQty, this.MinQty);
                this.MaxQty = Math.Max(stat.GapQty, this.MaxQty);
            }
        }