Ejemplo n.º 1
0
 public void CheckConnection()
 {
     if (m_obdInterface.ConnectedStatus)
     {
         if (!IsPlotting)
         {
             btnStart.Enabled = true;
         }
         comboSensor1.Items.Clear();
         comboSensor2.Items.Clear();
         comboSensor3.Items.Clear();
         comboSensor4.Items.Clear();
         foreach (OBDParameter obdParameter in m_obdInterface.SupportedParameterList(1))
         {
             comboSensor1.Items.Add(obdParameter);
             comboSensor2.Items.Add(obdParameter);
             comboSensor3.Items.Add(obdParameter);
             comboSensor4.Items.Add(obdParameter);
         }
     }
     else
     {
         IsPlotting       = false;
         btnStart.Enabled = false;
         comboSensor1.Items.Clear();
         comboSensor2.Items.Clear();
         comboSensor3.Items.Clear();
         comboSensor4.Items.Clear();
     }
 }
Ejemplo n.º 2
0
 public void CheckConnection()
 {
     if (m_obdInterface.ConnectedStatus)
     {
         groupDisplay.Enabled    = true;
         groupSelections.Enabled = true;
         groupLogging.Enabled    = true;
         if (IsLogging)
         {
             btnStart.Enabled = false;
             btnStart.Text    = Properties.Resources.btnStart_Name_Resume;
             btnReset.Enabled = true;
             btnSave.Enabled  = true;
         }
         else
         {
             btnStart.Enabled    = true;
             btnStart.Text       = Properties.Resources.btnStart_Name_Start;
             listSensors.Enabled = true;
             btnReset.Enabled    = false;
             btnSave.Enabled     = false;
         }
         listSensors.Items.Clear();
         foreach (OBDParameter obdParameter in m_obdInterface.SupportedParameterList(1))
         {
             listSensors.Items.Add(obdParameter);
         }
     }
     else
     {
         listSensors.Items.Clear();
         groupDisplay.Enabled    = false;
         groupSelections.Enabled = false;
         groupLogging.Enabled    = false;
     }
 }