private void Test_Click(object Sender, RoutedEventArgs E) { if (tabControl.SelectedIndex != 1) { return; } var paramGate = new Types.Gate.TestParameters { IsEnabled = false }; var paramBvt = new Types.BVT.TestParameters { IsEnabled = false }; var paramVtm = new Types.SL.TestParameters { IsEnabled = false }; var paramAtu = new Types.ATU.TestParameters { IsEnabled = false }; var paramQrrTq = new Types.QrrTq.TestParameters { IsEnabled = false }; var paramRAC = new Types.RAC.TestParameters { IsEnabled = false }; var paramIH = new Types.IH.TestParameters { IsEnabled = false }; var paramRCC = new Types.RCC.TestParameters { IsEnabled = false }; switch (tabControl.SelectedIndex) { case 1: paramVtm.IsEnabled = true; paramVtm.IsSelfTest = true; break; } var started = Cache.Net.Start(paramGate, paramVtm, paramBvt, paramAtu, paramQrrTq, paramRAC, paramIH, paramRCC, new Types.Commutation.TestParameters { BlockIndex = Types.Commutation.HWBlockIndex.Block1, CommutationType = Types.Commutation.HWModuleCommutationType.Direct, Position = Types.Commutation.HWModulePosition.Position1 }, new Types.Clamping.TestParameters { SkipClamping = true }, true); var stopped = Cache.Net.IsStopButtonPressed; if (stopped || !started) { return; } IsRunning = true; }
internal void Start() { if (IsRunning) { return; } var paramGate = new Types.Gate.TestParameters { IsEnabled = false }; var paramVtm = new Types.SL.TestParameters { IsEnabled = false }; var paramAtu = new Types.ATU.TestParameters { IsEnabled = false }; var paramQrrTq = new Types.QrrTq.TestParameters { IsEnabled = false }; var paramRAC = new Types.RAC.TestParameters { IsEnabled = false }; var paramIH = new Types.IH.TestParameters { IsEnabled = false }; var paramRCC = new Types.RCC.TestParameters { IsEnabled = false }; ClampParameters.SkipClamping = Cache.Clamp.ManualClamping; Parameters.VoltageFrequency = (ushort)Settings.Default.BVTVoltageFrequency; Parameters.MeasurementMode = Types.BVT.BVTMeasurementMode.ModeV; if (!Cache.Net.Start(paramGate, paramVtm, Parameters, paramAtu, paramQrrTq, paramRAC, paramIH, paramRCC, new Types.Commutation.TestParameters { BlockIndex = (!Cache.Clamp.clampPage.UseTmax) ? Types.Commutation.HWBlockIndex.Block1 : Types.Commutation.HWBlockIndex.Block2, CommutationType = ConverterUtil.MapCommutationType(CommType), Position = ConverterUtil.MapModulePosition(ModPosition) }, ClampParameters)) { return; } ClearStatus(); IsRunning = true; }
internal SLPage() { Parameters = new Types.SL.TestParameters { IsEnabled = true, UseLsqMethod = Settings.Default.UseVTMPostProcessing }; ClampParameters = new Types.Clamping.TestParameters { StandardForce = Types.Clamping.ClampingForceInternal.Custom, CustomForce = 5 }; CommType = Settings.Default.SinglePositionModuleMode ? Types.Commutation.ModuleCommutationType.Direct : Types.Commutation.ModuleCommutationType.MT3; InitializeComponent(); m_XGreen = (SolidColorBrush)FindResource("xGreen1"); m_XOrange = (SolidColorBrush)FindResource("xOrange1"); ClearStatus(); }
internal void Start() { if (IsRunning) { return; } var paramVtm = new Types.SL.TestParameters { IsEnabled = false }; var paramBvt = new Types.BVT.TestParameters { IsEnabled = false }; var paramAtu = new Types.ATU.TestParameters { IsEnabled = false }; var paramQrrTq = new Types.QrrTq.TestParameters { IsEnabled = false }; var paramRAC = new Types.RAC.TestParameters { IsEnabled = false }; var paramIH = new Types.IH.TestParameters { IsEnabled = false }; var paramRCC = new Types.RCC.TestParameters { IsEnabled = false }; ClampParameters.SkipClamping = Cache.Clamp.ManualClamping; if (!Cache.Net.Start(Parameters, paramVtm, paramBvt, paramAtu, paramQrrTq, paramRAC, paramIH, paramRCC, new Types.Commutation.TestParameters { BlockIndex = (!Cache.Clamp.clampPage.UseTmax) ? Types.Commutation.HWBlockIndex.Block1 : Types.Commutation.HWBlockIndex.Block2, CommutationType = ConverterUtil.MapCommutationType(CommType), Position = ConverterUtil.MapModulePosition(ModPosition) }, ClampParameters)) { return; } ClearStatus(); IsRunning = true; }