Beispiel #1
0
 public new void Update()
 {
     if (!m_obdInterface.getConnectedStatus())
     {
         return;
     }
     PopulateO2Locations();
 }
Beispiel #2
0
 public void CheckConnection()
 {
     if (!m_obd2Interface.getConnectedStatus())
     {
         return;
     }
     UpdateTests();
 }
Beispiel #3
0
 public void CheckConnection()
 {
     if (m_obdInterface.getConnectedStatus())
     {
         groupSetup.Enabled   = true;
         groupControl.Enabled = true;
     }
     else
     {
         groupSetup.Enabled   = false;
         groupControl.Enabled = false;
     }
 }
Beispiel #4
0
 public void CheckConnection()
 {
     if (m_obdInterface.getConnectedStatus())
     {
         btnStage.Enabled = true;
         btnReset.Enabled = true;
     }
     else
     {
         btnStage.Enabled = false;
         btnReset.Enabled = false;
     }
 }
Beispiel #5
0
 private void btnSend_Click(object sender, EventArgs e)
 {
     richText.SelectionStart = richText.Text.Length;
     richText.Focus();
     if (!m_obdInterface.getConnectedStatus())
     {
         MessageBox.Show("A vehicle connection must first be established.", "Connection Required", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
     else
     {
         richText.SelectionFont  = new Font("Microsoft Sans Serif", 9f, FontStyle.Regular);
         richText.SelectionColor = Color.Blue;
         richText.AppendText(txtCommand.Text);
         richText.AppendText("\r\n\r\n");
         string text = m_obdInterface.getRawResponse(txtCommand.Text);
         richText.SelectionColor = Color.DarkMagenta;
         richText.SelectionFont  = new Font("Microsoft Sans Serif", 12f, FontStyle.Bold);
         richText.AppendText(text);
         richText.SelectionFont = new Font("Microsoft Sans Serif", 9f, FontStyle.Regular);
         richText.AppendText("\r\n\r\n");
         richText.SelectionFont  = new Font("Microsoft Sans Serif", 9f, FontStyle.Regular);
         richText.SelectionColor = Color.Black;
         if (string.Compare(m_strID, "") == 0)
         {
             richText.AppendText("ELM > ");
         }
         else
         {
             richText.AppendText(m_strID + " > ");
         }
     }
 }
Beispiel #6
0
 private void btnStart_Click(object sender, EventArgs e)
 {
     if (!m_obdInterface.getConnectedStatus())
     {
         MessageBox.Show("A vehicle connection must first be established.", "Connection Required", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
     else
     {
         DateTime now = DateTime.Now;
         m_dtDynoTime     = now;
         m_dVehicleWeight = m_profile.Weight;
         dyno.Label       = m_profile.Name + "\r\n" + m_dtDynoTime.ToString("g");
         btnStart.Enabled = false;
         btnReset.Enabled = true;
         btnOpen.Enabled  = false;
         m_bCapture       = true;
         ThreadPool.QueueUserWorkItem(new WaitCallback(Capture));
     }
 }
Beispiel #7
0
 public void CheckConnection()
 {
     if (m_obdInterface.getConnectedStatus())
     {
         groupDisplay.Enabled    = true;
         groupSelections.Enabled = true;
         groupLogging.Enabled    = true;
         if (bLogging)
         {
             btnStart.Enabled = false;
             btnStart.Text    = "R&esume";
             btnReset.Enabled = true;
             btnSave.Enabled  = true;
         }
         else
         {
             btnStart.Enabled    = true;
             btnStart.Text       = "S&tart";
             listSensors.Enabled = true;
             btnReset.Enabled    = false;
             btnSave.Enabled     = false;
         }
         listSensors.Items.Clear();
         IEnumerator enumerator = m_obdInterface.getSupportedParameterList(1).GetEnumerator();
         if (!enumerator.MoveNext())
         {
             return;
         }
         do
         {
             ((ListBox.ObjectCollection)listSensors.Items).Add(enumerator.Current);
         }while (enumerator.MoveNext());
     }
     else
     {
         listSensors.Items.Clear();
         groupDisplay.Enabled    = false;
         groupSelections.Enabled = false;
         groupLogging.Enabled    = false;
     }
 }
Beispiel #8
0
 private void btnRefresh_Click(object sender, EventArgs e)
 {
     if (!m_obdInterface.getConnectedStatus())
     {
         MessageBox.Show("A vehicle connection must first be established.", "Connection Required", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
         m_obdInterface.logItem("Error. Freeze Frame Form. Attempted to refresh without vehicle connection.");
     }
     else
     {
         btnRefresh.Enabled = false;
         btnCancel.Enabled  = true;
         m_bKeepReading     = true;
         m_iFrameNumber     = int.Parse(numFrame.Value.ToString());
         ThreadPool.QueueUserWorkItem(new WaitCallback(ReadFreezeFrameData));
     }
 }