【修改修改预选模式、机器人驾驶代码】
This commit is contained in:
parent
df93f3d0ce
commit
04d46be14c
@ -573,10 +573,11 @@ public class ATPService {
|
||||
if (!train.isAtpOn()) {
|
||||
this.openAtp(train);
|
||||
}
|
||||
if ((train.isSignalEB() || preselectionMode.isMatchTheDriveMode(DriveMode.RM) )
|
||||
&& !train.isInTheGear(VirtualRealityTrain.Handwheel.MANUAL)) { //确保当前在手动档位
|
||||
changeGear(train, VirtualRealityTrain.Handwheel.MANUAL);
|
||||
}
|
||||
if (train.isSignalEB()) {
|
||||
if (!train.isInTheGear(VirtualRealityTrain.Handwheel.MANUAL)) {
|
||||
changeGear(train, VirtualRealityTrain.Handwheel.MANUAL);
|
||||
}
|
||||
if (!train.isStop() || !train.isLeverNotInTractionGear()) {
|
||||
changeTrainForce(train, -2F); // 改变列车的牵引/
|
||||
}
|
||||
|
@ -314,8 +314,9 @@ public class SimulationRobotService {
|
||||
*/
|
||||
private void robotDrive(Simulation simulation, SimulationMember driver, VirtualRealityTrain train, SectionPosition targetPosition) {
|
||||
if (!train.isInTheGear(VirtualRealityTrain.Handwheel.MANUAL)) { //确保当前在手动档位
|
||||
CommandBO.Step step = CommandBO.buildGearChangeStep(train.getGroupNumber(), VirtualRealityTrain.Handwheel.MANUAL);
|
||||
atsOperationDispatcher.execute(simulation, driver, step.getOperationType().name(), step.getOperationParams());
|
||||
return;
|
||||
// CommandBO.Step step = CommandBO.buildGearChangeStep(train.getGroupNumber(), VirtualRealityTrain.Handwheel.MANUAL);
|
||||
// atsOperationDispatcher.execute(simulation, driver, step.getOperationType().name(), step.getOperationParams());
|
||||
}
|
||||
if (train.isEB()) {
|
||||
if (train.getRobotDriveParam().isReleaseEB()) {
|
||||
|
Loading…
Reference in New Issue
Block a user