|
@ -208,13 +208,12 @@ public class MatrixSprayStart extends BaseCommandHandler { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
if (j == 0) { |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
|
|
|
} |
|
|
|
|
|
if (j == pathList.size() - 1) { |
|
|
if (j == pathList.size() - 1) { |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
|
|
|
}else{ |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
} |
|
|
} |
|
|
deviceCommandList.add(deviceCommands); |
|
|
deviceCommandList.add(deviceCommands); |
|
|
} |
|
|
} |
|
@ -246,13 +245,12 @@ public class MatrixSprayStart extends BaseCommandHandler { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
if (j == 0) { |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
|
|
|
} |
|
|
|
|
|
if (j == pathList.size() - 1) { |
|
|
if (j == pathList.size() - 1) { |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
|
|
|
}else{ |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
} |
|
|
} |
|
|
deviceCommandList.add(deviceCommands); |
|
|
deviceCommandList.add(deviceCommands); |
|
|
} |
|
|
} |
|
@ -283,13 +281,12 @@ public class MatrixSprayStart extends BaseCommandHandler { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
if (j == 0) { |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
|
|
|
} |
|
|
|
|
|
if (j == pathList.size() - 1) { |
|
|
if (j == pathList.size() - 1) { |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
|
|
|
}else{ |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
} |
|
|
} |
|
|
deviceCommandList.add(deviceCommands); |
|
|
deviceCommandList.add(deviceCommands); |
|
|
} |
|
|
} |
|
@ -307,13 +304,12 @@ public class MatrixSprayStart extends BaseCommandHandler { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
for (int j = 0; j < pathList.size(); j++) { |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
PathGenerator.Points p = pathList.get(j); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
List<DeviceCommand> deviceCommands = new ArrayList<>(); |
|
|
if (j == 0) { |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
|
|
|
} |
|
|
|
|
|
if (j == pathList.size() - 1) { |
|
|
if (j == pathList.size() - 1) { |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), 20.0));//移动x轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), 20.0));//移动y轴 |
|
|
|
|
|
}else{ |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorXPositionSet(p.getX(), movingSpeed));//移动x轴 |
|
|
|
|
|
deviceCommands.add(DeviceCommandGenerator.motorYPositionSet(75.5 - p.getY(), movingSpeed));//移动y轴 |
|
|
} |
|
|
} |
|
|
deviceCommandList.add(deviceCommands); |
|
|
deviceCommandList.add(deviceCommands); |
|
|
} |
|
|
} |
|
|