Ejemplo n.º 1
0
 private async void Reset_OnClick(object sender, RoutedEventArgs e)
 {
     await PopupIfThrowsAsync(async() => {
         if (_serial == null)
         {
             throw new InvalidOperationException("Not connected");
         }
         await _serial.SendCommandAsync(BciCommand.Simple(BciCommand.General.RESET));
         txtInfo.Text += "Device reset\n";
         txtInfo.Text  = "";
         DataManager.Current.Stop();
     });
 }