diff --git a/VectoCore/VectoCore/Models/SimulationComponent/Impl/StopStartCombustionEngine.cs b/VectoCore/VectoCore/Models/SimulationComponent/Impl/StopStartCombustionEngine.cs index 767422c91aa53f0880cf6065c23500d7ca7827a2..5825c20600adfcac8d035678aa7089fac5e4cad9 100644 --- a/VectoCore/VectoCore/Models/SimulationComponent/Impl/StopStartCombustionEngine.cs +++ b/VectoCore/VectoCore/Models/SimulationComponent/Impl/StopStartCombustionEngine.cs @@ -84,7 +84,10 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl //throw new VectoSimulationException("Combustion engine cannot supply outtorque when switched off (T_out: {0})", outTorque); } CurrentState.EngineOn = false; - CurrentState.EngineSpeed = DataBus.VehicleInfo.VehicleStopped || outAngularVelocity.IsEqual(0) ? ModelData.IdleSpeed : outAngularVelocity; //ModelData.IdleSpeed; + CurrentState.EngineSpeed = DataBus.VehicleInfo.VehicleStopped || outAngularVelocity.IsEqual(0) + ? ModelData.IdleSpeed + : VectoMath.Max(outAngularVelocity, ModelData.IdleSpeed); + CurrentState.EngineTorque = 0.SI<NewtonMeter>(); CurrentState.EngineTorqueOut = 0.SI<NewtonMeter>(); CurrentState.EnginePower = 0.SI<Watt>();