using Aitex.Core.Common; using Aitex.Core.RT.Device; using Aitex.Core.RT.Device.Unit; using athosRT.Devices.EFEM.ABS; using athosRT.tool; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace athosRT.Devices.EFEM.Task { public class LiftTask : CheckImp, ITask { public bool Execute(out string result, params string[] args) { string str1 = this.Args2Unit(args.Length != 0 ? args[0] : string.Empty); BufferServerModule entity = (BufferServerModule)this.GetEntity(str1); if (entity == null) { result = "PARAM_NG"; return false; } string str2 = args[1]; if (str2 != "UP" && str2 != "DOWN") { LogObject.Warning("LiftTask", "Lift command parameter 1 must be 'UP|DOWN'"); result = "PARAM_NG"; return false; } if (!this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result) || !this.Check(str1, out result)) return false; if (str2 == "UP") entity.LiftUp(out result); else entity.LiftDown(WaferSize.WS0, out result); return true; } public bool? Monitor(out string result, params string[] args) { result = string.Empty; string str = this.Args2Unit(args.Length != 0 ? args[0] : string.Empty); IoCoolingBuffer device = DEVICE.GetDevice(str); if (device.Error) { this.flag1 = ErrorCheckList1.VAC | ErrorCheckList1.STALL | ErrorCheckList1.LIMIT | ErrorCheckList1.POSITION | ErrorCheckList1.EMS | ErrorCheckList1.COMM | ErrorCheckList1.COMM2 | ErrorCheckList1.CLAMPON | ErrorCheckList1.CLAMPOF; this.flag2 = ErrorCheckList2.COMMAND | ErrorCheckList2.CLAMP_S; this.flag3 = ErrorCheckList3.WAFLOST | ErrorCheckList3.ALIGNNG | ErrorCheckList3.HARDWARE | ErrorCheckList3.INTERNAL; return new bool?(this.CheckError(str, out result)); } return !device.Busy ? new bool?(true) : new bool?(); } } }