using Aitex.Core.RT.DataCenter; using Aitex.Core.RT.Device; using Aitex.Core.RT.Event; using Aitex.Core.RT.Fsm; using Aitex.Core.RT.OperationCenter; using Aitex.Core.Util; using Aitex.Core.Utilities; using Aitex.Sorter.Common; using EfemDualRT.Equipments.Devices; using EfemDualSchedulerLib; using FutureEfemLib; using JetMainframe; using JetMainframe.LLs; using JetMainframe.TMs; using JetVirgoPM; using JetVirgoPM.PMs; using MECF.Framework.Common.Equipment; using MECF.Framework.Common.Schedulers; using MECF.Framework.Common.SubstrateTrackings; using MECF.Framework.RT.EquipmentLibrary.HardwareUnits.Robots.JEL; using MECF.Framework.RT.ModuleLibrary.LLModules; using MECF.Framework.RT.ModuleLibrary.PMModules; using MECF.Framework.RT.ModuleLibrary.SystemModules; namespace EfemDualRT.Equipments.Systems { public class EfemDualEquipment : EquipmentManager { private DeviceManagerBase _device; private DeviceController _controller; public EfemDualEquipment() { _controller = new DeviceController(); _device = new DeviceManagerBase(true); } public override bool Initialize() { base.Initialize(); Singleton.Instance.OnAlarmEvent += Instance_OnAlarmEvent; _device.AddCustomDevice(new IOMonitorDevice()); _controller.Start(_device); return true; } private void Instance_OnAlarmEvent(EventItem obj) { FSM_MSG msg = FSM_MSG.NONE; if (obj.Level == EventLevel.Warning) msg = FSM_MSG.WARNING; else if (obj.Level == EventLevel.Alarm) msg = FSM_MSG.ALARM; if (obj.Description.Contains("WaterLeak")) { Modules[ModuleName.PMA]?.PostMsg(msg, obj.Id, obj.Description); Modules[ModuleName.PMB]?.PostMsg(msg, obj.Id, obj.Description); Modules[ModuleName.TM]?.PostMsg(msg, obj.Id, obj.Description); return; } switch (obj.Source) { case "PMA": case "PMB": case "EFEM": case "TM": Modules[ModuleHelper.Converter(obj.Source)]?.PostMsg(msg, obj.Id, obj.Description); break; case "System": Modules[ModuleName.TM]?.PostMsg(msg, obj.Id, obj.Description); break; } } protected override void InitRoutine() { _auto = new AutoTransfer(this); _manualTransfer = new ManualTransfer(this); _homeAll = new HomeAll(); _returnAll = new ReturnAllWafer(this); _tmCycle = new TMCycle(this); } protected override void InitDevices() { base.InitDevices(); FutureEfemDeviceManager.Instance.Initialize(); JetMainframeDeviceManager.Instance.Initialize(); JetVirgoPMDeviceManager.Instance.Initialize(ModuleName.PMA); JetVirgoPMDeviceManager.Instance.Initialize(ModuleName.PMB); } protected override void InitModules() { BuildModules( new FutureEfemLib.Efems.EfemModule(ModuleName.EFEM), new FutureEfemLib.LPs.LoadPortModule(ModuleName.LP1), new FutureEfemLib.LPs.LoadPortModule(ModuleName.LP2), new FutureEfemLib.LPs.LoadPortModule(ModuleName.LP3), new FutureEfemLib.Aligners.AlignerModule(ModuleName.Aligner), new TMModule(ModuleName.TM){ RobotDevice = DEVICE.GetDevice($"TMRobot")}, new LoadLockModule(ModuleName.LLA, 8), new LoadLockModule(ModuleName.LLB, 8), new PMModule(ModuleName.PMA, 2), new PMModule(ModuleName.PMB, 2) //new PMModule(ModuleName.PMC, 2) ); } } }