Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit 0eea8104 authored by Markus QUARITSCH's avatar Markus QUARITSCH
Browse files

handle the case that a gearshift may occur for AT transmissions during coast...

handle the case that a gearshift may occur for AT transmissions during coast action. if this is the case, perform coast action once more.
parent 531e0427
No related branches found
No related tags found
No related merge requests found
......@@ -352,7 +352,16 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl
IterationStatistics.Increment(this, "Coast");
Log.Debug("DrivingAction Coast");
return CoastOrRollAction(absTime, ds, maxVelocity, gradient, false);
var gear = DataBus.Gear;
var tcLocked = DataBus.TCLocked;
var retVal = CoastOrRollAction(absTime, ds, maxVelocity, gradient, false);
var gearChanged = !(DataBus.Gear == gear && DataBus.TCLocked == tcLocked);
if (DataBus.GearboxType.AutomaticTransmission() && gearChanged && (retVal is ResponseOverload || retVal is ResponseUnderload)) {
Log.Debug("Gear changed after a valid operating point was found - re-try coasting!");
retVal = CoastOrRollAction(absTime, ds, maxVelocity, gradient, false);
}
return retVal;
}
/// <summary>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment