public MainForm() { InitializeComponent(); m_obdInterface = new OBDInterface(); m_obdInterface.OnConnect += new OBDInterface.__Delegate_OnConnect(On_OBD_Connect); m_obdInterface.OnDisconnect += new OBDInterface.__Delegate_OnDisconnect(On_OBD_Disconnect); m_originFont = buttonDefaultFontStyle.Font; m_boldFont = new Font(m_originFont, FontStyle.Bold); StatusLabelConnStatus.ForeColor = Color.Red; StatusLabelConnStatus.Text = "OBD通讯接口未连接"; StatusLabelDeviceName.Text = "未获取到设备名"; StatusLabelAppProtocol.Text = "应用层协议待定"; StatusLabelCommProtocol.Text = m_obdInterface.GetProtocol().ToString(); StatusLabelDeviceType.Text = m_obdInterface.GetDevice().ToString(); if (m_obdInterface.CommSettings != null) { if (m_obdInterface.CommSettings.AutoDetect) { StatusLabelPort.Text = "自动探测"; } else { StatusLabelPort.Text = m_obdInterface.CommSettings.ComPortName; } } InitSubForm(); this.Text = "SH_OBD - Ver " + MainFileVersion.AssemblyVersion; }
public TrackForm(OBDInterface obd) { m_obdInterface = obd; timeslip = new Timeslip { Vehicle = m_obdInterface.ActiveProfile.Name }; InitializeComponent(); CheckConnection(); }
public TerminalForm(OBDInterface obd) { m_obdInterface = obd; InitializeComponent(); m_strPmt = "ELM > "; richText.SelectionFont = new Font("Microsoft Sans Serif", 9f, FontStyle.Regular); richText.SelectionColor = Color.Black; richText.AppendText(m_strPmt); }
public FuelEconomyForm(OBDInterface obd) { InitializeComponent(); m_obdInterface = obd; m_RunThread = true; IsWorking = false; this.sensorInstantFuelConsumption.SetDisplayMode(1); this.sensorAvgFuelConsumption.SetDisplayMode(1); this.sensorAvgFuelEconomy.SetDisplayMode(1); this.sensorInstantFuelEconomy.SetDisplayMode(1); this.sensorTotalConsumed.SetDisplayMode(1); this.sensorDistance.SetDisplayMode(1); this.sensorTotalCost.SetDisplayMode(1); this.sensorCostPerMile.SetDisplayMode(1); }
public SensorGridForm(OBDInterface obd2) { try { InitializeComponent(); m_obdInterface = obd2; IsLogging = false; btnStart.Enabled = false; btnReset.Enabled = false; btnSave.Enabled = false; IsRunThread = true; m_ListSensors = new List <OBDParameter>(); m_ListLog = new List <SensorLogItem>(); } catch (Exception ex) { MessageBox.Show(ex.ToString()); } }
public SensorChartForm(OBDInterface obd2) { m_obdInterface = obd2; InitializeComponent(); m_arraySensorValues = new List <DatedValue> [4]; for (int i = 0; i < m_arraySensorValues.Length; i++) { m_arraySensorValues[i] = new List <DatedValue>(); } m_dSensorMax = new double[4]; m_dSensorMin = new double[4]; dSensorValues = new double[4][]; dSensorTimes = new double[4][]; sensorsEnable = new bool[4]; sensorsIndex = new int[4]; unitsIndex = new int[4]; }
public TestForm(OBDInterface obd) { InitializeComponent(); m_obdInterface = obd; }
public VehicleForm(OBDInterface obd) { InitializeComponent(); m_obdInterface = obd; m_VehicleList = m_obdInterface.VehicleProfiles; }
public FreezeFramesForm(OBDInterface obd) { InitializeComponent(); m_obdInterface = obd; }
public DTCForm(OBDInterface obd2) { InitializeComponent(); m_obdInterface = obd2; CheckConnection(); }
public ReportGeneratorForm(OBDInterface obd2) { m_obdInterface = obd2; InitializeComponent(); }
public OxygenSensorsForm(OBDInterface obd2) { m_obdInterface = obd2; InitializeComponent(); }