Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS will be completely phased out by mid-2025. To see alternatives please check here

Skip to content
Snippets Groups Projects
Commit 5b25c025 authored by Harald Martini's avatar Harald Martini
Browse files

simulate pevs with AT as APTN

parent aedc2943
No related branches found
No related tags found
No related merge requests found
......@@ -449,7 +449,7 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter.HeavyLorry
public override GearboxData CreateGearboxData(IVehicleDeclarationInputData inputData, VectoRunData runData,
IShiftPolygonCalculator shiftPolygonCalc)
{
return _gearboxDataAdapter.CreateGearboxData(inputData, runData, shiftPolygonCalc, new[] { GearboxType.AMT });
return _gearboxDataAdapter.CreateGearboxData(inputData, runData, shiftPolygonCalc, SupportedGearboxTypes);
}
public override ShiftStrategyParameters CreateGearshiftData(double axleRatio, PerSecond engineIdlingSpeed, GearboxType gearboxType, int gearsCount)
......
......@@ -78,18 +78,17 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter.SimulationComponen
gearData.TorqueConverterShiftPolygon = shiftPolygon;
}
protected virtual void CreateATGearData(
IGearboxDeclarationInputData gearbox, uint i, GearData gearData,
protected virtual void CreateATGearData(GearboxType gearboxType, uint i, GearData gearData,
ShiftPolygon tcShiftPolygon, double gearDifferenceRatio, Dictionary<uint, GearData> gears,
VehicleCategory vehicleCategory)
{
if (gearbox.Type == GearboxType.ATPowerSplit && i == 0)
if (gearboxType == GearboxType.ATPowerSplit && i == 0)
{
// powersplit transmission: torque converter already contains ratio and losses
CretateTCFirstGearATPowerSplit(gearData, i, tcShiftPolygon);
}
if (gearbox.Type == GearboxType.ATSerial)
if (gearboxType == GearboxType.ATSerial)
{
if (i == 0)
{
......@@ -296,10 +295,17 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter.SimulationComponen
var retVal = SetCommonGearboxData(gearbox);
//if (adas != null && retVal.Type.AutomaticTransmission() && adas.EcoRoll != EcoRollType.None &&
// !adas.ATEcoRollReleaseLockupClutch.HasValue) {
// throw new VectoException("Input parameter ATEcoRollReleaseLockupClutch required for AT transmission");
//}
if (adas != null && retVal.Type.AutomaticTransmission() && adas.EcoRoll != EcoRollType.None &&
!adas.ATEcoRollReleaseLockupClutch.HasValue)
{
throw new VectoException("Input parameter ATEcoRollReleaseLockupClutch required for AT transmission");
}
if ((inputData.VehicleType == VectoSimulationJobType.BatteryElectricVehicle || inputData.VehicleType == VectoSimulationJobType.SerialHybridVehicle) &&
gearbox.Type.AutomaticTransmission())
{
// PEV with APT-S or APT-P transmission are simulated as APT-N
retVal.Type = GearboxType.APTN;
}
retVal.ATEcoRollReleaseLockupClutch =
adas != null && adas.EcoRoll != EcoRollType.None && retVal.Type.AutomaticTransmission()
......@@ -308,7 +314,7 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter.SimulationComponen
if (!supportedGearboxTypes.Contains(gearbox.Type))
{
throw new VectoSimulationException("Unsupported gearbox type: {0}!", retVal.Type);
throw new VectoSimulationException("Unsupported gearbox type: {0}!", gearbox.Type);
}
var gearsInput = FilterDisabledGears(inputData.TorqueLimits, gearbox); //gearbox.Gears;
......@@ -354,7 +360,7 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter.SimulationComponen
LossMap = lossMap,
};
CreateATGearData(gearbox, i, gearData, tcShiftPolygon, gearDifferenceRatio, gears,
CreateATGearData(retVal.Type, i, gearData, tcShiftPolygon, gearDifferenceRatio, gears,
runData.VehicleData.VehicleCategory);
gears.Add(i + 1, gearData);
}
......
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