取消站台轨默认限速;列车在计轴故障区域不恢复通信
This commit is contained in:
parent
00c12177e2
commit
1e31cd0971
@ -976,8 +976,6 @@ public class Section extends MayOutOfOrderDevice {
|
||||
return this.getSpeedUpLimit() / 3.6f;
|
||||
} else if (this.isSwitchTrack() && this.getRelSwitch().isReversePosition()) {
|
||||
return 30 / 3.6f;
|
||||
} else if (this.isStandTrack()) {
|
||||
return 44 / 3.6f;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
@ -428,6 +428,10 @@ public class VirtualRealityTrain extends VirtualRealityDevice {
|
||||
*/
|
||||
private boolean released;
|
||||
|
||||
public SectionPosition getTailPosition() {
|
||||
return this.tailPosition == null ? calculateTailPosition() : this.tailPosition;
|
||||
}
|
||||
|
||||
public void setCommunication(boolean communication) {
|
||||
if ((Fault.COMMUNICATION_ABNORMAL.equals(this.fault) || !atpOn || this.noCommunicateDevice) && communication)
|
||||
return;
|
||||
|
@ -235,8 +235,16 @@ public class ATPLogicLoop {
|
||||
private void driveModeControl(Simulation simulation, VirtualRealityTrain train) {
|
||||
DriveMode preDriveMode = train.getPreDriveMode();
|
||||
DriveMode driveMode = train.getDriveMode();
|
||||
SectionPosition headPosition = train.getHeadPosition();
|
||||
SectionPosition tailPosition = train.getTailPosition();
|
||||
switch (preDriveMode) {
|
||||
case AM:
|
||||
if (Section.AxleFault.FAULT.equals(headPosition.getSection().getFault())) {
|
||||
break;
|
||||
}
|
||||
if (Section.AxleFault.FAULT.equals(tailPosition.getSection().getFault())) {
|
||||
break;
|
||||
}
|
||||
train.setCommunication(true); //恢复列车通信
|
||||
if (!Objects.equals(driveMode, preDriveMode)) {
|
||||
if (train.isCMMode() && train.isAtoOn()) {
|
||||
@ -245,6 +253,12 @@ public class ATPLogicLoop {
|
||||
}
|
||||
break;
|
||||
case CM:
|
||||
if (Section.AxleFault.FAULT.equals(headPosition.getSection().getFault())) {
|
||||
break;
|
||||
}
|
||||
if (Section.AxleFault.FAULT.equals(tailPosition.getSection().getFault())) {
|
||||
break;
|
||||
}
|
||||
train.setCommunication(true); //恢复列车通信
|
||||
if (!Objects.equals(driveMode, preDriveMode)) {
|
||||
atoService.closeATO(train);
|
||||
|
Loading…
Reference in New Issue
Block a user