FutureEfem3P.cs 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. using System;
  2. using System.Xml;
  3. using Aitex.Core.Common;
  4. using Aitex.Core.RT.DataCenter;
  5. using Aitex.Core.RT.Event;
  6. using Aitex.Core.RT.OperationCenter;
  7. using Aitex.Core.RT.Routine;
  8. using Aitex.Core.RT.SCCore;
  9. using Aitex.Sorter.Common;
  10. using MECF.Framework.Common.Equipment;
  11. using MECF.Framework.Common.Event;
  12. using MECF.Framework.Common.SubstrateTrackings;
  13. using MECF.Framework.RT.EquipmentLibrary.HardwareUnits.Efems.Rorzes;
  14. namespace JetEfemLib
  15. {
  16. public class FutureEfem3P : FutureEfemBase
  17. {
  18. public FutureEfem3P(string module, XmlElement node, string ioModule = "") : base(module, node, ioModule)
  19. {
  20. }
  21. public FutureEfem3P() : base("System", "EFEM")
  22. {
  23. }
  24. public override bool GetWafer(ModuleName chamber, int slot, Hand hand, out string reason)
  25. {
  26. if (Connection == null || !Connection.IsConnected || !IsInitialized)
  27. {
  28. reason = "not connected";
  29. return false;
  30. }
  31. WaferSize ws = WaferManager.Instance.GetWaferSize(chamber, slot);
  32. return Connection.Execute(new RorzeEfemHandlerLoad(this, chamber, slot, hand, ws), out reason);
  33. }
  34. public override bool PutWafer(ModuleName chamber, int slot, Hand hand, out string reason)
  35. {
  36. if (Connection == null || !Connection.IsConnected || !IsInitialized)
  37. {
  38. reason = "not connected";
  39. return false;
  40. }
  41. WaferSize ws = WaferManager.Instance.GetWaferSize(ModuleName.EfemRobot, (int)hand);
  42. return Connection.Execute(new RorzeEfemHandlerUnload(this, chamber, slot, hand, ws), out reason);
  43. }
  44. public override void NoteStateEvent(ModuleName module, string data1, string data2)
  45. {
  46. if (module == ModuleName.System)
  47. {
  48. uint result1 = Convert.ToUInt32(data1, 16);
  49. uint result2 = Convert.ToUInt32(data2, 16);
  50. _stateFfuAlarm = !((result1 & 0x00000001u) == 0x00000001u);
  51. if (_stateFfuAlarm)
  52. FfuAlarm.Set();
  53. _stateIonizerAlarm = !((result1 & 0x00000002u) == 0x00000002u);
  54. if (_stateIonizerAlarm)
  55. IonizerAlarm.Set();
  56. _stateAirErrorForRobot = !((result1 & 0x00000004u) == 0x00000004u);
  57. if (_stateAirErrorForRobot)
  58. AirErrorForRobot.Set();
  59. //_stateAirErrorForChamber = !((result1 & 0x00000008u) == 0x00000008u);
  60. //if (_stateAirErrorForChamber)
  61. // AirErrorForChamber.Set();
  62. _stateIsMaintain = !((result1 & 0x00000010u) == 0x00000010u);
  63. if (_stateIsMaintain)
  64. IsMaintain.Set();
  65. _stateDoorOpen = !((result1 & 0x00000020u) == 0x00000020u);
  66. if (_stateDoorOpen)
  67. DoorOpen.Set();
  68. _stateEmoAlarm = (result1 & 0x00000040u) == 0x00000040u;
  69. if (_stateEmoAlarm)
  70. EmoAlarm.Set();
  71. return;
  72. }
  73. base.NoteStateEvent(module, data1, data2);
  74. }
  75. }
  76. }