From 6304ad086feda61a42b2593accbda4badb574cb1 Mon Sep 17 00:00:00 2001 From: Markus Quaritsch <quaritsch@ivt.tugraz.at> Date: Tue, 17 Jan 2023 13:30:43 +0100 Subject: [PATCH] bugfix in PCC preprocessor for IEPCs with integrated axlegear (axlegeardata is null) (cherry picked from commit 571fe08157dae5a51420f32c6c7bfba0c322eb6e) --- .../Models/Simulation/Impl/PCCEcoRollEngineStopPreprocessor.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VectoCore/VectoCore/Models/Simulation/Impl/PCCEcoRollEngineStopPreprocessor.cs b/VectoCore/VectoCore/Models/Simulation/Impl/PCCEcoRollEngineStopPreprocessor.cs index 1b6c4c75fb..e75d98c02b 100644 --- a/VectoCore/VectoCore/Models/Simulation/Impl/PCCEcoRollEngineStopPreprocessor.cs +++ b/VectoCore/VectoCore/Models/Simulation/Impl/PCCEcoRollEngineStopPreprocessor.cs @@ -100,7 +100,7 @@ namespace TUGraz.VectoCore.Models.Simulation.Impl private GearshiftPosition FindLowestGearForSpeed(MeterPerSecond speed) { var data = Container.RunData; - var ratio = data.AxleGearData.AxleGear.Ratio * (data.AngledriveData?.Angledrive.Ratio ?? 1.0) / + var ratio = (data.AxleGearData?.AxleGear.Ratio ?? 1.0 ) * (data.AngledriveData?.Angledrive.Ratio ?? 1.0) / data.VehicleData.DynamicTyreRadius; var possible = new List<GearshiftPosition>(); foreach (var gear in data.GearboxData.GearList) { -- GitLab