diff --git a/Service/Execute/Step/CarPrepareState.cs b/Service/Execute/Step/CarPrepareState.cs index a358a61..70d714c 100644 --- a/Service/Execute/Step/CarPrepareState.cs +++ b/Service/Execute/Step/CarPrepareState.cs @@ -49,6 +49,14 @@ public class CarPrepareState : IState } + + ////调整车辆 + var adjustCarByRadar = AdjustCarByRadar(machine); + if (InvokeStatus.Done != adjustCarByRadar) + { + return SwappingStateMachine.ReturnWithInvokeErr(adjustCarByRadar, ExceptionReason.None); + } + //检查tbox链接状态 InvokeStatus checkTBoxConnect = CheckTBoxConnectFlag(machine); if (checkTBoxConnect != InvokeStatus.Done) @@ -83,14 +91,6 @@ public class CarPrepareState : IState _CommonMgr.SaveSwapBattery(machine); - - ////调整车辆 - var adjustCarByRadar = AdjustCarByRadar(machine); - if (InvokeStatus.Done != adjustCarByRadar) - { - return SwappingStateMachine.ReturnWithInvokeErr(adjustCarByRadar, ExceptionReason.None); - } - //车辆到位 InvokeStatus carInPosition = CarInPosition(machine); if (carInPosition != InvokeStatus.Done)