LLEntity.cs 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742
  1. using System;
  2. using Aitex.Core.Util;
  3. using Aitex.Core.RT.Fsm;
  4. using Aitex.Core.RT.Log;
  5. using MECF.Framework.Common.Equipment;
  6. using MECF.Framework.Common.SubstrateTrackings;
  7. using Venus_RT.Modules.TM;
  8. using Venus_RT.Devices;
  9. using Venus_Core;
  10. using Aitex.Core.RT.DataCenter;
  11. using Aitex.Core.RT.OperationCenter;
  12. using Aitex.Core.RT.Device;
  13. using Aitex.Core.RT.SCCore;
  14. using Aitex.Core.RT.Event;
  15. namespace Venus_RT.Modules
  16. {
  17. class LLEntity : Entity, IEntity, IModuleEntity
  18. {
  19. public enum LLStatus
  20. {
  21. Not_Ready,
  22. Ready_For_TM,
  23. Ready_For_EFEM,
  24. }
  25. public enum STATE
  26. {
  27. Unknown,
  28. Init,
  29. Initializing,
  30. Idle,
  31. Error,
  32. Pumping,
  33. Venting,
  34. Purging,
  35. LeakCheck,
  36. Prepare_For_TM,
  37. Prepare_For_EFEM,
  38. Ready_For_TM,
  39. Ready_For_EFEM,
  40. }
  41. public enum MSG
  42. {
  43. Home,
  44. Online,
  45. Offline,
  46. Pump,
  47. Vent,
  48. AutoPump,
  49. AutoVent,
  50. Purge,
  51. CyclePurge,
  52. LeakCheck,
  53. Prepare_TM,
  54. Prepare_EFEM,
  55. TM_Exchange_Ready,
  56. EFEM_Exchange_Ready,
  57. Error,
  58. Abort,
  59. }
  60. public ModuleName Module { get; private set; }
  61. public LLStatus Status { get; private set; }
  62. public bool Check(int msg, out string reason, params object[] args)
  63. {
  64. throw new NotImplementedException();
  65. }
  66. public bool IsIdle
  67. {
  68. get { return fsm.State == (int)STATE.Idle; }
  69. }
  70. public bool IsError
  71. {
  72. get { return fsm.State == (int)STATE.Error; }
  73. }
  74. public bool IsInit
  75. {
  76. get { return fsm.State == (int)STATE.Unknown || fsm.State == (int)STATE.Init; }
  77. }
  78. public bool IsBusy
  79. {
  80. get { return !IsInit && !IsError && !IsIdle; }
  81. }
  82. public bool IsOnline { get; internal set; }
  83. public bool IsInclude
  84. {
  85. get;
  86. private set;
  87. } = true;
  88. public bool IsVac { get { return _JetTM.IsModuleVaccum(Module); } }
  89. public bool IsATM { get { return _JetTM.IsModuleATM(Module); } }
  90. public override int TimeToReady
  91. {
  92. get
  93. {
  94. switch ((STATE)fsm.State)
  95. {
  96. case STATE.Pumping:
  97. case STATE.Venting:
  98. return base.TimeToReady;
  99. }
  100. return int.MaxValue;
  101. }
  102. }
  103. private readonly JetTM _JetTM;
  104. private readonly MFPumpRoutine _pumpingRoutine;
  105. private readonly MFVentRoutine _ventingRoutine;
  106. private readonly MFLeakCheckRoutine _leakCheckRoutine;
  107. private readonly MFPurgeRoutine _purgeRoutine;
  108. private readonly int _slotNumber = 4;
  109. //private bool startControlPressureFlag = true;
  110. //private int _controlPressureCheckPoint = 100;
  111. //private int _controlPressureSetPoint = 90;
  112. private int _controlFlowSetPoint = 90;
  113. //private bool _isEnableControlPressure;
  114. public LLEntity(ModuleName module)
  115. {
  116. Module = module;
  117. _JetTM = DEVICE.GetDevice<JetTM>("TM");
  118. _pumpingRoutine = new MFPumpRoutine(_JetTM, Module);
  119. _ventingRoutine = new MFVentRoutine(_JetTM, Module);
  120. _leakCheckRoutine = new MFLeakCheckRoutine(_JetTM, Module);
  121. _purgeRoutine = new MFPurgeRoutine(_JetTM, Module);
  122. _slotNumber = SC.GetValue<int>($"{module.ToString()}.SlotNumber");
  123. WaferManager.Instance.SubscribeLocation(Module, _slotNumber);
  124. InitFsmMap();
  125. }
  126. protected override bool Init()
  127. {
  128. OP.Subscribe($"{Module}.Home", (cmd, args) => CheckToPostMessage((int)MSG.Home));
  129. OP.Subscribe($"{Module}.{RtOperation.Pump}", (cmd, args) => CheckToPostMessage((int)MSG.Pump));
  130. OP.Subscribe($"{Module}.{RtOperation.Vent}", (cmd, args) => CheckToPostMessage((int)MSG.Vent));
  131. OP.Subscribe($"{Module}.{RtOperation.Purge}", (cmd, args) => CheckToPostMessage((int)MSG.Purge));
  132. OP.Subscribe($"{Module}.{RtOperation.Abort}", (cmd, args) => CheckToPostMessage((int)MSG.Abort));
  133. OP.Subscribe($"{Module}.{RtOperation.LeakCheck}", (cmd, args) => CheckToPostMessage((int)MSG.LeakCheck));
  134. OP.Subscribe($"{Module}.{RtOperation.Online}", (cmd, args) => CheckToPostMessage((int)MSG.Online));
  135. OP.Subscribe($"{Module}.{RtOperation.Offline}", (cmd, args) => CheckToPostMessage((int)MSG.Offline));
  136. OP.Subscribe($"{Module}.{RtOperation.Include}", (cmd, args) => FnSetInclude());
  137. OP.Subscribe($"{Module}.{RtOperation.Exclude}", (cmd, args) => FnSetExclude());
  138. //OP.Subscribe($"{Module}.{RtOperation.ControlPressure}", (cmd, args) => StartControlPressure());
  139. //OP.Subscribe($"{Module}.{RtOperation.AbortControlPressure}", (cmd, args) => StopControlPressure());
  140. DATA.Subscribe($"{Module}.FsmState", () => (((STATE)fsm.State).ToString()), SubscriptionAttribute.FLAG.IgnoreSaveDB);
  141. DATA.Subscribe($"{Module}.FsmPrevState", () => (((PMState)fsm.PrevState).ToString()), SubscriptionAttribute.FLAG.IgnoreSaveDB);
  142. DATA.Subscribe($"{Module}.FsmLastMessage", () => (((MSG)fsm.LastMsg).ToString()), SubscriptionAttribute.FLAG.IgnoreSaveDB);
  143. DATA.Subscribe($"{Module}.IsOnline", () => IsOnline, SubscriptionAttribute.FLAG.IgnoreSaveDB);
  144. DATA.Subscribe($"{Module}.IsInclude", () => IsInclude, SubscriptionAttribute.FLAG.IgnoreSaveDB);
  145. DATA.Subscribe($"{Module}.IsBusy", () => IsBusy, SubscriptionAttribute.FLAG.IgnoreSaveDB);
  146. //DATA.Subscribe($"{Module}.IsEnableControlPressure", () => _isEnableControlPressure, SubscriptionAttribute.FLAG.IgnoreSaveDB);
  147. return true;
  148. }
  149. private void InitFsmMap()
  150. {
  151. fsm = new StateMachine<LLEntity>(Module.ToString(), (int)STATE.Init, 50);
  152. fsm.EnableRepeatedMsg(true);
  153. EnterExitTransition<STATE, FSM_MSG>(STATE.Ready_For_TM, fnEnterTMReady, FSM_MSG.NONE, fnExitTMReady);
  154. EnterExitTransition<STATE, FSM_MSG>(STATE.Ready_For_EFEM, fnEnterEFEMReady, FSM_MSG.NONE, fnExitEFEMReady);
  155. //AnyStateTransition(FSM_MSG.TIMER, fnMonitor, FSM_STATE.SAME);
  156. AnyStateTransition(MSG.Error, fnError, STATE.Error);
  157. AnyStateTransition(MSG.Online, fnOnline, FSM_STATE.SAME);
  158. AnyStateTransition(MSG.Offline, fnOffline, FSM_STATE.SAME);
  159. AnyStateTransition(MSG.Home, fnHome, STATE.Initializing);
  160. // Home
  161. Transition(STATE.Initializing, FSM_MSG.TIMER, fnHoming, STATE.Idle);
  162. Transition(STATE.Idle, FSM_MSG.TIMER, fnMonitor, STATE.Idle);
  163. Transition(STATE.Init, FSM_MSG.TIMER, fnMonitor, STATE.Init);
  164. //vent sequence
  165. Transition(STATE.Idle, MSG.Vent, FnStartVent, STATE.Venting);
  166. Transition(STATE.Venting, FSM_MSG.TIMER, FnVentTimeout, STATE.Idle);
  167. Transition(STATE.Venting, MSG.Abort, FnAbortVent, STATE.Idle);
  168. //Pump sequence
  169. Transition(STATE.Idle, MSG.Pump, FnStartPump, STATE.Pumping);
  170. Transition(STATE.Pumping, FSM_MSG.TIMER, FnPumpTimeout, STATE.Idle);
  171. Transition(STATE.Pumping, MSG.Abort, FnAbortPump, STATE.Idle);
  172. // Purge sequence
  173. Transition(STATE.Idle, MSG.Purge, FnStartPurge, STATE.Purging);
  174. Transition(STATE.Purging, FSM_MSG.TIMER, FnPurgeTimeout, STATE.Idle);
  175. Transition(STATE.Purging, MSG.Abort, FnAbortPurge, STATE.Idle);
  176. // Leak check sequence
  177. Transition(STATE.Idle, MSG.LeakCheck, FnStartLeakCheck, STATE.LeakCheck);
  178. Transition(STATE.LeakCheck, FSM_MSG.TIMER, FnLeakCheckTimeout, STATE.Idle);
  179. Transition(STATE.LeakCheck, MSG.Abort, FnAbortLeakCheck, STATE.Idle);
  180. // Prepare TM Transfer
  181. Transition(STATE.Idle, MSG.Prepare_TM, FnStartPrepareTM, STATE.Prepare_For_TM);
  182. Transition(STATE.Prepare_For_TM, FSM_MSG.TIMER, FnPreparaTMTimeout, STATE.Ready_For_TM);
  183. Transition(STATE.Prepare_For_TM, MSG.Prepare_TM, null, STATE.Prepare_For_TM);
  184. Transition(STATE.Prepare_For_TM, MSG.Abort, FnAbortPreparaTM, STATE.Idle);
  185. Transition(STATE.Ready_For_TM, MSG.TM_Exchange_Ready, null, STATE.Idle);
  186. Transition(STATE.Ready_For_TM, MSG.Prepare_TM, null, STATE.Ready_For_TM);
  187. Transition(STATE.Ready_For_TM, MSG.Abort, null, STATE.Idle);
  188. Transition(STATE.Ready_For_TM, MSG.AutoVent, FnTryAutoVent, STATE.Venting);
  189. // Prepare EFEM Transfer
  190. Transition(STATE.Idle, MSG.Prepare_EFEM, FnStartPrepareEFEM, STATE.Prepare_For_EFEM);
  191. Transition(STATE.Prepare_For_EFEM, FSM_MSG.TIMER, FnPrepareEFEMTimeout, STATE.Ready_For_EFEM);
  192. Transition(STATE.Prepare_For_EFEM, MSG.Abort, FnAbortPrepareEFEM, STATE.Idle);
  193. Transition(STATE.Ready_For_EFEM, MSG.EFEM_Exchange_Ready, null, STATE.Idle);
  194. Transition(STATE.Ready_For_EFEM, MSG.Prepare_EFEM, null, STATE.Ready_For_EFEM);
  195. Transition(STATE.Ready_For_EFEM, MSG.Abort, null, STATE.Idle);
  196. Transition(STATE.Ready_For_EFEM, MSG.AutoPump, FnTryAutoPump, STATE.Pumping);
  197. //Cooling
  198. AnyStateTransition(FSM_MSG.TIMER, LLCoolingTimer_Elapsed, FSM_STATE.SAME);
  199. Running = true;
  200. }
  201. public int Invoke(string function, params object[] args)
  202. {
  203. switch (function)
  204. {
  205. case "Home":
  206. case "Vent":
  207. case "Pump":
  208. if(Enum.TryParse(function, out MSG message))
  209. {
  210. if (CheckToPostMessage((int)message))
  211. return (int)message;
  212. }
  213. break;
  214. }
  215. return (int)FSM_MSG.NONE;
  216. }
  217. public bool CheckAcked(int msg)
  218. {
  219. return fsm.CheckExecuted(msg);
  220. }
  221. public bool CheckToPostMessage(int msg, params object[] args)
  222. {
  223. if (!fsm.FindTransition(fsm.State, msg))
  224. {
  225. LOG.Write(eEvent.WARN_FSM_WARN, Module, $"{Module} is in {(STATE)fsm.State} state,can not do {(MSG)msg}");
  226. return false;
  227. }
  228. Running = true;
  229. fsm.PostMsg(msg, args);
  230. return true;
  231. }
  232. public (int processed, int unprocessed) GetWaferProcessStatus()
  233. {
  234. int processedCount = 0;
  235. int unprocessCount = 0;
  236. for (int i = 0; i < _slotNumber; i++)
  237. {
  238. var wafer = WaferManager.Instance.GetWafer(Module, i);
  239. if (!wafer.IsEmpty)
  240. {
  241. if (wafer.ProcessState == Aitex.Core.Common.EnumWaferProcessStatus.Completed)
  242. {
  243. processedCount++;
  244. }
  245. else
  246. {
  247. unprocessCount++;
  248. }
  249. }
  250. }
  251. return (processedCount, unprocessCount);
  252. }
  253. private bool fnEnterTMReady(object[] param)
  254. {
  255. if (RouteManager.IsATMMode)
  256. {
  257. Status = LLStatus.Ready_For_TM;
  258. return true;
  259. }
  260. //StartControlPressure();
  261. Status = LLStatus.Ready_For_TM;
  262. return true;
  263. }
  264. private bool fnExitTMReady(object[] param)
  265. {
  266. if (RouteManager.IsATMMode)
  267. {
  268. Status = LLStatus.Not_Ready;
  269. return true;
  270. }
  271. //StopControlPressure();
  272. Status = LLStatus.Not_Ready;
  273. return true;
  274. }
  275. private bool fnEnterEFEMReady(object[] param)
  276. {
  277. Status = LLStatus.Ready_For_EFEM;
  278. return true;
  279. }
  280. private bool fnExitEFEMReady(object[] param)
  281. {
  282. Status = LLStatus.Not_Ready;
  283. return true;
  284. }
  285. private bool fnMonitor(object[] param)
  286. {
  287. _debugRoutine();
  288. return true;
  289. }
  290. private bool fnError(object[] param)
  291. {
  292. IsOnline = false;
  293. return true;
  294. }
  295. private bool fnOnline(object[] param)
  296. {
  297. if (!IsInclude)
  298. {
  299. LOG.Write(eEvent.WARN_LL, Module, $"{Module} is excluded,can not be put online");
  300. return false;
  301. }
  302. IsOnline = true;
  303. return true;
  304. }
  305. private bool fnOffline(object[] param)
  306. {
  307. IsOnline = false;
  308. return true;
  309. }
  310. private bool FnSetInclude()
  311. {
  312. if (IsOnline == true)
  313. {
  314. LOG.Write(eEvent.WARN_LL, Module, $"{Module} is online,can not set Include");
  315. return false;
  316. }
  317. IsInclude = true;
  318. LOG.Write(eEvent.INFO_LL, Module, $"{Module} Set Include Success");
  319. return true;
  320. }
  321. private bool FnSetExclude()
  322. {
  323. if (IsOnline == true)
  324. {
  325. LOG.Write(eEvent.WARN_LL, Module, $"{Module} is online,can not set Exclude");
  326. return false;
  327. }
  328. IsInclude = false;
  329. LOG.Write(eEvent.INFO_LL, Module, $"{Module} Set Exclude Success");
  330. return true;
  331. }
  332. private bool fnAbort(object[] param)
  333. {
  334. return true;
  335. }
  336. private bool fnHome(object[] param)
  337. {
  338. //IsOnline = true;
  339. return true;
  340. }
  341. private bool fnHoming(object[] param)
  342. {
  343. return true;
  344. }
  345. private bool FnStartVent(object[] param)
  346. {
  347. return _ventingRoutine.Start() == RState.Running;
  348. }
  349. private bool FnTryAutoVent(object[] param)
  350. {
  351. if (RouteManager.IsATMMode)
  352. {
  353. PostMsg(MSG.TM_Exchange_Ready);
  354. return false;
  355. }
  356. return _ventingRoutine.Start() == RState.Running;
  357. }
  358. private bool FnVentTimeout(object[] param)
  359. {
  360. RState ret = _ventingRoutine.Monitor();
  361. if (ret == RState.Failed || ret == RState.Timeout)
  362. {
  363. PostMsg(MSG.Error);
  364. return false;
  365. }
  366. if(ret == RState.End)
  367. {
  368. MarkStateTime();
  369. return true;
  370. }
  371. return false;
  372. }
  373. private bool FnAbortVent(object[] param)
  374. {
  375. _ventingRoutine.Abort();
  376. return true;
  377. }
  378. private bool FnStartPump(object[] param)
  379. {
  380. return _pumpingRoutine.Start() == RState.Running;
  381. }
  382. private bool FnPumpTimeout(object[] param)
  383. {
  384. RState ret = _pumpingRoutine.Monitor();
  385. if (ret == RState.Failed || ret == RState.Timeout)
  386. {
  387. PostMsg(MSG.Error);
  388. return false;
  389. }
  390. if (ret == RState.End)
  391. {
  392. MarkStateTime();
  393. return true;
  394. }
  395. return false;
  396. }
  397. private bool FnAbortPump(object[] param)
  398. {
  399. _pumpingRoutine.Abort();
  400. return true;
  401. }
  402. private bool FnTryAutoPump(object[] param)
  403. {
  404. if (_JetTM.LLPumpStatus != JetTM.LLPumpState.Idle || RouteManager.IsATMMode)
  405. {
  406. PostMsg(MSG.EFEM_Exchange_Ready);
  407. return false;
  408. }
  409. return _pumpingRoutine.Start() == RState.Running;
  410. }
  411. private bool FnStartPurge(object[] param)
  412. {
  413. return _purgeRoutine.Start() == RState.Running;
  414. }
  415. private bool FnPurgeTimeout(object[] param)
  416. {
  417. RState ret = _purgeRoutine.Monitor();
  418. if (ret == RState.Failed || ret == RState.Timeout)
  419. {
  420. PostMsg(MSG.Error);
  421. return false;
  422. }
  423. return ret == RState.End;
  424. }
  425. private bool FnAbortPurge(object[] param)
  426. {
  427. _purgeRoutine.Abort();
  428. return true;
  429. }
  430. private bool FnStartLeakCheck(object[] param)
  431. {
  432. return _leakCheckRoutine.Start() == RState.Running;
  433. }
  434. private bool FnLeakCheckTimeout(object[] param)
  435. {
  436. RState ret = _leakCheckRoutine.Monitor();
  437. if (ret == RState.Failed || ret == RState.Timeout)
  438. {
  439. PostMsg(MSG.Error);
  440. return false;
  441. }
  442. return ret == RState.End;
  443. }
  444. private bool FnAbortLeakCheck(object[] param)
  445. {
  446. _leakCheckRoutine.Abort();
  447. return true;
  448. }
  449. private bool FnStartPrepareTM(object[] param)
  450. {
  451. if (RouteManager.IsATMMode)
  452. return true;
  453. return _pumpingRoutine.Start() == RState.Running;
  454. }
  455. private bool FnPreparaTMTimeout(object[] param)
  456. {
  457. if (RouteManager.IsATMMode)
  458. {
  459. if (fsm.ElapsedTime > 10000)
  460. {
  461. LOG.Write(eEvent.ERR_TM, Module, $"Cannot transfer wafer as {Module} is not ATM.");
  462. PostMsg(MSG.Error);
  463. return true;
  464. }
  465. return _JetTM.IsModuleATM(Module);
  466. }
  467. RState ret = _pumpingRoutine.Monitor();
  468. if (ret == RState.Failed || ret == RState.Timeout)
  469. {
  470. PostMsg(MSG.Error);
  471. return false;
  472. }
  473. return ret == RState.End;
  474. }
  475. private bool FnAbortPreparaTM(object[] param)
  476. {
  477. _pumpingRoutine.Abort();
  478. return true;
  479. }
  480. private bool FnStartPrepareEFEM(object[] param)
  481. {
  482. if (RouteManager.IsATMMode)
  483. return true;
  484. return _ventingRoutine.Start() == RState.Running;
  485. }
  486. private bool FnPrepareEFEMTimeout(object[] param)
  487. {
  488. if (RouteManager.IsATMMode)
  489. {
  490. if (fsm.ElapsedTime > 10000)
  491. {
  492. LOG.Write(eEvent.ERR_TM, Module, $"Cannot transfer wafer as {Module} is not ATM.");
  493. PostMsg(MSG.Error);
  494. return true;
  495. }
  496. return _JetTM.IsModuleATM(Module);
  497. }
  498. RState ret = _ventingRoutine.Monitor();
  499. if (ret == RState.Failed || ret == RState.Timeout)
  500. {
  501. PostMsg(MSG.Error);
  502. return false;
  503. }
  504. return ret == RState.End;
  505. }
  506. private bool FnAbortPrepareEFEM(object[] param)
  507. {
  508. _ventingRoutine.Abort();
  509. return true;
  510. }
  511. private bool LLCoolingTimer_Elapsed(object[] param)
  512. {
  513. if ((int)fsm.PrevState == (int)STATE.Venting && !WaferManager.Instance.CheckWaferEmpty(Module))
  514. {
  515. }
  516. return true;
  517. }
  518. //private bool StartControlPressure()
  519. //{
  520. // //_isEnableControlPressure = true;
  521. // //_controlPressureCheckPoint = SC.GetValue<int>($"{Module}.ControlPressureCheckPoint");
  522. // //_controlPressureSetPoint = SC.GetValue<int>($"{Module}.ControlPressureSetPoint");
  523. // _controlFlowSetPoint = SC.GetValue<int>($"{Module}.{Module}_MFC1.DefaultSetPoint");
  524. // //_JetTM.TurnFastPumpValve(Module, true);
  525. // _JetTM.TurnSoftPumpValve(Module, true);
  526. // _JetTM.TurnPurgeValve(Module, true);
  527. // _JetTM.TurnN2Valve(true);
  528. // if (Module == ModuleName.LLA)
  529. // {
  530. // _JetTM.SwitchLLAPressureMode(true);
  531. // _JetTM.SetLLAPressure((int)_controlPressureSetPoint);
  532. // }
  533. // else if (Module == ModuleName.LLB)
  534. // {
  535. // _JetTM.SwitchLLBPressureMode(true);
  536. // _JetTM.SetLLBPressure((int)_controlPressureSetPoint);
  537. // }
  538. // return true;
  539. //}
  540. //private bool StopControlPressure()
  541. //{
  542. // _isEnableControlPressure = false;
  543. // //_JetTM.TurnFastPumpValve(Module, false);
  544. // _JetTM.TurnSoftPumpValve(Module, false);
  545. // _JetTM.TurnPurgeValve(Module, false);
  546. // //_JetTM.TurnN2Valve(false);
  547. // if (Module == ModuleName.LLA)
  548. // {
  549. // _JetTM.SwitchLLAPressureMode(false);
  550. // _JetTM.SetLLAPressure(0);
  551. // }
  552. // else if (Module == ModuleName.LLB)
  553. // {
  554. // _JetTM.SwitchLLBPressureMode(false);
  555. // _JetTM.SetLLBPressure(0);
  556. // }
  557. // return true;
  558. //}
  559. private void _debugRoutine()
  560. {
  561. int flag = 0;
  562. // Test Home routine
  563. if (flag == 1)
  564. {
  565. PostMsg(MSG.Home);
  566. }
  567. else if (flag == 2)
  568. {
  569. PostMsg(MSG.Vent);
  570. }
  571. else if (flag == 3)
  572. {
  573. PostMsg(MSG.Pump);
  574. }
  575. //else if (flag == 4)
  576. //{
  577. // PostMsg(MSG.PumpLoadLock);
  578. //}
  579. //else if (flag == 5)
  580. //{
  581. // PostMsg(MSG.VentLoadLock);
  582. //}
  583. //else if (flag == 6)
  584. //{
  585. // PostMsg(MSG.PurgeLoadLock);
  586. //}
  587. //else if (flag == 7)
  588. //{
  589. // PostMsg(MSG.LaunchPump);
  590. //}
  591. //else if (flag == 8)
  592. //{
  593. // PostMsg(MSG.LaunchTurboPump);
  594. //}
  595. //else if (flag == 9)
  596. //{
  597. // PostMsg(MSG.LoadLockLeakCheck);
  598. //}
  599. else if (flag == 10)
  600. {
  601. PostMsg(MSG.CyclePurge);
  602. }
  603. //else if (flag == 11)
  604. //{
  605. // PostMsg(MSG.GasLinePurge);
  606. //}
  607. //else if (flag == 12)
  608. //{
  609. // PostMsg(MSG.LeakCheck);
  610. //}
  611. //else if (flag == 13)
  612. //{
  613. // PostMsg(MSG.GasLeakCheck);
  614. //}
  615. //else if (flag == 14)
  616. //{
  617. // PostMsg(MSG.LLPlace);
  618. //}
  619. //else if (flag == 15)
  620. //{
  621. // PostMsg(MSG.LLPick);
  622. //}
  623. //else if (flag == 16)
  624. //{
  625. // PostMsg(MSG.RunRecipe, "7777");
  626. //}
  627. //else if (flag == 17)
  628. //{
  629. // PostMsg(MSG.MFCVerification, "MFC2", (double)50, 10);
  630. //}
  631. }
  632. }
  633. }