BufferModuleBase.cs 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Diagnostics;
  4. using System.Linq;
  5. using System.Threading;
  6. using Aitex.Core.RT.Device;
  7. using Aitex.Core.RT.Event;
  8. using Aitex.Core.RT.Fsm;
  9. using Aitex.Core.RT.Log;
  10. using Aitex.Core.RT.Routine;
  11. using Aitex.Core.RT.SCCore;
  12. using Aitex.Sorter.Common;
  13. using MECF.Framework.Common.Equipment;
  14. using MECF.Framework.Common.Schedulers;
  15. using MECF.Framework.Common.SubstrateTrackings;
  16. using MECF.Framework.RT.EquipmentLibrary.LogicUnits;
  17. using MECF.Framework.RT.ModuleLibrary.Commons;
  18. namespace MECF.Framework.RT.ModuleLibrary.BufferModules
  19. {
  20. public abstract class BufferModuleBase : ModuleFsmDevice, ITransferTarget, IModuleDevice
  21. {
  22. private int _slot = 1;
  23. public BufferModuleBase(int slot)
  24. {
  25. _slot = slot;
  26. }
  27. public override bool Initialize()
  28. {
  29. WaferManager.Instance.SubscribeLocation(Module, _slot);
  30. return base.Initialize();
  31. }
  32. //IModuleDevice
  33. public abstract bool IsReady { get; }
  34. public abstract bool IsError { get; }
  35. public abstract bool IsInit { get; }
  36. public abstract bool Home(out string reason);
  37. //Transfer
  38. public abstract bool PrepareTransfer(ModuleName robot, Hand blade, int[] targetSlot, EnumTransferType transferType, out string reason);
  39. public abstract bool TransferHandoff(ModuleName robot, Hand blade, int[] targetSlot, EnumTransferType transferType, out string reason);
  40. public abstract bool PostTransfer(ModuleName robot, Hand blade, int[] targetSlot, EnumTransferType transferType, out string reason);
  41. public abstract bool CheckReadyForTransfer(ModuleName robot, Hand blade, int targetSlot, EnumTransferType transferType, out string reason);
  42. public abstract void NoteTransferStart(ModuleName robot, Hand blade, int targetSlot, EnumTransferType transferType);
  43. public abstract void NoteTransferStop(ModuleName robot, Hand blade, int targetSlot, EnumTransferType transferType);
  44. }
  45. }