diff --git a/src/main/java/com/qyft/ms/app/front/cmd/test/MoveTestCommand.java b/src/main/java/com/qyft/ms/app/front/cmd/business/MoveTestCommand.java similarity index 88% rename from src/main/java/com/qyft/ms/app/front/cmd/test/MoveTestCommand.java rename to src/main/java/com/qyft/ms/app/front/cmd/business/MoveTestCommand.java index 2dcca47..bfee72b 100644 --- a/src/main/java/com/qyft/ms/app/front/cmd/test/MoveTestCommand.java +++ b/src/main/java/com/qyft/ms/app/front/cmd/business/MoveTestCommand.java @@ -1,4 +1,4 @@ -package com.qyft.ms.app.front.cmd.test; +package com.qyft.ms.app.front.cmd.business; import com.qyft.ms.app.core.SelfMoveTestGenerator; import com.qyft.ms.app.device.status.DeviceStatus; @@ -34,7 +34,7 @@ public class MoveTestCommand extends BaseCommandHandler { try { //deviceSensorService.collectSensorState();//收集传感器转态 webSocketService.pushSelfMoveTest(SelfMoveTestGenerator.generateJson(form.getCmdId(), form.getCmdCode(), "1、各项传感器正常", 25, "success")); - DeviceCommand motorXPositionSetCommand = DeviceCommandGenerator.motorXPositionSet(200.0); //移动到200mm处 + DeviceCommand motorXPositionSetCommand = DeviceCommandGenerator.motorXPositionSet(200.0, 20.0); //移动到200mm处 CommandFuture motorXPositionSetCommandFuture = deviceCommandService.sendCommand(form.getCmdId(), form.getCmdCode(), motorXPositionSetCommand); commandWait(motorXPositionSetCommandFuture); @@ -44,8 +44,8 @@ public class MoveTestCommand extends BaseCommandHandler { webSocketService.pushSelfMoveTest(SelfMoveTestGenerator.generateJson(form.getCmdId(), form.getCmdCode(), "2、x轴电机检测完毕", 50, "success")); - DeviceCommand motorYPositionSetCommand = DeviceCommandGenerator.motorYPositionSet(100.0);//y轴移动100mm - CommandFuture motorYPositionSetCommandFuture = deviceCommandService.sendCommand(form.getCmdId(), form.getCmdCode(), motorYPositionSetCommand); + DeviceCommand motorYPositionSetCommand = DeviceCommandGenerator.motorYPositionSet(100.0, 20.0);//y轴移动100mm + CommandFuture motorYPositionSetCommandFuture = deviceCommandService.sendCommand(form.getCmdId(), form.getCmdCode(), motorYPositionSetCommand); commandWait(motorYPositionSetCommandFuture); DeviceCommand motorYOriginCommand = DeviceCommandGenerator.motorYOrigin();//y轴回原点 @@ -53,7 +53,7 @@ public class MoveTestCommand extends BaseCommandHandler { commandWait(motorYOriginCommandFuture); webSocketService.pushSelfMoveTest(SelfMoveTestGenerator.generateJson(form.getCmdId(), form.getCmdCode(), "3、y轴电机检测完毕", 75, "success")); - DeviceCommand motorZPositionCommand = DeviceCommandGenerator.motorZPositionSet(50.0);//z轴50mm处 + DeviceCommand motorZPositionCommand = DeviceCommandGenerator.motorZPositionSet(50.0, 20.0);//z轴50mm处 CommandFuture motorZPositionCommandFuture = deviceCommandService.sendCommand(form.getCmdId(), form.getCmdCode(), motorZPositionCommand); commandWait(motorZPositionCommandFuture); @@ -62,7 +62,7 @@ public class MoveTestCommand extends BaseCommandHandler { commandWait(motorZOriginCommandFuture); webSocketService.pushSelfMoveTest(SelfMoveTestGenerator.generateJson(form.getCmdId(), form.getCmdCode(), "4、z轴电机检测完毕", 100, "success")); } finally { - // deviceStatus.setSelfTestCompleted(true); + // deviceStatus.setSelfTestCompleted(true); } }); }