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

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

adapt configuration for generated images of PCC use cases

parent 63d498cb
No related branches found
No related tags found
No related merge requests found
......@@ -43,13 +43,14 @@ namespace TUGraz.VectoCore.Tests.Integration.ADAS
//#else
//GraphWriter.Disable();
//#endif
GraphWriter.Xfields = new[] { ModalResultField.time, ModalResultField.dist };
GraphWriter.Xfields = new[] { ModalResultField.dist };
GraphWriter.Yfields = new[] {
ModalResultField.v_act, ModalResultField.acc, ModalResultField.n_eng_avg, ModalResultField.Gear,
ModalResultField.P_eng_out, ModalResultField.P_eng_drag, ModalResultField.FCMap
ModalResultField.v_act, ModalResultField.altitude, ModalResultField.acc, ModalResultField.Gear,
ModalResultField.P_eng_out, ModalResultField.FCMap
};
GraphWriter.Series1Label = "EcoRoll";
GraphWriter.Series1Label = "ADAS PCC";
GraphWriter.PlotIgnitionState = true;
}
......
......@@ -65,6 +65,8 @@ namespace TUGraz.VectoCore.Tests.Utils
public static bool PlotDrivingMode = false;
public static bool PlotIgnitionState = false;
public static void Enable()
{
_enabled = true;
......@@ -119,7 +121,11 @@ namespace TUGraz.VectoCore.Tests.Utils
if (yfield == ModalResultField.v_act) {
var y3 = LoadData(modDataV3, ModalResultField.v_targ.GetName());
var series3 = CreateSeries("v_target", legend, chartArea, chart, Color.Green, x, y3);
}
if ((Yfields.Contains(ModalResultField.altitude) && yfield == ModalResultField.altitude) ||
(!Yfields.Contains(ModalResultField.altitude) && yfield == ModalResultField.v_act)) {
var grad = LoadData(modDataV3, ModalResultField.grad.GetName());
chartArea.AxisY2.Enabled = AxisEnabled.True;
......@@ -167,6 +173,20 @@ namespace TUGraz.VectoCore.Tests.Utils
//seriesAction.YAxisType = AxisType;
}
}
if (PlotIgnitionState && yfield == ModalResultField.P_eng_out) {
var ignition = LoadData(modDataV3, ModalResultField.IgnitionOn.GetName());
chartArea.AxisY2.Enabled = AxisEnabled.True;
chartArea.AxisY2.Title = "Engine On [0/1]";
chartArea.AxisY2.TitleFont = AxisTitleFont;
chartArea.AxisY2.LabelStyle.Font = AxisLabelFont;
chartArea.AxisY2.LabelAutoFitStyle = LabelAutoFitStyles.None;
chartArea.AxisY2.MinorGrid.Enabled = false;
chartArea.AxisY2.MajorGrid.Enabled = false;
var seriesIgnition = CreateSeries("Engine On", legend, chartArea, chart, Color.Crimson, x, ignition);
seriesIgnition.YAxisType = AxisType.Secondary;
}
var series1 = CreateSeries(string.Format("{1} - {0}", yfield, Series1Label), legend, chartArea, chart,
Color.Blue, x, y);
......
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