public void startAVT() { this.WriteSerialData(OBD.AVTRestart(), true); Thread.Sleep(200); this.WriteSerialData(OBD.AVTID(), true); this.searchforframe = "ID_AVT"; this.consolemessage("Connecting to AVT, please wait..."); }
public void Disconnect_Click(object sender, RoutedEventArgs e) { this.breakresponse.Stop(); this.autorespond.Stop(); if (!this.UserProgStart.IsEnabled) { this.WriteSerialData(OBD.ResetPCM(), false); Thread.Sleep(100); } this.WriteSerialData(OBD.AVTRestart(), true); MainWindow._serialPort.Close(); this.resetoptions(); this.consolemessage("Serial port closed"); }