修改连挂时的列车逻辑;
This commit is contained in:
parent
d7c5e7cd32
commit
f04cb9ae19
@ -624,6 +624,9 @@ public class VirtualRealityTrain extends VirtualRealityDevice {
|
||||
* 强制改变牵引制动力
|
||||
*/
|
||||
public void enforceUpdateTBForce(float fk, float fb) {
|
||||
if (linkTrain != null && linkTrain.isEB()) {
|
||||
return;
|
||||
}
|
||||
this.fk = fk;
|
||||
this.fb = fb;
|
||||
if (fk > 0) {
|
||||
|
@ -112,11 +112,14 @@ public class VRTrainRunningService {
|
||||
if (right == aTrain.isRight()) { //车头同向
|
||||
if (!aTrainTailPosition.isAheadOf(checkPosition, right) && !checkPosition.isAheadOf(aTrainHeadPosition, right)) {
|
||||
change = false;
|
||||
train.setSpeed(0);
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
if (!aTrainHeadPosition.isAheadOf(checkPosition, right) && !aTrainTailPosition.isAheadOf(checkPosition, right)) {
|
||||
change = false;
|
||||
train.setSpeed(0);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -108,6 +108,11 @@ public class ATPService {
|
||||
}
|
||||
case AM:
|
||||
case CM:{
|
||||
// 驾驶故障导致EB
|
||||
if (VirtualRealityTrain.Fault.DRIVE_FAULT.equals(train.getFault()) && !train.isEB()) {
|
||||
log.warn(train.debugStr() + "因驾驶故障EB");
|
||||
this.triggerSignalEB(train);
|
||||
}
|
||||
MovementAuthority ma = train.getMa();
|
||||
if (Objects.nonNull(ma)) { // 通信正常,移动授权可用
|
||||
// 获取移动授权剩余距离
|
||||
|
Loading…
Reference in New Issue
Block a user