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

Skip to content
Snippets Groups Projects
Commit dd613c08 authored by Markus Quaritsch's avatar Markus Quaritsch
Browse files

driver: do not limit deceleration when disengaged; search for acceleration if...

driver: do not limit deceleration when disengaged; search for acceleration if negative braking power occurs
parent 67ffe069
No related branches found
No related tags found
No related merge requests found
......@@ -196,12 +196,9 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl
// search again for operating point, transmission may have shifted inbetween
nextOperatingPoint = SearchOperatingPoint(absTime, ds, gradient, operatingPoint.Acceleration,
response);
limitedOperatingPoint = LimitAccelerationByDriverModel(nextOperatingPoint,
LimitationMode.LimitDecelerationDriver);
DriverAcceleration = limitedOperatingPoint.Acceleration;
retVal = NextComponent.Request(absTime, limitedOperatingPoint.SimulationInterval,
limitedOperatingPoint.Acceleration,
gradient);
DriverAcceleration = nextOperatingPoint.Acceleration;
retVal = NextComponent.Request(absTime, nextOperatingPoint.SimulationInterval,
nextOperatingPoint.Acceleration, gradient);
} else {
if (absTime > 0 && DataBus.VehicleStopped) {
Log.Info(
......@@ -526,6 +523,11 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl
operatingPoint = SearchBrakingPower(absTime, operatingPoint.SimulationDistance, gradient,
operatingPoint.Acceleration, response);
DriverAcceleration = operatingPoint.Acceleration;
if (DataBus.BrakePower.IsSmaller(0)) {
DataBus.BrakePower = 0.SI<Watt>();
operatingPoint = SearchOperatingPoint(absTime, ds, gradient, 0.SI<MeterPerSquareSecond>(), r);
}
retVal = NextComponent.Request(absTime, operatingPoint.SimulationInterval,
operatingPoint.Acceleration, gradient);
} else {
......
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