refactor: 将Framework库和RT、UI放在同一个解决方案中。
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
using Aitex.Core.RT.Routine;
|
||||
using Aitex.Core.RT.SCCore;
|
||||
|
||||
namespace SicModules.LLs.Routines
|
||||
{
|
||||
public class LoadLockLiftRoutine : LoadLockBaseRoutine
|
||||
{
|
||||
enum RoutineStep
|
||||
{
|
||||
LiftMove
|
||||
}
|
||||
|
||||
private bool _pinUp;
|
||||
private int _liftMoveTimeOut = 30;
|
||||
|
||||
|
||||
public LoadLockLiftRoutine()
|
||||
{
|
||||
Name = "Lift Move";
|
||||
}
|
||||
|
||||
public void Init(bool isUp)
|
||||
{
|
||||
_pinUp = isUp;
|
||||
}
|
||||
|
||||
public override Result Start(params object[] objs)
|
||||
{
|
||||
Reset();
|
||||
|
||||
_liftMoveTimeOut = SC.GetValue<int>("LoadLock.LiftMoveTimeOut");
|
||||
Notify("Start");
|
||||
return Result.RUN;
|
||||
}
|
||||
|
||||
|
||||
public override Result Monitor()
|
||||
{
|
||||
try
|
||||
{
|
||||
LiftMove((int)RoutineStep.LiftMove, _pinUp, _liftMoveTimeOut);
|
||||
}
|
||||
catch (RoutineBreakException)
|
||||
{
|
||||
return Result.RUN;
|
||||
}
|
||||
catch (RoutineFaildException)
|
||||
{
|
||||
return Result.FAIL;
|
||||
}
|
||||
|
||||
Notify("Finished");
|
||||
|
||||
return Result.DONE;
|
||||
}
|
||||
|
||||
public override void Abort()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user