|
@@ -1,19 +1,18 @@
|
|
|
-using Aitex.Core.RT.DataCenter;
|
|
|
-using Aitex.Core.RT.Device;
|
|
|
+using Aitex.Core.RT.Device;
|
|
|
using Aitex.Core.RT.Event;
|
|
|
using Aitex.Core.RT.Log;
|
|
|
+using Aitex.Core.RT.Routine;
|
|
|
using Aitex.Core.RT.SCCore;
|
|
|
using Aitex.Core.Util;
|
|
|
using EFEM.RT.Modules;
|
|
|
|
|
|
using MECF.Framework.Common.Equipment;
|
|
|
-using MECF.Framework.Common.SubstrateTrackings;
|
|
|
using MECF.Framework.RT.EquipmentLibrary.HardwareUnits.LoadPorts.LoadPortBase;
|
|
|
|
|
|
namespace EFEM.RT.Devices
|
|
|
{
|
|
|
public class EquipmentMonitor : BaseDevice, IDevice
|
|
|
- {
|
|
|
+ {
|
|
|
private readonly RD_TRIG _trigMaintenance = new RD_TRIG();
|
|
|
private readonly RD_TRIG _airForRobotTrig = new RD_TRIG();
|
|
|
private readonly RD_TRIG _airForLoadPortTrig = new RD_TRIG();
|
|
@@ -41,7 +40,10 @@ namespace EFEM.RT.Devices
|
|
|
|
|
|
private readonly bool _MaintenanceMode = DeviceDefineManager.Instance.GetValue<bool>("MaintenanceSignal") ?? false;
|
|
|
private readonly bool _EfemDoorOpen = DeviceDefineManager.Instance.GetValue<bool>("EfemDoorOpenSignal") ?? false;
|
|
|
-
|
|
|
+
|
|
|
+ private static readonly bool LoadPort1IsDisable = SC.ContainsItem("LoadPort.LP1.Disable") ? SC.GetValue<bool>("LoadPort.LP1.Disable") : true;
|
|
|
+ private static readonly bool LoadPort2IsDisable = SC.ContainsItem("LoadPort.LP2.Disable") ? SC.GetValue<bool>("LoadPort.LP2.Disable") : true;
|
|
|
+
|
|
|
private readonly RD_TRIG _trigWaterLeakNormalTOPM = new RD_TRIG();
|
|
|
private readonly RD_TRIG _trigCDAPressureOKTOPM = new RD_TRIG();
|
|
|
|
|
@@ -54,14 +56,16 @@ namespace EFEM.RT.Devices
|
|
|
private uint data2;
|
|
|
|
|
|
private int _fFUSettingKnob;
|
|
|
- private readonly int[] _speedTable = new[] { 0,200,300,400,500,550,600,650,700,750,800 };
|
|
|
+ private readonly int[] _speedTable = new[] { 0, 200, 300, 400, 500, 550, 600, 650, 700, 750, 800 };
|
|
|
+
|
|
|
public int IONCDAPressureSWHandler
|
|
|
{
|
|
|
- get
|
|
|
+ get
|
|
|
{
|
|
|
return SC.GetValue<int>("System.IONCDAPressureSWHandler");
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
public int IONAlarmSIGNALHandler
|
|
|
{
|
|
|
get
|
|
@@ -69,6 +73,7 @@ namespace EFEM.RT.Devices
|
|
|
return SC.GetValue<int>("System.IONAlarmSIGNALHandler");
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
public int WaterFlowSWHandler
|
|
|
{
|
|
|
get
|
|
@@ -76,6 +81,7 @@ namespace EFEM.RT.Devices
|
|
|
return SC.GetValue<int>("System.WaterFlowSWHandler");
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
public RD_TRIG TrigMaintenance
|
|
|
{
|
|
|
get
|
|
@@ -124,7 +130,6 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-
|
|
|
public RD_TRIG SensorFlowWarning
|
|
|
{
|
|
|
get
|
|
@@ -132,6 +137,7 @@ namespace EFEM.RT.Devices
|
|
|
return _flowWarningTrig;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
public RD_TRIG LeakWarningTrig
|
|
|
{
|
|
|
get
|
|
@@ -140,7 +146,6 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-
|
|
|
public R_TRIG SignalTowerTrig
|
|
|
{
|
|
|
get
|
|
@@ -148,12 +153,14 @@ namespace EFEM.RT.Devices
|
|
|
return signalTowerTrig;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
public enum HandlerState
|
|
|
{
|
|
|
ByPass,
|
|
|
ON,
|
|
|
OFF
|
|
|
}
|
|
|
+
|
|
|
public EquipmentMonitor() :
|
|
|
base("System", "EquipmentMonitor", "EquipmentMonitor", "EquipmentMonitor")
|
|
|
{
|
|
@@ -165,81 +172,64 @@ namespace EFEM.RT.Devices
|
|
|
//{
|
|
|
// DeviceModel.TrigLEDLight.SetTrigger(true, out _);
|
|
|
//}
|
|
|
-
|
|
|
- Subscriptions();
|
|
|
+
|
|
|
+ Subscriptions();
|
|
|
return true;
|
|
|
}
|
|
|
|
|
|
private bool _StopIonizerWork;
|
|
|
+
|
|
|
public bool StopIonizerWork
|
|
|
{
|
|
|
get
|
|
|
- {
|
|
|
- if(SC.ContainsItem("System.StopIonizerWorkingEnable"))
|
|
|
- return SC.GetValue<bool>("System.StopIonizerWorkingEnable");
|
|
|
+ {
|
|
|
+ if (SC.ContainsItem("System.StopIonizerWorkingEnable"))
|
|
|
+ return SC.GetValue<bool>("System.StopIonizerWorkingEnable");
|
|
|
return false;
|
|
|
}
|
|
|
set
|
|
|
- {
|
|
|
- _StopIonizerWork = value;
|
|
|
+ {
|
|
|
+ _StopIonizerWork = value;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
private readonly R_TRIG _trigStopIonizerAtFirst = new R_TRIG();
|
|
|
+
|
|
|
public void Monitor()
|
|
|
{
|
|
|
- if (!_noMaintenanceSignal && !_noNoDoorOpenSignal)
|
|
|
- {
|
|
|
- _trigMaintenance.CLK = (_MaintenanceMode ? DeviceModel.SensorMaintenanceMode.Value : !DeviceModel.SensorMaintenanceMode.Value)
|
|
|
- || (_EfemDoorOpen ? DeviceModel.SensorEFEMSideDoorClosed.Value : !DeviceModel.SensorEFEMSideDoorClosed.Value)
|
|
|
- /*|| DeviceModel.SensorTeachingPendantInUse.Value*/;
|
|
|
- }
|
|
|
-
|
|
|
if (_flowWarningTrig.T) EV.PostMessage("System", EventEnum.DefaultAlarm, "Flow Warning");
|
|
|
if (_leakWarningTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "Leak Warning");
|
|
|
-
|
|
|
if (_airForRobotTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "Air supply for Robot pressure error");
|
|
|
if (_airForLoadPortTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "Air supply for Load Port pressure error");
|
|
|
if (_vacuumErrorTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "Vacuum supply for system pressure error");
|
|
|
+ if (_airForRobotTrig.R || _airForLoadPortTrig.R || _vacuumErrorTrig.R)
|
|
|
+ Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.ERROR);
|
|
|
//if (_ffu1ErrorTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "FFU1 error");
|
|
|
//if (_ffu2ErrorTrig.R) EV.PostMessage("System", EventEnum.DefaultAlarm, "FFU1 error");
|
|
|
- if(_airForRobotTrig.R || _airForLoadPortTrig.R || _vacuumErrorTrig.R)
|
|
|
- Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.ERROR);
|
|
|
-
|
|
|
- if (_trigMaintenance.R) Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.SetMaintenanceMode);
|
|
|
+ //_fFUSettingKnob = SC.ContainsItem("System.FFUSpeedSet") ? SC.GetValue<int>("System.FFUSpeedSet") : 3;
|
|
|
+ //DeviceModel.TrigRobotAndPreAlignerHold.SetTrigger(!_trigMaintenance.M, out _);
|
|
|
+ //_trigRobotWafer.CLK = DeviceModel.SensorRobotFork1WaferOn.Value;
|
|
|
|
|
|
- if (_trigMaintenance.T) Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.SetManualMode);
|
|
|
+ #region Seperate Monitor for EFEM Num
|
|
|
|
|
|
- if (SC.GetStringValue("System.EFEMNUM") == "005")
|
|
|
- {
|
|
|
- _trigWaterLeakNormalTOPM.CLK = DeviceModel.SensorEFEMPowerON.Value && DeviceModel.SensorWaterLeakSW.Value;
|
|
|
- if (_trigWaterLeakNormalTOPM.R)
|
|
|
- {
|
|
|
- DeviceModel.TrigWaterLeakOkToPM.SetTrigger(true, out _);
|
|
|
- }
|
|
|
- if (_trigWaterLeakNormalTOPM.T)
|
|
|
- {
|
|
|
- DeviceModel.TrigWaterLeakOkToPM.SetTrigger(false, out _);
|
|
|
- }
|
|
|
+ string efemNum = SC.GetStringValue("System.EFEMNUM") ?? "";
|
|
|
+ MonitorByEfemNum(efemNum);
|
|
|
|
|
|
- _trigCDAPressureOKTOPM.CLK = DeviceModel.SensorEFEMPowerON.Value && DeviceModel.SensorCDAPressureSW.Value;
|
|
|
- if (_trigCDAPressureOKTOPM.R)
|
|
|
- {
|
|
|
- DeviceModel.TrigCDAPressureOkToPM.SetTrigger(true, out _);
|
|
|
- }
|
|
|
- if (_trigCDAPressureOKTOPM.T)
|
|
|
- {
|
|
|
- DeviceModel.TrigCDAPressureOkToPM.SetTrigger(false, out _);
|
|
|
- }
|
|
|
- }
|
|
|
+ #endregion Seperate Monitor for EFEM Num
|
|
|
|
|
|
- _fFUSettingKnob = SC.ContainsItem("System.FFUSpeedSet") ? SC.GetValue<int>("System.FFUSpeedSet") : 3;
|
|
|
+ #region Common Monitor
|
|
|
|
|
|
- //DeviceModel.TrigRobotAndPreAlignerHold.SetTrigger(!_trigMaintenance.M, out _);
|
|
|
- //_trigRobotWafer.CLK = DeviceModel.SensorRobotFork1WaferOn.Value;
|
|
|
-
|
|
|
- _trigStopIonizerAtFirst.CLK = true;
|
|
|
+ //Maintance Mode监控
|
|
|
+ if (!_noMaintenanceSignal && !_noNoDoorOpenSignal)
|
|
|
+ {
|
|
|
+ _trigMaintenance.CLK = (_MaintenanceMode ? DeviceModel.SensorMaintenanceMode.Value : !DeviceModel.SensorMaintenanceMode.Value)
|
|
|
+ || (_EfemDoorOpen ? DeviceModel.SensorEFEMSideDoorClosed.Value : !DeviceModel.SensorEFEMSideDoorClosed.Value)
|
|
|
+ /*|| DeviceModel.SensorTeachingPendantInUse.Value*/;
|
|
|
+ }
|
|
|
+ if (_trigMaintenance.R) Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.SetMaintenanceMode);
|
|
|
+ if (_trigMaintenance.T) Singleton<RouteManager>.Instance.PostMsg(RouteManager.MSG.SetManualMode);
|
|
|
|
|
|
+ _trigStopIonizerAtFirst.CLK = true;
|
|
|
if (_trigStopIonizerAtFirst.Q)
|
|
|
{
|
|
|
//if (DeviceModel.TrigIonizerInterrupt!=null&& SC.ContainsItem("System.StopIonizerWorkingEnable"))
|
|
@@ -247,7 +237,7 @@ namespace EFEM.RT.Devices
|
|
|
// if (DeviceModel.TrigIonizerInterrupt.Value != SC.GetValue<bool>("System.StopIonizerWorkingEnable"))
|
|
|
// SC.SetItemValue("System.StopIonizerWorkingEnable", DeviceModel.TrigIonizerInterrupt.Value);
|
|
|
//}
|
|
|
- if (SC.GetValue<int>("LoadPort.LP1.CstType")==1)
|
|
|
+ if (SC.GetValue<int>("LoadPort.LP1.CstType") == 1)
|
|
|
{
|
|
|
if (DeviceModel.SensorCstDoorClosed.Value && !DEVICE.GetDevice<LoadPortBaseDevice>(ModuleName.LP1.ToString()).IsWaferProtrude)
|
|
|
{
|
|
@@ -256,7 +246,7 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-
|
|
|
+ //IonizerInterrupt 监控
|
|
|
if (DeviceModel.TrigIonizerInterrupt != null && !DeviceModel.TrigIonizerInterrupt.Value)
|
|
|
{
|
|
|
//_trigIONAlarmSIGNAL.CLK = DeviceModel.SensorIONAlarmSIGNAL == null ? false : !DeviceModel.SensorIONAlarmSIGNAL.Value;
|
|
@@ -275,6 +265,7 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
break;
|
|
|
+
|
|
|
case (int)HandlerState.OFF:
|
|
|
{
|
|
|
_trigIONAlarmSIGNALON.CLK = !DeviceModel.SensorIONAlarmSIGNAL.Value;
|
|
@@ -285,20 +276,16 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
break;
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
- //else
|
|
|
- // _trigIONAlarmSIGNAL.RST = true;
|
|
|
-
|
|
|
if (DeviceModel.TrigIonizerInterrupt != null && DeviceModel.TrigIonizerInterrupt.Value != StopIonizerWork)
|
|
|
- {
|
|
|
- DeviceModel.TrigIonizerInterrupt.SetTrigger(StopIonizerWork, out _);
|
|
|
+ {
|
|
|
+ DeviceModel.TrigIonizerInterrupt.SetTrigger(StopIonizerWork, out _);
|
|
|
}
|
|
|
-
|
|
|
|
|
|
+ //Online Mode 监控
|
|
|
if (Singleton<EfemEntity>.Instance.IsOnlineMode)
|
|
|
{
|
|
|
- if(_trigMaintenance.R || _trigMaintenance.T ||
|
|
|
+ if (_trigMaintenance.R || _trigMaintenance.T ||
|
|
|
_airForLoadPortTrig.R || _airForLoadPortTrig.T ||
|
|
|
_airForRobotTrig.R || _airForRobotTrig.T ||
|
|
|
_vacuumErrorTrig.R || _vacuumErrorTrig.T ||
|
|
@@ -313,6 +300,7 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //IONCDAPressureSW 监控
|
|
|
if (DeviceModel.SensorIONCDAPressureSW != null)
|
|
|
{
|
|
|
switch (IONCDAPressureSWHandler)
|
|
@@ -326,6 +314,7 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
break;
|
|
|
+
|
|
|
case (int)HandlerState.OFF:
|
|
|
{
|
|
|
_trigIONCDAPressureOFF.CLK = !DeviceModel.SensorIONCDAPressureSW.Value;
|
|
@@ -337,8 +326,9 @@ namespace EFEM.RT.Devices
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
- if(DeviceModel.SensorWaterFlowSW != null)
|
|
|
+
|
|
|
+ //WaterFlowSW 监控
|
|
|
+ if (DeviceModel.SensorWaterFlowSW != null)
|
|
|
{
|
|
|
switch (WaterFlowSWHandler)
|
|
|
{
|
|
@@ -351,6 +341,7 @@ namespace EFEM.RT.Devices
|
|
|
}
|
|
|
}
|
|
|
break;
|
|
|
+
|
|
|
case (int)HandlerState.OFF:
|
|
|
{
|
|
|
_trigWaterFlowSWOFF.CLK = !DeviceModel.SensorWaterFlowSW.Value;
|
|
@@ -362,7 +353,8 @@ namespace EFEM.RT.Devices
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
+ //SignalTower监控
|
|
|
if (signalTowerTrig.Q)
|
|
|
{
|
|
|
data2 = Singleton<EfemEntity>.Instance.GetSigStatData2(ModuleName.System);
|
|
@@ -371,102 +363,7 @@ namespace EFEM.RT.Devices
|
|
|
Singleton<EfemEntity>.Instance.SendSigStatEvent(ModuleName.System);
|
|
|
}
|
|
|
|
|
|
- //DO_RobotSafetyToLP1触发逻辑
|
|
|
- //if (DeviceModel.SensorLP1OperationStatus != null && DeviceModel.SensorLP1FoupOpen != null && DeviceModel.SensorLP1FoupPlacement != null && DeviceModel.SensorLP1Presence != null
|
|
|
- // && DeviceModel.SensorLP1Ready != null && DeviceModel.SensorRobotEMStoEFEM != null && DeviceModel.SensorGratingSensorIN1 != null && DeviceModel.TrigSafetytoSMIF1 != null)
|
|
|
- //{
|
|
|
- // if (DeviceModel.SensorLP1OperationStatus.Value && DeviceModel.SensorLP1FoupOpen.Value && DeviceModel.SensorLP1FoupPlacement.Value
|
|
|
- // && DeviceModel.SensorLP1Presence.Value && DeviceModel.SensorLP1Ready.Value
|
|
|
- // && DeviceModel.SensorRobotEMStoEFEM.Value && DeviceModel.SensorGratingSensorIN1.Value)
|
|
|
- // {
|
|
|
- // if (!DeviceModel.TrigSafetytoSMIF1.Value)
|
|
|
- // {
|
|
|
- // DeviceModel.TrigSafetytoSMIF1.SetTrigger(true, out _);
|
|
|
- // LOG.Write("Sensor LP1 related signal change,set DO_RobotSafetyToLP1 signal on.");
|
|
|
- // }
|
|
|
-
|
|
|
- // }
|
|
|
- // else
|
|
|
- // {
|
|
|
- // if (DeviceModel.TrigSafetytoSMIF1.Value)
|
|
|
- // {
|
|
|
- // DeviceModel.TrigSafetytoSMIF1.SetTrigger(false, out _);
|
|
|
- // LOG.Write("Sensor LP1 related signal change,set DO_RobotSafetyToLP1 signal off.");
|
|
|
- // }
|
|
|
- // }
|
|
|
- //}
|
|
|
-
|
|
|
- //DO_RobotSafetyToLP2触发逻辑
|
|
|
- //if (DeviceModel.SensorLP2OperationStatus != null && DeviceModel.SensorLP2FoupOpen != null && DeviceModel.SensorLP2FoupPlacement != null && DeviceModel.SensorLP2Presence != null
|
|
|
- // && DeviceModel.SensorLP2Ready != null && DeviceModel.SensorRobotEMStoEFEM != null && DeviceModel.SensorGratingSensorIN1 != null && DeviceModel.TrigSafetytoSMIF2 != null)
|
|
|
- //{
|
|
|
- // if (DeviceModel.SensorLP2OperationStatus.Value && DeviceModel.SensorLP2FoupOpen.Value && DeviceModel.SensorLP2FoupPlacement.Value
|
|
|
- // && DeviceModel.SensorLP2Presence.Value && DeviceModel.SensorLP2Ready.Value
|
|
|
- // && DeviceModel.SensorRobotEMStoEFEM.Value && DeviceModel.SensorGratingSensorIN1.Value)
|
|
|
- // {
|
|
|
- // if (!DeviceModel.TrigSafetytoSMIF2.Value)
|
|
|
- // {
|
|
|
- // DeviceModel.TrigSafetytoSMIF2.SetTrigger(true, out _);
|
|
|
- // LOG.Write("Sensor LP2 related signal change,set DO_RobotSafetyToLP2 signal on.");
|
|
|
- // }
|
|
|
- // }
|
|
|
- // else
|
|
|
- // {
|
|
|
- // if (DeviceModel.TrigSafetytoSMIF2.Value)
|
|
|
- // {
|
|
|
- // DeviceModel.TrigSafetytoSMIF2.SetTrigger(false, out _);
|
|
|
- // LOG.Write("Sensor LP2 related signal change,set DO_RobotSafetyToLP2 signal off.");
|
|
|
- // }
|
|
|
-
|
|
|
- // }
|
|
|
- //}
|
|
|
-
|
|
|
- //DO_EnableToOperateLP1触发逻辑
|
|
|
- if(DeviceModel.TrigEnableToOperateLP1 != null)
|
|
|
- {
|
|
|
- if (SC.ContainsItem("LoadPort.LP1.Disable") ? !SC.GetValue<bool>("LoadPort.LP1.Disable") : false
|
|
|
- && Singleton<RouteManager>.Instance.IsRunning)
|
|
|
- {
|
|
|
- if (!DeviceModel.TrigEnableToOperateLP1.Value)
|
|
|
- {
|
|
|
- DeviceModel.TrigEnableToOperateLP1.SetTrigger(true, out _);
|
|
|
- LOG.Write("Sensor LP1 related signal change,set DO_EnableToOperateLP1 signal on.");
|
|
|
- }
|
|
|
-
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- if (DeviceModel.TrigEnableToOperateLP1.Value)
|
|
|
- {
|
|
|
- DeviceModel.TrigEnableToOperateLP1.SetTrigger(false, out _);
|
|
|
- LOG.Write("Sensor LP1 related signal change,set DO_EnableToOperateLP1 signal on.");
|
|
|
- }
|
|
|
-
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- //DO_EnableToOperateLP2触发逻辑
|
|
|
- if (DeviceModel.TrigEnableToOperateLP2 != null)
|
|
|
- {
|
|
|
- if (SC.ContainsItem("LoadPort.LP2.Disable") ? !SC.GetValue<bool>("LoadPort.LP2.Disable") : false
|
|
|
- && Singleton<RouteManager>.Instance.IsRunning)
|
|
|
- {
|
|
|
- if (!DeviceModel.TrigEnableToOperateLP2.Value)
|
|
|
- {
|
|
|
- DeviceModel.TrigEnableToOperateLP2.SetTrigger(true, out _);
|
|
|
- LOG.Write("Sensor LP2 related signal change,set DO_EnableToOperateLP2 signal on.");
|
|
|
- }
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- if (DeviceModel.TrigEnableToOperateLP2.Value)
|
|
|
- {
|
|
|
- DeviceModel.TrigEnableToOperateLP2.SetTrigger(false, out _);
|
|
|
- LOG.Write("Sensor LP2 related signal change,set DO_EnableToOperateLP2 signal on.");
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
+ #endregion Common Monitor
|
|
|
}
|
|
|
|
|
|
public void Terminate()
|
|
@@ -486,17 +383,153 @@ namespace EFEM.RT.Devices
|
|
|
_trigIONAlarmSIGNALON.RST = true;
|
|
|
_trigIONAlarmSIGNALOFF.RST = true;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
private void Subscriptions()
|
|
|
{
|
|
|
-
|
|
|
-
|
|
|
//DATA.Subscribe("Robot.WaferSize", () =>
|
|
|
// {
|
|
|
// return WaferManager.Instance.GetWaferSize(ModuleName.Robot, 0).ToString();
|
|
|
// });
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ /// 不同型号的EFEM监控
|
|
|
+ /// </summary>
|
|
|
+ private void MonitorByEfemNum(string efemNum)
|
|
|
+ {
|
|
|
+ if (efemNum.Equals("005"))
|
|
|
+ {
|
|
|
+ _trigWaterLeakNormalTOPM.CLK = DeviceModel.SensorEFEMPowerON.Value && DeviceModel.SensorWaterLeakSW.Value;
|
|
|
+ if (_trigWaterLeakNormalTOPM.R)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigWaterLeakOkToPM.SetTrigger(true, out _);
|
|
|
+ }
|
|
|
+ if (_trigWaterLeakNormalTOPM.T)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigWaterLeakOkToPM.SetTrigger(false, out _);
|
|
|
+ }
|
|
|
+
|
|
|
+ _trigCDAPressureOKTOPM.CLK = DeviceModel.SensorEFEMPowerON.Value && DeviceModel.SensorCDAPressureSW.Value;
|
|
|
+ if (_trigCDAPressureOKTOPM.R)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigCDAPressureOkToPM.SetTrigger(true, out _);
|
|
|
+ }
|
|
|
+ if (_trigCDAPressureOKTOPM.T)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigCDAPressureOkToPM.SetTrigger(false, out _);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else if (efemNum.Equals("006"))
|
|
|
+ {
|
|
|
+ //DO_RobotSafetyToLP1触发逻辑
|
|
|
+ if (!LoadPort1IsDisable && DeviceModel.SensorLP1OperationStatus != null && DeviceModel.SensorLP1FoupOpen != null && DeviceModel.SensorLP1FoupPlacement != null && DeviceModel.SensorLP1Presence != null
|
|
|
+ && DeviceModel.SensorLP1Ready != null && DeviceModel.SensorRobotEMStoEFEM != null && DeviceModel.SensorGratingSensorIN1 != null && DeviceModel.TrigSafetytoSMIF1 != null)
|
|
|
+ {
|
|
|
+ if (DeviceModel.SensorLP1OperationStatus.Value && DeviceModel.SensorLP1FoupOpen.Value && DeviceModel.SensorLP1FoupPlacement.Value
|
|
|
+ && DeviceModel.SensorLP1Presence.Value && DeviceModel.SensorLP1Ready.Value
|
|
|
+ && DeviceModel.SensorRobotEMStoEFEM.Value && DeviceModel.SensorGratingSensorIN1.Value)
|
|
|
+ {
|
|
|
+ if (!DeviceModel.TrigSafetytoSMIF1.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigSafetytoSMIF1.SetTrigger(true, out _);
|
|
|
+ LOG.Write("Sensor LP1 related signal change,set DO_RobotSafetyToLP1 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if (DeviceModel.TrigSafetytoSMIF1.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigSafetytoSMIF1.SetTrigger(false, out _);
|
|
|
+ LOG.Write("Sensor LP1 related signal change,set DO_RobotSafetyToLP1 signal off.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //DO_RobotSafetyToLP2触发逻辑
|
|
|
+ if (!LoadPort2IsDisable && DeviceModel.SensorLP2OperationStatus != null && DeviceModel.SensorLP2FoupOpen != null && DeviceModel.SensorLP2FoupPlacement != null && DeviceModel.SensorLP2Presence != null
|
|
|
+ && DeviceModel.SensorLP2Ready != null && DeviceModel.SensorRobotEMStoEFEM != null && DeviceModel.SensorGratingSensorIN1 != null && DeviceModel.TrigSafetytoSMIF2 != null)
|
|
|
+ {
|
|
|
+ if (DeviceModel.SensorLP2OperationStatus.Value && DeviceModel.SensorLP2FoupOpen.Value && DeviceModel.SensorLP2FoupPlacement.Value
|
|
|
+ && DeviceModel.SensorLP2Presence.Value && DeviceModel.SensorLP2Ready.Value
|
|
|
+ && DeviceModel.SensorRobotEMStoEFEM.Value && DeviceModel.SensorGratingSensorIN1.Value)
|
|
|
+ {
|
|
|
+ if (!DeviceModel.TrigSafetytoSMIF2.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigSafetytoSMIF2.SetTrigger(true, out _);
|
|
|
+ LOG.Write("Sensor LP2 related signal change,set DO_RobotSafetyToLP2 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if (DeviceModel.TrigSafetytoSMIF2.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigSafetytoSMIF2.SetTrigger(false, out _);
|
|
|
+ LOG.Write("Sensor LP2 related signal change,set DO_RobotSafetyToLP2 signal off.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //DO_EnableToOperateLP1触发逻辑
|
|
|
+ if (!LoadPort1IsDisable && DeviceModel.TrigEnableToOperateLP1 != null)
|
|
|
+ {
|
|
|
+ if ((SC.ContainsItem("LoadPort.LP1.Disable") ? !SC.GetValue<bool>("LoadPort.LP1.Disable") : false)
|
|
|
+ && Singleton<RouteManager>.Instance.IsRunning)
|
|
|
+ {
|
|
|
+ if (!DeviceModel.TrigEnableToOperateLP1.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigEnableToOperateLP1.SetTrigger(true, out _);
|
|
|
+ LOG.Write("Sensor LP1 related signal change,set DO_EnableToOperateLP1 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if (DeviceModel.TrigEnableToOperateLP1.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigEnableToOperateLP1.SetTrigger(false, out _);
|
|
|
+ LOG.Write("Sensor LP1 related signal change,set DO_EnableToOperateLP1 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //DO_EnableToOperateLP2触发逻辑
|
|
|
+ if (!LoadPort2IsDisable && DeviceModel.TrigEnableToOperateLP2 != null)
|
|
|
+ {
|
|
|
+ if ((SC.ContainsItem("LoadPort.LP2.Disable") ? !SC.GetValue<bool>("LoadPort.LP2.Disable") : false)
|
|
|
+ && Singleton<RouteManager>.Instance.IsRunning)
|
|
|
+ {
|
|
|
+ if (!DeviceModel.TrigEnableToOperateLP2.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigEnableToOperateLP2.SetTrigger(true, out _);
|
|
|
+ LOG.Write("Sensor LP2 related signal change,set DO_EnableToOperateLP2 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if (DeviceModel.TrigEnableToOperateLP2.Value)
|
|
|
+ {
|
|
|
+ DeviceModel.TrigEnableToOperateLP2.SetTrigger(false, out _);
|
|
|
+ LOG.Write("Sensor LP2 related signal change,set DO_EnableToOperateLP2 signal on.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //Pause / Resume to Robot触发逻辑(----------待完善----------)
|
|
|
+ //if (DeviceModel.SensorGratingSensorIN1 != null && DeviceModel.SensorRBNotExtendSIMF1 != null && DeviceModel.SensorRBNotExtendSIMF1 != null
|
|
|
+ // && DeviceModel.SensorPAorFLPDoorClosed != null)
|
|
|
+ //{
|
|
|
+ // if (true)
|
|
|
+ // {
|
|
|
+ // if (DeviceModel.TrigPauseResumetoRobot.Value)
|
|
|
+ // {
|
|
|
+ // DeviceModel.TrigPauseResumetoRobot.SetTrigger(false, out _);
|
|
|
+ // }
|
|
|
+
|
|
|
+ // if (!DeviceModel.TrigPauseResumetoRobot.Value)
|
|
|
+ // {
|
|
|
+ // DeviceModel.TrigPauseResumetoRobot.SetTrigger(true, out _);
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ //}
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
}
|